Commit graph

900515 commits

Author SHA1 Message Date
Mauro Carvalho Chehab
b64f682240 scsi: docs: convert ufs.txt to ReST
Link: https://lore.kernel.org/r/052d45576e342a217185e91a83793b384b1592a4.1583136624.git.mchehab+huawei@kernel.org
Acked-by: Avri Altman <avri.altman@wdc.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:03 -04:00
Mauro Carvalho Chehab
e92c45d272 scsi: docs: convert tcm_qla2xxx.txt to ReST
Link: https://lore.kernel.org/r/de73fa02f38f67f54f22ef2842f9680c0b34434a.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:03 -04:00
Mauro Carvalho Chehab
f02e84d29e scsi: docs: convert sym53c8xx_2.txt to ReST
Link: https://lore.kernel.org/r/08202c87294d61d147ec4ac784219d20805cdeb5.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:03 -04:00
Mauro Carvalho Chehab
110a89b1ca scsi: docs: convert sym53c500_cs.txt to ReST
Link: https://lore.kernel.org/r/eff6166b3442ddb37b934bca46e7f9ef25ebc2a4.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:03 -04:00
Mauro Carvalho Chehab
bf65c84647 scsi: docs: convert st.txt to ReST
Link: https://lore.kernel.org/r/6b2ddb36983e81e7028de6e5fd0c643c2fb4c6c9.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:02 -04:00
Mauro Carvalho Chehab
ff1efa7431 scsi: docs: convert smartpqi.txt to ReST
Link: https://lore.kernel.org/r/00b398efb7cfc667b046fbef92a84f1d3c33eb64.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:02 -04:00
Mauro Carvalho Chehab
d835971b2b scsi: docs: convert sd-parameters.txt to ReST
Link: https://lore.kernel.org/r/8d0b75b0faf13a2e81373570d6ce601b629fb22a.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:02 -04:00
Mauro Carvalho Chehab
b7223d9bde scsi: docs: convert scsi.txt to ReST
Link: https://lore.kernel.org/r/c617b37769a82901def0fed3d236a25995c4e160.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:02 -04:00
Mauro Carvalho Chehab
a0b1643bee scsi: docs: convert scsi-parameters.txt to ReST
Link: https://lore.kernel.org/r/f00a5f6f2bf9a2562e0856ee8f45bcf9521d181f.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:02 -04:00
Mauro Carvalho Chehab
ce5c5d6503 scsi: docs: convert scsi_mid_low_api.txt to ReST
Link: https://lore.kernel.org/r/881e7741dfed5d6f5f73e1dfc2826b200b8604aa.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:02 -04:00
Mauro Carvalho Chehab
d4d79340fb scsi: docs: convert scsi-generic.txt to ReST
Link: https://lore.kernel.org/r/f57b8ddf30397c2c7213e49634e5e9cbd4246368.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:02 -04:00
Mauro Carvalho Chehab
fedd7a4d09 scsi: docs: convert scsi_fc_transport.txt to ReST
Link: https://lore.kernel.org/r/f75bd9b6512f223847cc4ece8bd7e8e72e434b21.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:01 -04:00
Mauro Carvalho Chehab
e513de9936 scsi: docs: convert scsi_eh.txt to ReST
Link: https://lore.kernel.org/r/300314197f2e6a3258200711e825aa04c9e8ceaf.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:01 -04:00
Mauro Carvalho Chehab
731fc16c2f scsi: docs: convert scsi-changer.txt to ReST
Link: https://lore.kernel.org/r/433d073fa982174a19783c2e59412b724e2cf946.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:01 -04:00
Mauro Carvalho Chehab
058595d582 scsi: docs: convert qlogicfas.txt to ReST
Link: https://lore.kernel.org/r/b69f795c781811b9a908abe43485f1dca0ee8ac5.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:01 -04:00
Mauro Carvalho Chehab
304a8b6270 scsi: docs: convert ppa.txt to ReST
Link: https://lore.kernel.org/r/3db8cd51d77fef6b66632249412969caa29dec40.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:01 -04:00
Mauro Carvalho Chehab
dbfa1bceed scsi: docs: convert NinjaSCSI.txt to ReST
Link: https://lore.kernel.org/r/6385a411d000dad005b78647629e43700580ecf0.1583136624.git.mchehab+huawei@kernel.org
Acked-by: GOTO Masanori <gotom@debian.or.jp>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:01 -04:00
Mauro Carvalho Chehab
8dca37d259 scsi: docs: convert ncr53c8xx.txt to ReST
Link: https://lore.kernel.org/r/cover.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:01 -04:00
Mauro Carvalho Chehab
a756185de6 scsi: docs: convert megaraid.txt to ReST
Link: https://lore.kernel.org/r/b7ee59230c5a33ff6d60edba0d0bcf3e2aeaa88f.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:00 -04:00
Mauro Carvalho Chehab
b4adb75781 scsi: docs: convert lpfc.txt to ReST
Link: https://lore.kernel.org/r/48c13184b77ba61ed4fd7c235816fdb8e7530664.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:00 -04:00
Mauro Carvalho Chehab
cbbc70a8cd scsi: docs: convert link_power_management_policy.txt to ReST
Link: https://lore.kernel.org/r/c56177fdf046d80e0dec6031c4139cb4e8c39d31.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:00 -04:00
Mauro Carvalho Chehab
a88dc3ec2c scsi: docs: convert libsas.txt to ReST
Link: https://lore.kernel.org/r/9022cb5551487f774cab16a828fe06b0b6b3add3.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:00 -04:00
Mauro Carvalho Chehab
ac69461b60 scsi: docs: convert hptiop.txt to ReST
Link: https://lore.kernel.org/r/d189a339bb360b7b397914ee3ddeb75d9a7fd788.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:00 -04:00
Mauro Carvalho Chehab
1392de9d7a scsi: docs: convert hpsa.txt to ReST
Link: https://lore.kernel.org/r/ea58e04176d43fb7194615b145060aa04c9cf3ad.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:00 -04:00
Mauro Carvalho Chehab
3c1e681bcd scsi: docs: convert g_NCR5380.txt to ReST
Link: https://lore.kernel.org/r/a66e9ea704be6a7aa81b9864ad66a32b75ab808d.1583136624.git.mchehab+huawei@kernel.org
Acked-by: Finn Thain <fthain@telegraphics.com.au>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:08:00 -04:00
Mauro Carvalho Chehab
cc0d9d3ad7 scsi: docs: convert FlashPoint.txt to ReST
Link: https://lore.kernel.org/r/e755b9644047eed6be69fcc77eb797f0801fcb99.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:59 -04:00
Mauro Carvalho Chehab
f22978400e scsi: docs: convert dpti.txt to ReST
Link: https://lore.kernel.org/r/212fd7961c134c5bd73d87cd818bcddc30270804.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:59 -04:00
Mauro Carvalho Chehab
62e3bfa4a1 scsi: docs: convert dc395x.txt to ReST
Link: https://lore.kernel.org/r/3c0876df0045695185f922a0404c497a69de36a9.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:59 -04:00
Mauro Carvalho Chehab
d2ba7ca338 scsi: docs: convert cxgb3i.txt to ReST
Link: https://lore.kernel.org/r/0708b62b6ec4f0dddc581e412bb02ba6476f4523.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:59 -04:00
Mauro Carvalho Chehab
977b899ce3 scsi: docs: convert BusLogic.txt to ReST
Link: https://lore.kernel.org/r/750629b6a5233c85c5391c44d126606b8aabefc8.1583136624.git.mchehab+huawei@kernel.org
Acked-by: Khalid Aziz <khalid@gonehiking.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:59 -04:00
Mauro Carvalho Chehab
1d4f8dfe2d scsi: docs: convert bnx2fc.txt to ReST
Link: https://lore.kernel.org/r/f239116bd2c36f6fc8deb62e325bb8161da04270.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:59 -04:00
Mauro Carvalho Chehab
6e5a663d8e scsi: docs: convert bfa.txt to ReST
Link: https://lore.kernel.org/r/6660d0f83ddae2ab8efb31c39f9c220fc132e9d4.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:58 -04:00
Mauro Carvalho Chehab
cff7c4a596 scsi: docs: convert aic7xxx.txt to ReST
Link: https://lore.kernel.org/r/dc2b1ffe4bf64cfc4b32328740704a30e8d38a79.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:58 -04:00
Mauro Carvalho Chehab
520a44d4df scsi: docs: convert aic79xx.txt to ReST
Link: https://lore.kernel.org/r/e8a40337a2173f028c9ac569d3d71fd880f4fab5.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:58 -04:00
Mauro Carvalho Chehab
94b5530f1f scsi: docs: convert aha152x.txt to ReST
Link: https://lore.kernel.org/r/097cfcc7f25343676a1fedcefed7e3b91b41b4df.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:58 -04:00
Mauro Carvalho Chehab
cb32240894 scsi: docs: convert advansys.txt to ReST
Link: https://lore.kernel.org/r/3c697a046e641c81cdfd0784f037d41d54766931.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:58 -04:00
Mauro Carvalho Chehab
dd9cc1447a scsi: docs: convert aacraid.txt to ReST
Link: https://lore.kernel.org/r/67c60ad88777c91937d49771e2a3f48cbf353e4c.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:58 -04:00
Mauro Carvalho Chehab
f76576777a scsi: docs: convert 53c700.txt to ReST
Link: https://lore.kernel.org/r/a2e5116b70564f36b4fc7f1f1e5da1e693d7dadb.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:58 -04:00
Mauro Carvalho Chehab
7f877908df scsi: docs: include SCSI Transport SRP diagram at the doc body
Instead of having a separate makefile, and be alone, group
it at the SCSI documentation and make it being built as part
of docs makefile.

