From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCHv3] 3c59x: fix missing dma_mapping_error check and bad ring refill logic Date: Wed, 03 Jan 2018 13:44:37 -0500 (EST) Message-ID: <20180103.134437.1331978804063112439.davem@davemloft.net> References: <20180103180923.24868-1-nhorman@tuxdriver.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, tedheadster@gmail.com, nhorman@redhat.com, klassert@mathematik.tu-chemnitz.de To: nhorman@tuxdriver.com Return-path: Received: from shards.monkeyblade.net ([184.105.139.130]:35288 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750829AbeACSoj (ORCPT ); Wed, 3 Jan 2018 13:44:39 -0500 In-Reply-To: <20180103180923.24868-1-nhorman@tuxdriver.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Neil Horman Date: Wed, 3 Jan 2018 13:09:23 -0500 > A few spots in 3c59x missed calls to dma_mapping_error checks, casuing > WARN_ONS to trigger. Clean those up. While we're at it, refactor the > refill code a bit so that if skb allocation or dma mapping fails, we > recycle the existing buffer. This prevents holes in the rx ring, and > makes for much simpler logic > > Note: This is compile only tested. Ted, if you could run this and > confirm that it continues to work properly, I would appreciate it, as I > currently don't have access to this hardware > > Signed-off-by: Neil Horman > CC: Steffen Klassert > CC: "David S. Miller" > Reported-by: tedheadster@gmail.com > > --- > Change notes: > > v2) > * Fixed tx path to free skb on mapping error > * Refactored rx path to recycle skbs on allocation/mapping error > * Used refactoring to remove oom timer and dirty_rx index > > v3) > * Removed unused variable that was causing a warning Applied.