Re: [PATCH v2] scsi: ufs: add ioctl interface for query request

2015-10-07 Thread ygardi
Thanks Arnd. comments inline and will upload V3 shortly Yaniv > On Wednesday 07 October 2015 10:54:03 Yaniv Gardi wrote: >> >> +/* IOCTL opcode for command - ufs set device read only */ >> +#define UFS_IOCTL_BLKROSET BLKROSET >> + > > What is this for? Can't you just use the normal BLKROSET

Re: [PATCH v3 6/8] scsi: ufs: make the UFS variant a platform device

2015-08-30 Thread ygardi
> On Sun, Aug 23, 2015 at 8:09 AM, Yaniv Gardi > wrote: >> This change turns the UFS variant (SCSI_UFS_QCOM) into a UFS >> a platform device. >> In order to do so a few additional changes are required: >> 1. The ufshcd-pltfrm is no longer serves as a platform device. >>Now it only serves as a

Re: [PATCH v1 14/15] scsi: ufs: commit descriptors before setting the doorbell

2015-08-30 Thread ygardi
> On Thu, Aug 27, 2015 at 7:11 AM, wrote: >>> On Tue, Aug 25, 2015 at 7:36 AM, wrote: > On Aug 21, 2015 3:10 PM, "Yaniv Gardi" wrote: >> >> Add a write memory barrier to make sure descriptors prepared are >> actually >> written to memory before ringing the doorbell. We have

Re: [PATCH v4 6/8] scsi: ufs: make the UFS variant a platform device

2015-09-02 Thread ygardi
> On Sun, Aug 30, 2015 at 9:52 AM, Yaniv Gardi > wrote: >> This change turns the UFS variant (SCSI_UFS_QCOM) into a UFS >> a platform device. >> In order to do so a few additional changes are required: >> 1. The ufshcd-pltfrm is no longer serves as a platform device. >>Now it only serves as a

Re: [PATCH v5 6/8] scsi: ufs: make the UFS variant a platform device

2015-09-02 Thread ygardi
> On Wed, Sep 2, 2015 at 3:32 AM, Yaniv Gardi wrote: >> This change turns the UFS variant (SCSI_UFS_QCOM) into a UFS >> a platform device. >> In order to do so a few additional changes are required: >> 1. The ufshcd-pltfrm is no longer serves as a platform device. >>Now it only serves as a gro

Re: [PATCH v2 0/8] Fix error message and present UFS variant

2015-10-20 Thread ygardi
> Hi Yaniv, > > 2015-08-23 22:09 GMT+09:00 Yaniv Gardi : >> V3: fixes a few minor issues. >> >> V2: fixes a few issues of unnecessary EXPORT_SYMBOL, >> types of parameters in routine definition, >> build errors in case CONFIG_PM is not defined and some >> other minor fixes. > > I've checked outstan

Re: [PATCH v3 6/8] scsi: ufs: make the UFS variant a platform device

2015-10-25 Thread ygardi
> On Sun, Aug 30, 2015 at 3:43 AM, wrote: >>> On Sun, Aug 23, 2015 at 8:09 AM, Yaniv Gardi >>> wrote: This change turns the UFS variant (SCSI_UFS_QCOM) into a UFS a platform device. In order to do so a few additional changes are required: 1. The ufshcd-pltfrm is no longer ser

Re: [PATCH v3 6/8] scsi: ufs: make the UFS variant a platform device

2015-10-25 Thread ygardi
> On Sun, Aug 23, 2015 at 8:09 AM, Yaniv Gardi > wrote: >> This change turns the UFS variant (SCSI_UFS_QCOM) into a UFS >> a platform device. >> In order to do so a few additional changes are required: >> 1. The ufshcd-pltfrm is no longer serves as a platform device. >>Now it only serves as a

Re: [PATCH v7 6/8] scsi: ufs: make the UFS variant a platform device

2015-10-25 Thread ygardi
> On Thursday 22 October 2015 07:02:14 subha...@codeaurora.org wrote: >> > >> > Required properties: >> > -- compatible: compatible list, contains "jedec,ufs-1.1" >> > +- compatible: compatible list, contains "jedec,ufs-1.1" or >> > +"qcom,msm8994-ufshc" or "qcom,ms

Re: [PATCH v3 03/15] scsi: ufs: verify command tag validity

2015-10-25 Thread ygardi
> 2015-09-02 19:13 GMT+09:00 Yaniv Gardi : >> A race condition appear to exist between request completion when >> scsi_done() is called to end the request and set the tag back to >> -1 (at blk_queue_end_tag() scsi_end_request), and scsi layer error >> handling which aborts the command and reuses it

Re: [PATCH v3 05/15] scsi: ufs: increase fDeviceInit query response timeout

2015-10-25 Thread ygardi
> 2015-09-02 19:13 GMT+09:00 Yaniv Gardi : >> fDeviceInit query response time for some devices is too long that >> default >> query request timeout of 100ms may not be enough. Experiments show that >> fDeviceInit response sometimes takes 500ms so to be on safer side this >> change sets the timeout

