case SHOST_CANCEL_RECOVERY: switch (oldstate) { case SHOST_CANCEL: case SHOST_RECOVERY: break; default: goto illegal; } break;  case SHOST_DEL_RECOVERY: switch (oldstate) { case SHOST_CANCEL_RECOVERY: break; default: goto illegal; } break; 
int scsi_host_set_state(struct Scsi_Host *shost, enum scsi_host_state state){	enum scsi_host_state oldstate = shost->shost_state;	if (state == oldstate)		return 0;	switch (state) {	case SHOST_CREATED:		/* There are no legal states that come back to		 * created.  This is the manually initialised start		 * state */		goto illegal;	case SHOST_RUNNING:		switch (oldstate) {		case SHOST_CREATED:		case SHOST_RECOVERY:			break;		default:			goto illegal;		}		break;	case SHOST_RECOVERY:		switch (oldstate) {		case SHOST_RUNNING:			break;		default:			goto illegal;		}		break;	case SHOST_CANCEL:		switch (oldstate) {		case SHOST_CREATED:		case SHOST_RUNNING:			break;		default:			goto illegal;		}		break;	case SHOST_DEL:		switch (oldstate) {		case SHOST_CANCEL:			break;		default:			goto illegal;		}		break;	}	shost->shost_state = state;	return 0; illegal:	SCSI_LOG_ERROR_RECOVERY(1,				dev_printk(KERN_ERR, &shost->shost_gendev,					   "Illegal host state transition"					   "%s->%s\n",					   scsi_host_state_name(oldstate),					   scsi_host_state_name(state)));	return -EINVAL;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/939647ee308e0ad924e776657704c7bedd498664/hosts.c/buggy/drivers/scsi/hosts.c