Message ID | 1398416351-30567-4-git-send-email-kefeng.wang@linaro.org |
---|---|
State | New |
Headers | show |
On Fri, Apr 25, 2014 at 04:59:11PM +0800, Kefeng Wang wrote: > The hip04 SoC of hisilicon has an AHCI compliant SATA controller, > and it is compliant with the ahci 1.3 and sata 3.0 specification. > > There is a wrong bit in HOST_CAP of hip04 sata controller, which > enable unsupported feature of FBS, use AHCI_HFLAG_NO_FBS hflag to > disable it. > > Signed-off-by: Kefeng Wang <kefeng.wang@linaro.org> Doesn't apply to libata/for-3.16. Please refresh. Thanks.
On 2014-5-14 3:04, Tejun Heo wrote: > On Fri, Apr 25, 2014 at 04:59:11PM +0800, Kefeng Wang wrote: >> The hip04 SoC of hisilicon has an AHCI compliant SATA controller, >> and it is compliant with the ahci 1.3 and sata 3.0 specification. >> >> There is a wrong bit in HOST_CAP of hip04 sata controller, which >> enable unsupported feature of FBS, use AHCI_HFLAG_NO_FBS hflag to >> disable it. >> >> Signed-off-by: Kefeng Wang <kefeng.wang@linaro.org> > > Doesn't apply to libata/for-3.16. Please refresh. Send new patches, rebased onto libata/for-3.16, based on commit: 58eb8cd565af. Is this OK, if not, please let me know, thanks. > > Thanks. > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
diff --git a/Documentation/devicetree/bindings/ata/ahci-platform.txt b/Documentation/devicetree/bindings/ata/ahci-platform.txt index 48b285f..aab1d70 100644 --- a/Documentation/devicetree/bindings/ata/ahci-platform.txt +++ b/Documentation/devicetree/bindings/ata/ahci-platform.txt @@ -7,7 +7,8 @@ Required properties: - compatible : compatible list, one of "snps,spear-ahci", "snps,exynos5440-ahci", "ibm,476gtr-ahci", "allwinner,sun4i-a10-ahci", "fsl,imx53-ahci" - "fsl,imx6q-ahci" or "snps,dwc-ahci" + "fsl,imx6q-ahci", "snps,dwc-ahci" or + "hisilicon,hisi-ahci" - interrupts : <interrupt mapping for SATA IRQ> - reg : <registers mapping> diff --git a/drivers/ata/ahci_platform.c b/drivers/ata/ahci_platform.c index a476a1f..ebe505c 100644 --- a/drivers/ata/ahci_platform.c +++ b/drivers/ata/ahci_platform.c @@ -16,6 +16,7 @@ #include <linux/module.h> #include <linux/pm.h> #include <linux/device.h> +#include <linux/of_device.h> #include <linux/platform_device.h> #include <linux/libata.h> #include <linux/ahci_platform.h> @@ -33,6 +34,7 @@ static int ahci_probe(struct platform_device *pdev) struct device *dev = &pdev->dev; struct ahci_platform_data *pdata = dev_get_platdata(dev); struct ahci_host_priv *hpriv; + unsigned long hflags = 0; int rc; hpriv = ahci_platform_get_resources(pdev); @@ -55,7 +57,11 @@ static int ahci_probe(struct platform_device *pdev) goto disable_resources; } - rc = ahci_platform_init_host(pdev, hpriv, &ahci_port_info, 0, 0, 0); + if (of_device_is_compatible(dev->of_node, "hisilicon,hisi-ahci")) + hflags |= AHCI_HFLAG_NO_FBS; + + rc = ahci_platform_init_host(pdev, hpriv, &ahci_port_info, + hflags, 0, 0); if (rc) goto pdata_exit; @@ -76,6 +82,7 @@ static const struct of_device_id ahci_of_match[] = { { .compatible = "snps,exynos5440-ahci", }, { .compatible = "ibm,476gtr-ahci", }, { .compatible = "snps,dwc-ahci", }, + { .compatible = "hisilicon,hisi-ahci", }, {}, }; MODULE_DEVICE_TABLE(of, ahci_of_match);
The hip04 SoC of hisilicon has an AHCI compliant SATA controller, and it is compliant with the ahci 1.3 and sata 3.0 specification. There is a wrong bit in HOST_CAP of hip04 sata controller, which enable unsupported feature of FBS, use AHCI_HFLAG_NO_FBS hflag to disable it. Signed-off-by: Kefeng Wang <kefeng.wang@linaro.org> --- .../devicetree/bindings/ata/ahci-platform.txt | 3 ++- drivers/ata/ahci_platform.c | 9 ++++++++- 2 files changed, 10 insertions(+), 2 deletions(-)