Re: [PATCH v3 09/15] scsi: ufs: add retries for hibern8 enter

2015-10-25 Thread ygardi
> 2015-09-02 19:13 GMT+09:00 Yaniv Gardi : >> If hibern8 enter command fails then UFS link state may be unknown which >> may result into timeout of all the commands issued after failure. >> >> This change does 2 things (for pre-defined number of retry counts) after >> hibern8 enter failure: >> 1. R

Re: [PATCH v3 12/15] scsi: ufs: reduce the interrupts for power mode change requests

2015-10-25 Thread ygardi
> 2015-09-02 19:13 GMT+09:00 Yaniv Gardi : >> DME commands such as Hibern8 enter/exit and gear switch generate 2 >> completion interrupts, one for confirmation that command is received >> by local UniPro and 2nd one is the final confirmation after >> communication >> with remote UniPro. Currently b

Re: [PATCH v3 13/15] scsi: ufs: add missing memory barriers

2015-10-25 Thread ygardi
> 2015-09-02 19:13 GMT+09:00 Yaniv Gardi : >> Performing several writes to UFS host controller registers has >> no gurrantee of ordering, so we must make sure register writes >> to setup request list base address etc. are performed before the >> run/stop register is enabled. >> In addition, when se

Re: [PATCH v3 13/15] scsi: ufs: add missing memory barriers

2015-10-26 Thread ygardi
> 2015-10-25 23:40 GMT+09:00 : >>> 2015-09-02 19:13 GMT+09:00 Yaniv Gardi : Performing several writes to UFS host controller registers has no gurrantee of ordering, so we must make sure register writes to setup request list base address etc. are performed before the run/stop re

Re: [PATCH v1 02/17] scsi: ufs: add option to change default UFS power management level

