From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mugunthan V N Subject: Re: [PATCH] net: davinci_emac: fix oops caused by uninitialized ndev->dev Date: Tue, 20 May 2014 15:44:51 +0530 Message-ID: <537B2B1B.2000501@ti.com> References: <1400580697-24994-1-git-send-email-nsekhar@ti.com> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Cc: Kevin Hilman , Linux DaVinci Mailing List , Linux netdev Mailing List , Prabhakar Lad To: Sekhar Nori , David Miller Return-path: Received: from devils.ext.ti.com ([198.47.26.153]:38459 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752645AbaETKO5 (ORCPT ); Tue, 20 May 2014 06:14:57 -0400 In-Reply-To: <1400580697-24994-1-git-send-email-nsekhar@ti.com> Sender: netdev-owner@vger.kernel.org List-ID: On Tuesday 20 May 2014 03:41 PM, Sekhar Nori wrote: > Commit e194312854edc22a2faf1931b3c0608fe20cb969 (drivers: net: > davinci_cpdma: Convert kzalloc() to devm_kzalloc()) triggered > a bug in emac_probe() wherein dev member of net_device is used > for devres allocations even before it is initialized. > > This patch fixes that by using the struct device in platform_device > instead. > > While at it, use &pdev->dev consistently for console messages instead > of using ndev->dev for just one case and remove an unnecessary line > continuation. > > Reported-by: Kevin Hilman > Helped-by: George Cherian > Signed-off-by: Sekhar Nori > --- Acked-by: Mugunthan V N Regards Mugunthan V N