lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 28 Jul 2013 09:15:54 -0700
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Neil Horman <nhorman@...driver.com>
Cc:	David Miller <davem@...emloft.net>, bhutchings@...arflare.com,
	luis.henriques@...onical.com, netdev@...r.kernel.org,
	jcliburn@...il.com, stable@...r.kernel.org
Subject: Re: [net PATCH] atl1c: Fix misuse of netdev_alloc_skb in refilling
 rx ring

On Sun, 2013-07-28 at 06:44 -0400, Neil Horman wrote:
> On Sat, Jul 27, 2013 at 08:02:05PM -0700, David Miller wrote:
> > From: Eric Dumazet <eric.dumazet@...il.com>
> > Date: Sat, 27 Jul 2013 16:59:43 -0700
> > 
> > > If a hardware needs frame being in a single 4K page, its driver must do
> > > its own allocation, or add appropriate aligning logic.
> > 
> > Whatever the cause the original patch in this thread is not the
> > correct fix and I've thus reverted it.
> > 
> 
> So what exactly is the consensus here?  We can certainly modify the patch to
> ensure allocation on a 4k boundary, and within a unique 4k page, but thats just
> a guess at the problem, and the Qualcomm people have been silent on the issue
> for weeks now.
> 

Thats the guess yes, but since MTU can be more than 4096 bytes, it could
be something else, some kind of DMA problem.

I wonder why rx_buffer_len includes VLAN_HLEN as this nic provides
accelerated vlan.

drivers/net/ethernet/atheros/atl1c/atl1c_main.c uses :
 hw->dmar_block = atl1c_dma_req_1024;

while drivers/net/ethernet/atheros/atlx/atl1.c uses :
 hw->dmar_block = atl1_dma_req_256;

drivers/net/ethernet/atheros/atlx/atl1.c also has this code around line
1962 :

                        /* rrd seems to be bad */
                        if (unlikely(i-- > 0)) {
                                /* rrd may not be DMAed completely */
                                udelay(1);
                                goto chk_rrd;
                        }


I would add the following debugging aid just to make sure...

diff --git a/drivers/net/ethernet/atheros/atl1c/atl1c_main.c b/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
index 786a874..4c794f9 100644
--- a/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
+++ b/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
@@ -1794,6 +1794,7 @@ rrs_checked:
 				buffer_info->length, PCI_DMA_FROMDEVICE);
 			skb = buffer_info->skb;
 		} else {
+			WARN_ON_ONCE(1);
 			/* TODO */
 			if (netif_msg_rx_err(adapter))
 				dev_warn(&pdev->dev,



--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