2015-10-26 Thread ygardi
> 2015-09-13 23:52 GMT+09:00 Yaniv Gardi : >> UFS device and link can be put in multiple different low power modes >> hence UFS driver supports multiple different low power modes. >> By default UFS driver selects the default (optimal) low power mode >> (which gives moderate power savings and have r

Re: [PATCH v1 06/17] scsi :ufs: verify hba controller hce reg value

2015-10-26 Thread ygardi
> 2015-09-13 23:52 GMT+09:00 Yaniv Gardi : >> Sometimes due to hw issues it takes some time to the >> host controller register to update. In order to verify the register >> has updated, a polling is done until its value is set. >> >> In addition the functions ufshcd_hba_stop() and >> ufshcd_wait_fo

Re: [PATCH v1 07/17] scsi: ufs: separate device and host quirks

2015-10-26 Thread ygardi
> 2015-09-13 23:52 GMT+09:00 Yaniv Gardi : > >> diff --git a/drivers/scsi/ufs/ufs_quirks.c >> b/drivers/scsi/ufs/ufs_quirks.c >> new file mode 100644 >> index 000..b649bbf >> --- /dev/null >> +++ b/drivers/scsi/ufs/ufs_quirks.c >> @@ -0,0 +1,101 @@ >> +/* >> + * Copyright (c) 2013-2015, The Lin

Re: [PATCH v1 08/17] scsi: ufs: split broken LCC quirk

2015-10-26 Thread ygardi
> 2015-09-13 23:52 GMT+09:00 Yaniv Gardi : >> Currently when UFSHCD_BROKEN_LCC quirk is defined, LCC is getting >> disabled on both host and device side but there could be a need >> where we don't want to disable the LCC on both side hence this change >> splits the quirk in 2 parts one for host and

Re: [PATCH v1 12/17] scsi: ufs: add retry for query descriptors

2015-10-26 Thread ygardi
> 2015-09-13 23:52 GMT+09:00 Yaniv Gardi : >> Query commands have 100ms timeout and it may timeout if they are >> issued in parallel to ongoing read/write SCSI commands, this change >> adds the retry (max: 10) in case command timeouts. >> >> Signed-off-by: Subhash Jadavani >> Signed-off-by: Yaniv

Re: [PATCH v1 14/17] scsi: ufs: tune UniPro parameters to optimize hibern8 exit time

2015-10-26 Thread ygardi
> 2015-09-13 23:52 GMT+09:00 Yaniv Gardi : >> Optimal values of local UniPro parameters like PA_Hibern8Time & >> PA_TActivate can help reduce the hibern8 exit latency. If both host and >> device supports UniPro ver1.6 or later, these parameters will be >> automatically tuned during link startup its

Re: [PATCH v1 16/17] scsi: ufs: add delay before putting UFS rails in low power modes

2015-10-26 Thread ygardi
> 2015-09-13 23:52 GMT+09:00 Yaniv Gardi : >> We put the UFS device in sleep state & UFS link in hibern8 state during >> runtime suspaned. After this we put all the UFS rails in low power >> modes immediately but it seems some devices may still draw more than >> sleep current from UFS rails (especi

Re: [PATCH v2 17/17] scsi: ufs-qcom: fix compilation warnings

2015-10-27 Thread ygardi
> On 10/26/2015 08:41 AM, Yaniv Gardi wrote: >> Tnis patch fixes the following compilation warnings: >> ...ufs-qcom.c:1201:40: >> warning: incorrect type in argument 1 (different address spaces) >> ...ufs-qcom.c:1201:40: >> expected void const *ptr >> ...ufs-qcom.c:1201:40: >> got vo

Re: [PATCH v3 13/15] scsi: ufs: add missing memory barriers

2015-10-27 Thread ygardi
>> 2015-10-25 23:40 GMT+09:00 : 2015-09-02 19:13 GMT+09:00 Yaniv Gardi : > Performing several writes to UFS host controller registers has > no gurrantee of ordering, so we must make sure register writes > to setup request list base address etc. are performed before the > run/s

Re: [PATCH v4] scsi: ufs: add support of generic PHY and ICE in Qualcomm chips

2014-12-25 Thread ygardi
thanks for inputs. shortly I will upload a new version, where I address you comments thanks, Yaniv > > On Thursday 04 December 2014 09:24 PM, Christoph Hellwig wrote: >> On Thu, Nov 27, 2014 at 05:59:58PM +0200, Yaniv Gardi wrote: >>> In this change we add support to the generic PHY framework. >

Re: [PATCH v6 1/4] phy: qcom-ufs: add support for 20nm phy

2015-01-15 Thread ygardi
> Hi, > > On Sunday 11 January 2015 06:08 PM, Yaniv Gardi wrote: >> This change adds a support for a 20nm qcom-ufs phy that is required in >> platforms that use ufs-qcom controller. >> >> Signed-off-by: Yaniv Gardi >> >> --- >> drivers/phy/Kconfig | 7 + >> drivers/phy/Makefile

Re: [PATCH v5 1/4] phy: qcom-ufs: add support for 20nm phy

2015-01-11 Thread ygardi
> > On Jan 7, 2015, at 9:43 AM, Yaniv Gardi wrote: > >> This change adds a support for a 20nm qcom-ufs phy that is >> required in platforms that use ufs-qcom controller. >> >> Signed-off-by: Yaniv Gardi >> >> --- >> drivers/phy/Makefile| 2 + >> drivers/phy/phy-qcom-ufs-i.h

Re: [PATCH v2 4/4] scsi: ufs: probe and init of variant driver from the platform device

2015-06-04 Thread ygardi
> On Wed, 2015-06-03 at 12:37 +0300, Yaniv Gardi wrote: >> --- a/drivers/scsi/ufs/ufs-qcom.c >> +++ b/drivers/scsi/ufs/ufs-qcom.c > >> EXPORT_SYMBOL(ufs_hba_qcom_vops); > > Nothing uses this export. It's still a (static) symbol that is not > included in any header. I think this export serves no pu

Re: [PATCH v2 4/4] scsi: ufs: probe and init of variant driver from the platform device

2015-06-04 Thread ygardi
> Hi Yaniv, > > 2015-06-03 18:37 GMT+09:00 Yaniv Gardi : >> @@ -321,7 +313,22 @@ static int ufshcd_pltfrm_probe(struct >> platform_device *pdev) >> goto out; >> } >> >> - hba->vops = get_variant_ops(&pdev->dev); >> + err = of_platform_populate(node, NULL, NULL, &

Re: [PATCH v2 4/4] scsi: ufs: probe and init of variant driver from the platform device

2015-06-07 Thread ygardi
Thanks Paul for the review and comments. please see inline. > On Wed, 2015-06-03 at 12:37 +0300, Yaniv Gardi wrote: >> --- a/drivers/scsi/ufs/ufs-qcom.c >> +++ b/drivers/scsi/ufs/ufs-qcom.c > >> EXPORT_SYMBOL(ufs_hba_qcom_vops); > > Nothing uses this export. It's still a (static) symbol that is

Re: [PATCH v2 4/4] scsi: ufs: probe and init of variant driver from the platform device

2015-06-07 Thread ygardi
> 2015-06-05 5:53 GMT+09:00 : >>> Hi Yaniv, >>> >>> 2015-06-03 18:37 GMT+09:00 Yaniv Gardi : @@ -321,7 +313,22 @@ static int ufshcd_pltfrm_probe(struct platform_device *pdev) goto out; } - hba->vops = get_variant_ops(&pdev->dev); +

Re: [PATCH v3] scsi: ufs-msm: add UFS controller support for Qualcomm MSM chips

2014-08-21 Thread ygardi
> > On Aug 14, 2014, at 9:22 AM, Yaniv Gardi wrote: > >> The files in this change implement the UFS HW (controller & PHY) >> specific >> behavior in Qualcomm MSM chips. >> >> Signed-off-by: Yaniv Gardi >> --- >> Documentation/devicetree/bindings/ufs/ufs-msm.txt | 37 + >> .../devicetree/binding

Re: [PATCH v1] phy: extend APIs of the generic phy framework

2014-08-04 Thread ygardi
> Hi, > > On Thursday 31 July 2014 06:07 PM, Yaniv Gardi wrote: >> This change adds a few more APIs to the phy_ops structure: >> advertise_quirks - API for setting the phy quirks > > What are these phy quirks? An explanation on what you are are planning to > do > with these quirks might help. A ph

Re: [PATCH v1] phy: extend APIs of the generic phy framework

2014-08-05 Thread ygardi
> Hi, > > On Tuesday 05 August 2014 12:03 AM, yga...@codeaurora.org wrote: >>> Hi, >>> >>> On Thursday 31 July 2014 06:07 PM, Yaniv Gardi wrote: This change adds a few more APIs to the phy_ops structure: advertise_quirks - API for setting the phy quirks >>> >>> What are these phy quirks?

Re: [PATCH v2 0/8] Fix error message and present UFS variant

2015-08-25 Thread ygardi
Thank you Mita, We appreciate your comments and your time. will add "Reviewed-by". regards, Yaniv > Hi Yaniv, > > 2015-08-23 22:09 GMT+09:00 Yaniv Gardi : >> V3: fixes a few minor issues. >> >> V2: fixes a few issues of unnecessary EXPORT_SYMBOL, >> types of parameters in routine definition, >>

Re: [PATCH v3 2/8] scsi: ufs-qcom: fix compilation warning if compiled as a module

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > This change fixes a compilation warning that happens if SCSI_UFS_QCOM > is compiled as a module. > Also this patch fixes an error happens when insmod the module: > "ufs_qcom: module license 'unspecified' taints kernel." > > Signed-off-by: Yaniv Gardi > > --- > driver

Re: [PATCH v3 1/8] phy: qcom-ufs: fix build error when the component is built as a module

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > Export the following functions in order to avoid build errors > when the component PHY_QCOM_UFS is compiled as a module: > > ERROR: "ufs_qcom_phy_disable_ref_clk" > [drivers/scsi/ufs/ufs-qcom.ko] undefined! > ERROR: "ufs_qcom_phy_enable_ref_clk" > [drivers/

Re: [PATCH v3 0/8] Fix error message and present UFS variant

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > V3: fixes a few minor issues. > > V2: fixes a few issues of unnecessary EXPORT_SYMBOL, > types of parameters in routine definition, > build errors in case CONFIG_PM is not defined and some > other minor fixes. > > Yaniv Gardi (8): > phy: qcom-ufs: fix build error whe

Re: [PATCH v3 3/8] scsi: ufs-qcom: update configuration option of SCSI_UFS_QCOM component

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > This change is required in order to be able to build the component > as a module. > > Signed-off-by: Yaniv Gardi > > --- > drivers/scsi/ufs/Kconfig | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/scsi/ufs/Kconfig b/drivers/scsi/ufs/Kc

Re: [PATCH v3 5/8] scsi: ufs: creates wrapper functions for vops

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > In order to simplify the code a set of wrapper functions is created > to test and call each of the variant operations. > > Signed-off-by: Yaniv Gardi > > --- > drivers/scsi/ufs/ufs-qcom.c | 1 - > drivers/scsi/ufs/ufshcd.c | 104 > +--

Re: [PATCH v3 6/8] scsi: ufs: make the UFS variant a platform device

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > This change turns the UFS variant (SCSI_UFS_QCOM) into a UFS > a platform device. > In order to do so a few additional changes are required: > 1. The ufshcd-pltfrm is no longer serves as a platform device. >Now it only serves as a group of platform APIs such as PM

Re: [PATCH v3 8/8] scsi: ufs-qcom: add QUniPro hardware support and power optimizations

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > New revisions of UFS host controller supports the new UniPro > hardware controller (referred as QUniPro). This patch adds > the support to enable this new UniPro controller hardware. > > This change also adds power optimization for bus scaling feature, > as well as su

Re: [PATCH v3 7/8] scsi: ufs-qcom: add debug prints for test bus

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > Adds support for configuring and reading the test bus and debug > registers. This change also adds another vops in order to print the > debug registers. > > Signed-off-by: Yaniv Gardi > > --- > drivers/scsi/ufs/ufs-qcom.c | 165 >

Re: [PATCH v3 4/8] add ufshcd_get_variant ufshcd_set_variant

2015-08-25 Thread ygardi
Reviewed-by: Akinobu Mita > Signed-off-by: Yaniv Gardi > > --- > drivers/scsi/ufs/ufs-qcom.c | 34 +- > drivers/scsi/ufs/ufshcd.h | 21 + > 2 files changed, 38 insertions(+), 17 deletions(-) > > diff --git a/drivers/scsi/ufs/ufs-qcom.c b/dr

Re: [PATCH v1 14/15] scsi: ufs: commit descriptors before setting the doorbell

2015-08-25 Thread ygardi
> On Aug 21, 2015 3:10 PM, "Yaniv Gardi" wrote: >> >> Add a write memory barrier to make sure descriptors prepared are >> actually >> written to memory before ringing the doorbell. We have also added the >> write memory barrier after ringing the doorbell register so that >> controller sees the new

Re: [PATCH v1 15/15] scsi: ufs: add wrapper for retrying sending query attribute

2015-08-25 Thread ygardi
> On Aug 21, 2015 3:10 PM, "Yaniv Gardi" wrote: >> >> Sometimes queries from the device might return a failure so it is >> recommended to retry sending the query, before giving up. >> This change adds a wrapper to retry sending a query attribute, >> in cases where we need to wait longer, before we

Re: [PATCH v1 15/15] scsi: ufs: add wrapper for retrying sending query attribute

2015-08-25 Thread ygardi
> On Aug 21, 2015 3:10 PM, "Yaniv Gardi" wrote: >> >> Sometimes queries from the device might return a failure so it is >> recommended to retry sending the query, before giving up. >> This change adds a wrapper to retry sending a query attribute, >> in cases where we need to wait longer, before we

Re: [PATCH v1 14/15] scsi: ufs: commit descriptors before setting the doorbell

2015-08-27 Thread ygardi
> On Tue, Aug 25, 2015 at 7:36 AM, wrote: >>> On Aug 21, 2015 3:10 PM, "Yaniv Gardi" wrote: Add a write memory barrier to make sure descriptors prepared are actually written to memory before ringing the doorbell. We have also added the write memory barrier after ringing

Re: [PATCH v1 14/15] scsi: ufs: commit descriptors before setting the doorbell

2015-08-27 Thread ygardi
>> On Aug 21, 2015 3:10 PM, "Yaniv Gardi" wrote: >>> >>> Add a write memory barrier to make sure descriptors prepared are >>> actually >>> written to memory before ringing the doorbell. We have also added the >>> write memory barrier after ringing the doorbell register so that >>> controller sees

Re: [PATCH v1 6/8] scsi: ufs: make the UFS variant a platform device

2015-08-20 Thread ygardi
> 2015-08-16 19:14 GMT+09:00 Yaniv Gardi : >> +/** >> + * ufs_qcom_remove - set driver_data of the device to NULL >> + * @pdev: pointer to platform device handle >> + * >> + * Always return 0 >> + */ >> +static int ufs_qcom_remove(struct platform_device *pdev) >> +{ >> + struct ufs_hba *hba =

Re: [PATCH v1 8/8] scsi: ufs-qcom: add QUniPro hardware support and power optimizations

2015-08-20 Thread ygardi
Thank you Mita for the review. Your comments were correct and helpful. I appreciate your time and effort. please see inline. > 2015-08-16 19:14 GMT+09:00 Yaniv Gardi : >> @@ -1208,6 +1510,7 @@ static struct ufs_hba_variant_ops >> ufs_hba_qcom_vops = { >> .resume = ufs_qcom

Re: [PATCH v2 17/17] scsi: ufs-qcom: fix compilation warnings

2015-10-27 Thread ygardi
> On 10/27/2015 03:10 AM, yga...@codeaurora.org wrote: >>> On 10/26/2015 08:41 AM, Yaniv Gardi wrote: Tnis patch fixes the following compilation warnings: ...ufs-qcom.c:1201:40: warning: incorrect type in argument 1 (different address spaces) ...ufs-qcom.c:1201:40: ex

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

2016-02-28 Thread ygardi
>> 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 >>

Re: [PATCH v1 2/3] scsi: ufs-qcom: fix compilation warning if compiled as a module

2015-05-20 Thread ygardi
> On Tue, 2015-05-19 at 16:47 +0300, Yaniv Gardi wrote: >> --- a/drivers/scsi/ufs/ufs-qcom.c >> +++ b/drivers/scsi/ufs/ufs-qcom.c >> @@ -885,7 +885,7 @@ out: >> >> #define ANDROID_BOOT_DEV_MAX30 >> static char android_boot_dev[ANDROID_BOOT_DEV_MAX]; >> -static int get_android_boot_dev(cha

Re: [PATCH v1 3/3] scsi: ufs-qcom: update configuration option of SCSI_UFS_QCOM component

2015-05-21 Thread ygardi
> On Wed, 2015-05-20 at 10:22 +0200, Paul Bolle wrote: >> By the way, as far as I can see, this (new) module can only be loaded >> manually (or via scripts). Is that what people want? > > This comment wasn't well thought through. So I hand another look at the > code of usf-qcom. > > I noticed that

Re: [PATCH v1 3/3] scsi: ufs-qcom: update configuration option of SCSI_UFS_QCOM component

2015-05-21 Thread ygardi
> On Thu, 2015-05-21 at 10:09 +, yga...@codeaurora.org wrote: >> > On Wed, 2015-05-20 at 10:22 +0200, Paul Bolle wrote: >> > Am I missing something obvious here? Because ufs-qcom currently looks >> > pointless to me, and I actually see little reason to even have it in >> the >> > mainline tree.

Re: [PATCH v1 1/3] phy: qcom-ufs: fix build error when the driver is built as a module

2015-05-20 Thread ygardi
> On Tue, 2015-05-19 at 16:47 +0300, Yaniv Gardi wrote: >> Export the following functions in order to avoid build errors >> when the driver is compiled as a module: > > Where "the driver" actually means something like ufs-qcom.c, or > SCSI_UFS_QCOM, or "QCOM specific hooks to UFS controller platfor

Re: [PATCH] phy: qcom-ufs: Switch dependency to ARCH_QCOM

2015-05-12 Thread ygardi
looks good. Acked-by: Yaniv Gardi > This phy only exists on platforms under ARCH_QCOM, not ARCH_MSM. > > Cc: Yaniv Gardi > Cc: Dov Levenglick > Cc: Christoph Hellwig > Cc: David Brown > Cc: Bryan Huntsman > Cc: Daniel Walker > Signed-off-by: Stephen Boyd > --- > drivers/phy/Kconfig | 2

Re: [PATCH] ufs-qcom: Switch dependency to ARCH_QCOM

2015-05-12 Thread ygardi
looks good. Acked-by: Yaniv Gardi > This device only exists on platforms under ARCH_QCOM, not > ARCH_MSM. > > Cc: Yaniv Gardi > Cc: Dov Levenglick > Cc: Vinayak Holikatti > Cc: David Brown > Cc: Bryan Huntsman > Cc: Daniel Walker > Signed-off-by: Stephen Boyd > --- > drivers/scsi/ufs/Kc

Re: [PATCH] phy: qcom-ufs: Switch dependency to ARCH_QCOM

2015-05-12 Thread ygardi
I'd change the tag to Reviewed-by. looks-good. Reviewed-by: Yaniv Gardi > looks good. > > Acked-by: Yaniv Gardi > > >> This phy only exists on platforms under ARCH_QCOM, not ARCH_MSM. >> >> Cc: Yaniv Gardi >> Cc: Dov Levenglick >> Cc: Christoph Hellwig >> Cc: David Brown >> Cc: Bryan Hunt

Re: [PATCH] ufs-qcom: Switch dependency to ARCH_QCOM

2015-05-12 Thread ygardi
I'd change the tag to Reviewed-by. looks-good. Reviewed-by: Yaniv Gardi > looks good. > > Acked-by: Yaniv Gardi > > >> This device only exists on platforms under ARCH_QCOM, not >> ARCH_MSM. >> >> Cc: Yaniv Gardi >> Cc: Dov Levenglick >> Cc: Vinayak Holikatti >> Cc: David Brown >> Cc: Brya

Re: [PATCH] phy: qcom-ufs: export symbols needed by main drivers

2015-02-02 Thread ygardi
> The qcom ufs phy support is split into three separate loadable > modules, however none of the interfaces are exported, resulting > in a link error: > > ERROR: "ufs_qcom_phy_power_off" [drivers/phy/phy-qcom-ufs-qmp-20nm.ko] > undefined! > ERROR: "ufs_qcom_phy_power_on" [drivers/phy/phy-qcom-ufs-qm

Re: [PATCH v7 5/5] scsi: ufs-qcom-ice: add Inline Crypto Engine (ICE) support for UFS

2015-02-02 Thread ygardi
Paul, we have decided to revert the ICE change that support UFS. a change already uploaded: look for subject: [PATCH v1] Revert "scsi: ufs-qcom-ice: add Inline Crypto Engine (ICE) support for UFS" thanks, Yaniv > Yaniv, > > On Thu, 2015-01-15 at 16:32 +0200, Yaniv Gardi wrote: >> From: Yaniv Ga

Re: [PATCH] phy: qcom-ufs: export symbols needed by main drivers

2015-02-02 Thread ygardi
Reviewed-by: Yaniv Gardi > The qcom ufs phy support is split into three separate loadable > modules, however none of the interfaces are exported, resulting > in a link error: > > ERROR: "ufs_qcom_phy_power_off" [drivers/phy/phy-qcom-ufs-qmp-20nm.ko] > undefined! > ERROR: "ufs_qcom_phy_power_on" [

Re: [PATCH v7 03/17] scsi: ufs: implement scsi host timeout handler

2016-03-08 Thread ygardi
> On 03/08/2016 02:01 PM, Hannes Reinecke wrote: >> On 03/08/2016 01:35 PM, Yaniv Gardi wrote: >>> A race condition exists between request requeueing and scsi layer >>> error handling: >>> When UFS driver queuecommand returns a busy status for a request, >>> it will be requeued and its tag will be

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

2016-03-09 Thread ygardi
> On Wed, Mar 09, 2016 at 04:11:33PM +0200, Yaniv Gardi wrote: >> This patch exposes the ioctl interface for UFS driver via SCSI device >> ioctl interface. As of now UFS driver would provide the ioctl for query >> interface to connected UFS device. >> >> Reviewed-by: Subhash Jadavani >> Signed-off

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

2016-03-09 Thread ygardi
> On Wed, Mar 09, 2016 at 04:11:33PM +0200, Yaniv Gardi wrote: >> This patch exposes the ioctl interface for UFS driver via SCSI device >> ioctl interface. As of now UFS driver would provide the ioctl for query >> interface to connected UFS device. >> >> Reviewed-by: Subhash Jadavani >> Signed-off

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

2016-03-09 Thread ygardi
> On Wed, Mar 09, 2016 at 07:09:49PM -, yga...@codeaurora.org wrote: >> > On Wed, Mar 09, 2016 at 04:11:33PM +0200, Yaniv Gardi wrote: >> >> This patch exposes the ioctl interface for UFS driver via SCSI device >> >> ioctl interface. As of now UFS driver would provide the ioctl for >> query >>

Re: [PATCH v7 06/17] scsi: ufs: separate device and host quirks

2016-03-10 Thread ygardi
Martin, the only way i can avoid the circular dependency is to move the routines from ufs_quirks.c into ufshcd.c. i will upload V8 soon thanks, Yaniv >> "Yaniv" == Yaniv Gardi writes: > > Yaniv> Currently we use the host quirks mechanism in order to handle > Yaniv> both device and host co

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

2016-03-10 Thread ygardi
> On Wed, Mar 09, 2016 at 08:52:59PM -, yga...@codeaurora.org wrote: >> > On Wed, Mar 09, 2016 at 07:09:49PM -, yga...@codeaurora.org wrote: >> >> > On Wed, Mar 09, 2016 at 04:11:33PM +0200, Yaniv Gardi wrote: >> >> >> This patch exposes the ioctl interface for UFS driver via SCSI >> device

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

2016-03-10 Thread ygardi
> On Thu, Mar 10, 2016 at 03:52:54PM -, yga...@codeaurora.org wrote: >> > On Wed, Mar 09, 2016 at 08:52:59PM -, yga...@codeaurora.org wrote: >> >> > On Wed, Mar 09, 2016 at 07:09:49PM -, yga...@codeaurora.org >> wrote: >> >> >> > On Wed, Mar 09, 2016 at 04:11:33PM +0200, Yaniv Gardi wro

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

2016-03-10 Thread ygardi
> On Thu, Mar 10, 2016 at 04:29:55PM -, yga...@codeaurora.org wrote: >> > On Thu, Mar 10, 2016 at 03:52:54PM -, yga...@codeaurora.org wrote: >> >> > On Wed, Mar 09, 2016 at 08:52:59PM -, yga...@codeaurora.org >> wrote: >> >> >> > On Wed, Mar 09, 2016 at 07:09:49PM -, yga...@codeauro

Re: [PATCH v3] scsi: ufs: add ioctl interface for query request

2015-10-11 Thread ygardi
thanks Arnd for the comment. V4 is on its way > On Thursday 08 October 2015 14:09:24 Yaniv Gardi wrote: >> This patch exposes the ioctl interface for UFS driver via SCSI device >> ioctl interface. As of now UFS driver would provide the ioctl for query >> interface to connected UFS device. >> >> S

Re: [PATCH v5 03/15] scsi: ufs: implement scsi host timeout handler

2016-03-03 Thread ygardi
> On 03/01/2016 09:25 PM, yga...@codeaurora.org wrote: >>> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: A race condition exists between request requeueing and scsi layer error handling: When UFS driver queuecommand returns a busy status for a request, it will be requeued and its t

Re: [PATCH v5 03/15] scsi: ufs: implement scsi host timeout handler

2016-03-06 Thread ygardi
> On 03/03/2016 05:10 PM, yga...@codeaurora.org wrote: >>> On 03/01/2016 09:25 PM, yga...@codeaurora.org wrote: > On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >> A race condition exists between request requeueing and scsi layer >> error handling: >> When UFS driver queuecommand return

Re: [PATCH v5 15/15] scsi: ufs-qcom: set PA_Local_TX_LCC_Enable before link startup

2016-03-06 Thread ygardi
> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >> Some UFS devices (and may be host) have issues if LCC is >> enabled. So we are setting PA_Local_TX_LCC_Enable to 0 >> before link startup which will make sure that both host >> and device TX LCC are disabled once link startup is >> completed. >> >> Th

Re: [PATCH v5 03/15] scsi: ufs: implement scsi host timeout handler

2016-03-08 Thread ygardi
Hello, Hannes, Re-sending thanks, Yaniv >> On 03/03/2016 05:10 PM, yga...@codeaurora.org wrote: On 03/01/2016 09:25 PM, yga...@codeaurora.org wrote: >> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >>> A race condition exists between request requeueing and scsi layer >>> error hand

Re: [PATCH v5 03/15] scsi: ufs: implement scsi host timeout handler

2016-03-08 Thread ygardi
Hello, Hannes, Re-sending thanks, Yaniv >> On 03/03/2016 05:10 PM, yga...@codeaurora.org wrote: On 03/01/2016 09:25 PM, yga...@codeaurora.org wrote: >> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >>> A race condition exists between request requeueing and scsi layer >>> error hand

Re: [PATCH v7 03/17] scsi: ufs: implement scsi host timeout handler

2016-03-08 Thread ygardi
> On 03/08/2016 01:35 PM, Yaniv Gardi wrote: >> A race condition exists between request requeueing and scsi layer >> error handling: >> When UFS driver queuecommand returns a busy status for a request, >> it will be requeued and its tag will be freed and set to -1. >> At the same time it is possibl

Re: [PATCH v5 08/15] scsi: ufs: make error handling bit faster

2016-03-01 Thread ygardi
> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >> UFS driver's error handler forcefully tries to clear all the pending >> requests. For each pending request in the queue, it waits 1 sec for it >> to get cleared. If we have multiple requests in the queue then it's >> possible that we might end up wait

Re: [PATCH v5 05/15] scsi: ufs: add support to read device and string descriptors

2016-03-01 Thread ygardi
> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >> This change adds support to read device descriptor and string descriptor >> from a UFS device >> >> Reviewed-by: Gilad Broner >> Signed-off-by: Raviv Shvili >> Signed-off-by: Yaniv Gardi >> >> --- >> drivers/scsi/ufs/ufs.h| 1 + >> drivers/sc

Re: [PATCH v5 03/15] scsi: ufs: implement scsi host timeout handler

2016-03-01 Thread ygardi
> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >> A race condition exists between request requeueing and scsi layer >> error handling: >> When UFS driver queuecommand returns a busy status for a request, >> it will be requeued and its tag will be freed and set to -1. >> At the same time it is possibl

Re: [PATCH v5 04/15] scsi: ufs: verify hba controller hce reg value

2016-03-01 Thread ygardi
> On 02/28/2016 09:32 PM, Yaniv Gardi wrote: >> Sometimes due to hw issues it takes some time to the >> host controller register to update. In order to verify the register >> has updated, a polling is done until its value is set. >> >> In addition the functions ufshcd_hba_stop() and >> ufshcd_wait_

Re: [PATCH v2 6/8] scsi: ufs: make the UFS variant a platform device

2015-08-21 Thread ygardi
> 2015-08-20 22:59 GMT+09:00 Yaniv Gardi : >> @@ -1036,7 +1037,7 @@ void ufs_qcom_clk_scale_notify(struct ufs_hba >> *hba) >> * The variant operations configure the necessary controller and PHY >> * handshake during initialization. >> */ >> -static const struct ufs_hba_variant_ops ufs_hba_qco

Re: [PATCH v2 7/8] scsi: ufs-qcom: add debug prints for test bus

2015-08-21 Thread ygardi
> 2015-08-20 22:59 GMT+09:00 Yaniv Gardi : >> @@ -30,6 +48,14 @@ static void ufs_qcom_get_speed_mode(struct >> ufs_pa_layer_attr *p, char *result); >> static int ufs_qcom_get_bus_vote(struct ufs_qcom_host *host, >> const char *speed_mode); >> static int ufs_qcom_set_bus_vote(struc

Re: [PATCH v2 7/8] scsi: ufs-qcom: add debug prints for test bus

2015-08-23 Thread ygardi
> 2015-08-20 22:59 GMT+09:00 Yaniv Gardi : > >> +static bool ufs_qcom_testbus_cfg_is_ok(struct ufs_qcom_host *host) >> +{ >> + if (host->testbus.select_major >= TSTBUS_MAX) { >> + dev_err(host->hba->dev, >> + "%s: UFS_CFG1[TEST_BUS_SEL} may not equal >> 0x%

Re: [PATCH v2 6/8] scsi: ufs: make the UFS variant a platform device

2015-08-24 Thread ygardi
> O > n Aug 20, 2015 6:59 AM, "Yaniv Gardi" wrote: >> >> This change turns the UFS variant (SCSI_UFS_QCOM) into a UFS >> a platform device. >> In order to do so a few additional changes are required: >> 1. The ufshcd-pltfrm is no longer serves as a platform device. >>Now it only serves as a gr

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

2016-02-01 Thread ygardi
> > >> +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

Re: [PATCH v6 07/15] scsi: ufs: set REQUEST_SENSE command size to 18 bytes

2016-02-01 Thread ygardi
> On 10/28/2015 02:13 PM, Yaniv Gardi wrote: >> According to UFS device specification REQUEST_SENSE command can >> only report back up to 18 bytes of data. >> >> Reviewed-by: Dolev Raviv >> Signed-off-by: Gilad Broner >> Signed-off-by: Yaniv Gardi >> > Really? The spec only says that the inline