Received: by 2002:a05:6358:bb9e:b0:b9:5105:a5b4 with SMTP id df30csp2588327rwb; Sun, 4 Sep 2022 20:08:46 -0700 (PDT) X-Google-Smtp-Source: AA6agR6YRJD7oaKUXND3kusYMWKForqy0wyB/nRudQhMHzJSo182TJuFyuAC0BWEDKiEJSkY9zXD X-Received: by 2002:a17:907:2724:b0:741:4a1f:6159 with SMTP id d4-20020a170907272400b007414a1f6159mr26841477ejl.542.1662347326173; Sun, 04 Sep 2022 20:08:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1662347326; cv=none; d=google.com; s=arc-20160816; b=cBjP8dciW+9hrrsorMR5ifU6xfiuZgREyoqqonR+SpOlh3ALkK3p9pVXEriAyFfsI/ nr++7mOFBpPBCXOfFQlSRbbM4ife9ldbSpp8Aolg4OGW/WOo6O0RF25QyNaPveDjl4dZ cj8v/Mh6rzk1lnuYhV7eaiDFUlxVarJU2CSM/cyWrW0hq1yKFRLk3KzaFciOwSavDJwq /dY2MEpIKh7Wfm+JR0eB4Jnq4soJqURpi5aEuRuiIDePTEGFeSThKVNusCHhc0ZVUfgs D2ekFcBthunojYeJRI2xH4mRxCjSfK9fvFUmXwzlgKNm1eAkOAHOUfCARUV6y+eoOqDh FtGA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=k86oOvJ5wXqnXWu6T6OWishvUXs410ZMERMItsuJZLM=; b=nNuA1Qy/k05BUppIwGmmszofgAWuVKllmWZgP1rW9Fv7Mbx/XajP7bPqfSGjnxHgj9 c8Vw47S498gA1IbGJ80/9T/33aTniKA7Z2nNsRYLHhz85f0OVV5gj3uq8RoidVXt+vG4 q8m86vmTBSwIKaFRvDVZG5uAZcT9sLmvvQSagc5F2vy6uCyQrB/CPFrcDvRy7i4cQMpI CEDNa3M5oLSmIpMFJHTpfZPMHTIeaKZMaAAKKQIo0TOZ8v3E4Kb2vgE0htaCvxeYOCwz GGur9Gys7ENTsZ2rC1gQx1NJOKP20SbmG/Sz3gSvPQXttmCOFws/zc1/FU5+etRSaCrz +OAg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hr12-20020a1709073f8c00b00730c9a41812si7328426ejc.723.2022.09.04.20.08.21; Sun, 04 Sep 2022 20:08:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235444AbiIECJi (ORCPT + 99 others); Sun, 4 Sep 2022 22:09:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50258 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235064AbiIECJc (ORCPT ); Sun, 4 Sep 2022 22:09:32 -0400 Received: from mail.nfschina.com (mail.nfschina.com [124.16.136.209]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 7D9FF110E for ; Sun, 4 Sep 2022 19:09:30 -0700 (PDT) Received: from localhost (unknown [127.0.0.1]) by mail.nfschina.com (Postfix) with ESMTP id 162BB1E80D74; Mon, 5 Sep 2022 10:08:36 +0800 (CST) X-Virus-Scanned: amavisd-new at test.com Received: from mail.nfschina.com ([127.0.0.1]) by localhost (mail.nfschina.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id HiXgdR0GdOS1; Mon, 5 Sep 2022 10:08:33 +0800 (CST) Received: from localhost.localdomain (unknown [219.141.250.2]) (Authenticated sender: zeming@nfschina.com) by mail.nfschina.com (Postfix) with ESMTPA id 876B51E80D59; Mon, 5 Sep 2022 10:08:33 +0800 (CST) From: Li zeming To: mike.kravetz@oracle.com, songmuchun@bytedance.com, akpm@linux-foundation.org Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Li zeming Subject: [PATCH] mm: Remove unnecessary '0' values from err Date: Mon, 5 Sep 2022 10:09:18 +0800 Message-Id: <20220905020918.3552-1-zeming@nfschina.com> X-Mailer: git-send-email 2.18.2 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org First execute the kstrtoul function and assign a value to err. Signed-off-by: Li zeming --- mm/hugetlb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/hugetlb.c b/mm/hugetlb.c index e070b8593b37..be7a2c4081fc 100644 --- a/mm/hugetlb.c +++ b/mm/hugetlb.c @@ -3714,7 +3714,7 @@ static ssize_t demote_store(struct kobject *kobj, unsigned long nr_available; nodemask_t nodes_allowed, *n_mask; struct hstate *h; - int err = 0; + int err; int nid; err = kstrtoul(buf, 10, &nr_demote); -- 2.18.2