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 0E720A04A6; Mon, 24 Jan 2022 01:07:54 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7280542849; Mon, 24 Jan 2022 01:05:53 +0100 (CET) Received: from mail-pj1-f54.google.com (mail-pj1-f54.google.com [209.85.216.54]) by mails.dpdk.org (Postfix) with ESMTP id 2B06842837 for ; Mon, 24 Jan 2022 01:05:50 +0100 (CET) Received: by mail-pj1-f54.google.com with SMTP id nn16-20020a17090b38d000b001b56b2bce31so3902877pjb.3 for ; Sun, 23 Jan 2022 16:05:50 -0800 (PST) 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=SVEXLdTcsVppg5dFgNaFR63Y9RESnOdSyfFIOefb5jw=; b=2gu02u3iw0OcuV+vTPVyhNL050WmMODMAWctVEaseFjLJ0DRdTqJOSscpNI3DO7ewZ PSujHyGCtN1id1uFLsEdhLSeOY5wJXcbkNMb0LbeKuZHFSIfMtXp+4FbRxM2XHNPQg7t xseBvdD/Pe34Z7pAwgN0PHUUXohq1RMbglY1kC4AjhCNCOiF7LwhhFvofmOXvsBVCa6K Ur+sW1I0eehz1fkhjO6eK7DRrCtrYFYvSefpWhqJrai9dClHqRWgVCpHoQKjgQHI7qu7 I5GTxszpcwlT2UYLEMHloDtYrRASsSoc4B/QMIyLnRNVNIbAtImjsxIXseJHxlYVPnz0 NZug== 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=SVEXLdTcsVppg5dFgNaFR63Y9RESnOdSyfFIOefb5jw=; b=YFRz/VwV6XxSxEqA9xOCsnhdVvj40AXxdJ/7oHKtzSiPHWC0eguPIAqDmwCzg11WO8 Tg9WpqlLdHvsCsJFLOEcBK5ukHoJlfwcvZNQBLyERuCWhQ8SyugYePDhNCCDPirO8S22 85GjVjg6D2Io2Sx43kM4eAzM+APtuDWI3aN07VHJqrje31Fk2jTkX3oiFilXmaIvdo30 fVOPb/L9wJu3MVAMMdgcb1M+PZ4gu3ZyIpoJdFceXlh3NTgYutW61ztKPG5W7ynznEOf ibSz61d+m44OxrDTMLYfd2kXsxC/odYL6QcMZ/ynHhK9x2iJu6xKNjPoEQHaDKdH16Ss safg== X-Gm-Message-State: AOAM533Twr/hMF4PQ1Q6DHj84eW93Ydtgl1/G+pZfu9lt+/65naQ37Gn RpfzbIp/o2Hln1okE3HAYcBGHGwTz8zwrQ== X-Google-Smtp-Source: ABdhPJxLzdEenUYaCa7DTfNPzGlZgBEw2Xk8GBsqzsks71VOZOJtemhmVmtP5KqlMPxibskSeJdrig== X-Received: by 2002:a17:90a:3f09:: with SMTP id l9mr10666569pjc.38.1642982748796; Sun, 23 Jan 2022 16:05:48 -0800 (PST) Received: from hermes.local (204-195-112-199.wavecable.com. [204.195.112.199]) by smtp.gmail.com with ESMTPSA id ck21sm10935350pjb.51.2022.01.23.16.05.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 23 Jan 2022 16:05:48 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Matan Azrad , Fan Zhang , Ashish Gupta Subject: [PATCH 26/82] compress/mlx5: remove unnecessary NULL checks Date: Sun, 23 Jan 2022 16:04:22 -0800 Message-Id: <20220124000518.319850-27-stephen@networkplumber.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20220124000518.319850-1-stephen@networkplumber.org> References: <20220124000518.319850-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 Remove redundant NULL pointer checks before free functions found by nullfree.cocci Signed-off-by: Stephen Hemminger --- drivers/compress/mlx5/mlx5_compress.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/compress/mlx5/mlx5_compress.c b/drivers/compress/mlx5/mlx5_compress.c index 82b871bd860a..b12951da8b51 100644 --- a/drivers/compress/mlx5/mlx5_compress.c +++ b/drivers/compress/mlx5/mlx5_compress.c @@ -146,8 +146,7 @@ mlx5_compress_qp_release(struct rte_compressdev *dev, uint16_t qp_id) void *opaq = qp->opaque_mr.addr; mlx5_common_verbs_dereg_mr(&qp->opaque_mr); - if (opaq != NULL) - rte_free(opaq); + rte_free(opaq); } mlx5_mr_btree_free(&qp->mr_ctrl.cache_bh); rte_free(qp); -- 2.30.2