netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chen Baozi <cbz@baozis.org>
To: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org
Cc: Chen Baozi <cbz@baozis.org>, netdev@vger.kernel.org
Subject: [PATCH 3/3] stmmac: Add AXI burst length support to platform device.
Date: Sat,  7 Feb 2015 13:07:16 +0800	[thread overview]
Message-ID: <1423285636-8623-4-git-send-email-cbz@baozis.org> (raw)
In-Reply-To: <1423285636-8623-1-git-send-email-cbz@baozis.org>

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

       reply	other threads:[~2015-02-07  5:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1423285636-8623-1-git-send-email-cbz@baozis.org>
2015-02-07  5:07 ` Chen Baozi [this message]
2015-02-09 12:04   ` [PATCH 3/3] stmmac: Add AXI burst length support to platform device Mark Rutland
2015-02-10  0:02     ` Chen Baozi
     [not found] <20150210020734.GE7920@cbz-thinkpad>
     [not found] ` <20150210114837.GC6659@leverpostej>
2015-02-11 11:11   ` Chen Baozi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1423285636-8623-4-git-send-email-cbz@baozis.org \
    --to=cbz@baozis.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).