Link: https://lore.kernel.org/r/419c455fb40c9a1e85cc9a654a7fdb07aeeccf71.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Mauro Carvalho Chehab
31df2fd54c scsi: docs: Add an empty index file for SCSI documents
In preparation for adding the SCSI documents to the documentation
body, add an empty index for it.

The next patches should be adding contents to it, as files get
converted to ReST format.

Link: https://lore.kernel.org/r/4d8c1b7ebe5898ac4a8265ca5e5a9552da3b426f.1583136624.git.mchehab+huawei@kernel.org
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Rajan Shanmugavelu
598a90f200 scsi: qla2xxx: add ring buffer for tracing debug logs
Having this log in a ring buffer helps to diagnose qla2xxx driver and
firmware issues instead of having to reproduce the problem with
extended_logging enabled. This saves cycles and helps when it is hard
to reproduce problem.

Link: https://lore.kernel.org/r/1581557368-32080-1-git-send-email-rajan.shanmugavelu@oracle.com
Reviewed-by: Joe Jin <joe.jin@oracle.com>
Acked-by: Himanshu Madhani <hmadhani@marvell.com>
Signed-off-by: Rajan Shanmugavelu <rajan.shanmugavelu@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Phong Tran
779dfcf643 scsi: aacraid: clean up warning cast-function-type
Make the aacraid driver -Wcast-function-type clean

