Revision 3ccd6e83df8a0d4a664edeecc453c4fa046395fb authored by Nicholas Bellinger on 13 September 2015, 09:30:46 UTC, committed by Nicholas Bellinger on 25 September 2015, 06:17:07 UTC
This patch fixes a v4.2+ regression introduced by commit 79dc9c9e86 where lookup of t10_pr_registration->pr_reg_deve and associated ->pr_kref get was missing from __core_scsi3_do_alloc_registration(), which is responsible for setting DEF_PR_REG_ACTIVE. This would result in REGISTER operations completing successfully, but subsequent core_scsi3_pr_seq_non_holder() checking would fail with !DEF_PR_REG_ACTIVE -> RESERVATION CONFLICT status. Update __core_scsi3_add_registration() to drop ->pr_kref reference after registration and any optional ALL_TG_PT=1 processing has completed. Update core_scsi3_decode_spec_i_port() to release the new parent local_pr_reg->pr_kref as well. Also, update __core_scsi3_check_aptpl_registration() to perform the same target_nacl_find_deve() lookup + ->pr_kref get, now that __core_scsi3_add_registration() expects to drop the reference. Finally, since there are cases when se_dev_entry->se_lun_acl can still be dereferenced in core_scsi3_lunacl_undepend_item() while holding ->pr_kref, go ahead and move explicit rcu_assign_pointer() NULL assignments within core_disable_device_list_for_node() until after orig->pr_comp finishes. Reported-by: Scott L. Lykens <scott@lykens.org> Tested-by: Scott L. Lykens <scott@lykens.org> Cc: Christoph Hellwig <hch@lst.de> Cc: Hannes Reinecke <hare@suse.de> Cc: Lee Duncan <lduncan@suse.com> Cc: <stable@vger.kernel.org> # v4.2+ Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
1 parent 9fd6008
File | Mode | Size |
---|---|---|
bpf | ||
configs | ||
debug | ||
events | ||
gcov | ||
irq | ||
livepatch | ||
locking | ||
power | ||
printk | ||
rcu | ||
sched | ||
time | ||
trace | ||
.gitignore | -rw-r--r-- | 91 bytes |
Kconfig.freezer | -rw-r--r-- | 52 bytes |
Kconfig.hz | -rw-r--r-- | 1.6 KB |
Kconfig.locks | -rw-r--r-- | 4.8 KB |
Kconfig.preempt | -rw-r--r-- | 2.1 KB |
Makefile | -rw-r--r-- | 3.8 KB |
acct.c | -rw-r--r-- | 15.4 KB |
async.c | -rw-r--r-- | 9.9 KB |
audit.c | -rw-r--r-- | 52.7 KB |
audit.h | -rw-r--r-- | 10.9 KB |
audit_fsnotify.c | -rw-r--r-- | 6.1 KB |
audit_tree.c | -rw-r--r-- | 22.7 KB |
audit_watch.c | -rw-r--r-- | 14.4 KB |
auditfilter.c | -rw-r--r-- | 34.7 KB |
auditsc.c | -rw-r--r-- | 64.0 KB |
backtracetest.c | -rw-r--r-- | 2.1 KB |
bounds.c | -rw-r--r-- | 703 bytes |
capability.c | -rw-r--r-- | 12.1 KB |
cgroup.c | -rw-r--r-- | 153.1 KB |
cgroup_freezer.c | -rw-r--r-- | 12.5 KB |
cgroup_pids.c | -rw-r--r-- | 8.9 KB |
compat.c | -rw-r--r-- | 29.5 KB |
configs.c | -rw-r--r-- | 2.8 KB |
context_tracking.c | -rw-r--r-- | 6.4 KB |
cpu.c | -rw-r--r-- | 20.4 KB |
cpu_pm.c | -rw-r--r-- | 6.5 KB |
cpuset.c | -rw-r--r-- | 75.2 KB |
crash_dump.c | -rw-r--r-- | 1.3 KB |
cred.c | -rw-r--r-- | 21.4 KB |
delayacct.c | -rw-r--r-- | 4.5 KB |
dma.c | -rw-r--r-- | 3.6 KB |
elfcore.c | -rw-r--r-- | 396 bytes |
exec_domain.c | -rw-r--r-- | 1.4 KB |
exit.c | -rw-r--r-- | 41.5 KB |
extable.c | -rw-r--r-- | 4.0 KB |
fork.c | -rw-r--r-- | 50.8 KB |
freezer.c | -rw-r--r-- | 4.4 KB |
futex.c | -rw-r--r-- | 84.3 KB |
futex_compat.c | -rw-r--r-- | 4.5 KB |
groups.c | -rw-r--r-- | 5.9 KB |
hung_task.c | -rw-r--r-- | 5.7 KB |
irq_work.c | -rw-r--r-- | 4.5 KB |
jump_label.c | -rw-r--r-- | 12.6 KB |
kallsyms.c | -rw-r--r-- | 14.9 KB |
kcmp.c | -rw-r--r-- | 4.3 KB |
kexec.c | -rw-r--r-- | 6.6 KB |
kexec_core.c | -rw-r--r-- | 37.9 KB |
kexec_file.c | -rw-r--r-- | 24.9 KB |
kexec_internal.h | -rw-r--r-- | 789 bytes |
kmod.c | -rw-r--r-- | 18.9 KB |
kprobes.c | -rw-r--r-- | 60.7 KB |
ksysfs.c | -rw-r--r-- | 5.6 KB |
kthread.c | -rw-r--r-- | 19.2 KB |
latencytop.c | -rw-r--r-- | 7.6 KB |
membarrier.c | -rw-r--r-- | 2.4 KB |
memremap.c | -rw-r--r-- | 5.1 KB |
module-internal.h | -rw-r--r-- | 458 bytes |
module.c | -rw-r--r-- | 102.3 KB |
module_signing.c | -rw-r--r-- | 2.0 KB |
notifier.c | -rw-r--r-- | 16.3 KB |
nsproxy.c | -rw-r--r-- | 6.0 KB |
padata.c | -rw-r--r-- | 26.8 KB |
panic.c | -rw-r--r-- | 12.5 KB |
params.c | -rw-r--r-- | 24.1 KB |
pid.c | -rw-r--r-- | 15.0 KB |
pid_namespace.c | -rw-r--r-- | 10.0 KB |
profile.c | -rw-r--r-- | 16.1 KB |
ptrace.c | -rw-r--r-- | 30.5 KB |
range.c | -rw-r--r-- | 3.0 KB |
reboot.c | -rw-r--r-- | 13.3 KB |
relay.c | -rw-r--r-- | 32.5 KB |
resource.c | -rw-r--r-- | 37.0 KB |
seccomp.c | -rw-r--r-- | 23.2 KB |
signal.c | -rw-r--r-- | 95.3 KB |
smp.c | -rw-r--r-- | 19.9 KB |
smpboot.c | -rw-r--r-- | 13.2 KB |
smpboot.h | -rw-r--r-- | 564 bytes |
softirq.c | -rw-r--r-- | 18.9 KB |
stacktrace.c | -rw-r--r-- | 1.7 KB |
stop_machine.c | -rw-r--r-- | 16.2 KB |
sys.c | -rw-r--r-- | 57.5 KB |
sys_ni.c | -rw-r--r-- | 6.9 KB |
sysctl.c | -rw-r--r-- | 63.5 KB |
sysctl_binary.c | -rw-r--r-- | 51.0 KB |
task_work.c | -rw-r--r-- | 3.2 KB |
taskstats.c | -rw-r--r-- | 16.1 KB |
test_kprobes.c | -rw-r--r-- | 7.4 KB |
torture.c | -rw-r--r-- | 19.8 KB |
tracepoint.c | -rw-r--r-- | 13.3 KB |
tsacct.c | -rw-r--r-- | 4.9 KB |
uid16.c | -rw-r--r-- | 5.0 KB |
up.c | -rw-r--r-- | 1.7 KB |
user-return-notifier.c | -rw-r--r-- | 1.3 KB |
user.c | -rw-r--r-- | 5.4 KB |
user_namespace.c | -rw-r--r-- | 25.6 KB |
utsname.c | -rw-r--r-- | 3.0 KB |
utsname_sysctl.c | -rw-r--r-- | 3.0 KB |
watchdog.c | -rw-r--r-- | 27.2 KB |
workqueue.c | -rw-r--r-- | 145.2 KB |
workqueue_internal.h | -rw-r--r-- | 2.2 KB |
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...