Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752259Ab3CPESZ (ORCPT ); Sat, 16 Mar 2013 00:18:25 -0400 Received: from perches-mx.perches.com ([206.117.179.246]:36881 "EHLO labridge.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750848Ab3CPESY (ORCPT ); Sat, 16 Mar 2013 00:18:24 -0400 Message-ID: <1363407501.2030.1.camel@joe-AO722> Subject: Re: [PATCH net-next] drivers:net: dma_alloc_coherent: use __GFP_ZERO instead of memset(, 0) From: Joe Perches To: "Abodunrin, Akeem G" Cc: "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "e1000-devel@lists.sourceforge.net" , "linux-wireless@vger.kernel.org" , "b43-dev@lists.infradead.org" , "users@rt2x00.serialmonkey.com" Date: Fri, 15 Mar 2013 21:18:21 -0700 In-Reply-To: References: Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.6.2-0ubuntu0.1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1225 Lines: 35 On Fri, 2013-03-15 at 22:51 +0000, Abodunrin, Akeem G wrote: > -----Original Message----- > From: netdev-owner@vger.kernel.org [mailto:netdev-owner@vger.kernel.org] On Behalf Of Joe Perches [] > Reduce the number of calls required to alloc a zeroed block of memory. [] > diff --git a/drivers/net/ethernet/intel/igbvf/netdev.c b/drivers/net/ethernet/intel/igbvf/netdev.c [] > @@ -488,7 +487,6 @@ int igbvf_setup_rx_resources(struct igbvf_adapter *adapter, > > rx_ring->desc = dma_alloc_coherent(&pdev->dev, rx_ring->size, > &rx_ring->dma, GFP_KERNEL); > - > if (!rx_ring->desc) > goto err; > > Hi Joe, Hello Akeem. > Your changes did not seem to make it to igbvf/netdev.c - I think > instead of removing an extra line added for code clarity, you > want to add: > "tx_ring->desc = dma_alloc_coherent(&pdev->dev, tx_ring->size, > &tx_ring->dma, GFP_KERNEL| __GFP_ZERO);" Not really, there's no memset here so this bit is just a whitespace neatening. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/