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 95FB9A034F; Mon, 24 Jan 2022 01:10:06 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DB78B428D3; Mon, 24 Jan 2022 01:06:21 +0100 (CET) Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) by mails.dpdk.org (Postfix) with ESMTP id CFDE8428BC for ; Mon, 24 Jan 2022 01:06:16 +0100 (CET) Received: by mail-pj1-f45.google.com with SMTP id s61-20020a17090a69c300b001b4d0427ea2so18759413pjj.4 for ; Sun, 23 Jan 2022 16:06:16 -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=skn4RezxA6fzdblvvu4Dbyud7yUiw8Oo0uSoBCpx7wE=; b=B2YRUVns06S8yIkJJHcCQ2gZhUFkAgqrq+qwOeqvrgJFzaKCh1ifvjkq1CIMkQPYjF mj6qw/lfnQRTqEUGT/hwIIF/e7D190bba3QIfKh3AVm0tuD4Zq/6zjlMw5TXwVU/gyPu gl74vKLGxWo+k3jTOjua2y20tq2ZBbt6GTwXFrIpyupJW/OTgs9otesgzi4T6L6wajGo DVDlNF62hp8tIm5qTFx6vWt1EkTyVGf3hDRbliBhzRI35rE+L8AGbKjFYoCc98jqlSeG pG3zT5xQHe7HYlRc0KkXbLvV4tT1uGvHAGfXoo+C40XRdfQAuOvcGwsNgtBGStQzMd4n F+ng== 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=skn4RezxA6fzdblvvu4Dbyud7yUiw8Oo0uSoBCpx7wE=; b=CwcvBkQnKcIea5BVuDyz6UIEYc05Cj++pfH6z1DrdtKjFJHFYBX+cjoNZVmJETSrMj 6zRmxPL8usAeJHyvT8JC19G2b6AAw0xcCGQnqFSD2yJSZwdMIq0KFnmYbtPgT3WSW3cW y3JQG873+ZRw3cMrxFHmoOM93ol8tXW3bJ8DJiGNLRhU56W/iJWd+YU6DeOhxqbEQDgf dyKiMai4DT1rnDeGx7zeK4RBQELSRHFsIAqJ7RIQnuEhiuCm4J/n74uZiGYfS2FQ2GNS IS13NFbMio94F9SU+eJVsK7dS4jcltIIV5zOuBGszV+L7Mp6iyKw+7eKS3C2/Lq/X0d7 GCBQ== X-Gm-Message-State: AOAM532RwTzC7+70vV3Zj9GG2jz8cL4Tomtzfmi1t87JTCLIqtIrLJ1s dBEgppyYXTjZULXR9Tao/Z8EBykxWMm78A== X-Google-Smtp-Source: ABdhPJzTDvXjvxp8VN9Khr/K1dfApkQo6FX0wcxs51tQPIM4oDlLNSNGA6gQ5MMY9cghjn5HBwNkiQ== X-Received: by 2002:a17:90a:5d83:: with SMTP id t3mr10552469pji.159.1642982775855; Sun, 23 Jan 2022 16:06:15 -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.06.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 23 Jan 2022 16:06:15 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Qiming Yang , Qi Zhang Subject: [PATCH 52/82] net/ice: remove unnecessary NULL checks Date: Sun, 23 Jan 2022 16:04:48 -0800 Message-Id: <20220124000518.319850-53-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/net/ice/ice_fdir_filter.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/net/ice/ice_fdir_filter.c b/drivers/net/ice/ice_fdir_filter.c index 13a2ac42df87..3fce8e1e6253 100644 --- a/drivers/net/ice/ice_fdir_filter.c +++ b/drivers/net/ice/ice_fdir_filter.c @@ -421,10 +421,8 @@ ice_fdir_release_filter_list(struct ice_pf *pf) { struct ice_fdir_info *fdir_info = &pf->fdir; - if (fdir_info->hash_map) - rte_free(fdir_info->hash_map); - if (fdir_info->hash_table) - rte_hash_free(fdir_info->hash_table); + rte_free(fdir_info->hash_map); + rte_hash_free(fdir_info->hash_table); fdir_info->hash_map = NULL; fdir_info->hash_table = NULL; -- 2.30.2