Message ID | 20230315030359.14162-5-palmer@rivosinc.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 34EFDC6FD1F for <linux-mm@archiver.kernel.org>; Wed, 15 Mar 2023 03:05:35 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 9D0F78E0006; Tue, 14 Mar 2023 23:05:33 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 95BF78E0001; Tue, 14 Mar 2023 23:05:33 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 75EE58E0006; Tue, 14 Mar 2023 23:05:33 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 63A018E0001 for <linux-mm@kvack.org>; Tue, 14 Mar 2023 23:05:33 -0400 (EDT) Received: from smtpin14.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 3A390C0898 for <linux-mm@kvack.org>; Wed, 15 Mar 2023 03:05:33 +0000 (UTC) X-FDA: 80569642146.14.55A406F Received: from mail-pg1-f179.google.com (mail-pg1-f179.google.com [209.85.215.179]) by imf02.hostedemail.com (Postfix) with ESMTP id 5FEAF80013 for <linux-mm@kvack.org>; Wed, 15 Mar 2023 03:05:31 +0000 (UTC) Authentication-Results: imf02.hostedemail.com; dkim=pass header.d=rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b=4mZhqkrZ; dmarc=none; spf=pass (imf02.hostedemail.com: domain of palmer@rivosinc.com designates 209.85.215.179 as permitted sender) smtp.mailfrom=palmer@rivosinc.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1678849531; 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:in-reply-to:references:references:dkim-signature; bh=0CSfwyQHlQ4M4jXaSH+LdMi3uBUPZy3NPttk2ev1MeM=; b=eQg9D1oXgH6CAUqECSw+HK8fhCV7Er4CDO2xOAvcZLt3g3amqMTImaCaT07TMkCyrPme33 9Tvn5Q7kNXlCAS2k+lJQWAuGKPGEkVj6Kd4hXN47GrMo7qWQwwuYJcCR5aG/x6P6xb42+f 9Iv6QALr2hvxhoqvxBr04QXYFai1/Lo= ARC-Authentication-Results: i=1; imf02.hostedemail.com; dkim=pass header.d=rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b=4mZhqkrZ; dmarc=none; spf=pass (imf02.hostedemail.com: domain of palmer@rivosinc.com designates 209.85.215.179 as permitted sender) smtp.mailfrom=palmer@rivosinc.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1678849531; a=rsa-sha256; cv=none; b=ort3jfzTCBU1hZPZtIAXBcElEA4XlWJrJUGNTtb/5oh+EJJo9dz7pEn206xbdbWQ34gRlF ms8vLpx8OXQ1aV/6FaFLzAd3Be6boEzkHDtYvm4gA9wBX6nrv9cmEyyQKTkq6N/pcMTeRU kALQRTEsCWjKOpg77euLiLD867CODjU= Received: by mail-pg1-f179.google.com with SMTP id s17so10034358pgv.4 for <linux-mm@kvack.org>; Tue, 14 Mar 2023 20:05:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; t=1678849530; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:from:to:cc:subject:date :message-id:reply-to; bh=0CSfwyQHlQ4M4jXaSH+LdMi3uBUPZy3NPttk2ev1MeM=; b=4mZhqkrZl2MkO6B6mqEDLTirH3SlLVvooXtpQuTuH/xzUmMWO0qlG33s8kcsf8vR+X 1FoOK2Rk0bJmVb+8FuKG/2Jxjnt0oUDaFG+VqsxM9hrbjvOV2ZarD+HZLutU5YIiAVXL IZDZQgKVdEkHiqO2TWB2SNLAlsr0Wiul9s5npuCAjeBOJ5joViCl/33dOtfcuNA0qTKJ wI89dyMtuHkmCnCcbUMyMFUQHfyAxxbiJrKXeydYHQhFoxpswgDnmjyFK1K2t7/bFmGC dvm2FAw3pTK46SBSowzA4dhLd1uqkTrpZPHWJKiwmyDolqIdJoRm8AiDKGHFgfo1NVtm xglA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678849530; h=to:from:cc:content-transfer-encoding:mime-version:references :in-reply-to:message-id:date:subject:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0CSfwyQHlQ4M4jXaSH+LdMi3uBUPZy3NPttk2ev1MeM=; b=QA3I0W1L2s8J6R3m2QwE44rE5cHK7u+U73uzdK3JwqqCfv+snJOG6xXFmvaWD76dhW tukwcbUWPYY5N6iH795MOZP/IMLnuNxB6ie9F8XpoflBMaRCb7GcBvyubd0APFCFFX3/ sHmed+jL8S/jBQParWvlPI5dfI7Sw9lcP/8Z0uoBY52/Zmi+QldYSAXS6d8a0uUnGWfc XMiNkvbwPyPRX9iRdIa3xp5cz3+wtTJHlmFCvOldn6x3uPxyv7Y2sdOMEEwexJUprEBt QakTaGv231l/LqrAMqhVu2TO8t29A/4VmqDtEZlrGfcPFxV1mmxptdbZmpsrb6XGPy3M oWuA== X-Gm-Message-State: AO0yUKWUB1+ejZpyweQ5d9IObu8NLD+2P5xM4fOiY2/VXKavrBACxPoY TgoKRlQdweIXxNe1r2b6bu1oVuqriQk3FOY/pHY= X-Google-Smtp-Source: AK7set9ZnZdofrFWQ0U8lJyHxwjbzhYXBh8dBYrjkL6TD0h/9D1nJL1aS2SUyiziKQzZO7kTArkNIA== X-Received: by 2002:a62:18c8:0:b0:622:bdec:d49 with SMTP id 191-20020a6218c8000000b00622bdec0d49mr9133281pfy.11.1678849529904; Tue, 14 Mar 2023 20:05:29 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id o6-20020a63f146000000b0050376cedb3asm2230300pgk.24.2023.03.14.20.05.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Mar 2023 20:05:29 -0700 (PDT) Subject: [PATCH v2 4/6] RISC-V: fault: Convert to VM_FAULT_ARCH_* codes Date: Tue, 14 Mar 2023 20:03:57 -0700 Message-Id: <20230315030359.14162-5-palmer@rivosinc.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230315030359.14162-1-palmer@rivosinc.com> References: <20230315030359.14162-1-palmer@rivosinc.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Cc: linux-mm@kvack.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Palmer Dabbelt <palmer@rivosinc.com> From: Palmer Dabbelt <palmer@rivosinc.com> To: akpm@linux-foundation.org X-Rspam-User: X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: 5FEAF80013 X-Stat-Signature: ktxjsafc9jjtcas6ias7bz9cgde71fwh X-HE-Tag: 1678849531-805033 X-HE-Meta: U2FsdGVkX18weo1lX/RnCkynUmdyEpKy71m04+q6LTbf1B2fZBsSc5lB/qyky7wFPLEoyW95lpgBhrWwDu45U3FbvYU8j/m8enyum5GVRuOPQoLWYTWgNARGpse3DUFDaAnhT71UN/MtHbt8suxSSug41lrnOJOHSrNnA6BfMrp4ddm9wkRwnkUu7uoT+Hi8eznkNaBRXbr0NQdNW1uxTOtXiItrpAw0yHpR9irdAnwwlCMb2Z5abNFtZod0ghCC6j+3kTex+qk0AW50Cg3EISiffyGMQo4xwgBinSgiMdoU5tAe/3A6xw3DJftO9CpCtXZeV43XX1/FD/S/VD+MMjYh9ewCFsTy4pU1xnW96U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LwbAtRyrEQZIGW0vIZHSWd77YvPM7Wn4dzyYmBEQd6MdeuR/kJjgYYOke0mv 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> |
Series |
mm: Stop alaising VM_FAULT_HINDEX_MASK in arch code
|
expand
|
diff --git a/arch/riscv/mm/fault.c b/arch/riscv/mm/fault.c index 0a8c9afeee22..5b035c0ae782 100644 --- a/arch/riscv/mm/fault.c +++ b/arch/riscv/mm/fault.c @@ -202,8 +202,8 @@ static inline bool access_error(unsigned long cause, struct vm_area_struct *vma) return false; } -#define VM_FAULT_BADMAP ((__force vm_fault_t)0x010000) -#define VM_FAULT_BADACCESS ((__force vm_fault_t)0x020000) +#define VM_FAULT_BADMAP VM_FAULT_ARCH_0 +#define VM_FAULT_BADACCESS VM_FAULT_ARCH_1 static vm_fault_t __do_page_fault(struct mm_struct *mm, unsigned long addr, unsigned int mm_flags, struct pt_regs *regs)
These conflict with VM_FAULT_HINDEX_MASK, so move to some designated arch-specific values. Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com> --- arch/riscv/mm/fault.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)