From patchwork Sat Jul 8 08:57:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miaohe Lin X-Patchwork-Id: 13305637 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2264DEB64DC for ; Sat, 8 Jul 2023 08:57:54 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 2FD128D0007; Sat, 8 Jul 2023 04:57:40 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id E67FF8E0001; Sat, 8 Jul 2023 04:57:39 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id BCFDE8E0002; Sat, 8 Jul 2023 04:57:39 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id 835C38D0007 for ; Sat, 8 Jul 2023 04:57:39 -0400 (EDT) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 4593EAF690 for ; Sat, 8 Jul 2023 08:57:39 +0000 (UTC) X-FDA: 80987841438.20.88385D2 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by imf02.hostedemail.com (Postfix) with ESMTP id E8AAE80006 for ; Sat, 8 Jul 2023 08:57:36 +0000 (UTC) Authentication-Results: imf02.hostedemail.com; dkim=none; spf=pass (imf02.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.188 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1688806657; 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=SdGpbb556DGksW+H1uvavfz+poJOo1vWJOFJPx6ylv4=; b=opVI7exxon6S0CSFal5kzhvM/8Gb1HYN3GdV0aWSkmaBOSCRwa45oZmtkP5b+3dRU7rWeI PeZun9EuJcu5ukeUT8SwNmFrK+GLQAEIzXFa7SSSeuNxthdGFCS8W18iW4cG8jENoDpi6Z tMCPLdpYC08CJ9iDJGRNQq38QRbxvCc= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1688806657; a=rsa-sha256; cv=none; b=ixZZGsIBQgskGenxBRh8UsbhU0FHrH0eQIzwJqhgqZgmxHZrkHH191y25iNniBCYesXjW9 aFhWE5eGrC3nfKTGhd3BGHijdjCkV3iZy2fUBhy5Ydhc9BAEbsVKO+hLJG0cz4quXAPUCp UF5GbdDySj60yES/Bi+2vZFJEDDCr5M= ARC-Authentication-Results: i=1; imf02.hostedemail.com; dkim=none; spf=pass (imf02.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.188 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com Received: from canpemm500002.china.huawei.com (unknown [172.30.72.57]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4Qykdh22YNzTm2M; Sat, 8 Jul 2023 16:56:24 +0800 (CST) Received: from huawei.com (10.174.151.185) by canpemm500002.china.huawei.com (7.192.104.244) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Sat, 8 Jul 2023 16:57:30 +0800 From: Miaohe Lin To: , CC: , , Subject: [PATCH 6/8] mm: memory-failure: minor cleanup for comments and codestyle Date: Sat, 8 Jul 2023 16:57:42 +0800 Message-ID: <20230708085744.3599311-7-linmiaohe@huawei.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20230708085744.3599311-1-linmiaohe@huawei.com> References: <20230708085744.3599311-1-linmiaohe@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.174.151.185] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To canpemm500002.china.huawei.com (7.192.104.244) X-CFilter-Loop: Reflected X-Rspamd-Queue-Id: E8AAE80006 X-Rspam-User: X-Stat-Signature: 6ib84656aqhwiedehn9ghcyjenxa6syx X-Rspamd-Server: rspam03 X-HE-Tag: 1688806656-888780 X-HE-Meta: U2FsdGVkX1/ocZijmpX11rC5NSTGSZAbt/5DH+3GkEoJkF6NTthuYP0SnJsM3ZXEHEP6wrHXM6Uj9iuYFNlYxiYcNr3JuiOF1Wtf5L8gesI+z0jV/tb6paXwjkFXJjhxfXo7TSsVhWORwP27qoVbTnJux46TQEzv/UMwM1F9OJhpntHZt53GN9GV7dMI8mNFmrKXBMVf/9PH7yMzI7AkL4iavhusn22Wz7ubWr7Ix6iHOykSiKGUx6KeUOwZxzpbodvUDqWTYt562xlsFEpigZFIJwD8l3KgHfEFQiIZzOeQ8FyjmMe9jUoOXfkx2m3FT52asW6WxmOzAwxwD+OfYlBYPekZKIpKAmLx/kGRuSg33PQi3ZTHGURlx1wNWSbw2PYu7mywQDD0CG47EAuoCaiNh+zzucZh/0+5VN3KxVLEEax868lqTkwlDgCtoSJYIWC7GIl0HmlOdbitt3xe72pAgfBePOAYV+dbHHWJvEi9g9UGvSeJPycHlGWfKuKxMJQsiiuA5FtLU0gJHDtL3s3xgthr+nbd4S5UV9ofLvxc5MOwytp9KfJ2bmePjQOjZBU8HM9DvE0yn2SsTBZFMVceRQsr2izpXxszrZAL/pUe45vY96wmnYqRBDmbYWs52ORltvOfKqLJIiwOH2Co81MUDxmzL5DNRC++5WST7mecu9g/Jg6AEfbjv3KxM8XjS6CvsLLnH+j6wYma7JO+vBd60/M7PToubuauVLfhg2+miaUxPL/BwYCfpzTdLCH/9lX7LdPt9DANZ5Z0W4a8O6+s/nlJMxQIBfh7b3MR3Rob/zd79iotYTWQNcA/WKGpvrqnBYKN2iystOBW2asL4yM3AYyYj2o7KKrs03/A9KSkvfG6VL9FQH7i4myV5fk0yJq4K6i+2lM/slez103mAaNoUo5C9RSdCPlmp99CRA40FhH8DhkNPnz6iwdMPJIgnvAvFl0fD14Jck9kINs llbbq3O0 yGBZ/fT6sVelDoEphF8na4YrAUumLwsBTwYUjGtpXyGsh7tAfA3FSnWS30/4PGVtrNVE/Bpn7gfKAmyseZpjWlCyeOK2mkDDFvdIOMea2bkcYWt4TrhW4u8OazIGT8Crn/Q9Nv+rNjrX2ZZg= 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: Fix some wrong function names and grammar error in comments. Also remove unneeded space after for_each_process. No functional change intended. Signed-off-by: Miaohe Lin Acked-by: Naoya Horiguchi --- mm/memory-failure.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/mm/memory-failure.c b/mm/memory-failure.c index 601936f8d30b..0f93175ed862 100644 --- a/mm/memory-failure.c +++ b/mm/memory-failure.c @@ -608,7 +608,7 @@ static void collect_procs_anon(struct page *page, struct list_head *to_kill, pgoff = page_to_pgoff(page); read_lock(&tasklist_lock); - for_each_process (tsk) { + for_each_process(tsk) { struct anon_vma_chain *vmac; struct task_struct *t = task_early_kill(tsk, force_early); @@ -652,7 +652,7 @@ static void collect_procs_file(struct page *page, struct list_head *to_kill, /* * Send early kill signal to tasks where a vma covers * the page but the corrupted page is not necessarily - * mapped it in its pte. + * mapped in its pte. * Assume applications who requested early kill want * to be informed of all such data corruptions. */ @@ -2120,7 +2120,7 @@ static DEFINE_MUTEX(mf_mutex); * detected by a background scrubber) * * Must run in process context (e.g. a work queue) with interrupts - * enabled and no spinlocks hold. + * enabled and no spinlocks held. * * Return: 0 for successfully handled the memory error, * -EOPNOTSUPP for hwpoison_filter() filtered the error event, @@ -2225,7 +2225,7 @@ int memory_failure(unsigned long pfn, int flags) * otherwise it may race with THP split. * And the flag can't be set in get_hwpoison_page() since * it is called by soft offline too and it is just called - * for !MF_COUNT_INCREASE. So here seems to be the best + * for !MF_COUNT_INCREASED. So here seems to be the best * place. * * Don't need care about the above error handling paths for @@ -2582,10 +2582,10 @@ static bool isolate_page(struct page *page, struct list_head *pagelist) /* * If we succeed to isolate the page, we grabbed another refcount on - * the page, so we can safely drop the one we got from get_any_pages(). + * the page, so we can safely drop the one we got from get_any_page(). * If we failed to isolate the page, it means that we cannot go further * and we will return an error, so drop the reference we got from - * get_any_pages() as well. + * get_any_page() as well. */ put_page(page); return isolated;