adding mailing list From: Himanshu Madhani <himanshu.madhani@xxxxxxxxxx> Date: Friday, May 29, 2015 at 11:59 AM To: "Nicholas A. Bellinger" <nab@xxxxxxxxxxxxxxx> Cc: Quinn Tran <quinn.tran@xxxxxxxxxx>, Arun Easi <arun.easi@xxxxxxxxxx>, Giridhar Malavali <giridhar.malavali@xxxxxxxxxx> Subject: Targetcli issue with 4.1.0-rc5+ and qla2xxx >Hi Nicholas, > >I just updated my kernel to 4.1.0-rc5+ and I am seeing problem to create >ram disk target with latest kernel. > >/> cd backstores/ramdisk >/backstores/ramdisk> create rm_lun0 1G >Created ramdisk rm_lun0 with size 1G. >/backstores/ramdisk> ls >o- ramdisk >.......................................................................... >................. [Storage Objects: 1] > o- rm_lun0 >.......................................................................... >............. [(1.0GiB) deactivated] >/backstores/ramdisk> cd .. >/backstores> cd .. >/> cd qla2xxx > >/qla2xxx> create 21:00:00:24:ff:78:46:b4 >Cannot change enable state: [Errno 19] No such device > >/qla2xxx> create naa.2100000e1e08c720 >Cannot change enable state: [Errno 19] No such device > > >Note when I revert back to 4.0.0-rc7+ I am able to create the ram disk >target. I¹ve identified the patch by which introduced this regression > >https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id >=9ac8928e6a3e1ed02e632e45aa766129fe6b1802 > >I also verified while debugging this that directory structured did get >created for target portal group before we go enable it. > >Here¹s script that I used to check that the call to create tpgt_1 was >successful > ># tcm_setup.sh -m qla2xxx -c >++ lsmod >++ grep -w '^tcm_qla2xxx' >+ tmp='tcm_qla2xxx 28705 0 ' >+ [[ tcm_qla2xxx 28705 0 == '' ]] >+ mount -t configfs configfs /sys/kernel/config >+ mkdir /sys/kernel/config/target/qla2xxx >+ cd /sys/kernel/config/target/core >+ mkdir rd_mcp_0 >+ mkdir rd_mcp_0/q_tcm_mcp.0 >+ echo rd_pages=12800 >+ echo 1 >+ echo 73f3ebae-f06f-41be-94ca-3d7ec76f >+ cd /sys/kernel/config/target/qla2xxx >+ mkdir 21:00:00:0e:1e:08:c7:20 >+ cd /sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20 >+ mkdir tpgt_1 >+ [[ fc == \i\s\c\s\i ]] >+ mkdir tpgt_1/lun/lun_0 >+ ln -s /sys/kernel/config/target/core/rd_mcp_0/q_tcm_mcp.0 >/sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1/lun/lun_0 >/tcm_123 >+ cd /sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1/acls >+ mkdir 21:00:00:0e:1e:15:f7:50 >+ mkdir 21:00:00:0e:1e:15:f7:50/lun_0 >+ ln -s >/sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1/lun/lun_0 > 21:00:00:0e:1e:15:f7:50/lun_0/ >+ cd /sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1 >+ [[ fc == \i\s\c\s\i ]] >+ [[ tcm_qla2xxx == \t\c\m\_\q\l\a\4\x\x\x ]] >+ echo 1 >/root/bin/tcm_setup.sh: line 152: echo: write error: No such device > >Here¹s same script I ran with this setup before the patch ("target: >simplify the target template registration > API²) > ># ./tcm_setup.sh -m qla2xxx -c >++ lsmod >++ grep -w '^tcm_qla2xxx' >+ tmp='tcm_qla2xxx 29399 0 ' >+ [[ tcm_qla2xxx 29399 0 == '' ]] >+ mount -t configfs configfs /sys/kernel/config >+ mkdir /sys/kernel/config/target/qla2xxx >+ cd /sys/kernel/config/target/core >+ mkdir rd_mcp_0 >+ mkdir rd_mcp_0/q_tcm_mcp.0 >+ echo rd_pages=12800 >+ echo 1 >+ echo 73f3ebae-f06f-41be-94ca-73dd50ed >+ cd /sys/kernel/config/target/qla2xxx >+ mkdir 21:00:00:0e:1e:08:c7:20 >+ cd /sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20 >+ mkdir tpgt_1 >+ [[ fc == \i\s\c\s\i ]] >+ mkdir tpgt_1/lun/lun_0 >+ ln -s /sys/kernel/config/target/core/rd_mcp_0/q_tcm_mcp.0 >/sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1/lun/lun_0 >/tcm_123 >+ cd /sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1/acls >+ mkdir 21:00:00:0e:1e:15:f7:50 >+ mkdir 21:00:00:0e:1e:15:f7:50/lun_0 >+ ln -s >/sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1/lun/lun_0 > 21:00:00:0e:1e:15:f7:50/lun_0/ >+ cd /sys/kernel/config/target/qla2xxx/21:00:00:0e:1e:08:c7:20/tpgt_1 >+ [[ fc == \i\s\c\s\i ]] >+ [[ tcm_qla2xxx == \t\c\m\_\q\l\a\4\x\x\x ]] >+ echo 1 > >Any suggestion to fix this would be really helpful. > >Thanks, > >-Himanshu -- To unsubscribe from this list: send the line "unsubscribe target-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html