From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: Russell King <rmk+kernel@arm.linux.org.uk>
Cc: netdev@vger.kernel.org,
Jesse Brandeburg <jesse.brandeburg@intel.com>,
Bruce Allan <bruce.w.allan@intel.com>,
Carolyn Wyborny <carolyn.wyborny@intel.com>,
Don Skidmore <donald.c.skidmore@intel.com>,
Greg Rose <gregory.v.rose@intel.com>,
Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>,
Alex Duyck <alexander.h.duyck@intel.com>,
John Ronciak <john.ronciak@intel.com>,
Tushar Dave <tushar.n.dave@intel.com>,
e1000-devel@lists.sourceforge.net
Subject: Re: [PATCH 7/7] NET: intel/ixgbevf/ixgbevf_main.c: fix 32-bit DMA mask handling
Date: Mon, 10 Jun 2013 16:28:29 -0700 [thread overview]
Message-ID: <1370906909.2133.6.camel@jtkirshe-mobl> (raw)
In-Reply-To: <E1UmBJP-0006KR-5h@rmk-PC.arm.linux.org.uk>
[-- Attachment #1: Type: text/plain, Size: 1355 bytes --]
On Tue, 2013-06-11 at 00:15 +0100, Russell King wrote:
>
> The fallback to 32-bit DMA mask is rather odd:
> if (!dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)) &&
> !dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64))) {
> pci_using_dac = 1;
> } else {
> err = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));
> if (err) {
> err = dma_set_coherent_mask(&pdev->dev,
> DMA_BIT_MASK(32));
> if (err) {
> dev_err(&pdev->dev, "No usable DMA "
> "configuration, aborting\n");
> goto err_dma;
> }
> }
> pci_using_dac = 0;
> }
> This means we only set the coherent DMA mask in the fallback path if
> the DMA mask set failed, which is silly. This fixes it to set the
> coherent DMA mask only if dma_set_mask() succeeded, and to error out
> if either fails.
>
> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
> ---
> drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 11 +++++------
> 1 files changed, 5 insertions(+), 6 deletions(-)
Thanks Russell, I will add this to my queue.
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2013-06-10 23:28 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-10 23:08 [RFC 0/7] Fixing dma mask setting in various network drivers Russell King - ARM Linux
2013-06-10 23:09 ` [PATCH 1/7] NET: brocade/bna/bnad.c: fix 32-bit DMA mask handling Russell King
2013-06-10 23:10 ` [PATCH 2/7] NET: intel/e1000e/netdev.c: " Russell King
2013-06-10 23:27 ` Jeff Kirsher
2013-06-10 23:11 ` [PATCH 3/7] NET: intel/igb/igb_main.c: " Russell King
2013-06-10 23:27 ` Jeff Kirsher
2013-06-10 23:12 ` [PATCH 4/7] NET: intel/igbvf/netdev.c: " Russell King
2013-06-10 23:27 ` Jeff Kirsher
2013-06-10 23:13 ` [PATCH 5/7] NET: intel/ixgb/ixgb_main.c: " Russell King
2013-06-10 23:27 ` Jeff Kirsher
2013-06-10 23:14 ` [PATCH 6/7] NET: intel/ixgbe/ixgbe_main.c: " Russell King
2013-06-10 23:28 ` Jeff Kirsher
2013-06-10 23:15 ` [PATCH 7/7] NET: intel/ixgbevf/ixgbevf_main.c: " Russell King
2013-06-10 23:28 ` Jeff Kirsher [this message]
2013-06-11 18:12 ` [RFC 0/7] Fixing dma mask setting in various network drivers Jesse Brandeburg
2013-06-11 20:35 ` Russell King - ARM Linux
2013-06-11 23:50 ` Jesse Brandeburg
2013-06-12 0:01 ` Russell King - ARM Linux
2013-06-17 14:01 ` Russell King - ARM Linux
2013-06-17 20:35 ` Jeff Kirsher
2013-06-17 20:45 ` Russell King - ARM Linux
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=1370906909.2133.6.camel@jtkirshe-mobl \
--to=jeffrey.t.kirsher@intel.com \
--cc=alexander.h.duyck@intel.com \
--cc=bruce.w.allan@intel.com \
--cc=carolyn.wyborny@intel.com \
--cc=donald.c.skidmore@intel.com \
--cc=e1000-devel@lists.sourceforge.net \
--cc=gregory.v.rose@intel.com \
--cc=jesse.brandeburg@intel.com \
--cc=john.ronciak@intel.com \
--cc=netdev@vger.kernel.org \
--cc=peter.p.waskiewicz.jr@intel.com \
--cc=rmk+kernel@arm.linux.org.uk \
--cc=tushar.n.dave@intel.com \
/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).