All of lore.kernel.org
 help / color / mirror / Atom feed
* sata_dwc_460ex driver
@ 2016-05-27 14:54 Mason
  2016-05-27 16:20 ` Måns Rullgård
       [not found] ` <CAAd0S9BQoLsz1226seRW697rzNC9=SJDRC=JR2s4242tyg1+4g@mail.gmail.com>
  0 siblings, 2 replies; 7+ messages in thread
From: Mason @ 2016-05-27 14:54 UTC (permalink / raw)
  To: linux-ide
  Cc: Tejun Heo, Hans de Goede, Andy Shevchenko, Mans Rullgard,
	Christian Lamparter, Srinivas Kandagatla, Andy Gross,
	Kishon Vijay Abraham, Sebastian Frias

Hello everyone,

I'm working on a SoC which embeds an IP block from Synopsys labeled
Synopsys DesignWare Cores Serial ATA AHCI Core, aka DWC_ahsata
(DWC SATA AHCI Host 6Gb/s AXI Interface).

Would the sata_dwc_460ex driver support this DWC_ahsata hardware?

I suppose I would also need to enable AHCI support, right?

What is the difference between SATA_AHCI and SATA_AHCI_PLATFORM ?

SATA_AHCI          = 971db06e09231
SATA_AHCI_PLATFORM = 1c2a49f61785e

If I understand correctly, SATA_AHCI is for platforms with a PCI bus,
while SATA_AHCI_PLATFORM is for other platforms. I probably want the
latter then?

On the analog side, the SATA PHY is also made by Synopsys.
Do I need to enable a specific driver?
I didn't see anything relevant in drivers/phy

(The documentation mentions 11 registers for tweaking the controller,
but maybe it's the boot-loader's job to set this up correctly?)

Regards.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sata_dwc_460ex driver
  2016-05-27 14:54 sata_dwc_460ex driver Mason
@ 2016-05-27 16:20 ` Måns Rullgård
  2016-05-27 16:56   ` Mason
       [not found] ` <CAAd0S9BQoLsz1226seRW697rzNC9=SJDRC=JR2s4242tyg1+4g@mail.gmail.com>
  1 sibling, 1 reply; 7+ messages in thread
From: Måns Rullgård @ 2016-05-27 16:20 UTC (permalink / raw)
  To: Mason
  Cc: linux-ide, Tejun Heo, Hans de Goede, Andy Shevchenko,
	Christian Lamparter, Srinivas Kandagatla, Andy Gross,
	Kishon Vijay Abraham, Sebastian Frias

Mason <slash.tmp@free.fr> writes:

> Hello everyone,
>
> I'm working on a SoC which embeds an IP block from Synopsys labeled
> Synopsys DesignWare Cores Serial ATA AHCI Core, aka DWC_ahsata
> (DWC SATA AHCI Host 6Gb/s AXI Interface).
>
> Would the sata_dwc_460ex driver support this DWC_ahsata hardware?
>
> I suppose I would also need to enable AHCI support, right?
>
> What is the difference between SATA_AHCI and SATA_AHCI_PLATFORM ?
>
> SATA_AHCI          = 971db06e09231
> SATA_AHCI_PLATFORM = 1c2a49f61785e
>
> If I understand correctly, SATA_AHCI is for platforms with a PCI bus,
> while SATA_AHCI_PLATFORM is for other platforms. I probably want the
> latter then?
>
> On the analog side, the SATA PHY is also made by Synopsys.
> Do I need to enable a specific driver?
> I didn't see anything relevant in drivers/phy
>
> (The documentation mentions 11 registers for tweaking the controller,
> but maybe it's the boot-loader's job to set this up correctly?)

The sata_dwc_460ex driver can be made to work with the tango3/4 chips.
You need a dmaengine driver (I've written one for tango3, needs slight
tweaking for tango4) and some additions to the SATA driver to handle the
DMA glue logic (I have unpublished code for this as well).  There are a
bunch of fixes for the SATA driver currently in linux-next, and I was
planning to take another look at supporting tango3/4 once these hit
mainline (4.7-rc1 most likely).

A driver for the PHY is probably a good idea, even if the boot loader
does some configuration, since this allows it to be powered down when
not in use.

-- 
Måns Rullgård

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sata_dwc_460ex driver
  2016-05-27 16:20 ` Måns Rullgård
@ 2016-05-27 16:56   ` Mason
  2016-05-27 18:15     ` Andy Gross
  0 siblings, 1 reply; 7+ messages in thread
From: Mason @ 2016-05-27 16:56 UTC (permalink / raw)
  To: Mans Rullgard
  Cc: linux-ide, Tejun Heo, Hans de Goede, Andy Shevchenko,
	Christian Lamparter, Srinivas Kandagatla, Andy Gross,
	Kishon Vijay Abraham, Sebastian Frias

On 27/05/2016 18:20, Måns Rullgård wrote:

