From: Srinivas KANDAGATLA <srinivas.kandagatla@st.com>
To: Giuseppe CAVALLARO <peppe.cavallaro@st.com>
Cc: netdev@vger.kernel.org, Grant Likely <grant.likely@linaro.org>,
Rob Herring <rob.herring@calxeda.com>,
Rob Landley <rob@landley.net>,
devicetree-discuss@lists.ozlabs.org, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH RFC 2/3] dt:net:stmmac: Add support to dwmac version 3.610 and 3.710
Date: Tue, 02 Jul 2013 07:42:32 +0100 [thread overview]
Message-ID: <51D27658.1060806@st.com> (raw)
In-Reply-To: <51D1BA52.3030201@st.com>
Thanks Peppe for the comments,
On 01/07/13 18:20, Giuseppe CAVALLARO wrote:
> On 7/1/2013 1:43 PM, Srinivas KANDAGATLA wrote:
>> From: Srinivas Kandagatla <srinivas.kandagatla@st.com>
>>
>> +
>> + plat->bus_id = of_alias_get_id(np, "ethernet");
>> + if (plat->bus_id < 0)
>> + plat->bus_id = 0;
>> +
>> + of_property_read_u32(np, "snps,phy-addr", &plat->phy_addr);
>> +
>> plat->mdio_bus_data = devm_kzalloc(&pdev->dev,
>> sizeof(struct stmmac_mdio_bus_data),
>> GFP_KERNEL);
>> @@ -51,11 +60,25 @@ static int stmmac_probe_config_dt(struct
>> platform_device *pdev,
>> */
>> if (of_device_is_compatible(np, "st,spear600-gmac") ||
>> of_device_is_compatible(np, "snps,dwmac-3.70a") ||
>> + of_device_is_compatible(np, "snps,dwmac-3.610") ||
I forgot to add "snps,dwmac-3.710" to this list, I will do it in V2 patch.
>> of_device_is_compatible(np, "snps,dwmac")) {
>> plat->has_gmac = 1;
>> plat->pmt = 1;
>> }
>>
>> + if (of_device_is_compatible(np, "snps,dwmac-3.610") ||
>> + of_device_is_compatible(np, "snps,dwmac-3.710")) {
>> + plat->enh_desc = 1;
>> + plat->bugged_jumbo = 1;
>> + plat->force_sf_dma_mode = 1;
>> + }
>
> I think some these shouldn't be forced here. Maybe plat->enh_desc could
> be set because for new syn mac cores.
>
> Also pmt could not be forced because it is an extra module so it could
> happen that a new chip has no PMT block.
I agree with you, But the new chips should/will have different version
numbers, so having the version number in the compatible string should
make it possible for cores without PMT module to not set pmt or any
other properties.
Are you happy with the setting pmt based on compatible string or do you
think passing pmt as another property to device tree makes more sense?
Thanks,
srini
next prev parent reply other threads:[~2013-07-02 6:42 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-01 11:42 [PATCH RFC 0/3] extend stmmac DT support Srinivas KANDAGATLA
2013-07-01 11:43 ` [PATCH RFC 1/3] dt:net:stmmac: Allocate platform data only if its NULL Srinivas KANDAGATLA
2013-07-01 17:20 ` Giuseppe CAVALLARO
2013-07-01 17:20 ` Giuseppe CAVALLARO
2013-07-01 11:43 ` [PATCH RFC 2/3] dt:net:stmmac: Add support to dwmac version 3.610 and 3.710 Srinivas KANDAGATLA
2013-07-01 17:20 ` Giuseppe CAVALLARO
2013-07-02 6:42 ` Srinivas KANDAGATLA [this message]
[not found] ` <51D27658.1060806-qxv4g6HH51o@public.gmane.org>
2013-07-02 8:04 ` Giuseppe CAVALLARO
2013-07-01 11:44 ` [PATCH RFC 3/3] dt:net:stmmac: Add dt specific phy reset callback support Srinivas KANDAGATLA
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=51D27658.1060806@st.com \
--to=srinivas.kandagatla@st.com \
--cc=devicetree-discuss@lists.ozlabs.org \
--cc=grant.likely@linaro.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=peppe.cavallaro@st.com \
--cc=rob.herring@calxeda.com \
--cc=rob@landley.net \
/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).