Report by: https://github.com/KSPP/linux/issues/20

drivers/scsi/aacraid/aachba.c:813:23:
warning: cast between incompatible function types from
'int (*)(struct scsi_cmnd *)' to 'void (*)(struct scsi_cmnd *)'
[-Wcast-function-type]

Link: https://lore.kernel.org/r/20200309155319.12658-1-tranmanphong@gmail.com
Reviewed-by: Bart van Assche <bvanassche@acm.org>
Reviewed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Phong Tran <tranmanphong@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Stanley Chu
47d054580a scsi: ufs-mediatek: fix HOST_PA_TACTIVATE quirk for Samsung UFS Devices
Device quirk "UFS_DEVICE_QUIRK_HOST_PA_TACTIVATE" is enabled for all
Samsung devices by default currently.

However MediaTek UFS host requires different host PA_TACTIVATE
configuration. Hence clear this quirk first and then apply vendor-specific
value in vops callback.

Link: https://lore.kernel.org/r/20200302135346.16797-1-stanley.chu@mediatek.com
Reviewed-by: Avri Altman <avri.altman@wdc.com>
Signed-off-by: Stanley Chu <stanley.chu@mediatek.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Brian King
b893eb0141 scsi: ibmvfc: Fix NULL return compiler warning
Fix up a compiler warning introduced via 54b04c99d02e

Link: https://lore.kernel.org/r/1583159961-15903-1-git-send-email-brking@linux.vnet.ibm.com
Fixes: 54b04c99d02e ("scsi: ibmvfc: Avoid loss of all paths during SVC node reboot")
Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Randy Dunlap
5848fe960b scsi: fusion: fix if-statement empty body warning
When driver debugging is not enabled, change the debug print macros
to use the no_printk() macro.

This fixes a gcc warning when -Wextra is set:
../drivers/message/fusion/mptlan.c:266:39: warning: suggest braces around empty body in an ‘else’ statement [-Wempty-body]

I have verified that there is very little object code change (with
gcc 7.5.0). There are a few changes like:
  cmp %a,%b
  jl $1
to
  cmp %b,%a
  jg $1

Link: https://lore.kernel.org/r/ff9df31b-c4c1-c942-1cbf-18039e084c8e@infradead.org
Cc: Bart Van Assche <bvanassche@acm.org>
Cc: "James E.J. Bottomley" <jejb@linux.ibm.com>
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
Cc: linux-scsi@vger.kernel.org
Cc: MPT-FusionLinux.pdl@broadcom.com
Cc: Suganath Prabu Subramani <suganath-prabu.subramani@broadcom.com>
Cc: Chaitra P B <chaitra.basappa@broadcom.com>
Cc: Sathya Prakash <sathya.prakash@broadcom.com>
Reviewed-by: Bart van Assche <bvanassche@acm.org>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Frank Mayhar
cc6b32ee3b scsi: iscsi: Add support for asynchronous iSCSI session destruction
iSCSI session destruction can be arbitrarily slow, since it might require
network operations and serialization inside the SCSI layer.  This patch
adds a new user event to trigger the destruction work asynchronously,
releasing the rx_queue_mutex as soon as the operation is queued and before
it is performed.  This change allows other operations to run in other
sessions in the meantime, removing one of the major iSCSI bottlenecks for
us.

