From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 3650AA0471 for ; Mon, 15 Jul 2019 18:04:23 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 768484CE4; Mon, 15 Jul 2019 18:04:21 +0200 (CEST) Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 7F7502BF5; Mon, 15 Jul 2019 18:04:19 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 15 Jul 2019 09:04:18 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.63,493,1557212400"; d="scan'208";a="342424498" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by orsmga005.jf.intel.com with ESMTP; 15 Jul 2019 09:04:17 -0700 Received: from fmsmsx101.amr.corp.intel.com (10.18.124.199) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 15 Jul 2019 09:04:12 -0700 Received: from fmsmsx117.amr.corp.intel.com ([169.254.3.206]) by fmsmsx101.amr.corp.intel.com ([169.254.1.16]) with mapi id 14.03.0439.000; Mon, 15 Jul 2019 09:04:12 -0700 From: "Carrillo, Erik G" To: Stephen Hemminger CC: "thomas@monjalon.net" , "dev@dpdk.org" , "stable@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH 1/2] timer: fix null pointer dereference Thread-Index: AQHVOyON7FzSx+6Ovkut0ZzoYIKzHKbMSJ6A//+OPaA= Date: Mon, 15 Jul 2019 16:04:11 +0000 Message-ID: References: <1563205172-352-1-git-send-email-erik.g.carrillo@intel.com> <1563205172-352-2-git-send-email-erik.g.carrillo@intel.com> <20190715084841.4f6baebf@hermes.lan> In-Reply-To: <20190715084841.4f6baebf@hermes.lan> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.600.7 dlp-reaction: no-action x-originating-ip: [10.1.200.107] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH 1/2] timer: fix null pointer dereference X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Hi Stephen, > -----Original Message----- > From: Stephen Hemminger > Sent: Monday, July 15, 2019 10:49 AM > To: Carrillo, Erik G > Cc: thomas@monjalon.net; dev@dpdk.org; stable@dpdk.org > Subject: Re: [dpdk-dev] [PATCH 1/2] timer: fix null pointer dereference >=20 > On Mon, 15 Jul 2019 10:39:31 -0500 > Erik Gabriel Carrillo wrote: >=20 > > If the timer subsystem is not initialized before rte_timer_manage (for > > example) is invoked, a pointer to a shared hugepage memory region will > > still be null and dereferenced when it is checked for validity; handle > > this case. > > > > Fixes: c0749f7096c7 ("timer: allow management in shared memory") > > Cc: stable@dpdk.org > > > > Signed-off-by: Erik Gabriel Carrillo >=20 > I have mixed feelings about this patch. > Any calls to rte_timer before rte_timer_subsystem_init is not a valid usa= ge. > Better to kill the application. Ok, that sounds like a better approach. I'll update the patch and resubmit= . Thanks, Erik