Re: [PATCH 1/1] scsi/ufshcd: Fix NULL pointer dereference for in ufshcd_init

2018-09-25 Thread Vivek Gautam
Hi Martin, On Wed, Aug 29, 2018 at 1:50 PM Vivek Gautam wrote: > > On Wed, Aug 29, 2018 at 1:13 AM Evan Green wrote: > > > > On Tue, Aug 7, 2018 at 10:48 AM Vivek Gautam > > wrote: > > > > > > Error paths in ufshcd_init() ufshcd_hba_exit() killed clk_scaling > > > workqueue when the workqueue i

Re: [PATCH 2/3] scsi/ufs: qcom: Remove ufs_qcom_phy_*() calls from host

2018-09-25 Thread Vivek Gautam
Hi Martin, On Mon, Sep 24, 2018 at 10:51 PM Bjorn Andersson wrote: > > On Tue 04 Sep 03:17 PDT 2018, Vivek Gautam wrote: > > > The host makes direct calls into phy using ufs_qcom_phy_*() > > APIs. These APIs are only defined for 20nm qcom-ufs-qmp phy > > which is not being used by any architectur

Re: [PATCH v4 1/2] dt-bindings: ufs: Add bindings for Cadence UFS

2018-09-25 Thread Rob Herring
On Thu, Sep 20, 2018 at 01:08:22PM +, Janek Kotas wrote: > This patch adds a DT binding documentation for > Cadence UFS Host Controller. > > Signed-off-by: Jan Kotas > --- > .../devicetree/bindings/ufs/cdns,ufshc.txt | 31 > ++ > 1 file changed, 31 insertions(+)

[GIT PULL] SCSI fixes for 4.19-rc5

2018-09-25 Thread James Bottomley
Nine obvious bug fixes mostly in individual drivers. The target fix is of particular importance because it's CVE related. The patch is available here: git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git scsi-fixes The short changelog is: Adrian Hunter (1):   scsi: ufs: Disable blk-

Re: [GIT PULL] SCSI fixes for 4.19-rc5

2018-09-25 Thread Greg Kroah-Hartman
On Tue, Sep 25, 2018 at 08:34:52AM -0700, James Bottomley wrote: > Nine obvious bug fixes mostly in individual drivers. The target fix is > of particular importance because it's CVE related. > > The patch is available here: > > git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi.git scsi-fix

duplicate check for CAP_SYS_RAWIO

2018-09-25 Thread Tong Zhang
Kernel Version: 4.18.5 Problem Description: We found a path where duplicate capability checks are observed, the path is : scsi_ioctl<- require CAP_SYS_ADMIN and CAP_SYS_RAWIO `->sg_scsi_ioctl() `->blk_verify_command() <- require CAP_SYS_RAWIO CAP_SYS_RAWIO is checked twice

Re: [PATCH v4] scsi: ufs: Make sysfs attributes writable

2018-09-25 Thread Doug Anderson
Hi, On Tue, Sep 4, 2018 at 3:29 AM Adrian Hunter wrote: > > On 22/08/18 14:00, Adrian Hunter wrote: > > On 09/08/18 01:44, Evan Green wrote: > >> This change makes the UFS controller's sysfs attributes writable, which > >> will enable users to provision unprovisioned UFS devices, or > >> re-provi

Re: [PATCH 2/3] scsi/ufs: qcom: Remove ufs_qcom_phy_*() calls from host

2018-09-25 Thread Martin K. Petersen
Vivek, > Kishon is looking to pick this series through linux-phy tree. > Will you please consider giving your ack for this patch? Thanks. Looks fine. Acked-by: Martin K. Petersen -- Martin K. Petersen Oracle Linux Engineering

Re: [RESEND PATCH v2] scsi: Use vmemdup_user to replace the open code

2018-09-25 Thread Martin K. Petersen
zhong, > vmemdup_user is better than duplicating its implementation, So just > replace the open code. Applied to 4.20/scsi-queue, thanks! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH] scsi: FlashPoint: Remove unnecessary parentheses

2018-09-25 Thread Martin K. Petersen
Nathan, > Clang warns when multiple pairs of parentheses are used for a single > conditional statement. Applied to 4.20/scsi-queue, thanks! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH] scsi: advansys: Remove unnecessary parentheses

2018-09-25 Thread Martin K. Petersen
Hannes, > On 9/20/18 10:58 PM, Nathan Chancellor wrote: >> Clang warns when multiple pairs of parentheses are used for a single >> conditional statement. Applied to 4.20/scsi-queue, thanks! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH v2] scsi: sd: don't crash the host on invalid commands

