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 D880145CFC; Thu, 14 Nov 2024 02:54:55 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A8869427C6; Thu, 14 Nov 2024 02:54:26 +0100 (CET) Received: from mail-pj1-f44.google.com (mail-pj1-f44.google.com [209.85.216.44]) by mails.dpdk.org (Postfix) with ESMTP id 1A42C427BB for ; Thu, 14 Nov 2024 02:54:22 +0100 (CET) Received: by mail-pj1-f44.google.com with SMTP id 98e67ed59e1d1-2e2ed59a35eso128678a91.0 for ; Wed, 13 Nov 2024 17:54:22 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1731549261; x=1732154061; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=nty0XBWWTjLBUKKftxt/XVsL+wbUPIw1NLIfrRmY5W4=; b=zWcPxnpQEULjR0MF7Lm9R333KCe/fIispaGtVJJiG/qzJFfq+zZPlB4bNFQMJCqs1G pWqlYWrdzSSIm6Z7olnZToYnzLfyRUkvkwsmDmajisvOEayFksdFYMor01CPeYvDwukc U3GFkbWzhHomBieuhppgXA0ddIeaYjZcBSb7++7LjKQhw60EADd7kObXMejcPyzy/o43 Zs2RKHJcKU7fu1ZPPWzIedDo3urv4gaMMJFBcxKznax4uQqbNIz0E8oR3njxUJkvdoc5 freclcccjpo9cCOqV2le5l5cBIyQ8C94j47NE1o9eV3nIMFxeHugYkLQwtqfbfiWyJz6 M6dA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1731549261; x=1732154061; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=nty0XBWWTjLBUKKftxt/XVsL+wbUPIw1NLIfrRmY5W4=; b=jaG2Jf+mLk6xm3djqqvkBAFbdZ01WV20DgZJ0qitAm8K7LmKk6Aqp30aLkehwoAgeG jTh+pE305GJy8CVimoOmGgL+3ebnHGvK4q2uSddgMHrLAuIyAeS/icOTb590qdnT/osP 3NdGB7kkqaICNOiXr6cppMEDMd/IQkSyqBnrJI4ve1K6jguzgZ0C0b4bCXEih+pfRFxE hUc5xJKyQzp8eb7XC9X2IgN+wvvTma0fKm0Knx196FkPr7tywdp7q8bUJqK0N6kDoZr0 AWQ4C0Ag/08IRWH2yMbyS+Da7Iy6yvhUlf9ttP5rLV6hwVeH4cDNAkQZLJHeERwB7b7V 7tqw== X-Gm-Message-State: AOJu0YzKJlQ7BPleu1P3MaJfgNUqx57QMyy0clABrylX4D7i2+hcfq/H KWs20hX6hZ/ahur8nIMjA7nhZuawVdJzdbeLhSOQ0ZCnwPH4MfdoePyoLNADqN1vBR7t6y0oJUG 1 X-Google-Smtp-Source: AGHT+IFZfSwqaxzImX0TvTgjqpN8JwJCCd7UDR4w4/aQuAj2HxttsKcKWMJpEMKA1o6W5gAYHqr2zA== X-Received: by 2002:a17:90b:3884:b0:2e7:7f7f:9681 with SMTP id 98e67ed59e1d1-2e9b16eebdbmr29313701a91.6.1731549261355; Wed, 13 Nov 2024 17:54:21 -0800 (PST) Received: from hermes.local (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2ea02496eedsm210050a91.18.2024.11.13.17.54.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Nov 2024 17:54:20 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Chengwen Feng Subject: [PATCH v2 6/8] bus/uacce: remove memset before free Date: Wed, 13 Nov 2024 17:52:20 -0800 Message-ID: <20241114015405.77060-7-stephen@networkplumber.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241114015405.77060-1-stephen@networkplumber.org> References: <20241114011129.451243-1-stephen@networkplumber.org> <20241114015405.77060-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 Doing memset before free maybe removed by compiler, and is flagged by security scanning tools as potential problem. In this case the memset is unnecessary. Signed-off-by: Stephen Hemminger --- drivers/bus/uacce/uacce.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/bus/uacce/uacce.c b/drivers/bus/uacce/uacce.c index c1529c38c0..35c1027245 100644 --- a/drivers/bus/uacce/uacce.c +++ b/drivers/bus/uacce/uacce.c @@ -454,7 +454,6 @@ uacce_cleanup(void) dev->device.driver = NULL; free: - memset(dev, 0, sizeof(*dev)); free(dev); } -- 2.45.2