Message ID | 20240606063247.712575-7-linmiaohe@huawei.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8B3CBC25B75 for <linux-mm@archiver.kernel.org>; Thu, 6 Jun 2024 06:36:42 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 404386B00A7; Thu, 6 Jun 2024 02:36:32 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 2C6E76B00A3; Thu, 6 Jun 2024 02:36:32 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id DC7BB6B00A6; Thu, 6 Jun 2024 02:36:31 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id A96716B00A3 for <linux-mm@kvack.org>; Thu, 6 Jun 2024 02:36:31 -0400 (EDT) Received: from smtpin19.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 5EF15C1242 for <linux-mm@kvack.org>; Thu, 6 Jun 2024 06:36:31 +0000 (UTC) X-FDA: 82199504982.19.EEB803F Received: from szxga06-in.huawei.com (szxga06-in.huawei.com [45.249.212.32]) by imf03.hostedemail.com (Postfix) with ESMTP id 2C4212000F for <linux-mm@kvack.org>; Thu, 6 Jun 2024 06:36:28 +0000 (UTC) Authentication-Results: imf03.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf03.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.32 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1717655789; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=UH2rm6YiNrNNYVCZu41szqctz2O14RfFm9t+tz4o6Bk=; b=p7hBGawIAKakEBskq0D61fcdrr3ilJp3N3x9c84OWeEd6unBWuXqBCjc9nNDU4G+8Mh4bh cTheN07uCLYUEWmoEJNth+kPVN1wRse3+NsajJbyzvW4mnU0CtV6ODCVaGQXM5zwqo/ZT6 1KEne4FQWWCGVAQgjN1tZXYV7DIDGI0= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1717655789; a=rsa-sha256; cv=none; b=PVfok4LeiW2MbBcBNDjPIfJaUj3gZIbldMW1FFgSykCVXG7KqK6lOr5Ey1xsa4mYU8RsmF cpbZBWfdIXNe8vme1lb43q5JWR3y3MkJ0TxjGFpgIBhITNycRT+Kf5Vj4N5UADP7EW9AS9 eeaKQoIqMRWRMlFQbrvEU6MVb1E7TJo= ARC-Authentication-Results: i=1; imf03.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf03.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.32 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com Received: from mail.maildlp.com (unknown [172.19.162.112]) by szxga06-in.huawei.com (SkyGuard) with ESMTP id 4VvvhT19Fgz1xsBF; Thu, 6 Jun 2024 14:35:05 +0800 (CST) Received: from canpemm500002.china.huawei.com (unknown [7.192.104.244]) by mail.maildlp.com (Postfix) with ESMTPS id AFA62140109; Thu, 6 Jun 2024 14:36:25 +0800 (CST) Received: from huawei.com (10.173.135.154) by canpemm500002.china.huawei.com (7.192.104.244) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Thu, 6 Jun 2024 14:36:25 +0800 From: Miaohe Lin <linmiaohe@huawei.com> To: <akpm@linux-foundation.org>, <tony.luck@intel.com>, <bp@alien8.de> CC: <nao.horiguchi@gmail.com>, <linmiaohe@huawei.com>, <linux-mm@kvack.org>, <linux-kernel@vger.kernel.org>, <linux-edac@vger.kernel.org> Subject: [PATCH v2 06/13] mm/memory-failure: remove confusing initialization to count Date: Thu, 6 Jun 2024 14:32:40 +0800 Message-ID: <20240606063247.712575-7-linmiaohe@huawei.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20240606063247.712575-1-linmiaohe@huawei.com> References: <20240606063247.712575-1-linmiaohe@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.173.135.154] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To canpemm500002.china.huawei.com (7.192.104.244) X-Stat-Signature: jgau68zrtibo6xzhugtgb65umgdg6g96 X-Rspamd-Queue-Id: 2C4212000F X-Rspam-User: X-Rspamd-Server: rspam01 X-HE-Tag: 1717655788-86182 X-HE-Meta: U2FsdGVkX186jDoD/NLVPbsfEoPw5oXKTPryuxS2hd8XT6tGb9mVJvyxhJwHmkRIJtM/rhHnnlK1KMXYsEqbiKY8BQTI1XHmyQMXrzwnj8zsIMoz6udy5hA7aLp5pnbdtFtfMPJqY9BYL/xhZRfTGiQtJlhp7SjA9FACwpUCtnuK5fuUJGlswJNLAvypSN9xpZDqUbmQeJlSmpgogZjfyloyzzjQtXYfn5t14gh5w3VIODM4Z542uFQRbP1A9oZCeBmsepej0gkEaBMq+phi4TsWviEn1MG0GtTwmZGLXgnNO2CZpWS+uucEOoUUN1GgwYVYzMUmiruNZlL1lHjliQEfDKVpbRhBVob9W+fiVQSrmQnt2EUwRksR7DdgkgRJTjpeRW4/HZAvLI1h6fgGVBUT3QCCJVjA6exIuVTxXKGfdzaOEIWAlMT7+m3/BR8KJUJoOBFY09i7iAGJ/FZbsE2PSl655KVz8Gmzq0EB0+0pOnto6aGkcpH9fhEzfp/K2ZxJF7HBWnZo39qTzJIEFwrVrvGQsoZI4wS3npIEKp1cUMbbmmAqQB7CMOilT9Fk7qyziarmOCJaXnOcGhMYAeZpHW5B+cHvzm+fv5TeMOzp+nX+6Q3jC8IQAnX2zNNhJfNt6DmCXeTGliqG97G0ZAIb8YX9b1I22gXmiG2/fG2PAjhznV8BmJQY6l+hFpxE4UE6RgbNkguTg3BdvvuEtm7fxPhLqSMmhUpNCTvps00CFbSeKv81/1Zc1G52K0Xdx4nkx5xMBhH51ap2MGGAPs96ve+i5tPr6iSJYpeL57m4Fg+gi1ZgFSHCFQhs9cOBcp6SrntuX3CDd86BXXsJzLADahUsNLB+vapYmHUgU+9slgohfKxuactIN9hJXqsDUj8UtoNilEgjob2KD0kJj4VW2gJvUisfiZkhtSaROIoJxKY4Ym62TjYrXLvEcpTXHMNE0cGCJ3cCd62Gtzi vxwjgm5F 9ohlRh/qNuINbAZJxCNYruQIsWfl1ddrSuiY6NcdnGvEmMJnpatfMmg0ToL3lnc37f4C286YCKG7F8hfzQ4YuQTXRnK3F0sp4pgSN/jKBBl/u+nnyzpgcmnny0CANu9kuaC4krMghF4y08hLb0HAdbTlDYOvtQDwCvuLHF2n0kXadY6cKRChLSEdvFgvcQjLtyTQNLtnvIE/Ce10Svo+yDuRBoA== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
Some cleanups for memory-failure
|
expand
|
diff --git a/mm/memory-failure.c b/mm/memory-failure.c index ec482524158e..339752d768d8 100644 --- a/mm/memory-failure.c +++ b/mm/memory-failure.c @@ -2542,7 +2542,7 @@ int unpoison_memory(unsigned long pfn) struct folio *folio; struct page *p; int ret = -EBUSY, ghp; - unsigned long count = 1; + unsigned long count; bool huge = false; static DEFINE_RATELIMIT_STATE(unpoison_rs, DEFAULT_RATELIMIT_INTERVAL, DEFAULT_RATELIMIT_BURST);
It's meaningless and confusing to init local variable count to 1. Remove it. No functional change intended. Signed-off-by: Miaohe Lin <linmiaohe@huawei.com> --- mm/memory-failure.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)