To prevent the session from being used after the destruction request, we
remove it immediately from the sesslist. This simplifies the locking
required during the asynchronous removal.

Link: https://lore.kernel.org/r/20200227195945.761719-1-krisman@collabora.com
Co-developed-by: Gabriel Krisman Bertazi <krisman@collabora.com>
Co-developed-by: Khazhismel Kumykov <khazhy@google.com>
Reviewed-by: Lee Duncan <lduncan@suse.com>
Signed-off-by: Gabriel Krisman Bertazi <krisman@collabora.com>
Signed-off-by: Frank Mayhar <fmayhar@google.com>
Signed-off-by: Khazhismel Kumykov <khazhy@google.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Sagar Biradar
bef18d308a scsi: aacraid: Disabling TM path and only processing IOP reset
Fixes the occasional adapter panic when sg_reset is issued with -d, -t, -b
and -H flags.  Removal of command type HBA_IU_TYPE_SCSI_TM_REQ in
aac_hba_send since iu_type, request_id and fib_flags are not populated.
Device and target reset handlers are made to send TMF commands only when
reset_state is 0.

Link: https://lore.kernel.org/r/1581553771-25796-1-git-send-email-Sagar.Biradar@microchip.com
Reviewed-by: Sagar Biradar <Sagar.Biradar@microchip.com>
Signed-off-by: Sagar Biradar <Sagar.Biradar@microchip.com>
Signed-off-by: Balsundar P <balsundar.p@microsemi.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Brian King
ed830385a2 scsi: ibmvfc: Avoid loss of all paths during SVC node reboot
When an SVC node goes down as part of a node reboot, its WWPNs are moved to
the remaining node. When the node is back online, its WWPNs are moved
back. The result is that the WWPN moves from one NPort_ID to another, then
back again.  The ibmvfc driver was forcing the old port to be removed, but
not sending an implicit logout. When the WWPN showed up at the new
location, the PLOGI failed as there was already a login established for the
old scsi id. The patch below fixes this by ensuring we always send an
implicit logout for any scsi id associated with an rport prior to calling
fc_remote_port_delete.

Link: https://lore.kernel.org/r/1582767943-16611-1-git-send-email-brking@linux.vnet.ibm.com
Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:57 -04:00
Gustavo A. R. Silva
5febf6d6ae scsi: Replace zero-length array with flexible-array member
The current codebase makes use of the zero-length array language extension
to the C90 standard, but the preferred mechanism to declare variable-length
types such as these ones is a flexible array member[1][2], introduced in
C99:

struct foo {
        int stuff;
        struct boo array[];
};

By making use of the mechanism above, we will get a compiler warning in
case the flexible array does not occur last in the structure, which will
help us prevent some kind of undefined behavior bugs from being
inadvertently introduced[3] to the codebase from now on.

Also, notice that, dynamic memory allocations won't be affected by this
change:

"Flexible array members have incomplete type, and so the sizeof operator
may not be applied. As a quirk of the original implementation of
zero-length arrays, sizeof evaluates to zero."[1]

This issue was found with the help of Coccinelle.

[1] https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html
[2] https://github.com/KSPP/linux/issues/21
[3] commit 7649773293 ("cxgb3/l2t: Fix undefined behaviour")

Link: https://lore.kernel.org/r/20200224161406.GA21454@embeddedor
Reviewed-by: Lee Duncan <lduncan@suse.com>
Reviewed-by: Satish Kharat <satishkh@cisco.com>
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-03-11 23:07:56 -04:00
Bart Van Assche
5905d4648e scsi: ufs: Simplify two tests
lrbp->cmd is set only for SCSI commands. Use this knowledge to simplify two
boolean expressions.

Link: https://lore.kernel.org/r/20200123035637.21848-4-bvanassche@acm.org
Cc: Alim Akhtar <alim.akhtar@samsung.com>
Cc: Tomas Winkler <tomas.winkler@intel.com>
Cc: Bean Huo <beanhuo@micron.com>
Cc: Can Guo <cang@codeaurora.org>
Reviewed-by: Stanley Chu <stanley.chu@mediatek.com>
Reviewed-by: Asutosh Das <asutoshd@codeaurora.org>
Reviewed-by: Avri Altman <avri.altman@wdc.com>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
2020-02-28 21:05:06 -05:00