> Mason wrote:
> 
>> I'm working on a SoC which embeds an IP block from Synopsys labeled
>> Synopsys DesignWare Cores Serial ATA AHCI Core, aka DWC_ahsata
>> (DWC SATA AHCI Host 6Gb/s AXI Interface).
>>
>> Would the sata_dwc_460ex driver support this DWC_ahsata hardware?
>>
>> I suppose I would also need to enable AHCI support, right?
>>
>> What is the difference between SATA_AHCI and SATA_AHCI_PLATFORM ?
>>
>> SATA_AHCI          = 971db06e09231
>> SATA_AHCI_PLATFORM = 1c2a49f61785e
>>
>> If I understand correctly, SATA_AHCI is for platforms with a PCI bus,
>> while SATA_AHCI_PLATFORM is for other platforms. I probably want the
>> latter then?
>>
>> On the analog side, the SATA PHY is also made by Synopsys.
>> Do I need to enable a specific driver?
>> I didn't see anything relevant in drivers/phy
>>
>> (The documentation mentions 11 registers for tweaking the controller,
>> but maybe it's the boot-loader's job to set this up correctly?)
> 
> The sata_dwc_460ex driver can be made to work with the tango3/4 chips.

I'm talking about tango5. It's not the same controller as tango3/4.
(They use different Synopsys DesignWare controllers.)

> You need a dmaengine driver (I've written one for tango3, needs slight
> tweaking for tango4) and some additions to the SATA driver to handle the
> DMA glue logic (I have unpublished code for this as well).  There are a
> bunch of fixes for the SATA driver currently in linux-next, and I was
> planning to take another look at supporting tango3/4 once these hit
> mainline (4.7-rc1 most likely).

FWIW, it seems like tango4 is low-priority internally ATM.

> A driver for the PHY is probably a good idea, even if the boot loader
> does some configuration, since this allows it to be powered down when
> not in use.

How come there are so few phy drivers in drivers/phy if most devices
would typically require one?

Regards.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sata_dwc_460ex driver
       [not found] ` <CAAd0S9BQoLsz1226seRW697rzNC9=SJDRC=JR2s4242tyg1+4g@mail.gmail.com>
@ 2016-05-27 17:33   ` Mason
  0 siblings, 0 replies; 7+ messages in thread
From: Mason @ 2016-05-27 17:33 UTC (permalink / raw)
  To: Christian Lamparter; +Cc: Sebastian Frias, linux-ide

On 27/05/2016 17:12, Christian Lamparter wrote:

> As far as I know, the ahci dwc core can be supported via the libahci of.
> The binding is already present.
> See http://lxr.free-electrons.com/source/Documentation/devicetree/bindings/ata/ahci-platform.txt
> (snps,dwc-ahci). The SATA_dwc_460ex is not necessary in this case.

Hello Christian,

Thanks for the information.

By the way, I see no difference between using "snps,dwc-ahci"
and "generic-ahci" compatible strings, correct?

Note: I've added linux-ide back to the mix ;-)

Regards.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sata_dwc_460ex driver
  2016-05-27 16:56   ` Mason
@ 2016-05-27 18:15     ` Andy Gross
  2016-05-27 18:41       ` Mason
  0 siblings, 1 reply; 7+ messages in thread
From: Andy Gross @ 2016-05-27 18:15 UTC (permalink / raw)
  To: Mason
  Cc: Mans Rullgard, linux-ide, Tejun Heo, Hans de Goede,
	Andy Shevchenko, Christian Lamparter, Srinivas Kandagatla,
	Kishon Vijay Abraham, Sebastian Frias

On 27 May 2016 at 11:56, Mason <slash.tmp@free.fr> wrote:
> On 27/05/2016 18:20, Måns Rullgård wrote:
>
>> Mason wrote:
>>
>>> I'm working on a SoC which embeds an IP block from Synopsys labeled
>>> Synopsys DesignWare Cores Serial ATA AHCI Core, aka DWC_ahsata
>>> (DWC SATA AHCI Host 6Gb/s AXI Interface).
>>>
>>> Would the sata_dwc_460ex driver support this DWC_ahsata hardware?
>>>
>>> I suppose I would also need to enable AHCI support, right?
>>>
>>> What is the difference between SATA_AHCI and SATA_AHCI_PLATFORM ?
>>>
>>> SATA_AHCI          = 971db06e09231
>>> SATA_AHCI_PLATFORM = 1c2a49f61785e
>>>
>>> If I understand correctly, SATA_AHCI is for platforms with a PCI bus,
>>> while SATA_AHCI_PLATFORM is for other platforms. I probably want the
>>> latter then?
>>>
>>> On the analog side, the SATA PHY is also made by Synopsys.
>>> Do I need to enable a specific driver?
>>> I didn't see anything relevant in drivers/phy
>>>
>>> (The documentation mentions 11 registers for tweaking the controller,
>>> but maybe it's the boot-loader's job to set this up correctly?)
>>
>> The sata_dwc_460ex driver can be made to work with the tango3/4 chips.
>
> I'm talking about tango5. It's not the same controller as tango3/4.
> (They use different Synopsys DesignWare controllers.)
>
>> You need a dmaengine driver (I've written one for tango3, needs slight
>> tweaking for tango4) and some additions to the SATA driver to handle the
>> DMA glue logic (I have unpublished code for this as well).  There are a
>> bunch of fixes for the SATA driver currently in linux-next, and I was
>> planning to take another look at supporting tango3/4 once these hit
>> mainline (4.7-rc1 most likely).
>
> FWIW, it seems like tango4 is low-priority internally ATM.
>
>> A driver for the PHY is probably a good idea, even if the boot loader
>> does some configuration, since this allows it to be powered down when
>> not in use.
>
> How come there are so few phy drivers in drivers/phy if most devices
> would typically require one?

Short answer is that the generic phy framework is fairly recent (~3
years old).  A lot of phys are stuck off in other places like
drivers/usb/phy.  At least that's my take on it.


Regards,

Andy Gross

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sata_dwc_460ex driver
  2016-05-27 18:15     ` Andy Gross
