Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1511008rdb; Mon, 19 Feb 2024 20:08:28 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWDksSnDPclRGeFMzpzo+RGCANAw1Ul/SAGYbpfSdvu5RTNd9DtYzvy1olN2qRUC/54wvTreEPeMEBHTV/kyCAXK3jS15b6I18GVudTIA== X-Google-Smtp-Source: AGHT+IHyjMD9xNywHZkyPUjHxZPDP3VjospX6Ez6HY1OkIg3FndtOGX+uZ127FzBA1S1qqlJ32Q1 X-Received: by 2002:a17:902:d490:b0:1db:b6d3:ade1 with SMTP id c16-20020a170902d49000b001dbb6d3ade1mr10863400plg.27.1708402108364; Mon, 19 Feb 2024 20:08:28 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708402108; cv=pass; d=google.com; s=arc-20160816; b=o3M1JpVqjpYMXEdsbPXoxuHPYZqrv2uhn8k8oOCJXeqDnOmiZR+h9idLQJOtKU1A7y fLNA88pTVV7uHtEqQKHpm6qo0qi1WD97SK8t2NCHJMsIpRBuOXkwtgs0FkgBrG/5mq80 pRZO9FV+dec6nhjANuaqZ6BLfDP0diwrs2lemq4ddys2r2DapWJc7F9y1tFezHuhqyzp ORO3STcDBvZhMH/2Ly1r/HGoFaSPfOTQIxxmetWwtCeIG/SgRdyTEUXzkxSeFZYvahPj xQTtWYSztXVhAdGl9Tx5hJNVuGsCJ0N9eYYAU1E5SLLnI7ftcqnlVfKJGR1FrjYsRwJc O+sg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=tkz9kXCf4qk0KNOhtQOL6+KYyW747vUshHKY9ctWqGc=; fh=zpgpHhi7NFRm0UrQnwLzLdFqTpbxRncqQ6HhcVWeB8c=; b=pKrVGCAsmG3kcbTyy3Cht67puxcy5hK+2X2R4ymuwRkBaAn1fiUvLbBtC5ADZvMgH9 SJ27eia8Etyw4V2mmgVWK+pbnznEiMeFMa35M1Z0+EAbew84aVjOSZ4DeJkiRrVWqzLT VoSCnlq20g+dq8aBmb+f06NEDfR4nJa/CNakhKumSsl1CAH9HgEZp0/tNflrgEp7MSt2 zsCHhFiLdM6jfl78CljKoGnYb5FY4yhzLkm4Z8o3D9RMHA1Bb3lJJJO7VyxwR28JtHq6 BL9yGAQervApEdYQ3ANyTxYbH6kdAObuZKTZ1qglZcp/tsFBHihQ+6knCTY6piecVQPH qdww==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-72309-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-72309-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id mc3-20020a1709032b0300b001db5b4036fesi5588399plb.108.2024.02.19.20.08.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Feb 2024 20:08:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-72309-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-72309-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-72309-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id C79D428431A for ; Tue, 20 Feb 2024 04:08:27 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 91BD454BC4; Tue, 20 Feb 2024 04:08:23 +0000 (UTC) Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2C3C6168B8 for ; Tue, 20 Feb 2024 04:08:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.189 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708402103; cv=none; b=p0vgnEAkaoeOpXhizXgVvB1OFPuvfggNRt8I66b5HhF/GqT13MHevPovnroFsdvbk5GsLIRGoeoNsk44Gr8/hg27QycsqENM88sUJmzF5Yzs+yShRE1+ZgSBLIl1Bpht0IwATT28eWrrdbZGzs/uziWD6uawFFpSXUiw8WBctDY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708402103; c=relaxed/simple; bh=2j4D5kYG7JtSUKyxtW/u2iHPXr2uOOtuX8szenPUMeY=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=Ivzi2/NcK1WTmoRIDZJRQIaSFoguH886GQAq8T8SW4kz4DR7htz31oi02K8hLoH7sH2iIz2zFSLchbosiaxqOzw5H/kCJtdkFLROM/jSu3v3TOofhbXiDXJhazs1aCRSYK6SQRcItlh1+OgjkURAMbDjRazMMStErZmIxcgC6aI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.189 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.88.105]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4Tf52G06ZtzNlm1; Tue, 20 Feb 2024 11:47:18 +0800 (CST) Received: from dggpemd200001.china.huawei.com (unknown [7.185.36.224]) by mail.maildlp.com (Postfix) with ESMTPS id A70F0140257; Tue, 20 Feb 2024 11:48:39 +0800 (CST) Received: from localhost.localdomain (10.175.112.125) by dggpemd200001.china.huawei.com (7.185.36.224) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.2.1258.28; Tue, 20 Feb 2024 11:48:38 +0800 From: Wupeng Ma To: , , , , , CC: , , , , , , , Subject: [PATCH v4 0/3] Cleanup for PAT Date: Tue, 20 Feb 2024 11:48:32 +0800 Message-ID: <20240220034835.507022-1-mawupeng1@huawei.com> X-Mailer: git-send-email 2.25.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpemd200001.china.huawei.com (7.185.36.224) From: Ma Wupeng Patch #1 move follow_phys to memtype.c since only pat use this. Patch #2 cleanup parameter in follow_phys. Patch #3 drop the unnecessary WARN_ON_ONCE if follow_phys fails. Changelog since v3: - rebase to latest linux - fix compile warnings Changelog since v2: - rebase to latest linux Changelog since v1: - split patch #1 into two patches based on Boris's advise Ma Wupeng (3): x86/mm/pat: Move follow_phys to pat-related file x86/mm/pat: Cleanup unused parameter in follow_phys x86/mm/pat: Remove WARN_ON_ONCE if follow_phys fails arch/x86/mm/pat/memtype.c | 32 ++++++++++++++++++++++++++------ include/linux/mm.h | 2 -- mm/memory.c | 28 ---------------------------- 3 files changed, 26 insertions(+), 36 deletions(-) -- 2.25.1