2018-09-25 Thread Martin K. Petersen
Johannes, > When sd_init_command() get's a with a unknown req_op() it crashes the > system via BUG(). > > This makes debugging the actual reason for the broken request > cmd_flags pretty hard as the system is down before it's able to write > out debugging data on the serial console or the trace

Re: [PATCH 1/1] scsi/ufshcd: Fix NULL pointer dereference for in ufshcd_init

2018-09-25 Thread Martin K. Petersen
Vivek, >> > > Bjorn, Subhash, >> > > I am not certain of some of these devfreq, and clk_scaling bits >> > > that are moved as part of this patch. Please help in reviewing the >> > > change in the light of these features, and related sequence should >> > > be followed. >> > > Thanks. >> > > >> >

Re: [PATCH v4] scsi: ufs: Make sysfs attributes writable

2018-09-25 Thread Martin K. Petersen
Doug, > I came across this patch and Evan's other one and noticed that they > haven't been applied though a batch of other SCSI patches for 4.20 > were applied about a week ago. Martin: is there something about these > patches that needs to change before they can land? I have simply been await

Re: [PATCH v3 0/5] scsi: libsas: some code cleanups and bug fixes

2018-09-25 Thread Martin K. Petersen
Jason, > I split some code cleanups and bug fixes patches from my earlier series: > https://lkml.org/lkml/2018/5/28/2154 Applied to 4.20/scsi-queue, thank you! -- Martin K. Petersen Oracle Linux Engineering

Re: [PATCH v4] scsi: ufs: Make sysfs attributes writable

2018-09-25 Thread Doug Anderson
Martin, On Tue, Sep 25, 2018 at 6:08 PM Martin K. Petersen wrote: > > Doug, > > > I came across this patch and Evan's other one and noticed that they > > haven't been applied though a batch of other SCSI patches for 4.20 > > were applied about a week ago. Martin: is there something about these >

Re: [PATCH] scsi: qla2xxx: Fix comment in MODULE_PARM_DESC in qla2xxx

2018-09-25 Thread Madhani, Himanshu
> On Sep 11, 2018, at 2:48 AM, Masanari Iida wrote: > > External Email > > Default value of ql2xasynctmfenable for qla2xxx driver was > set to 1 in commit 043dc1d7e8501. > But comment in MODULE_PARAM_DESC was not modified. > > Signed-off-by: Masanari Iida > --- > drivers/scsi/qla2xxx/qla_os.

[PATCH] scsi: bfa: Avoid implicit enum conversion in bfad_im_post_vendor_event

2018-09-25 Thread Nathan Chancellor
Clang warns when one enumerated type is implicitly converted to another. drivers/scsi/bfa/bfa_fcs_lport.c:379:26: warning: implicit conversion from enumeration type 'enum bfa_lport_aen_event' to different enumeration type 'enum bfa_ioc_aen_event' [-Wenum-conversion]

Re: [PATCH 2/3] scsi/ufs: qcom: Remove ufs_qcom_phy_*() calls from host

2018-09-25 Thread Vivek Gautam
On Wed, Sep 26, 2018 at 5:59 AM Martin K. Petersen wrote: > > > Vivek, > > > Kishon is looking to pick this series through linux-phy tree. > > Will you please consider giving your ack for this patch? Thanks. > > Looks fine. > > Acked-by: Martin K. Petersen Thanks Martin. Best regards Vivek > >

Re: [PATCH 1/1] scsi/ufshcd: Fix NULL pointer dereference for in ufshcd_init

2018-09-25 Thread Vivek Gautam
On Wed, Sep 26, 2018 at 6:36 AM Martin K. Petersen wrote: > > > Vivek, > > >> > > Bjorn, Subhash, > >> > > I am not certain of some of these devfreq, and clk_scaling bits > >> > > that are moved as part of this patch. Please help in reviewing the > >> > > change in the light of these features, and

Re: [PATCH v2] scsi: sd: don't crash the host on invalid commands

2018-09-25 Thread Johannes Thumshirn
On Tue, Sep 25, 2018 at 08:52:58PM -0400, Martin K. Petersen wrote: > Looks like a bunch of my merge mails didn't make it out last week. > > For the record, I did merge this into 4.19/scsi-fixes and it has made > its way upstream. Thanks for the info. Byte, Johannes -- Johannes Thumshir

Re: [PATCH v3 0/6] mpt3sas: Hot-Plug Surprise removal support on IOC.