@ 2016-05-27 18:41       ` Mason
  2016-05-27 18:46         ` Måns Rullgård
  0 siblings, 1 reply; 7+ messages in thread
From: Mason @ 2016-05-27 18:41 UTC (permalink / raw)
  To: Andy Gross
  Cc: Mans Rullgard, linux-ide, Tejun Heo, Hans de Goede,
	Andy Shevchenko, Christian Lamparter, Srinivas Kandagatla,
	Kishon Vijay Abraham, Sebastian Frias

On 27/05/2016 20:15, Andy Gross wrote:

> On 27 May 2016 at 11:56, Mason wrote:
> 
>> How come there are so few phy drivers in drivers/phy if most
>> devices would typically require one?
> 
> Short answer is that the generic phy framework is fairly recent
> (~3 years old).  A lot of phys are stuck off in other places like
> drivers/usb/phy.  At least that's my take on it.

<confused> Where did the SATA phy drivers use to live?

$ find -name phy
./drivers/usb/phy
./drivers/phy
./drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy
./drivers/net/phy
./drivers/gpu/drm/msm/dsi/phy
./include/linux/phy
./include/dt-bindings/phy
./Documentation/devicetree/bindings/phy
./Documentation/phy

drivers/ata/ahci.h mentions SATA phy registers.
Is AHCI standardized to the point that platform-specific PHYs
are not required?

Regards.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: sata_dwc_460ex driver
  2016-05-27 18:41       ` Mason
@ 2016-05-27 18:46         ` Måns Rullgård
  0 siblings, 0 replies; 7+ messages in thread
From: Måns Rullgård @ 2016-05-27 18:46 UTC (permalink / raw)
  To: Mason
  Cc: Andy Gross, linux-ide, Tejun Heo, Hans de Goede, Andy Shevchenko,
	Christian Lamparter, Srinivas Kandagatla, Kishon Vijay Abraham,
	Sebastian Frias

Mason <slash.tmp@free.fr> writes:

> On 27/05/2016 20:15, Andy Gross wrote:
>
>> On 27 May 2016 at 11:56, Mason wrote:
>> 
>>> How come there are so few phy drivers in drivers/phy if most
>>> devices would typically require one?
>> 
>> Short answer is that the generic phy framework is fairly recent
>> (~3 years old).  A lot of phys are stuck off in other places like
>> drivers/usb/phy.  At least that's my take on it.
>
> <confused> Where did the SATA phy drivers use to live?
>
> $ find -name phy
> ./drivers/usb/phy
> ./drivers/phy
> ./drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy
> ./drivers/net/phy
> ./drivers/gpu/drm/msm/dsi/phy
> ./include/linux/phy
> ./include/dt-bindings/phy
> ./Documentation/devicetree/bindings/phy
> ./Documentation/phy
>
> drivers/ata/ahci.h mentions SATA phy registers.
> Is AHCI standardized to the point that platform-specific PHYs
> are not required?

A lot of hardware, especially older, doesn't need PHY drivers since the
PHY either has no settings or is configured by platform firmware.  In
some other cases, the PHY is tightly coupled to the SATA/USB/whatever
controller and handled directly by its driver.

-- 
Måns Rullgård

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-05-27 18:46 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-27 14:54 sata_dwc_460ex driver Mason
2016-05-27 16:20 ` Måns Rullgård
2016-05-27 16:56   ` Mason
2016-05-27 18:15     ` Andy Gross
2016-05-27 18:41       ` Mason
2016-05-27 18:46         ` Måns Rullgård
     [not found] ` <CAAd0S9BQoLsz1226seRW697rzNC9=SJDRC=JR2s4242tyg1+4g@mail.gmail.com>
2016-05-27 17:33   ` Mason

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.