mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-22 16:06:04 -05:00
a0fde512f7
nr_attrs should start counting from zero, otherwise we will end up
dereferencing an invalid memory address.
$ targetcli /loopback create
general protection fault
RIP: 0010:configfs_create_file+0x12/0x70
Call Trace:
<TASK>
configfs_attach_item.part.0+0x5f/0x150
configfs_attach_group.isra.0+0x49/0x120
configfs_mkdir+0x24f/0x4d0
vfs_mkdir+0x192/0x240
do_mkdirat+0x131/0x160
__x64_sys_mkdir+0x48/0x70
do_syscall_64+0x5c/0x90
Fixes:
|
||
---|---|---|
.. | ||
iscsi | ||
loopback | ||
sbp | ||
tcm_fc | ||
tcm_remote | ||
Kconfig | ||
Makefile | ||
target_core_alua.c | ||
target_core_alua.h | ||
target_core_configfs.c | ||
target_core_device.c | ||
target_core_fabric_configfs.c | ||
target_core_fabric_lib.c | ||
target_core_file.c | ||
target_core_file.h | ||
target_core_hba.c | ||
target_core_iblock.c | ||
target_core_iblock.h | ||
target_core_internal.h | ||
target_core_pr.c | ||
target_core_pr.h | ||
target_core_pscsi.c | ||
target_core_pscsi.h | ||
target_core_rd.c | ||
target_core_rd.h | ||
target_core_sbc.c | ||
target_core_spc.c | ||
target_core_stat.c | ||
target_core_tmr.c | ||
target_core_tpg.c | ||
target_core_transport.c | ||
target_core_ua.c | ||
target_core_ua.h | ||
target_core_user.c | ||
target_core_xcopy.c | ||
target_core_xcopy.h |