From patchwork Tue Nov 26 15:56:54 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Donet Tom X-Patchwork-Id: 13895570 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 5822BE7716D for ; Thu, 5 Dec 2024 15:28:16 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 09F606B00B8; Thu, 5 Dec 2024 10:19:27 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id B23896B00C0; Thu, 5 Dec 2024 10:19:22 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1FCCE6B00E4; Thu, 5 Dec 2024 10:19:14 -0500 (EST) 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 D792D6B009A for ; Tue, 26 Nov 2024 10:57:03 -0500 (EST) Received: from smtpin13.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 94117160F0D for ; Tue, 26 Nov 2024 15:57:03 +0000 (UTC) X-FDA: 82828699674.13.4C5C2AC Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by imf12.hostedemail.com (Postfix) with ESMTP id 6B7C74001D for ; Tue, 26 Nov 2024 15:56:59 +0000 (UTC) Authentication-Results: imf12.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=P3FvoJg1; dmarc=pass (policy=none) header.from=ibm.com; spf=pass (imf12.hostedemail.com: domain of donettom@linux.ibm.com designates 148.163.158.5 as permitted sender) smtp.mailfrom=donettom@linux.ibm.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1732636619; a=rsa-sha256; cv=none; b=W1veksZFqVypeZhr8zJC8lyohKIpwUmoUCws+FEUOEmzvYnRwenA05wKKNiWkbhhMU0sZc CddMwIWwCf3FNxLW7AiLgkFQezmthR7trFmo3ypoVHqctL2kwczuH8RPWmoZNBC2od+pI9 76kHq+BJk2GEOz1D6Pf0umri9Fnp6Bw= ARC-Authentication-Results: i=1; imf12.hostedemail.com; dkim=pass header.d=ibm.com header.s=pp1 header.b=P3FvoJg1; dmarc=pass (policy=none) header.from=ibm.com; spf=pass (imf12.hostedemail.com: domain of donettom@linux.ibm.com designates 148.163.158.5 as permitted sender) smtp.mailfrom=donettom@linux.ibm.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1732636619; 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-transfer-encoding:content-transfer-encoding: in-reply-to:references:dkim-signature; bh=ZiEzFkEEG/yOd1SYlmIUbRGREFxV/2noPsDQUv2e7+4=; b=2+qrwBIzrIw1Hg6xPvfxIxb1hPOSZ6fXTI/vTKtW3Sc+yIPQ7uA/dMFr8L33DDcEPqFGkC U/7gbNmuCuyEaVVAUPHbl83c/Cp870qsoR38ZHKdzRTR4laHZ7XYel4emy090E5MGYVLmh 9hOu4Knna8bqCwrrNWRrPL7DNPEydEc= Received: from pps.filterd (m0360072.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 4AQCTsoi002420; Tue, 26 Nov 2024 15:57:00 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=cc :content-transfer-encoding:date:from:message-id:mime-version :subject:to; s=pp1; bh=ZiEzFkEEG/yOd1SYlmIUbRGREFxV/2noPsDQUv2e7 +4=; b=P3FvoJg133j+VaaQ8p9Glw/lWNfDu96qeoVcWgbn1JHfItydm2EqnazlU Rdu999Tt2pGKY4ybj24BlGVtR7t+N1faGDtTVUc+cwTzgmH/mCGPfW7a3lILJOhC OGVCCPybZHO3kgL/D9F+AOrp197FHxEmVlJdZO3WKjIR7rWdLR1r+iLTRPbwBR4S 0E3vRmF9KljS2gRuac7dXwrPssHec1m/YvM97W5nqE61I1VY3dr65dzSvPldX57+ WOKqr05nOTGckCEoXT0hciST+CAUJpw/wP5i2OmSha9h7z2UpAA3kTdNMeFnU2PR ne6bLIatsVxAh7xXJrfEAyAod4PZg== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 435ecmh0w0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 26 Nov 2024 15:57:00 +0000 (GMT) Received: from m0360072.ppops.net (m0360072.ppops.net [127.0.0.1]) by pps.reinject (8.18.0.8/8.18.0.8) with ESMTP id 4AQFrnoZ002824; Tue, 26 Nov 2024 15:56:59 GMT Received: from ppma11.dal12v.mail.ibm.com (db.9e.1632.ip4.static.sl-reverse.com [50.22.158.219]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 435ecmh0vx-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 26 Nov 2024 15:56:59 +0000 (GMT) Received: from pps.filterd (ppma11.dal12v.mail.ibm.com [127.0.0.1]) by ppma11.dal12v.mail.ibm.com (8.18.1.2/8.18.1.2) with ESMTP id 4AQEpjB0026370; Tue, 26 Nov 2024 15:56:58 GMT Received: from smtprelay06.fra02v.mail.ibm.com ([9.218.2.230]) by ppma11.dal12v.mail.ibm.com (PPS) with ESMTPS id 433v30vjp1-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 26 Nov 2024 15:56:58 +0000 Received: from smtpav07.fra02v.mail.ibm.com (smtpav07.fra02v.mail.ibm.com [10.20.54.106]) by smtprelay06.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 4AQFuvir34079400 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 26 Nov 2024 15:56:57 GMT Received: from smtpav07.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 2A28F2004B; Tue, 26 Nov 2024 15:56:57 +0000 (GMT) Received: from smtpav07.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id EF79F20040; Tue, 26 Nov 2024 15:56:55 +0000 (GMT) Received: from ltczz402-lp1.aus.stglabs.ibm.com (unknown [9.40.194.31]) by smtpav07.fra02v.mail.ibm.com (Postfix) with ESMTP; Tue, 26 Nov 2024 15:56:55 +0000 (GMT) From: Donet Tom To: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org, David Hildenbrand Cc: Ritesh Harjani , Baolin Wang , Zi Yan Subject: [PATCH v2] mm: migrate: Removed unused argument vma from migrate_misplaced_folio Date: Tue, 26 Nov 2024 09:56:54 -0600 Message-ID: <20241126155655.466186-1-donettom@linux.ibm.com> X-Mailer: git-send-email 2.43.5 MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: WxJmLFfR-jztPCh5UfWLIRIzY6oCxbi- X-Proofpoint-GUID: FbdtrPHVT26p0mdygF1ze3MGpw1xuuCp X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1051,Hydra:6.0.680,FMLib:17.12.62.30 definitions=2024-10-15_01,2024-10-11_01,2024-09-30_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 impostorscore=0 mlxscore=0 lowpriorityscore=0 phishscore=0 spamscore=0 adultscore=0 mlxlogscore=999 bulkscore=0 clxscore=1015 suspectscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2409260000 definitions=main-2411260125 X-Rspam-User: X-Rspamd-Queue-Id: 6B7C74001D X-Rspamd-Server: rspam11 X-Stat-Signature: 7u1qmdffobito4pb4bjadggctiqhh6z8 X-HE-Tag: 1732636619-597808 X-HE-Meta: U2FsdGVkX19yPwCor6w21eot37sNNIZDQJ7sQFyhvq13vlxxoFGRePrTB0Wnw5NrA77Nr/zXkclnUYSsyttFz/lLq3gjkmc/+9mA3uFEtRMkDGYR3ZS0EdNbB5uVlukyBcSww3isfa7TPqv+06P09ZFXQWXBYKbyw+86z8pdHLdtomFTKFpd211g7i2cAeFfe2o1I7AzNL2CmBuhBERb2XuBErVYOtfXugq3ejJB6DRrsXoOG2rS/+GRngTbOaU4TIk0QJ4A9BSr8nNt9jaS3HQTx3PJkO/erjSAwsh+KYHC9AfP318zs9Wod9a2CJOn26hDD3DtyKPD/H53v1W4AZqYDQqNtONJB2STB5L1205P3nv07MSPyRMRuqM8uj8ea3Qc4d/VOJhAH2nrrmedrPOfwoKNOURHJmduHkJ0OrU/tnXhtLlrTck33SuDnPyRR1Pi9Q7YjQETWNXCRBMlbg0Cv4RZsfUTKJZXW8d49umYDzcOw6VRMgHyHgmLsoxEyldLFyT/vvgPTPxoOr1GTSDScEG8wbDdksaPzAe49jaZw2iqtJUzstA1mcq6lorkb/CIwFdf5WKkNUzQrtAtGnX2gq8q6enITOhrnAcTaDdb//8pVBt2+t68lSL7XbKNpy5V7X2tLol8yCBNZHseus2rx29TvXdcBUDZ6b8LM2GRZRxDw4EqUEqqTBUZY/+ebDffCEv7zwA5aunc4Sz+hEt1xg4D1MLQ1pCv1QilVT16myBDad1PIGTH+ffmWgyuz6UqfE8r1p83PE1xnRQCPGznM4UwmpohO/wrj1JdPioNhPUGC5glmAKfCxxBhyTxl01pD4DDIAvtLSaMJaH21ohwaL6KfB0oIT6YWK1nB7IvPpkrj3K36x/e/PjkbzG5oHEoLgzcY8ozGs2KjVAgQGRgNdXldcw73ibkjgWyhiDdr9HPWsuoVmV8XbMwULgfa2T58oad3MB+XWI6swv mBJVPqh2 52qyyaWdqco/37X/VFkWI4VSrsY8/7+vyHTXQhPxIUfHQay9AeufiUTXU/qWgJoMdiCcL45IzXrPtpXkVdY++J8g19VOyrjneoB+rA9p3Yh1IA0KZpBg0khkNK/Isk73wqvYsHVMm9jpkilBLXEpYRKYNrJYkLVHQyFLygurIPKf0ZB1Ps3F/Yt19QxjL8qVQzk3DkrHyoqwMCYBj/of/nD+T9IfUn3vQyUEzTUWGKcF1wy01l/3zSn6Z3VskOSn8tYHZVyR0g7dYNTJSjZJOi4GXp5tvP+W3r6bptmyg6384WWmscIT30zESf6SZGN5PedX56+/Z4ieit4RqjF0rKiNEGwNrl1lE3LBOcbLWJwSXumQaOzCwok6zEkdmEEgirhgz6Z7Tw+36zjBS7ypkDUT5SSFy1bux5lk8eEjS6WVik8HDI29iCxBIMsEnggczo9OEt444g24edQHAykj16JwLK7bZqEG0QOkpjYZw2gAB+O4gTkLyFRus4kyR15OmZFVX 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: List-Subscribe: List-Unsubscribe: Commit ee86814b0562 ("mm/migrate: move NUMA hinting fault folio isolation + checks under PTL") removed the code that had used the vma argument in migrate_misplaced_folio. Since the vma argument was no longer used in migrate_misplaced_folio, this patch removed it. changes: V2: Added mm:migrate prefix in subject line. V1: https://lore.kernel.org/all/20241125075731.176573-1-donettom@linux.ibm.com/ Signed-off-by: Donet Tom Reviewed-by: Baolin Wang Reviewed-by: Zi Yan --- include/linux/migrate.h | 6 ++---- mm/huge_memory.c | 2 +- mm/memory.c | 2 +- mm/migrate.c | 3 +-- 4 files changed, 5 insertions(+), 8 deletions(-) diff --git a/include/linux/migrate.h b/include/linux/migrate.h index 002e49b2ebd9..29919faea2f1 100644 --- a/include/linux/migrate.h +++ b/include/linux/migrate.h @@ -144,16 +144,14 @@ const struct movable_operations *page_movable_ops(struct page *page) #ifdef CONFIG_NUMA_BALANCING int migrate_misplaced_folio_prepare(struct folio *folio, struct vm_area_struct *vma, int node); -int migrate_misplaced_folio(struct folio *folio, struct vm_area_struct *vma, - int node); +int migrate_misplaced_folio(struct folio *folio, int node); #else static inline int migrate_misplaced_folio_prepare(struct folio *folio, struct vm_area_struct *vma, int node) { return -EAGAIN; /* can't migrate now */ } -static inline int migrate_misplaced_folio(struct folio *folio, - struct vm_area_struct *vma, int node) +static inline int migrate_misplaced_folio(struct folio *folio, int node) { return -EAGAIN; /* can't migrate now */ } diff --git a/mm/huge_memory.c b/mm/huge_memory.c index ee335d96fc39..ab46ef718b44 100644 --- a/mm/huge_memory.c +++ b/mm/huge_memory.c @@ -2002,7 +2002,7 @@ vm_fault_t do_huge_pmd_numa_page(struct vm_fault *vmf) spin_unlock(vmf->ptl); writable = false; - if (!migrate_misplaced_folio(folio, vma, target_nid)) { + if (!migrate_misplaced_folio(folio, target_nid)) { flags |= TNF_MIGRATED; nid = target_nid; task_numa_fault(last_cpupid, nid, HPAGE_PMD_NR, flags); diff --git a/mm/memory.c b/mm/memory.c index 75c2dfd04f72..12bb79d4df72 100644 --- a/mm/memory.c +++ b/mm/memory.c @@ -5625,7 +5625,7 @@ static vm_fault_t do_numa_page(struct vm_fault *vmf) ignore_writable = true; /* Migrate to the requested node */ - if (!migrate_misplaced_folio(folio, vma, target_nid)) { + if (!migrate_misplaced_folio(folio, target_nid)) { nid = target_nid; flags |= TNF_MIGRATED; task_numa_fault(last_cpupid, nid, nr_pages, flags); diff --git a/mm/migrate.c b/mm/migrate.c index 2ce6b4b814df..411b378dd39f 100644 --- a/mm/migrate.c +++ b/mm/migrate.c @@ -2683,8 +2683,7 @@ int migrate_misplaced_folio_prepare(struct folio *folio, * elevated reference count on the folio. This function will un-isolate the * folio, dereferencing the folio before returning. */ -int migrate_misplaced_folio(struct folio *folio, struct vm_area_struct *vma, - int node) +int migrate_misplaced_folio(struct folio *folio, int node) { pg_data_t *pgdat = NODE_DATA(node); int nr_remaining;