From: Tom Lendacky <thomas.lendacky@amd.com>
To: David Laight <David.Laight@ACULAB.COM>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Cc: David Miller <davem@davemloft.net>
Subject: Re: [PATCH net-next 06/10] amd-xgbe: Set DMA mask based on hardware register value
Date: Thu, 19 Mar 2015 12:40:05 -0500 [thread overview]
Message-ID: <550B09F5.8000707@amd.com> (raw)
In-Reply-To: <063D6719AE5E284EB5DD2968C1650D6D1CB046B5@AcuExch.aculab.com>
On 03/19/2015 12:32 PM, David Laight wrote:
> From: Tom Lendacky
>> The hardware supplies a value that indicates the DMA range that it
>> is capable of using. Use this value rather than hard-coding it in
>> the driver.
> ...
>> + /* Translate the address width setting into actual number */
>> + switch (hw_feat->dma_width) {
>> + case 0:
>> + hw_feat->dma_width = 32;
>> + break;
>> + case 1:
>> + hw_feat->dma_width = 40;
>> + break;
>> + case 2:
>> + hw_feat->dma_width = 48;
>> + break;
>> + }
>> +
>
> I see a glaring problem should the hardware ever return 3.
Except this version of the hardware can't return a 3 and any future
versions will have a different device tree id or ACPI id and won't
match this driver (or the driver will be updated at that point to
support the newer versions). I could have it default to 32 if you
feel it's really needed, though.
Thanks,
Tom
>
> David
>
next prev parent reply other threads:[~2015-03-19 17:56 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-19 17:12 [PATCH net-next 00/10] amd-xgbe: AMD XGBE driver updates 2015-03-19 Tom Lendacky
2015-03-19 17:12 ` [PATCH net-next 01/10] amd-xgbe-phy: Use phydev advertising field vs supported Tom Lendacky
2015-03-19 17:12 ` [PATCH net-next 02/10] amd-xgbe-phy: Use the phy_driver flags field Tom Lendacky
2015-03-19 17:12 ` [PATCH net-next 03/10] amd-xgbe-phy: Provide support for auto-negotiation timeout Tom Lendacky
2015-03-19 17:12 ` [PATCH net-next 04/10] amd-xgbe: Clarify output message about queues Tom Lendacky
2015-03-19 17:12 ` [PATCH net-next 05/10] amd-xgbe: Use the new DMA memory barriers where appropriate Tom Lendacky
2015-03-19 17:13 ` [PATCH net-next 06/10] amd-xgbe: Set DMA mask based on hardware register value Tom Lendacky
2015-03-19 17:32 ` David Laight
2015-03-19 17:40 ` Tom Lendacky [this message]
2015-03-19 18:43 ` David Miller
2015-03-19 18:53 ` Tom Lendacky
2015-03-19 17:13 ` [PATCH net-next 07/10] amd-xgbe: Remove Tx coalescing Tom Lendacky
2015-03-19 17:13 ` [PATCH net-next 08/10] amd-xgbe: Fix Rx coalescing reporting Tom Lendacky
2015-03-19 17:13 ` [PATCH net-next 09/10] amd-xgbe: Use napi_alloc_skb when allocating skb in softirq Tom Lendacky
2015-03-19 17:13 ` [PATCH net-next 10/10] amd-xgbe: Rework the Rx path SKB allocation Tom Lendacky
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=550B09F5.8000707@amd.com \
--to=thomas.lendacky@amd.com \
--cc=David.Laight@ACULAB.COM \
--cc=davem@davemloft.net \
--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).