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 68F21A034C; Wed, 22 Jun 2022 20:52:09 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7F486427F1; Wed, 22 Jun 2022 20:52:05 +0200 (CEST) Received: from mail-pl1-f178.google.com (mail-pl1-f178.google.com [209.85.214.178]) by mails.dpdk.org (Postfix) with ESMTP id 83DC44069F for ; Wed, 22 Jun 2022 20:52:02 +0200 (CEST) Received: by mail-pl1-f178.google.com with SMTP id y6so16162086plg.0 for ; Wed, 22 Jun 2022 11:52:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ASDI7VlMGbt/sowXqxAvG6UCiOr64gL8QK31uMKnzVs=; b=GTq/F/qGSLUhB3cPGnxqPxdqVuuNqlypqq2DK7lSbxlgPtIo3IPExdmZIKyA/Yhw++ lNdcsXBzhN6KgD92dqfzuu4P3gWS3b2UbIm/oD1pVO8C4wySZWDpIS35L3U4tEuRXTV1 jrjAcuWNs9TPazxdmKGzGLwFTrNClp9ZgDV/xuy1C7Md32ii0/HZQiutag+IRykJTFxe pdB3bwJK179CHJAjfvBi+hPc+ro9EL/FP/0PhnL5GYFm4eeBTntSMjMr3htR3QOxsNo+ cXloHGFuQepZP1xPfd/3ep2eSutiUUjnySnWTYJbw2IzpYG/kdiW45FE4GKNrolCDx7j orlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ASDI7VlMGbt/sowXqxAvG6UCiOr64gL8QK31uMKnzVs=; b=06mSJlR8d+TJzmqu+JlYPbBXLlLqtDM0bLtjaVy8mX1cHXfpiT0+qZqhUcL6JZObYQ LGhn5YUd/nyYV4F5l7zV1QO7oMqGhgo/NXqBrx3VO/aMQ7d4hGC0GiuKrmo2SeIzXIpy 2Dm/jkC7+uMDShMoh2+GnCgpEdKg04oSZ0IVSG7+Od9MweZCzZ8tWCfhkgnwMCdK0nyM 12AEO7L0SPq3sLVRBBZowc/kT5q4/zStQtBBD4+uHIVRiPnsMWoqrwYiys4dAsEBNZJw jmJdL89nXJGYrIa8i3JpND+9F42sXQc2cftTOvKp1Bde6m6CtPC6hfKiV8XTMVbzuY6i l0Cg== X-Gm-Message-State: AJIora+eOUfzIxCGf74gZTbrSyHPWL4VFOCVvUWSkEicnwUawXIhcZj/ dUvNC24TGB7knnsebWWfeevXJ/RKCa1yLZLU X-Google-Smtp-Source: AGRyM1veChZ7mZY2tJbI2drB+QAiPBL9boGQtX+kh+N9TqR3vA90WsdJUWoBVoxssc/pLeAewz6LKA== X-Received: by 2002:a17:903:41d2:b0:16a:2cca:4869 with SMTP id u18-20020a17090341d200b0016a2cca4869mr13690920ple.13.1655923921460; Wed, 22 Jun 2022 11:52:01 -0700 (PDT) Received: from hermes.local (204-195-112-199.wavecable.com. [204.195.112.199]) by smtp.gmail.com with ESMTPSA id r6-20020a638f46000000b00407e25d4527sm9215817pgn.22.2022.06.22.11.52.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Jun 2022 11:52:00 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Matan Azrad , Viacheslav Ovsiienko Subject: [PATCH 1/3] vdpa/mlx5: remove unnecessary null check Date: Wed, 22 Jun 2022 11:51:56 -0700 Message-Id: <20220622185158.397779-2-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220622185158.397779-1-stephen@networkplumber.org> References: <20220622185158.397779-1-stephen@networkplumber.org> 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 Found by nullfree.cocci. Signed-off-by: Stephen Hemminger --- drivers/vdpa/mlx5/mlx5_vdpa_virtq.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/vdpa/mlx5/mlx5_vdpa_virtq.c b/drivers/vdpa/mlx5/mlx5_vdpa_virtq.c index e025be47d277..e06d6afb676f 100644 --- a/drivers/vdpa/mlx5/mlx5_vdpa_virtq.c +++ b/drivers/vdpa/mlx5/mlx5_vdpa_virtq.c @@ -285,8 +285,7 @@ mlx5_vdpa_virtq_setup(struct mlx5_vdpa_priv *priv, int index) if (virtq->umems[i].obj) claim_zero(mlx5_glue->devx_umem_dereg (virtq->umems[i].obj)); - if (virtq->umems[i].buf) - rte_free(virtq->umems[i].buf); + rte_free(virtq->umems[i].buf); virtq->umems[i].size = 0; virtq->umems[i].obj = NULL; virtq->umems[i].buf = NULL; -- 2.35.1