From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id E8390A0352; Mon, 14 Feb 2022 18:08:23 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8147C40DDA; Mon, 14 Feb 2022 18:08:23 +0100 (CET) Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) by mails.dpdk.org (Postfix) with ESMTP id B18DB4067E for ; Mon, 14 Feb 2022 18:08:21 +0100 (CET) Received: from pps.filterd (m0246617.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 21EGL4nj018242; Mon, 14 Feb 2022 17:08:20 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding; s=corp-2021-07-09; bh=emD/wYPlwAW2iiC/zBDDuXL4oE2OUyTNbUf9yqHJaSo=; b=tHUE9VXqzmhQ6idNSNS+UWKesEcOZXAK/z2xREpTgC/HUvhgS7Gz0dusG4QQlLx0acVM AnJ64JpuYADAwp4Qzkx66IthrSNyruS36y8ZOhIB6BvVJby7GpxIwGEQVdDeBtImI7xk s+y0hnIXaPAH5qvtgb+H2kTYKKJG5WJnrr1rtV717MIqAO+48+zN2GjvoJYjP64CUMaq +fH/MTiCEwiqq0sYnydcWjFwRESBtqmTiSZ8j5WY4x2UBR9hrDRBn+3Yce/QrEGOznHy JTxEbD2Y9Zwk8jC85ujHU8TD2grNcdtmq0u1346I4jm0e/IywZOWP6H3uXnZDy/WfhBi wA== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by mx0b-00069f02.pphosted.com with ESMTP id 3e65eud480-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 14 Feb 2022 17:08:20 +0000 Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.1.2/8.16.1.2) with SMTP id 21EH62aK068665; Mon, 14 Feb 2022 17:08:19 GMT Received: from pps.reinject (localhost [127.0.0.1]) by aserp3020.oracle.com with ESMTP id 3e6qkx0xw8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 14 Feb 2022 17:08:19 +0000 Received: from aserp3020.oracle.com (aserp3020.oracle.com [127.0.0.1]) by pps.reinject (8.16.0.36/8.16.0.36) with SMTP id 21EH8JR3077571; Mon, 14 Feb 2022 17:08:19 GMT Received: from mmythri-7410.in.oracle.com (dhcp-10-76-57-47.vpn.oracle.com [10.76.57.47]) by aserp3020.oracle.com with ESMTP id 3e6qkx0xru-1; Mon, 14 Feb 2022 17:08:17 +0000 From: madhuker.mythri@oracle.com To: ferruh.yigit@intel.com Cc: dev@dpdk.org, Madhuker Mythri Subject: [PATCH] devargs: Fix crash due to global devargs uninitailization from secondary process Date: Mon, 14 Feb 2022 22:38:11 +0530 Message-Id: <20220214170811.1192-1-madhuker.mythri@oracle.com> X-Mailer: git-send-email 2.32.0.windows.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Proofpoint-ORIG-GUID: KTaT1WSrq8_sEkYkx6YQtphH2mf1ndv- X-Proofpoint-GUID: KTaT1WSrq8_sEkYkx6YQtphH2mf1ndv- X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org From: Madhuker Mythri Failsafe pmd started crashing with global devargs syntax as devargs is not memset to zero. Access it to in rte_devargs_parse() resulted in a crash when called from secondary process. Bugzilla Id: 933 Signed-off-by: Madhuker Mythri --- lib/eal/common/eal_common_devargs.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/eal/common/eal_common_devargs.c b/lib/eal/common/eal_common_devargs.c index 69004b0a2d..ad60febad9 100644 --- a/lib/eal/common/eal_common_devargs.c +++ b/lib/eal/common/eal_common_devargs.c @@ -190,6 +190,7 @@ rte_devargs_parse(struct rte_devargs *da, const char *dev) if (da == NULL) return -EINVAL; + memset(da, 0, sizeof(*da)); /* First parse according global device syntax. */ if (rte_devargs_layers_parse(da, dev) == 0) { -- 2.32.0.windows.1