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 11F9B43BDC; Tue, 27 Feb 2024 10:23:35 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A623D4027D; Tue, 27 Feb 2024 10:23:34 +0100 (CET) Received: from mail-lj1-f170.google.com (mail-lj1-f170.google.com [209.85.208.170]) by mails.dpdk.org (Postfix) with ESMTP id 412F740150 for ; Tue, 27 Feb 2024 10:23:33 +0100 (CET) Received: by mail-lj1-f170.google.com with SMTP id 38308e7fff4ca-2d094bc2244so47288551fa.1 for ; Tue, 27 Feb 2024 01:23:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709025812; x=1709630612; darn=dpdk.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=jHu3d1Qde4kUh//OaKmxRmhlPTrYlAljVX/Uw39Gq/g=; b=PMvl7JYjiXQENAntR+ucyI1N3JOCC/sBwVqvl4pqAWuzSAMdcFQ8baGpoN2X9Agez+ vPN3hbBUs37WXTCTjNWv5ZfdM8Frg4xqdhzxJZUSqA2DOo57/Gx6gDFrO/AK3sCXts8h YcdGEPF7foSSPp9rW6v7Kq5r234SkahdwTGbPWAvfjAvyRmsQRk0tquZbTtoUEg5Gf6d 9iZgUHPtUuOhxf8z401PdgAYvP0Kv8AfwNwbindY65k+5RA8vvWB3YE2eBJEeZWWwbGf UVf6OiYWDVFV3fHdK/c6IEj+cpmbtFjYZgNW3T+W4v+7hyAPXovi0A8heIOXzWN9Zplc h9Qw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709025812; x=1709630612; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=jHu3d1Qde4kUh//OaKmxRmhlPTrYlAljVX/Uw39Gq/g=; b=epVvSZoNIF+pnHNY84NZCe6ncSlp3ESVf/oPAAbXeZKv7sid/gBRUrhqOnxEURGNeY 9+kUhUVbQk+m0iOZfGyfYUjmCp5bXkSw28haTTaBs9loEUPSV0mn24qf02y2aDnalM97 oKT09GEmWfyo/aABEtBJWmFXESgmFGMZ1dEfDcXGU2aAVjTQAOkLXZ/sLtyITCIWDT1v tjKAFjnk7XNfeGz3C4D9HANCkXbonNTHc/dVWh0MeAy2+yCN9BzLWfPgCkmVMNoELZt3 gl3DaubeVyEY27OltTA2xqF6ZxDI/FpgBqqKyjP6SbGlyNcrwSKpIyY6y2L1RDYtXxkE 545g== X-Gm-Message-State: AOJu0Yw/SJWIAF5KYDNPJfuc27eZlYQniqGr3N0Us6fXerw/R8G6nvjl C3zqzeysXR+6vcTdgHTUFP/XCOI5UEnT/O1hU0sBBWeRX2HzcwXz X-Google-Smtp-Source: AGHT+IEhC7ug7YuA0iP9K0rSQYE9dtY6khI8p2jcEVacdMSuMd1ytj4ct4yNzsXNTdlQZGB8koFZ2A== X-Received: by 2002:a05:651c:1a21:b0:2d2:3aea:bc78 with SMTP id by33-20020a05651c1a2100b002d23aeabc78mr7109633ljb.38.1709025812381; Tue, 27 Feb 2024 01:23:32 -0800 (PST) Received: from localhost.localdomain ([109.253.220.157]) by smtp.googlemail.com with ESMTPSA id u14-20020a056000038e00b0033dca6f8b44sm8115995wrf.16.2024.02.27.01.23.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 27 Feb 2024 01:23:31 -0800 (PST) From: Isaac Boukris To: stephen@networkplumber.org Cc: dev@dpdk.org, Isaac Boukris Subject: [PATCH] dumpcap: correctly disable promiscuous mode at exit Date: Tue, 27 Feb 2024 11:23:26 +0200 Message-ID: <20240227092326.340229-1-iboukris@gmail.com> X-Mailer: git-send-email 2.43.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 Signed-off-by: Isaac Boukris --- app/dumpcap/main.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/dumpcap/main.c b/app/dumpcap/main.c index d57db0589a..88cec43086 100644 --- a/app/dumpcap/main.c +++ b/app/dumpcap/main.c @@ -830,11 +830,12 @@ static void enable_pdump(struct rte_ring *r, struct rte_mempool *mp) intf->opts.promisc_mode = false; } else { ret = rte_eth_promiscuous_enable(intf->port); - if (ret != 0) + if (ret != 0) { fprintf(stderr, "port %u set promiscuous enable failed: %d\n", intf->port, ret); - intf->opts.promisc_mode = false; + intf->opts.promisc_mode = false; + } } } ++count; -- 2.43.2