RE: [PATCH 1/1] scsi: ufs: Print real incorrect request response code

2019-04-15 Thread Winkler, Tomas
> On 4/15/19 5:23 AM, Stanley Chu wrote: > > If UFS device responds an unknown request response code, we can not > > know what it was via logs because the code is replaced by "DID_ERROR > > << 16" before log printing. > > > > Fix this to provide precise request response code information for > > ea

RE: [PATCH] scsi: ufs: remove unnecessary pointer judgement

2019-03-30 Thread Winkler, Tomas
> > The pointer value is initialized as &hba->vreg_info, and it's never changed. > It's > not necessary to check the pointer is null or not. > > Signed-off-by: Zeng Guangyue Looks like you are correct. Ack. Thanks Tomas > --- > drivers/scsi/ufs/ufshcd.c | 11 +-- > 1 file changed,

RE: [PATCH] scsi: ufs: revamp string descriptor reading

2019-01-16 Thread Winkler, Tomas
> > Hello Tomas, > > > > > > > > Define new a type: uc_string_id for easier string handling and less > > > casting. Reduce number or string copies in price of a dynamic > > > allocation. > > > > > > Signed-off-by: Tomas Winkler > > Tested-by: Avri Altman > > > > Just one nit - doesn't really matt

RE: [PATCH v1] scsi: ufs: Use explicit access size in ufshcd_dump_regs

2019-01-16 Thread Winkler, Tomas
> > On 09/01/2019 16:38, Jeffrey Hugo wrote: > > >> On 11/12/2018 15:18, Marc Gonzalez wrote: > >> > >>> memcpy_fromio() doesn't provide any control over access size. > >>> For example, on arm64, it is implemented using readb and readq. > >>> This may trigger a synchronous external abort: > >>> >

RE: [PATCH v1] scsi: ufs: Use explicit access size in ufshcd_dump_regs

2018-12-13 Thread Winkler, Tomas
> memcpy_fromio() doesn't provide any control over access size. > For example, on arm64, it is implemented using readb and readq. > This may trigger a synchronous external abort: > > [3.729943] Internal error: synchronous external abort: 96000210 [#1] > PREEMPT SMP > [3.737000] Modules l

RE: [PATCH] scsi: ufs: revamp string descriptor reading

2018-12-13 Thread Winkler, Tomas
> -Original Message- > From: Avri Altman [mailto:avri.alt...@wdc.com] > Sent: Tuesday, December 11, 2018 18:18 > To: Winkler, Tomas ; James E . J . Bottomley > ; Martin K . Petersen > ; Vinayak Holikatti ; > Hunter, Adrian > Cc: Christoph Hellwig ; Vivek Gau

RE: [PATCH v7 09/11] scsi: ufs: connect to RPMB subsystem

2017-03-22 Thread Winkler, Tomas
> > On Mon, Nov 07, 2016 at 07:27:38PM +, Winkler, Tomas wrote: > > I value your opinion but I'm not responsible for inventing RPMB > > and/or its implementation storage devices (eMMC, UFC, NVMe), it's pretty > much done deal out there in the wild. > >

RE: [PATCH v7 09/11] scsi: ufs: connect to RPMB subsystem

2016-11-07 Thread Winkler, Tomas
> > On Mon, Nov 07, 2016 at 09:53:12PM +0200, Tomas Winkler wrote: > > Register UFS RPMB LUN with the RPMB subsystem and provide > > implementation for the RPMB access operations. RPMB partition is > > accessed via a sequence of security protocol in and security protocol > > out commands with UFS

RE: [PATCH v6 1/9] rpmb: add Replay Protected Memory Block (RPMB) subsystem

