From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from alln-iport-7.cisco.com (alln-iport-7.cisco.com [173.37.142.94]) by dpdk.org (Postfix) with ESMTP id 266547288 for ; Thu, 11 Jan 2018 15:59:18 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=796; q=dns/txt; s=iport; t=1515682759; x=1516892359; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=E6vtPQtmWB2C6Q6HTjY91FYREvWd16PY7wi3M9iCstQ=; b=Sj4cDO41MXjh98NWAOCIgFCKjVM3TLNw7AAvmGyNgrBFNNv++K9SkYJ4 X3x9VQtG8LUvMgbOsNhjN5ooZuez5A5CS1qc9mGRXRoAwVz8YHKDMWrSL 6uRL2PHe5U+VI0iggzP8kXROLNy6u5tPNNVCCqwoaZDjG11nCYOhapA2I Q=; X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0AYAQDZelda/4wNJK1eGQEBAQEBAQEBA?= =?us-ascii?q?QEBAQcBAQEBAYNBgVonB44kjl6CApcwFIICCoU7AoQ9PxgBAQEBAQEBAQFrKIU?= =?us-ascii?q?jAQEBBDo/DAQCAQgVIQkHMhQRAgQOBQiKK7FwijgBAQEBAQEBAQEBAQEBAQEBA?= =?us-ascii?q?QEBAR6EK4IVgVeBaYMugy8EgViGEwWjZAKVPJQXlncCERkBgTsBHzmBUG8Vgme?= =?us-ascii?q?EV3gBiXUsgQaBFwEBAQ?= X-IronPort-AV: E=Sophos;i="5.46,344,1511827200"; d="scan'208";a="54749249" Received: from alln-core-7.cisco.com ([173.36.13.140]) by alln-iport-7.cisco.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 11 Jan 2018 14:59:17 +0000 Received: from XCH-RCD-016.cisco.com (xch-rcd-016.cisco.com [173.37.102.26]) by alln-core-7.cisco.com (8.14.5/8.14.5) with ESMTP id w0BExH8b007218 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=FAIL); Thu, 11 Jan 2018 14:59:17 GMT Received: from xch-rcd-016.cisco.com (173.37.102.26) by XCH-RCD-016.cisco.com (173.37.102.26) with Microsoft SMTP Server (TLS) id 15.0.1320.4; Thu, 11 Jan 2018 08:59:17 -0600 Received: from xch-rcd-016.cisco.com ([173.37.102.26]) by XCH-RCD-016.cisco.com ([173.37.102.26]) with mapi id 15.00.1320.000; Thu, 11 Jan 2018 08:59:17 -0600 From: "David Harton (dharton)" To: "Van Haaren, Harry" , "Wu, Jingjing" , "Xing, Beilei" CC: "dev@dpdk.org" , "Zhao1, Wei" Thread-Topic: [dpdk-dev] [PATCH] net/i40e: fix VF reset stats crash Thread-Index: AQHTit9vt6RcFBKcZEuisYs3ZD0wLaNvJiUA//+btBA= Date: Thu, 11 Jan 2018 14:59:16 +0000 Message-ID: References: <20180111132337.14389-1-dharton@cisco.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.82.170.179] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH] net/i40e: fix VF reset stats crash 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: , X-List-Received-Date: Thu, 11 Jan 2018 14:59:19 -0000 > -----Original Message----- > From: Van Haaren, Harry [mailto:harry.van.haaren@intel.com] >=20 > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of David C Harton > > > > Calling i40evf_dev_xstats_reset can sometimes crash. > > > > Fixed issue by adding a pstats NULL check. >=20 > Perhaps add a note here, that the root cause of (pstats =3D=3D NULL) is a > valid error return from i40evf_query_stats(), if the vf command fails to > execute. >=20 > Hence, we are not hiding symptoms of a different issue here, this NULL > check is required to validate the returned values. > =20 NULL is returned if the call fails. =20 If desired I can capture the return code and base the check off the rc inst= ead. That's the pattern used in a couple other places. Thanks, Dave