2018-09-25 Thread Andy Shevchenko
On Mon, Sep 24, 2018 at 9:36 AM Suganath Prabu S wrote: > > Posting below set of patches to support PCIe Hot Plug surprise removal, > and few defect fixes. > > This is NOT the normal PCIe Hot Plug support, whereby the user informs the > OS that a hot removal is desired, the OS does an orderly shut

Re: [PATCH v3 1/6] mpt3sas: Introduce mpt3sas_base_pci_device_is_available

2018-09-25 Thread Andy Shevchenko
On Mon, Sep 24, 2018 at 9:36 AM Suganath Prabu S wrote: > > * Driver uses "pci_device_is_present" to check whether > If Hot unplugged: > the outstanding IOs with 'DID_NO_CONNECT' before removing the drives > attached to the HBA. > "DID_NO_CONNECT" status and free the smid, if driver detects that >

Re: [PATCH v3 1/6] mpt3sas: Introduce mpt3sas_base_pci_device_is_available

2018-09-25 Thread Suganath Prabu Subramani
Hi Andy, I forgot to add Lukas in last patch CC list, But i have sent a note regarding the updated patch to him. Also added linux-pci On Tue, Sep 25, 2018 at 2:10 PM Andy Shevchenko wrote: > > On Mon, Sep 24, 2018 at 9:36 AM Suganath Prabu S > wrote: > > > > * Driver uses "pci_device_is_presen

Re: [PATCH v3 1/6] mpt3sas: Introduce mpt3sas_base_pci_device_is_available

