>
> Signed-off-by: Tomas Winkler <tomas.wink...@intel.com>
> Signed-off-by: Alexander Usyskin <alexander.usys...@intel.com>
Tested-by: Avri Altman <avri.alt...@sandisk.com>
- mmc - full functionality. One issue found that was fixed on V6: patch V6 2/9.
- ufs
m
> Cc: linux-scsi@vger.kernel.org
> Subject: [PATCH] scsi: ufs: reqs and tasks were put in the wrong order
>
> Signed-off-by: Zang Leigang <zangleig...@hisilicon.com>
Acked-by: Avri Altman <avri.alt...@sandisk.com>
>
> diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/uf
> -Original Message-
> From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi-
> ow...@vger.kernel.org] On Behalf Of Michal Potomski
> Sent: Thursday, November 09, 2017 11:17 AM
> To: linux-scsi@vger.kernel.org
> Cc: vinholika...@gmail.com; martin.peter...@oracle.com;
>
o that other vendors like
> exynos can use the same.
>
> Signed-off-by: Seungwon Jeon <ess...@gmail.com>
> Signed-off-by: Alim Akhtar <alim.akh...@samsung.com>
Acked-by: Avri Altman <avri.alt...@wdc.com>
Might be also useful exporting an API for all uic commands?
Thanks,
Avri
Hi,
Can you elaborate how this can even happen?
Isn't the interrupt aggregation capability should attend for those cases?
Thanks,
Avri
> -Original Message-
> From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi-
> ow...@vger.kernel.org] On Behalf Of Asutosh Das
> Sent: Tuesday,
> >>> -Original Message-
> >>> From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi-
> >>> ow...@vger.kernel.org] On Behalf Of Asutosh Das
> >>> Sent: Tuesday, January 30, 2018 6:54 AM
> >>> To: subha...@codeaurora.org; c...@codeaurora.org;
> >>> vivek.gau...@codeaurora.org;
> -Original Message-
> From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi-
> ow...@vger.kernel.org] On Behalf Of Adrian Hunter
> Sent: Friday, February 16, 2018 2:01 PM
> To: Vinayak Holikatti ; Martin K. Petersen
> ; James E.J.
> -Original Message-
> From: linux-scsi-ow...@vger.kernel.org [mailto:linux-scsi-
> ow...@vger.kernel.org] On Behalf Of Greg Kroah-Hartman
> Sent: Thursday, December 21, 2017 10:00 AM
> To: Jaegeuk Kim
> Cc: linux-ker...@vger.kernel.org; linux-scsi@vger.kernel.org;
Thanks,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 01, 2018 6:39 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vi
Johannes,
Thanks a lot for your comments.
Cheers,
Avri
> -Original Message-
> From: linux-scsi-ow...@vger.kernel.org
> On Behalf Of Johannes Thumshirn
> Sent: Wednesday, August 01, 2018 2:17 PM
> To: Avri Altman
> Cc: Christoph Hellwig ; Hannes Reinecke ;
> Bart V
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly,
as it will be copied without any further input validations.
Signed-off
Call the Attach/Probe/Remove APIs.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 7 +++
1 file changed, 7 insertions(+)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 3560185..c2ae406 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs
Add support to those uic commands, that are currently supported
by ufshcd api: the variants of dme_{peer}_{set_get}.
At this point better not to add any new api, as careless
uic command may turn the device into a brick.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 56
for that.
We also still not supporting uic commands:
For first phase, we plan to use the existing api,
and send only uic commands that are already supported.
Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 119
retty lean structure. This is because we are
using upiu transactions that contains the outmost detailed info,
so we don't really need complex constructs to support it.
The transport will keep track of its ufs-ports via its scsi host.
Signed-off-by: Avri Altman
---
drivers/scsi/Kconfig |
, and able to communicate with the device in ways,
that are sometimes beyond the capacity of the ufs driver.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/Makefile| 1 +
drivers/scsi/ufs/ufs_bsg.c | 127 +++
drivers/scsi/ufs/ufs_bsg.h | 74
platform with a V4.14 kernel,
"modernized" by recent bsg and ufs patches.
We also used a htc11 with a V4.4 kernel, but needed much more
transport/bsg/ufs patches to make it relevant.
Avri Altman (6):
scsi: Add ufs transport class
scsi: ufs: Add ufs-bsg module
scsi: ufs: Instant
suse.de; martin.peter...@oracle.com;
> Avri Altman
> Cc: Vinayak Holikatti ; Avi Shchislowski
> ; Alex Lemberg ;
> Stanislav Nijnikov ; subha...@codeaurora.org
> Subject: Re: [RFC 0/6] scsi: scsi transport for ufs devices
>
> On 2018-07-30 02:13 PM, Hannes Reinecke wrote:
> &g
retty lean structure. This is because we are
using upiu transactions that contains the outmost detailed info,
so we don't really need complex constructs to support it.
The transport will keep track of its ufs-ports via its scsi host.
Signed-off-by: Avri Altman
---
drivers/scsi/Kconfig |
platform with a V4.14 kernel,
"modernized" by recent bsg and ufs patches.
We also used a htc11 with a V4.4 kernel, but needed much more
transport/bsg/ufs patches to make it relevant.
Avri Altman (6):
scsi: Add ufs transport class
scsi: ufs: Add ufs-bsg module
scsi: ufs: Instant
for that.
We also still not supporting uic commands:
For first phase, we plan to use the existing api,
and send only uic commands that are already supported.
Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 119
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly,
as it will be copied without any further input validations.
Signed-off
Call the Attach/Probe/Remove APIs.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 7 +++
1 file changed, 7 insertions(+)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 3560185..c2ae406 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs
, and able to communicate with the device in ways,
that are sometimes beyond the capacity of the ufs driver.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/Makefile| 1 +
drivers/scsi/ufs/ufs_bsg.c | 127 +++
drivers/scsi/ufs/ufs_bsg.h | 74
Add support to those uic commands, that are currently supported
by ufshcd api: the variants of dme_{peer}_{set_get}.
At this point better not to add any new api, as careless
uic command may turn the device into a brick.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 56
, and able to communicate with the device in ways,
that are sometimes beyond the capacity of the ufs driver.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/Makefile| 1 +
drivers/scsi/ufs/ufs_bsg.c | 127 +++
drivers/scsi/ufs/ufs_bsg.h | 72
Do that in preparation to re-use ufshcd_issue_tm_cmd code.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 50 +++
1 file changed, 29 insertions(+), 21 deletions(-)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index
Use a more appropriate name when checking if enough memory
was allocated for write descriptor, and remove redundant goto.
Add reference to the spec to explain uic command size.
Fix a lot of typos.
Avri Altman (8):
scsi: Add ufs transport class
scsi: ufs: Add ufs-bsg modul
retty lean structure. This is because we are
using upiu transactions that contains the outmost detailed info,
so we don't really need complex constructs to support it.
The transport will keep track of its ufs-ports via its scsi host.
Signed-off-by: Avri Altman
---
drivers/scsi/Kconfig |
for that.
We also still not supporting uic commands:
For first phase, we plan to use the existing api,
and send only uic commands that are already supported.
Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 118
Add support to those uic commands, that are currently supported
by ufshcd api: the variants of dme_{peer}_{set_get}.
At this point better not to add any new api, as careless
uic command may turn the device into a brick.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 56
Do that in order to re-use its code if the task request and response
UPIUs are given externally.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 35 ++-
1 file changed, 26 insertions(+), 9 deletions(-)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers
Call the Attach/Probe/Remove APIs.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 7 +++
1 file changed, 7 insertions(+)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index 3560185..c2ae406 100644
--- a/drivers/scsi/ufs/ufshcd.c
+++ b/drivers/scsi/ufs
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly,
as it will be copied without any further input validations.
Signed-off
Thanks,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 01, 2018 6:36 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vi
Bart,
Thanks a lot,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 01, 2018 6:13 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
>
Bart, thanks.
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 01, 2018 6:28 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vi
Thanks,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 01, 2018 6:36 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vi
Thanks,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 08, 2018 7:40 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vi
Thanks,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 08, 2018 7:27 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vi
Thanks,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 08, 2018 7:39 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vi
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 08, 2018 7:21 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vinayak Holikat
> On Sun, Aug 05, 2018 at 02:39:48PM +0300, Avri Altman wrote:
> > Here is a proposal to use the scsi transport subsystem to manage
> > ufs devices.
>
> This should superceed previous patches to provide provisioning
> support through sysfs or configfs, right?
Yes.
Thanks,
Avri
> -Original Message-
> From: Bart Van Assche
> Sent: Wednesday, August 08, 2018 7:58 PM
> To: h...@lst.de; Avri Altman ; linux-scsi@vger.kernel.org;
> jthumsh...@suse.de; h...@suse.com; martin.peter...@oracle.com;
> j...@linux.vnet.ibm.com
> Cc: Vinayak Holikat
Hi Bart,
> -Original Message-
> From: Bart Van Assche
> Sent: Tuesday, August 21, 2018 4:54 AM
> To: jthumsh...@suse.de; h...@lst.de; Avri Altman ;
> martin.peter...@oracle.com; linux-scsi@vger.kernel.org; h...@suse.com;
> j...@linux.vnet.ibm.com; Stanislav Nijn
> On Wed, Sep 05, 2018 at 07:30:03AM +0000, Avri Altman wrote:
> > Looking into the UFSHCI spec (JESD223C March 2016) paragraph 6.2,
> > It doesn't specify any inner structure of the task management
> > request or response, just a bunch of 8 DW each.
> > I gues
> -Original Message-
> From: Christoph Hellwig
> Sent: Tuesday, September 04, 2018 10:16 PM
> To: Avri Altman
> Cc: Christoph Hellwig ; Johannes Thumshirn
> ; Hannes Reinecke ; Bart Van Assche
> ; James E.J. Bottomley
> ; Martin K. Petersen
> ; linux-scsi
> > + */
> > +#ifndef SCSI_BSG_UFS_H
> > +#define SCSI_BSG_UFS_H
> > +
> > +/*
> > + * This file intended to be included by both kernel and user space
> > + */
> > +
> > +
> > +/**
> > + * struct ufs_bsg_upiu - upiu transaction structure
> > + *
> > + * @header: upiu header
> > + * @tsf:
> -Original Message-
> From: Christoph Hellwig
> Sent: Tuesday, September 04, 2018 10:20 PM
> To: Avri Altman
> Cc: Christoph Hellwig ; Johannes Thumshirn
> ; Hannes Reinecke ; Bart Van Assche
> ; James E.J. Bottomley
> ; Martin K. Petersen
> ; linux-scsi
> -Original Message-
> From: linux-scsi-ow...@vger.kernel.org
> On Behalf Of Christoph Hellwig
> Sent: Tuesday, September 04, 2018 10:12 PM
> To: Avri Altman
> Cc: Christoph Hellwig ; Johannes Thumshirn
> ; Hannes Reinecke ; Bart Van Assche
> ; James E.J
> > ---
> > drivers/scsi/ufs/ufshcd.c | 35 ++-
> > 1 file changed, 26 insertions(+), 9 deletions(-)
> >
> > diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
> > index d18832a..15be103 100644
> > --- a/drivers/scsi/ufs/ufshcd.c
> > +++
Ok thanks.
Will test and those as the first 2 patches in the series.
Thanks a lot,
Avri
> -Original Message-
> From: Christoph Hellwig
> Sent: Wednesday, September 05, 2018 8:15 PM
> To: Avri Altman
> Cc: Christoph Hellwig ; Johannes Thumshirn
> ; Hannes Reinecke
- needed a couple of patches for that,
and call req_upiu and rsp_upio with their appropriate struct pointers.
Use a more appropriate name when checking if enough memory
was allocated for write descriptor, and remove redundant goto.
Add reference to the spec to explain uic command size.
Fix a lot of typos.
structure - ufs_bsg_node has
a pretty lean structure: using upiu transactions that contains
the outmost detailed info, so we don't really need complex
constructs to support it.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/Kconfig | 19 ++
drivers/scsi/ufs/Makefile | 3 +
drivers/scsi/ufs
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly,
as it will be copied without any further input validations.
Signed-off
Do that in order to re-use its code if the task request and response
UPIUs are given externally.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 39 ---
1 file changed, 28 insertions(+), 11 deletions(-)
diff --git a/drivers/scsi/ufs/ufshcd.c b
Add support to those uic commands, that are currently supported
by ufshcd api: the variants of dme_{peer}_{set_get}.
At this point better not to add any new api, as careless
uic command may turn the device into a brick.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 54
for that.
We also still not supporting uic commands:
For first phase, we plan to use the existing api,
and send only uic commands that are already supported.
Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 127
From: Christoph Hellwig
Remove the pointless task_req_upiu and task_rsp_upiu indirections,
which are __le32 arrays always cast to given structures and just add
the members directly. Also clean up variables names in use in the
callers a bit to make the code more readable.
Signed-off-by:
From: Christoph Hellwig
Add a helper that takes a utp_task_req_desc and issues it, which will
be useful for UFS bsg support. Rewrite ufshcd_issue_tm_cmd0x to use
this new helper.
Signed-off-by: Christoph Hellwig
---
drivers/scsi/ufs/ufshcd.c | 140
12:28 AM
To: Avri Altman; Christoph Hellwig; Johannes Thumshirn; Hannes Reinecke; Bart
Van Assche; James E.J. Bottomley; Martin K. Petersen; linux-scsi@vger.kernel.org
Cc: Stanislav Nijnikov; Avi Shchislowski; Alex Lemberg; Subhash Jadavani;
Vinayak Holikatti
Subject: RE: [PATCH v8 0/8] scsi: Add
From: Christoph Hellwig
Add a helper that takes a utp_task_req_desc and issues it, which will
be useful for UFS bsg support. Rewrite ufshcd_issue_tm_cmd0x to use
this new helper.
Signed-off-by: Christoph Hellwig
Tested-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 141
in preparation to send UPIU requests via bsg.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs.h | 61 +
include/uapi/scsi/scsi_bsg_ufs.h | 74
2 files changed, 75 insertions(+), 60 deletions(-)
create mode
structure - ufs_bsg_node has
a pretty lean structure: using upiu transactions that contains
the outmost detailed info, so we don't really need complex
constructs to support it.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
---
Documentation/scsi/ufs.txt
-by: Christoph Hellwig
Tested-by: Avri Altman
---
drivers/scsi/ufs/ufs.h| 30 -
drivers/scsi/ufs/ufshcd.c | 68 ++-
drivers/scsi/ufs/ufshci.h | 25 +
3 files changed, 34 insertions(+), 89 deletions(-)
diff --git a/drivers
Make ufshcd_send_uic_cmd() public for that.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
---
drivers/scsi/ufs/ufs_bsg.c | 11 +++
drivers/scsi/ufs/ufshcd.c| 3 +--
drivers/scsi/ufs/ufshcd.h| 2 ++
include/uapi/scsi
for that.
We also still not supporting uic commands:
For first phase, we plan to use the existing api,
and send only uic commands that are already supported.
Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
Use the structure size in pointer arithmetic's instead of
an opaque 32 bytes for the over allocation of descriptors.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
---
drivers/scsi/ufs/ufs.h| 2 +-
drivers/scsi/ufs/ufshcd.c | 3 +--
2 files changed, 2 insertions(+), 3 deletions
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly,
as it will be copied without any further input validations.
Signed
was allocated for write descriptor, and remove redundant goto.
Add reference to the spec to explain uic command size.
Fix a lot of typos.
Avri Altman (6):
uapi: ufs: Make utp_upiu_req visible to user space
scsi: ufs: Add ufs-bsg module
scsi: ufs: Use data structure size in pointer arithmetic
> > +
> > +/*
> > + * This file intended to be included by both kernel and user space
> > + */
> > +
> > +#define MAX_CDB_SIZE 16
>
> Please rename this constant such that it has either "UFS" or "UTP" in its
> name. This name is too generic for a protocol-specific header file.
Done.
-by: Christoph Hellwig
Tested-by: Avri Altman
---
drivers/scsi/ufs/ufs.h| 30 -
drivers/scsi/ufs/ufshcd.c | 68 ++-
drivers/scsi/ufs/ufshci.h | 25 +
3 files changed, 34 insertions(+), 89 deletions(-)
diff --git a/drivers
name when checking if enough memory
was allocated for write descriptor, and remove redundant goto.
Add reference to the spec to explain uic command size.
Fix a lot of typos.
Avri Altman (6):
uapi: ufs: Make utp_upiu_req visible to user space
scsi: ufs: Add ufs-bsg module
scsi: ufs: Use da
in preparation to send UPIU requests via bsg.
Signed-off-by: Avri Altman
Reviewed-by: Bart Van Assche
---
drivers/scsi/ufs/ufs.h | 61 +
drivers/scsi/ufs/ufshcd.c| 6 ++--
include/uapi/scsi/scsi_bsg_ufs.h | 74
Use the structure size in pointer arithmetic's instead of
an opaque 32 bytes for the over allocation of descriptors.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
---
drivers/scsi/ufs/ufs.h| 2 +-
drivers/scsi/ufs/ufshcd.c | 3 +--
2 files changed, 2 insertions(+), 3 deletions
From: Christoph Hellwig
Add a helper that takes a utp_task_req_desc and issues it, which will
be useful for UFS bsg support. Rewrite ufshcd_issue_tm_cmd0x to use
this new helper.
Signed-off-by: Christoph Hellwig
Tested-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 141
Make ufshcd_send_uic_cmd() public for that.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
---
drivers/scsi/ufs/ufs_bsg.c | 11 +++
drivers/scsi/ufs/ufshcd.c| 3 +--
drivers/scsi/ufs/ufshcd.h| 2 ++
include/uapi/scsi
structure - ufs_bsg_node has
a pretty lean structure: using upiu transactions that contains
the outmost detailed info, so we don't really need complex
constructs to support it.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
---
Documentation/scsi/ufs.txt
for that.
We also still not supporting uic commands:
For first phase, we plan to use the existing api,
and send only uic commands that are already supported.
Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly,
as it will be copied without any further input validations.
Signed
in preparation to send UPIU requests via bsg.
Signed-off-by: Avri Altman
Reviewed-by: Bart Van Assche
Reviewed-by: Christoph Hellwig
---
drivers/scsi/ufs/ufs.h | 61 +
drivers/scsi/ufs/ufshcd.c| 6 ++--
include/uapi/scsi/scsi_bsg_ufs.h | 74
for
that.
We also still not supporting uic commands: For first phase, we plan to
use the existing api, and send only uic commands that are already
supported. Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
ufshcd_issue_tm_cmd code - needed a couple of patches for that,
and call req_upiu and rsp_upio with their appropriate struct pointers.
Use a more appropriate name when checking if enough memory
was allocated for write descriptor, and remove redundant goto.
Add reference to the spec to explain uic comm
From: Christoph Hellwig
Add a helper that takes a utp_task_req_desc and issues it, which will
be useful for UFS bsg support. Rewrite ufshcd_issue_tm_cmd0x to use
this new helper.
Signed-off-by: Christoph Hellwig
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 141
structure: using upiu transactions that contains the outmost
detailed info, so we don't really need complex constructs to support it.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
---
Documentation/scsi/ufs.txt | 20 +
drivers/scsi/ufs
Make ufshcd_send_uic_cmd() public for that.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
Reviewed-by: Bart Van Assche
---
drivers/scsi/ufs/ufs_bsg.c | 11 +++
drivers/scsi/ufs/ufshcd.c| 3 +--
drivers/scsi/ufs/ufshcd.h| 2 ++
include/uapi/scsi
-by: Christoph Hellwig
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs.h| 30 -
drivers/scsi/ufs/ufshcd.c | 68 ++-
drivers/scsi/ufs/ufshci.h | 25 +
3 files changed, 34 insertions(+), 89 deletions(-)
diff --git
Use the structure size in pointer arithmetic's instead of an opaque 32
bytes for the over allocation of descriptors.
Signed-off-by: Avri Altman
Reviewed-by: Christoph Hellwig
---
drivers/scsi/ufs/ufs.h| 2 +-
drivers/scsi/ufs/ufshcd.c | 3 +--
2 files changed, 2 insertions(+), 3 deletions
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly, as it will be
copied without any further input validations.
Signed
> >
> > diff --git a/include/uapi/scsi/scsi_bsg_ufs.h
> > b/include/uapi/scsi/scsi_bsg_ufs.h
> > new file mode 100644
> > index 000..4108ce3
> > --- /dev/null
> > +++ b/include/uapi/scsi/scsi_bsg_ufs.h
> > @@ -0,0 +1,74 @@
> > +/* SPDX-License-Identifier: GPL-2.0 */
> > +/*
> > + * TBD - UFS
> On Thu, Oct 04, 2018 at 08:20:30AM +0300, Avri Altman wrote:
> > From: Christoph Hellwig
> >
> > Remove the pointless task_req_upiu and task_rsp_upiu indirections,
> > which are __le32 arrays always cast to given structures and just add
> > the members directl
> > Add a bsg endpoint that supports UPIUs.
>
> This should probably go into the subject line.
Done.
>
> >
> > For now, just provide an API to allocate and remove
> > ufs-bsg node. We will use this framework to
> > manage ufs devices by sending UPIU transactions.
>
> Please use up to 73
gt; >Will reply with the full list on Sunday.
> >
> >Thanks,
> >Avri
> >____
> >From: Bean Huo (beanhuo)
> >Sent: Friday, October 5, 2018 12:28 AM
> >To: Avri Altman; Christoph Hellwig; Johannes Thumshirn; Hannes Rein
for that.
We also still not supporting uic commands:
For first phase, we plan to use the existing api,
and send only uic commands that are already supported.
Anyway, all that will come in the next patch.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 118
Add support to those uic commands, that are currently supported
by ufshcd api: the variants of dme_{peer}_{set_get}.
At this point better not to add any new api, as careless
uic command may turn the device into a brick.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufs_bsg.c | 56
priate name when checking if enough memory
was allocated for write descriptor, and remove redundant goto.
Add reference to the spec to explain uic command size.
Fix a lot of typos.
Avri Altman (7):
scsi: ufs: Add ufs-bsg module
scsi: ufs: Instantiate a ufs bsg if its available
scsi: uf
structure - ufs_bsg_node has
a pretty lean structure: using upiu transactions that contains
the outmost detailed info, so we don't really need complex
constructs to support it.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/Kconfig | 19 +
drivers/scsi/ufs/Makefile| 1
Do that in preparation to re-use ufshcd_issue_tm_cmd code.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 50 +++
1 file changed, 29 insertions(+), 21 deletions(-)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c
index
Do that in order to re-use its code if the task request and response
UPIUs are given externally.
Signed-off-by: Avri Altman
---
drivers/scsi/ufs/ufshcd.c | 35 ++-
1 file changed, 26 insertions(+), 9 deletions(-)
diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers
and task work queues.
That is, all utrd-typed UPIUs are "disguised" as device management
commands. Similarly, the utmrd-typed UPUIs uses the task management
infrastructure.
It is up to the caller to fill the upiu request properly,
as it will be copied without any further input validations.
Signed-off
1 - 100 of 136 matches
Mail list logo