Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752227AbbHRCyh (ORCPT ); Mon, 17 Aug 2015 22:54:37 -0400 Received: from mga14.intel.com ([192.55.52.115]:43875 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751318AbbHRCye convert rfc822-to-8bit (ORCPT ); Mon, 17 Aug 2015 22:54:34 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.15,699,1432623600"; d="scan'208";a="770742028" From: "Brown, Aaron F" To: Jia-Ju Bai , "Kirsher, Jeffrey T" , "Brandeburg, Jesse" CC: "netdev@vger.kernel.org" , "intel-wired-lan@lists.osuosl.org" , "linux-kernel@vger.kernel.org" Subject: RE: [Intel-wired-lan] [PATCH] e100: Add a check after pci_pool_create to avoid null pointer dereference Thread-Topic: [Intel-wired-lan] [PATCH] e100: Add a check after pci_pool_create to avoid null pointer dereference Thread-Index: AQHQzZKjEkLrW2ExmEOtJ7jytiLj454RJybA Date: Tue, 18 Aug 2015 02:54:28 +0000 Message-ID: <309B89C4C689E141A5FF6A0C5FB2118B81AE873D@ORSMSX101.amr.corp.intel.com> References: <1438568228-13288-1-git-send-email-baijiaju1990@163.com> In-Reply-To: <1438568228-13288-1-git-send-email-baijiaju1990@163.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.22.254.138] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1127 Lines: 25 > From: Intel-wired-lan [mailto:intel-wired-lan-bounces@lists.osuosl.org] On > Behalf Of Jia-Ju Bai > Sent: Sunday, August 02, 2015 7:17 PM > To: Kirsher, Jeffrey T; Brandeburg, Jesse > Cc: netdev@vger.kernel.org; Jia-Ju Bai; intel-wired-lan@lists.osuosl.org; > linux-kernel@vger.kernel.org > Subject: [Intel-wired-lan] [PATCH] e100: Add a check after pci_pool_create > to avoid null pointer dereference > > The driver lacks the check of nic->cbs_pool after pci_pool_create > in e100_probe. When this function is failed, a null pointer dereference > occurs when pci_pool_alloc uses nic->cbs_pool in e100_alloc_cbs. > This patch adds a check and related error handling code to fix it. > > Signed-off-by: Jia-Ju Bai > --- > drivers/net/ethernet/intel/e100.c | 7 +++++++ > 1 file changed, 7 insertions(+) Tested-by: Aaron Brown -- 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/