2018-09-25 Thread Andy Shevchenko
On Tue, Sep 25, 2018 at 12:46 PM Suganath Prabu Subramani wrote: > > > + pr_err(MPT3SAS_FMT > > > + "%s: pci error recovery reset or" > > > + " pci device unplug occurred\n", > > > > This should be just one line. > Above line crosses over 80 chara

Re: [PATCH v3 1/6] mpt3sas: Introduce mpt3sas_base_pci_device_is_available

2018-09-25 Thread Suganath Prabu Subramani
On Tue, Sep 25, 2018 at 3:22 PM Andy Shevchenko wrote: > > On Tue, Sep 25, 2018 at 12:46 PM Suganath Prabu Subramani > wrote: > > > > > + pr_err(MPT3SAS_FMT > > > > + "%s: pci error recovery reset or" > > > > + " pci device unplug occurred\n", > >

Re: [PATCH v3 1/6] mpt3sas: Introduce mpt3sas_base_pci_device_is_available

2018-09-25 Thread Andy Shevchenko
On Tue, Sep 25, 2018 at 1:29 PM Suganath Prabu Subramani wrote: > > On Tue, Sep 25, 2018 at 3:22 PM Andy Shevchenko > wrote: > > > > On Tue, Sep 25, 2018 at 12:46 PM Suganath Prabu Subramani > > wrote: > > > > > > > + pr_err(MPT3SAS_FMT > > > > > + "%s: pci error

Re: [PATCH] scsi: sd: Use info prints if no write cache

2018-09-25 Thread Martin K. Petersen
Per, >>We have it at error level because many consumer devices lie about >>having caches and we would like the users to know that their data >>integrity may be at risk. > > There are users that get confused by these errors thinking something > is broken. Something is broken: Their hardware! >

[PATCH v4 3/6] mpt3sas: Introdude _scsih_get_shost_and_ioc.

2018-09-25 Thread Suganath Prabu S
The code for getting shost and IOC is redundant so moved that to function "scsih_get_shost_and_ioc". Also checks for NULL are added to IOC and shost. Signed-off-by: Suganath Prabu S --- drivers/scsi/mpt3sas/mpt3sas_scsih.c | 98 ++-- 1 file changed, 82 insertions(

[PATCH v4 6/6] mpt3sas: Bump driver version to 27.100.00.00.

2018-09-25 Thread Suganath Prabu S
Modify driver version to 27.100.00.00 (which is equivalent to PH8 OOB driver) Signed-off-by: Suganath Prabu S --- drivers/scsi/mpt3sas/mpt3sas_base.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/mpt3sas/mpt3sas_base.h b/drivers/scsi/mpt3sas/mpt3sas_base.h

[PATCH v4 5/6] mpt3sas: Fix driver modifying NVRAM/persistent data.

2018-09-25 Thread Suganath Prabu S
* If EEDPTagMode field in manufacturing page11 is set, unset it. This is needed to fix a hardware bug in SAS3/SAS2 cards, So, skipping EEDPTagMode changes in Manufacturing page11 for SAS35 controllers. * Fix driver modifying NVRAM/persistent data in Manufacturing page11 along with current copy. Dr

[PATCH v4 4/6] mpt3sas: Fix Sync cache command failure during driver unload.

2018-09-25 Thread Suganath Prabu S
This is to fix Sync cache and start stop command failures with DID_NO_CONNECT during driver unload. 1) Release drives first from SML, then remove internally in driver. 2) And allow sync cache and Start stop commands to firmware, even when remove_host flag is set v2 Changeset: Replaced this funct

[PATCH v4 1/6] mpt3sas: Introduce mpt3sas_base_pci_device_is_available

2018-09-25 Thread Suganath Prabu S
* Driver uses "pci_device_is_present" to check whether If Hot unplugged: the outstanding IOs with 'DID_NO_CONNECT' before removing the drives attached to the HBA. "DID_NO_CONNECT" status and free the smid, if driver detects that HBA is hot unplugged. * In the hard reset flush out all the outstandi

[PATCH v4 2/6] mpt3sas: Separate out mpt3sas_wait_for_ioc_to_operational

2018-09-25 Thread Suganath Prabu S
Introduce mpt3sas_wait_for_ioc_to_operational. This section of code "wait for IOC to be operational" is used in many places across the driver, and hence moved this section of code in to the function "mpt3sas_wait_for_ioc_to_operational". Also added HBA hot unplug checks, and this returns with err

[PATCH v4 0/6] mpt3sas: Hot-Plug Surprise removal support on IOC.

2018-09-25 Thread Suganath Prabu S
Posting below set of patches to support PCIe Hot Plug surprise removal, and few defect fixes. This is NOT the normal PCIe Hot Plug support, whereby the user informs the OS that a hot removal is desired, the OS does an orderly shutdown of the driver on the device, special hot plug circuitry removes

[PATCH v2 5/5] qla2xxx: Update driver version to 11.00.00.00-k

2018-09-25 Thread Himanshu Madhani
Signed-off-by: Himanshu Madhani --- drivers/scsi/qla2xxx/qla_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/qla2xxx/qla_version.h b/drivers/scsi/qla2xxx/qla_version.h index 12bafff71a1a..0d58aa629c08 100644 --- a/drivers/scsi/qla2xxx/qla_version.h

[PATCH v2 0/5] qla2xxx: Add FC-NVMe Target support

2018-09-25 Thread Himanshu Madhani
Hi Martin, This series adds support for FC-NVMe Target. Patch #1 addes new qla_nvmet files for FC-NVMe Target support. Patch #2 adds Kconfig and Makefile changes to prepare code compile. Patch #3, #4 has bulk of changes to handle FC-NVMe Target LS4 processing via Purex pass through pat

[PATCH v2 4/5] qla2xxx_nvmet: Add SysFS node for FC-NVMe Target

2018-09-25 Thread Himanshu Madhani
From: Anil Gurumurthy This patch adds SysFS node for NVMe Target configuration Signed-off-by: Anil Gurumurthy Signed-off-by: Himanshu Madhani --- drivers/scsi/qla2xxx/qla_attr.c | 33 + drivers/scsi/qla2xxx/qla_gs.c| 2 +- drivers/scsi/qla2xxx/qla_init.c

[PATCH v2 3/5] qla2xxx_nvmet: Add FC-NVMe Target handling

2018-09-25 Thread Himanshu Madhani
From: Anil Gurumurthy This patch Adds following code in the driver to support FC-NVMe Target - Updated ql2xenablenvme to allow FC-NVMe Target operation - Added Link Serviccce Request handling for NVMe Target - Added passthru IOCB for LS4 request - Added CTIO for sending response to FW - Added FC

[PATCH v2 1/5] qla2xxx_nvmet: Add files for FC-NVMe Target support

2018-09-25 Thread Himanshu Madhani
From: Anil Gurumurthy This patch adds initial files to enable NVMe Target Support Signed-off-by: Anil Gurumurthy Signed-off-by: Giridhar Malavali Signed-off-by: Darren Trapp Signed-off-by: Himanshu Madhani --- drivers/scsi/qla2xxx/Makefile| 3 +- drivers/scsi/qla2xxx/qla_nvmet.c | 798

[PATCH v2 2/5] qla2xxx_nvmet: Add FC-NVMe Target Link Service request handling

2018-09-25 Thread Himanshu Madhani
From: Anil Gurumurthy This patch provides link service pass through feature handling in the driver. This feature is implemented mainly by the firmware and the same implementation is handled in the driver via an IOCB interface. Signed-off-by: Anil Gurumurthy Signed-off-by: Giridhar Malavali Sig