From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5F6D8C83F11 for ; Mon, 28 Aug 2023 01:47:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229646AbjH1BrO (ORCPT ); Sun, 27 Aug 2023 21:47:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56024 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229641AbjH1Bqs (ORCPT ); Sun, 27 Aug 2023 21:46:48 -0400 Received: from mail.nfschina.com (unknown [42.101.60.195]) by lindbergh.monkeyblade.net (Postfix) with SMTP id 09C00113 for ; Sun, 27 Aug 2023 18:46:44 -0700 (PDT) Received: from localhost.localdomain (unknown [219.141.250.2]) by mail.nfschina.com (Maildata Gateway V2.8.8) with ESMTPA id 10A23604C5038; Mon, 28 Aug 2023 09:46:36 +0800 (CST) X-MD-Sfrom: zeming@nfschina.com X-MD-SrcIP: 219.141.250.2 From: Li zeming To: tj@kernel.org, jiangshanlai@gmail.com Cc: linux-kernel@vger.kernel.org, Li zeming Subject: [PATCH] =?UTF-8?q?kernel/workqueue:=20Remove=20unnecessary=20?= =?UTF-8?q?=E2=80=980=E2=80=99=20values=20from=20hash?= Date: Wed, 30 Aug 2023 02:17:55 +0800 Message-Id: <20230829181755.3204-1-zeming@nfschina.com> X-Mailer: git-send-email 2.18.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org hash is assigned first, so it does not need to initialize the assignment. Signed-off-by: Li zeming --- kernel/workqueue.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/workqueue.c b/kernel/workqueue.c index 45213c74d391..c3a0d10088b4 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -3736,7 +3736,7 @@ static void copy_workqueue_attrs(struct workqueue_attrs *to, /* hash value of the content of @attr */ static u32 wqattrs_hash(const struct workqueue_attrs *attrs) { - u32 hash = 0; + u32 hash; hash = jhash_1word(attrs->nice, hash); hash = jhash(cpumask_bits(attrs->cpumask), -- 2.18.2