return 0; out:
destory_tgt: stgt_target_destroy(target->stt); free_target:
static int iscsi_target_create(struct target_info *info){	int err = -EINVAL;	struct iscsi_target *target;	if (!(target = kmalloc(sizeof(*target), GFP_KERNEL))) {		err = -ENOMEM;		goto out;	}	memset(target, 0, sizeof(*target));	memcpy(&target->sess_param, &default_session_param, sizeof(default_session_param));	memcpy(&target->trgt_param, &default_target_param, sizeof(default_target_param));	init_MUTEX(&target->target_sem);	INIT_LIST_HEAD(&target->session_list);	list_add(&target->t_list, &target_list);	nthread_init(target);	if ((err = target_thread_start(target)) < 0) {		target_thread_stop(target);		goto out;	}	target->stt = stgt_target_create("iet", DEFAULT_NR_QUEUED_CMNDS);	target->tid = info->tid = target->stt->tid;	return 0;out:	kfree(target);	return err;}