* Re: [PATCH 3/3] stmmac: Add AXI burst length support to platform device. [not found] ` <20150210114837.GC6659@leverpostej> @ 2015-02-11 11:11 ` Chen Baozi 0 siblings, 0 replies; 4+ messages in thread From: Chen Baozi @ 2015-02-11 11:11 UTC (permalink / raw) To: Mark Rutland; +Cc: netdev, linux-kernel, linux-arm-kernel On Tue, Feb 10, 2015 at 11:48:37AM +0000, Mark Rutland wrote: > > On Mon, Feb 09, 2015 at 12:04:43PM +0000, Mark Rutland wrote: > > > On Sat, Feb 07, 2015 at 05:07:16AM +0000, Chen Baozi wrote: > > > > The AXI Bus Mode Register controls the AXI master behavior. It is mainly > > > > used to control the burst splitting and the number of outstanding requests. > > > > This register is present and valid only in GMAC-AXI configuration. The old > > > > driver only supports this feature on PCI devices. This patch adds an > > > > 'snps,apl' properties in DT to enable it on platform devices. > > > > > > > > Signed-off-by: Chen Baozi <chenbaozi@kylinos.com.cn> > > > > --- > > > > Documentation/devicetree/bindings/net/stmmac.txt | 1 + > > > > drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 1 + > > > > 2 files changed, 2 insertions(+) > > > > > > > > diff --git a/Documentation/devicetree/bindings/net/stmmac.txt b/Documentation/devicetree/bindings/net/stmmac.txt > > > > index c41afd9..8f3c834 100644 > > > > --- a/Documentation/devicetree/bindings/net/stmmac.txt > > > > +++ b/Documentation/devicetree/bindings/net/stmmac.txt > > > > @@ -43,6 +43,7 @@ Optional properties: > > > > available this clock is used for programming the Timestamp Addend Register. > > > > If not passed then the system clock will be used and this is fine on some > > > > platforms. > > > > +- snps,abl: AXI Burst Length > > > > > > This is not a good name (though I see it follows "snps,pbl", which is > > > also not a good name)... > > > > Any idea for a better name? > > Perhaps snps,axi-burst-length ? > > > > Why does this need to be in the DT? Is this required for correctness? Or > > > performance? > > > > This is required for correctness. Otherwise, the driver would write > > '0' to the register by default, which makes the driver not work. > > What does that mean at the HW level? If that won't work in all cases > why does the driver do that? According to the manual, this is used to select the burst length on AXI master interface. The register is optional and valid only in GMAC-AXI configuration. IMHO, not all cases require the driver to set this register. So I just put it in the 'optional properties', in case some devices depend on that. Cheers, Baozi. ^ permalink raw reply [flat|nested] 4+ messages in thread
[parent not found: <1423285636-8623-1-git-send-email-cbz@baozis.org>]
* [PATCH 3/3] stmmac: Add AXI burst length support to platform device. [not found] <1423285636-8623-1-git-send-email-cbz@baozis.org> @ 2015-02-07 5:07 ` Chen Baozi 2015-02-09 12:04 ` Mark Rutland 0 siblings, 1 reply; 4+ messages in thread From: Chen Baozi @ 2015-02-07 5:07 UTC (permalink / raw) To: linux-kernel, linux-arm-kernel; +Cc: Chen Baozi, netdev The AXI Bus Mode Register controls the AXI master behavior. It is mainly used to control the burst splitting and the number of outstanding requests. This register is present and valid only in GMAC-AXI configuration. The old driver only supports this feature on PCI devices. This patch adds an 'snps,apl' properties in DT to enable it on platform devices. Signed-off-by: Chen Baozi <chenbaozi@kylinos.com.cn> --- Documentation/devicetree/bindings/net/stmmac.txt | 1 + drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 1 + 2 files changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/net/stmmac.txt b/Documentation/devicetree/bindings/net/stmmac.txt index c41afd9..8f3c834 100644 --- a/Documentation/devicetree/bindings/net/stmmac.txt +++ b/Documentation/devicetree/bindings/net/stmmac.txt @@ -43,6 +43,7 @@ Optional properties: available this clock is used for programming the Timestamp Addend Register. If not passed then the system clock will be used and this is fine on some platforms. +- snps,abl: AXI Burst Length Examples: diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c index 3039de2..abbc897 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c @@ -230,6 +230,7 @@ static int stmmac_probe_config_dt(struct platform_device *pdev, return -ENOMEM; plat->dma_cfg = dma_cfg; of_property_read_u32(np, "snps,pbl", &dma_cfg->pbl); + of_property_read_u32(np, "snps,abl", &dma_cfg->burst_len); dma_cfg->fixed_burst = of_property_read_bool(np, "snps,fixed-burst"); dma_cfg->mixed_burst = -- 2.1.4 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 3/3] stmmac: Add AXI burst length support to platform device. 2015-02-07 5:07 ` Chen Baozi @ 2015-02-09 12:04 ` Mark Rutland 2015-02-10 0:02 ` Chen Baozi 0 siblings, 1 reply; 4+ messages in thread From: Mark Rutland @ 2015-02-09 12:04 UTC (permalink / raw) To: Chen Baozi; +Cc: linux-kernel, linux-arm-kernel, netdev On Sat, Feb 07, 2015 at 05:07:16AM +0000, Chen Baozi wrote: > The AXI Bus Mode Register controls the AXI master behavior. It is mainly > used to control the burst splitting and the number of outstanding requests. > This register is present and valid only in GMAC-AXI configuration. The old > driver only supports this feature on PCI devices. This patch adds an > 'snps,apl' properties in DT to enable it on platform devices. > > Signed-off-by: Chen Baozi <chenbaozi@kylinos.com.cn> > --- > Documentation/devicetree/bindings/net/stmmac.txt | 1 + > drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 1 + > 2 files changed, 2 insertions(+) > > diff --git a/Documentation/devicetree/bindings/net/stmmac.txt b/Documentation/devicetree/bindings/net/stmmac.txt > index c41afd9..8f3c834 100644 > --- a/Documentation/devicetree/bindings/net/stmmac.txt > +++ b/Documentation/devicetree/bindings/net/stmmac.txt > @@ -43,6 +43,7 @@ Optional properties: > available this clock is used for programming the Timestamp Addend Register. > If not passed then the system clock will be used and this is fine on some > platforms. > +- snps,abl: AXI Burst Length This is not a good name (though I see it follows "snps,pbl", which is also not a good name)... Why does this need to be in the DT? Is this required for correctness? Or performance? Thanks, Mark. > > Examples: > > diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c > index 3039de2..abbc897 100644 > --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c > +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c > @@ -230,6 +230,7 @@ static int stmmac_probe_config_dt(struct platform_device *pdev, > return -ENOMEM; > plat->dma_cfg = dma_cfg; > of_property_read_u32(np, "snps,pbl", &dma_cfg->pbl); > + of_property_read_u32(np, "snps,abl", &dma_cfg->burst_len); > dma_cfg->fixed_burst = > of_property_read_bool(np, "snps,fixed-burst"); > dma_cfg->mixed_burst = > -- > 2.1.4 > > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel > ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 3/3] stmmac: Add AXI burst length support to platform device. 2015-02-09 12:04 ` Mark Rutland @ 2015-02-10 0:02 ` Chen Baozi 0 siblings, 0 replies; 4+ messages in thread From: Chen Baozi @ 2015-02-10 0:02 UTC (permalink / raw) To: Mark Rutland; +Cc: netdev, linux-kernel, linux-arm-kernel On Mon, Feb 09, 2015 at 12:04:43PM +0000, Mark Rutland wrote: > On Sat, Feb 07, 2015 at 05:07:16AM +0000, Chen Baozi wrote: > > The AXI Bus Mode Register controls the AXI master behavior. It is mainly > > used to control the burst splitting and the number of outstanding requests. > > This register is present and valid only in GMAC-AXI configuration. The old > > driver only supports this feature on PCI devices. This patch adds an > > 'snps,apl' properties in DT to enable it on platform devices. > > > > Signed-off-by: Chen Baozi <chenbaozi@kylinos.com.cn> > > --- > > Documentation/devicetree/bindings/net/stmmac.txt | 1 + > > drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 1 + > > 2 files changed, 2 insertions(+) > > > > diff --git a/Documentation/devicetree/bindings/net/stmmac.txt b/Documentation/devicetree/bindings/net/stmmac.txt > > index c41afd9..8f3c834 100644 > > --- a/Documentation/devicetree/bindings/net/stmmac.txt > > +++ b/Documentation/devicetree/bindings/net/stmmac.txt > > @@ -43,6 +43,7 @@ Optional properties: > > available this clock is used for programming the Timestamp Addend Register. > > If not passed then the system clock will be used and this is fine on some > > platforms. > > +- snps,abl: AXI Burst Length > > This is not a good name (though I see it follows "snps,pbl", which is > also not a good name)... Any idea for a better name? > > Why does this need to be in the DT? Is this required for correctness? Or > performance? This is required for correctness. Otherwise, the driver would write '0' to the register by default, which makes the driver not work. Cheers, Baozi. > > Thanks, > Mark. > > > > > Examples: > > > > diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c > > index 3039de2..abbc897 100644 > > --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c > > +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c > > @@ -230,6 +230,7 @@ static int stmmac_probe_config_dt(struct platform_device *pdev, > > return -ENOMEM; > > plat->dma_cfg = dma_cfg; > > of_property_read_u32(np, "snps,pbl", &dma_cfg->pbl); > > + of_property_read_u32(np, "snps,abl", &dma_cfg->burst_len); > > dma_cfg->fixed_burst = > > of_property_read_bool(np, "snps,fixed-burst"); > > dma_cfg->mixed_burst = > > -- > > 2.1.4 > > > > > > _______________________________________________ > > linux-arm-kernel mailing list > > linux-arm-kernel@lists.infradead.org > > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel > > > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-02-11 11:11 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <20150210020734.GE7920@cbz-thinkpad> [not found] ` <20150210114837.GC6659@leverpostej> 2015-02-11 11:11 ` [PATCH 3/3] stmmac: Add AXI burst length support to platform device Chen Baozi [not found] <1423285636-8623-1-git-send-email-cbz@baozis.org> 2015-02-07 5:07 ` Chen Baozi 2015-02-09 12:04 ` Mark Rutland 2015-02-10 0:02 ` Chen Baozi
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).