2016-09-24 Thread Winkler, Tomas
> > > > > > Signed-off-by: Tomas Winkler > > Signed-off-by: Alexander Usyskin > Tested-by: Avri Altman > > - mmc - full functionality. One issue found that was fixed on V6: patch V6 > 2/9. > - ufs - read & read counter only. Testing is still wip. > > > > +static int rpmb_request_verify(s

RE: [PATCH v6 0/9] Replay Protected Memory Block (RPMB) subsystem

2016-09-20 Thread Winkler, Tomas
> > On Mon, Sep 19, 2016 at 12:17:48PM +, Winkler, Tomas wrote: > > \ > > > Subject: [PATCH v6 0/9] Replay Protected Memory Block (RPMB) > > > subsystem > > > > > > > > > Few storage technologies such is EMMC, UFS, and NVMe support RPM

RE: [PATCH v6 0/9] Replay Protected Memory Block (RPMB) subsystem

2016-09-19 Thread Winkler, Tomas
\ > Subject: [PATCH v6 0/9] Replay Protected Memory Block (RPMB) subsystem > > > Few storage technologies such is EMMC, UFS, and NVMe support RPMB > hardware partition with common protocol and frame layout. > The RPMB partition cannot be accessed via standard block layer, but by a set > of specif

RE: [PATCH v5 4/8] char: rpmb: provide a user space interface

2016-09-04 Thread Winkler, Tomas
\ > Subject: Re: [PATCH v5 4/8] char: rpmb: provide a user space interface > > On Sun 2016-09-04 11:35:33, Winkler, Tomas wrote: > > > > > On Thu, Sep 01, 2016 at 08:05:26PM +, Winkler, Tomas wrote: > > > > > > > > > > > > > &

RE: [PATCH v5 4/8] char: rpmb: provide a user space interface

2016-09-04 Thread Winkler, Tomas
> On Thu, Sep 01, 2016 at 08:05:26PM +0000, Winkler, Tomas wrote: > > > > > > > > On Sun, Aug 07, 2016 at 09:44:03AM +, Winkler, Tomas wrote: > > > > > > > > > > On Mon 2016-07-18 23:27:49, Tomas Winkler wrote: > > &

RE: [PATCH v5 4/8] char: rpmb: provide a user space interface

2016-09-01 Thread Winkler, Tomas
> > On Sun, Aug 07, 2016 at 09:44:03AM +, Winkler, Tomas wrote: > > > > > > On Mon 2016-07-18 23:27:49, Tomas Winkler wrote: > > > > The user space API is achieved via two synchronous IOCTL. > > > > > > IOCTLs? > > > > Will

RE: [PATCH v5 3/8] char: rpmb: add device attributes

2016-09-01 Thread Winkler, Tomas
> > On Mon, Jul 18, 2016 at 11:27:48PM +0300, Tomas Winkler wrote: > > Add attribute type that displays underlay storage type technology > > EMMC, UFS, and attribute id, that displays underlay storage device id. > > For EMMC this would be content of CID and for UFS serial number from > > the devic

RE: [PATCH v5 5/8] char: rpmb: add RPMB simulation device

2016-09-01 Thread Winkler, Tomas
> > On Mon, Jul 18, 2016 at 11:27:50PM +0300, Tomas Winkler wrote: > > This is a simple platform device used for testing the RPMB subsystem. > > > > The module currently supports two configuration options: > > 1. max_wr_blks: for specifying max blocks that can be written in a > > single command 2.

RE: [PATCH v5 4/8] char: rpmb: provide a user space interface

2016-08-07 Thread Winkler, Tomas
> > On Mon 2016-07-18 23:27:49, Tomas Winkler wrote: > > The user space API is achieved via two synchronous IOCTL. > > IOCTLs? Will fix > > Simplified one, RPMB_IOC_REQ_CMD, were read result cycles is > performed > > by the framework on behalf the user and second, RPMB_IOC_SEQ_CMD > where > >

RE: [PATCH v5 0/8] Replay Protected Memory Block (RPMB) subsystem

2016-07-23 Thread Winkler, Tomas
> > Few storage technologies such is EMMC, UFS, and NVMe support RPMB > hardware partition with common protocol and frame layout. > The RPMB partition cannot be accessed via standard block layer, but by a set > of specific commands: WRITE, READ, GET_WRITE_COUNTER, and > PROGRAM_KEY. > Such a part

RE: [PATCH v5 4/8] char: rpmb: provide a user space interface

2016-07-20 Thread Winkler, Tomas
> > On Mon, Jul 18, 2016 at 4:27 PM, Tomas Winkler > wrote: > > The user space API is achieved via two synchronous IOCTL. > > Simplified one, RPMB_IOC_REQ_CMD, were read result cycles is > performed > > by the framework on behalf the user and second, RPMB_IOC_SEQ_CMD > where > > the whole RPMB se

RE: [PATCH v4 7/8] mmc: block: register RPMB partition with the RPMB subsystem

2016-06-27 Thread Winkler, Tomas
> 2; > > This looks like it does not support 8KB writes added in v5.1 spec. Can that > be > supported? You are right there is not support for 8K packet, but the change should be simple. I will update the patch. Thanks Tomas -- To unsubscribe from this list: send the line "unsubscribe linux-

RE: [PATCH v4 0/8] Replay Protected Memory Block (RPMB) subsystem

2016-06-14 Thread Winkler, Tomas
>>> wrote: >>> > Few storage technology such is EMMC, UFS, and NVMe support RPMB >>> >hardware partition with common protocol and frame layout. >>> > The RPMB partition cannot be accessed via standard block layer, but >>> >by a set of specific commands: WRITE, READ, GET_WRITE_COUNTER, and >>> >PROG

RE: [PATCH v4 0/8] Replay Protected Memory Block (RPMB) subsystem

2016-06-02 Thread Winkler, Tomas
> > On Wed, Jun 1, 2016 at 2:41 PM, Tomas Winkler > wrote: > > Few storage technology such is EMMC, UFS, and NVMe support RPMB > >hardware partition with common protocol and frame layout. > > The RPMB partition cannot be accessed via standard block layer, but > >by a set of specific commands: WRI

RE: [PATCH v2.5 2/6] scsi_debug: rework resp_report_luns

2016-05-02 Thread Winkler, Tomas
> -Original Message- > From: Hannes Reinecke [mailto:h...@suse.de] > Sent: Monday, May 02, 2016 11:25 > To: Douglas Gilbert ; linux-scsi@vger.kernel.org > Cc: martin.peter...@oracle.com; Winkler, Tomas > ; emi...@redhat.com; > bart.vanass...@sandisk.com > Subj

RE: [PATCH 08/12] scsi_debug: rework resp_report_luns

2016-04-26 Thread Winkler, Tomas
> > Based on "[PATH V2] scsi_debug: rework resp_report_luns" patch sent by > Tomas Winkler on Thursday, 26 Feb 2015. His notes: > 1. Remove duplicated boundary checks which simplify the fill-in > loop > 2. Use more of scsi generic API > Replace fixed length response array a with heap al

RE: [PATCH 2/8] char: rpmb: add sysfs-class ABI documentation

2016-04-24 Thread Winkler, Tomas
> > On Sun 2016-04-03 12:42:46, Tomas Winkler wrote: > > Signed-off-by: Tomas Winkler > > --- > > Documentation/ABI/testing/sysfs-class-rpmb | 15 +++ > > MAINTAINERS| 1 + > > 2 files changed, 16 insertions(+) > > create mode 100644 Documentation/AB

Re: [PATCH v2 6/8] tools rpmb: add RPBM access tool

2016-04-11 Thread Winkler, Tomas
On Tue, 2016-04-05 at 20:16 +0800, kbuild test robot wrote: > Hi Tomas, > > [auto build test ERROR on char-misc/char-misc-testing] > [also build test ERROR on v4.6-rc2 next-20160405] > [if your patch is applied to the wrong git tree, please drop us a > note to help improving the system] > > url: 

RE: [PATCH v2 8/8] scsi: ufs: connect to RPMB subsystem

2016-04-08 Thread Winkler, Tomas
> > On 4/7/2016 10:15 PM, Winkler, Tomas wrote: > > On Wed, 2016-04-06 at 09:51 +0100, Joao Pinto wrote: > >> Hi! > >> > >> On 4/4/2016 12:11 PM, Tomas Winkler wrote: > >>> Register UFS RPMB LUN with the RPMB subsystem and provide > &

Re: [PATCH v2 8/8] scsi: ufs: connect to RPMB subsystem

2016-04-07 Thread Winkler, Tomas
On Wed, 2016-04-06 at 09:51 +0100, Joao Pinto wrote: > Hi! > > On 4/4/2016 12:11 PM, Tomas Winkler wrote: > > Register UFS RPMB LUN with the RPMB subsystem and provide > > implementation for the RPMB access operations. RPMB partition is > > accessed via a sequence of security protocol in and secur

RE: [PATCH v13 0/9] add support for DWC UFS Controller

2016-04-05 Thread Winkler, Tomas
Hi, On 4/5/2016 12:34 AM, Martin K. Petersen wrote: >> "Joao" == Joao Pinto writes: > > Joao, > > Joao> The work consisted of: - Fixed typo in ufshcd-pltfrm.c - Tweak > Joao> ufshcd.c for UFS 2.0 support - Implement ufshcd-dwc which > Joao> contains all DWC HW specific code - Unipro attr

RE: [PATCH 8/8] scsi: ufs: connect to RPMB subsystem

2016-04-04 Thread Winkler, Tomas
> I saw some kbuild robot issues regarding the patchset, so I would suggest you make a v2 of the patch set and I can run some tests with the DW UFS Host design. Yes the second round is on the way but there are (for) quite minor issues. Tomas -- To unsubscribe from this list: send the line "u

RE: [PATCH 0/8] Replay Protected Memory Block (RPMB) subsystem

2016-04-03 Thread Winkler, Tomas
On 04/03/2016 02:42 AM, Tomas Winkler wrote: > Few storage technology such is EMMC, UFS, and NVMe support RPMB > hardware partition with common protocol and frame layout. > The RPMB partition cannot be accessed via standard block layer, but by > a set of specific commands: WRITE, READ, GET_WRIT

Re: [PATCH v12 3/9] added UFS 2.0 capabilities

2016-03-31 Thread Winkler, Tomas
On Thu, 2016-03-31 at 19:57 +0100, Joao Pinto wrote: > Adding UFS 2.0 support to the UFS core driver. > > Signed-off-by: Joao Pinto Looks good to me, though not tested yet Tomas > --- > Changes v11->v12 (Tomas Winkler): > - devicetree binding tweak was moved to a separated patch > - unipro twea

RE: [RESEND] [PATCH v11 3/6] added support for DesignWare Controller

2016-03-29 Thread Winkler, Tomas
diff --git a/drivers/scsi/ufs/ufshcd.h b/drivers/scsi/ufs/ufshcd.h index 2570d94..8b0cdf0 100644 --- a/drivers/scsi/ufs/ufshcd.h +++ b/drivers/scsi/ufs/ufshcd.h @@ -262,6 +262,7 @@ struct ufs_pwr_mode_info { * @suspend: called during host controller PM callback * @resume: called during host c

RE: [RESEND] [PATCH v11 2/6] added UFS 2.0 capabilities

2016-03-29 Thread Winkler, Tomas
Hi Thomas, On 3/29/2016 11:41 AM, Winkler, Tomas wrote: > > Adding UFS 2.0 support to the UFS core driver. > > Signed-off-by: Joao Pinto > Acked-by: Arnd Bergmann > Acked-by: Rob Herring > --- > Changes v8->v11: > - Nothing changed (just to keep up with patch

RE: [RESEND] [PATCH v11 2/6] added UFS 2.0 capabilities

2016-03-29 Thread Winkler, Tomas
Adding UFS 2.0 support to the UFS core driver. Signed-off-by: Joao Pinto Acked-by: Arnd Bergmann Acked-by: Rob Herring --- Changes v8->v11: - Nothing changed (just to keep up with patch set version). Changes v7->v8: - Added "jedec, ufs-2.0" to the ufschd-platform compatibility strings Changes

RE: [PATCH v7] scsi: ufs: add ioctl interface for query request

2016-03-13 Thread Winkler, Tomas
> > On 03/11/2016 02:43 AM, Martin K. Petersen wrote: > >> "Arnd" == Arnd Bergmann writes: > > > > Arnd> Looking through what other drivers do, I've found a couple of > > Arnd> patterns now. n particular, most use the SG_IO ioctl to pass down > > Arnd> commands from user space into a device s

RE: [v4 05/14] scsi: ufs: separate device and host quirks

2016-02-09 Thread Winkler, Tomas
> Currently we use the host quirks mechanism in order to > handle both device and host controller quirks. > In order to support various of UFS devices we should separate > handling the device quirks from the host controller's. > > Reviewed-by: Gilad Broner > Signed-off-by: Raviv Shvili > Signed-

RE: [PATCH v7 02/14] scsi: ufs: clear fields UTRD, UPIU req and rsp before new transfers

2016-02-02 Thread Winkler, Tomas
> Some of the data structures (like response UPIU) and/or its elements > (unused fields) should be cleared before sending out the respective > command to UFS device. > > This change clears the UPIU response data structure for query commands > and NOP command before sending out the command. We al

RE: [PATCH v6 01/15] scsi: ufs: clear UTRD, UPIU req and rsp before new transfers

2015-11-02 Thread Winkler, Tomas
> + cdb_len = min_t(unsigned short, lrbp->cmd->cmd_len, MAX_CDB_SIZE); > + memcpy(ucd_req_ptr->sc.cdb, lrbp->cmd->cmnd, cdb_len); > + if (cdb_len < MAX_CDB_SIZE) > + memset(ucd_req_ptr->sc.cdb + cdb_len, 0, > +(MAX_CDB_SIZE - cdb_len)); It's just 16 byt

RE: [scsi 5/7 RESEND] scsi_debug: schedule_resp fix input variable check

2015-08-31 Thread Winkler, Tomas
> > On Sun, 2015-08-30 at 10:36 +, Winkler, Tomas wrote: > > > > > > > > > > > > > > > I'm just not sure why the patches are not merged or even rejected. > > > > > > > > Because ideally I want a Maintainer ack.

RE: [scsi 5/7 RESEND] scsi_debug: schedule_resp fix input variable check

2015-08-30 Thread Winkler, Tomas
> > > > > > > > > I'm just not sure why the patches are not merged or even rejected. > > > > Because ideally I want a Maintainer ack. That's Doug Gilbert. James The patches were discussed and the ACked by Doug in February and reviewed again after resend by Martin Petersen > > > > > I'm submi

RE: [scsi 5/7 RESEND] scsi_debug: schedule_resp fix input variable check

2015-08-25 Thread Winkler, Tomas
> > + /* this should never happen */ > > + if (WARN_ON(!cmnd)) > > + return SCSI_MLQUEUE_HOST_BUSY; > > > > - if (NULL == cmnd || NULL == devip) { > > - pr_warn("called with NULL cmnd or devip pointer\n"); > > + if (NULL == devip) { > > + pr_warn("called devip

RE: [PATCH] scsi_debug: rework resp_report_luns

2015-02-25 Thread Winkler, Tomas
> Correct, so if the app client sets an allocation length > of 3, then at your discretion, you can either leave the > code doing what it does now, or return those 3 bytes. > IOW leave it alone, improve it but don't make it worse. Ack, got the new spec and looks like the check < 4 is the correct on

RE: [PATCH] scsi_debug: rework resp_report_luns

2015-02-24 Thread Winkler, Tomas
> On 15-02-24 04:37 PM, Tomas Winkler wrote: > > 1. Fix the error check: the alloc length should be > 16 > > and not > 4 > > You are proposing to make a marginally incorrect test > completely incorrect! Quoting from the spec: The ALLOCATION LENGTH field is defined in 2.2.6. The allocation length

RE: [scsi 1/2] scsi_debug: schedule_resp fix input variable check

2015-02-23 Thread Winkler, Tomas
> > @@ -3947,11 +3947,18 @@ schedule_resp(struct scsi_cmnd *cmnd, struct > sdebug_dev_info *devip, > > struct sdebug_queued_cmd *sqcp = NULL; > > struct scsi_device *sdp = cmnd->device; > > This patch seems incorrect because it still dereferences > cmnd (in the above line) before it checks