Message ID | 358dfe21-a47f-9d3-bf21-9c454735944@google.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp498466vqr; Thu, 8 Jun 2023 12:34:08 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4dGaz9oQ7kYJOpzOBb94fyMDV5ZgyHuOvmWiF2vc1kqXx6BcE8qPp8M8gaYAoN5pD9dWfv X-Received: by 2002:a05:6a00:c84:b0:64f:5406:d59e with SMTP id a4-20020a056a000c8400b0064f5406d59emr12094731pfv.17.1686252847752; Thu, 08 Jun 2023 12:34:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686252847; cv=none; d=google.com; s=arc-20160816; b=qxPq7FlccY6RuKM1UlhRxhcY0zdxG23nTmu2NgAvAlOBfslmnOOQxY12qC1ziSvYBn ucSxnllCTnXtNNXEzloN4FgNPRj91fB8ExMYK0NwAs765wW93eA2DJkA/0mXe4MMX6yO q0EVzS09+2u60m5AUKzps0XXHuChbbEpQ4kPmnwdTZV6+D8/rWcHxwUraNn2MI4pRqLn rTqDfK94qA4ehXXZQGGeXf4nAaHyu68EJlQLuLLm2imz4akxY9c9likKvqJZROhlTC+U x9sZKsxEL9Za7xW3OJQzwZXjrSIitBI1SjoqxsqFXpPZI8riS6cN3ZpBCc72EseBWpVO IPXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:message-id:in-reply-to :subject:cc:to:from:date:dkim-signature; bh=E/dR8Qg9bFHe49vUjKvOi0Rl/4IhXWfwv6MExDzA+GE=; b=Rjt7y19q9H8a85hKI5Uy06yAQ9Slc7I5QGx8q2NHguFSzj2hqpoJU6w8WmCHiJBt0+ U0I/k8SvXQ6e+F9F13hNZu0HAXhTwd50b0Nnprl8F6b8lFFZc2qhqttAvPqkoQGN2cBS UlrL+pgnCazWVyjDGRzPjyAdbejfOyOr2WJ/Jv45TwM/9zm/TZMyn3Uu8t5/fIdkaHya Sc1Z1vaEq2d3jG6lyxh6bzlyjwQ1+btnHe+UUMQjwTEQ1WnDY5nmVMdWtvIEUtaYqa8U PXt5015da/eu27JNVFLdgUwlQ2MFG2P5v5AkGNcfh5yxS9wQmoOSmqK+ibtsf8Z+/Sz8 BEOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20221208 header.b=mXQ7UC6c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t189-20020a6381c6000000b005346d98e741si1457415pgd.50.2023.06.08.12.33.54; Thu, 08 Jun 2023 12:34:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20221208 header.b=mXQ7UC6c; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236644AbjFHTUr (ORCPT <rfc822;literming00@gmail.com> + 99 others); Thu, 8 Jun 2023 15:20:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37736 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236465AbjFHTUp (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 8 Jun 2023 15:20:45 -0400 Received: from mail-yb1-xb2a.google.com (mail-yb1-xb2a.google.com [IPv6:2607:f8b0:4864:20::b2a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2DC1530C3 for <linux-kernel@vger.kernel.org>; Thu, 8 Jun 2023 12:20:09 -0700 (PDT) Received: by mail-yb1-xb2a.google.com with SMTP id 3f1490d57ef6-bb167972cffso1090998276.1 for <linux-kernel@vger.kernel.org>; Thu, 08 Jun 2023 12:20:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20221208; t=1686252005; x=1688844005; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:from:to:cc:subject:date:message-id:reply-to; bh=E/dR8Qg9bFHe49vUjKvOi0Rl/4IhXWfwv6MExDzA+GE=; b=mXQ7UC6cKQLLZIQ28oFk9gQ5KxeKVwwY9rk3e7MKP3JMMgFBUS0Y4Ow9xYO3QBbWBp OG1o7JhalsKeTrmK+H6URVPXbxrefFexNILlJOVSmAp7Qw//UVTcssC14O2AbNOpA95o 3fphns61QjibpjRegZHBgnDNFY4BaX8z0yU2Yg9FB0o8UxxLFxwBrXonk679QJW2NVtL a5CA3hBH6G8j2p1GNpc9/KN99Dv4NvapDgXnvT++Pvq7LeadMsdSuwcoq6yEHgW25m/P tlZmPB8WvPaouvvNC3jzVDH6WgeuI0e6ggHbT3c4Xpt7le2+MhNk3DZW5USJxtb/KL2r qm0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686252005; x=1688844005; h=mime-version:references:message-id:in-reply-to:subject:cc:to:from :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=E/dR8Qg9bFHe49vUjKvOi0Rl/4IhXWfwv6MExDzA+GE=; b=Ce8Itk5xjP3Ngyi63G4RKDyj+UvIllO1EWkOoUGzgpf88Rx4pdvwGbFYcciy6KnsSs VBnHod6IS0zSu+8oBreSYKjJohqmTUHCRJs5brX4s3I9hh7dHEP37gQt7X5+i360WazD nRAU8eYy7ib8/R+iIk+GCziKbRSa4KSMC3u+Aozp1ge6m53hRTXvXYK4zlNHVKgxCg/w siYUzP/L0INQLHqHf0w5z40RzWH5r7haHXa8ho2zwTzd02JvoL/GX+7z++VJuZ9O8vyD 9Dp4msHCLhYW6NTKyU88Asjdp0LG4wOFl/C0g/5oXwo1X/+dAaHJ5mz/vZ5M82R4o0kD LVwA== X-Gm-Message-State: AC+VfDy1+jUn3xCslgqecsXVjdDnjK5BUWBrAP7zAgfggJEi2BFcy74y cYbkqumkT8TUVYV3Uya420h8gw== X-Received: by 2002:a25:ce90:0:b0:ba8:16df:e3f5 with SMTP id x138-20020a25ce90000000b00ba816dfe3f5mr700600ybe.0.1686252005314; Thu, 08 Jun 2023 12:20:05 -0700 (PDT) Received: from ripple.attlocal.net (172-10-233-147.lightspeed.sntcca.sbcglobal.net. [172.10.233.147]) by smtp.gmail.com with ESMTPSA id 2-20020a251802000000b00b9dfcc7a1fasm446566yby.7.2023.06.08.12.20.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Jun 2023 12:20:04 -0700 (PDT) Date: Thu, 8 Jun 2023 12:20:00 -0700 (PDT) From: Hugh Dickins <hughd@google.com> X-X-Sender: hugh@ripple.attlocal.net To: Andrew Morton <akpm@linux-foundation.org> cc: Mike Kravetz <mike.kravetz@oracle.com>, Mike Rapoport <rppt@kernel.org>, "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>, Matthew Wilcox <willy@infradead.org>, David Hildenbrand <david@redhat.com>, Suren Baghdasaryan <surenb@google.com>, Qi Zheng <zhengqi.arch@bytedance.com>, Peter Zijlstra <peterz@infradead.org>, Russell King <linux@armlinux.org.uk>, Catalin Marinas <catalin.marinas@arm.com>, Will Deacon <will@kernel.org>, Geert Uytterhoeven <geert@linux-m68k.org>, Greg Ungerer <gerg@linux-m68k.org>, Michal Simek <monstr@monstr.eu>, Thomas Bogendoerfer <tsbogend@alpha.franken.de>, Helge Deller <deller@gmx.de>, John David Anglin <dave.anglin@bell.net>, "Aneesh Kumar K.V" <aneesh.kumar@linux.ibm.com>, Michael Ellerman <mpe@ellerman.id.au>, Alexandre Ghiti <alexghiti@rivosinc.com>, Palmer Dabbelt <palmer@dabbelt.com>, Heiko Carstens <hca@linux.ibm.com>, Christian Borntraeger <borntraeger@linux.ibm.com>, Claudio Imbrenda <imbrenda@linux.ibm.com>, Alexander Gordeev <agordeev@linux.ibm.com>, John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>, "David S. Miller" <davem@davemloft.net>, Chris Zankel <chris@zankel.net>, Max Filippov <jcmvbkbc@gmail.com>, x86@kernel.org, linux-arm-kernel@lists.infradead.org, linux-ia64@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-mips@vger.kernel.org, linux-parisc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-riscv@lists.infradead.org, linux-s390@vger.kernel.org, linux-sh@vger.kernel.org, sparclinux@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: [PATCH v2 09/23] parisc: unmap_uncached_pte() use pte_offset_kernel() In-Reply-To: <a4963be9-7aa6-350-66d0-2ba843e1af44@google.com> Message-ID: <358dfe21-a47f-9d3-bf21-9c454735944@google.com> References: <a4963be9-7aa6-350-66d0-2ba843e1af44@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Spam-Status: No, score=-17.6 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,USER_IN_DEF_DKIM_WL,USER_IN_DEF_SPF_WL autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1768164266189236771?= X-GMAIL-MSGID: =?utf-8?q?1768164266189236771?= |
Series |
arch: allow pte_offset_map[_lock]() to fail
|
|
Commit Message
Hugh Dickins
June 8, 2023, 7:20 p.m. UTC
unmap_uncached_pte() is working from pgd_offset_k(vaddr), so it should
use pte_offset_kernel() instead of pte_offset_map(), to avoid the
question of whether a pte_unmap() will be needed to balance.
Signed-off-by: Hugh Dickins <hughd@google.com>
---
arch/parisc/kernel/pci-dma.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/parisc/kernel/pci-dma.c b/arch/parisc/kernel/pci-dma.c index 71ed5391f29d..415f12d5bab3 100644 --- a/arch/parisc/kernel/pci-dma.c +++ b/arch/parisc/kernel/pci-dma.c @@ -164,7 +164,7 @@ static inline void unmap_uncached_pte(pmd_t * pmd, unsigned long vaddr, pmd_clear(pmd); return; } - pte = pte_offset_map(pmd, vaddr); + pte = pte_offset_kernel(pmd, vaddr); vaddr &= ~PMD_MASK; end = vaddr + size; if (end > PMD_SIZE)