Received: by 2002:a05:7412:e79e:b0:f3:1519:9f41 with SMTP id o30csp144586rdd; Wed, 22 Nov 2023 11:36:26 -0800 (PST) X-Google-Smtp-Source: AGHT+IFuZAPowE3ZmuB3afbXpVJxA9kuz0Gk7yz1VaQDobkIej9SEyEDrHn99mLFI9MeEPKqD9ww X-Received: by 2002:a17:90a:1a10:b0:280:959c:660f with SMTP id 16-20020a17090a1a1000b00280959c660fmr3285447pjk.27.1700681786571; Wed, 22 Nov 2023 11:36:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700681786; cv=none; d=google.com; s=arc-20160816; b=zcqaqTAPCfHgvAjM4mxVJa6MVnakTbh8qf2I0xFGNKCoNuehSlA+NogKxWFrDl7WoC IsaE/mzzT/DxeOkU4Hoj1ybsUY+/JygkWcNd7zxl04isMqN1SmEAAMw4tIe54rb4/d2J Vo2l9dUlj+52gFYVA1PO1058SYyLbT8Iyn9DxNChvjabNSVMnNwPWkmmoyt2NYcXl/CV 5/X34hQ7TE6rTugaT5/JuEsoo/p8IR32C0j6sKUwlPanM+us4ixaaeVq32bBM9QXukZ8 aC85TD0R13F1cdhQ7Oo85pniibz+JBESjJSOROEdboUdaWRs7P0Zb1sqRy6YJcYYmYxl Gm1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:subject:cc:to:from:date:references:in-reply-to :message-id:mime-version:user-agent:feedback-id:dkim-signature :dkim-signature; bh=lx3Gf8Ml5YHZ79DEZBtfhV6TJngHlrEmAjf3G2BUG5I=; fh=RRzJ4yYsmM7ICU6+AsEy+M3FW5A0VPLNdBBEJlC+uyg=; b=DPZfN/rW9wLEo4E03iC4280XN49iYIX3SFquCOndbiIKpvkk1YTH9vVYXzJ9mDHJvi W55Yz/7h/BSrToHgGSlO6WHbaaZEZoBXgBLbbzDLFnFBLDKm1ajHPYw30cEqs2d+ww0b vR3IwFcuKSvbC/zyZChFC1yKkmpfK683Fa1epeX/xMxxuBlZWNis5yEDt4jsPCc0zEY1 sLi5cdhPlR1Mbw9MbgQh1B7Yt2K9TtLoD4EQr92SXuDiZwtUFqcXevxA2tTxmwFJeXiE GxuAKD+pDs07fc8wWsnBtH/wIs9vR2mHxGtkEJCgqWjdURosCvrCkvV3Ry3xN9EWNPlR +tvQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@arndb.de header.s=fm3 header.b=u2TiS0xI; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=HktlyKuM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id mg21-20020a17090b371500b002847ae0871fsi214032pjb.125.2023.11.22.11.36.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Nov 2023 11:36:26 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@arndb.de header.s=fm3 header.b=u2TiS0xI; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=HktlyKuM; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id EDDC38342FEA; Wed, 22 Nov 2023 11:35:54 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231738AbjKVTfb (ORCPT + 99 others); Wed, 22 Nov 2023 14:35:31 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45342 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231459AbjKVTfa (ORCPT ); Wed, 22 Nov 2023 14:35:30 -0500 Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B942118E; Wed, 22 Nov 2023 11:35:25 -0800 (PST) Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 983C35C0231; Wed, 22 Nov 2023 14:35:22 -0500 (EST) Received: from imap51 ([10.202.2.101]) by compute5.internal (MEProxy); Wed, 22 Nov 2023 14:35:22 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arndb.de; h=cc :cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:sender :subject:subject:to:to; s=fm3; t=1700681722; x=1700768122; bh=lx 3Gf8Ml5YHZ79DEZBtfhV6TJngHlrEmAjf3G2BUG5I=; b=u2TiS0xIOQsffzBAVU JSTs2mGFfVTuQMlgIJgHNPnrhs78q46sLtXDhRnurDbnCTVctxhViklKISCbXqPJ 4zklquNGsoexd+vDTADrs5yNRWdE8cNDhrKrQPrcT6KxgF80yzbPKqc3Aowq1yJ8 EmU0xsb04QOXaRiCBNSDVlt+k9fXanRUneRaXg4Llmo3gShROyoFwVzU6nAAzkH8 VPvMLjauYd75oxdJ3jmOOLieuJYh8o4TJgz8XRtQ7uh/AQbSS4681JPFeJau9SKu CdMal+gFwVhzjafLGclkZ1iOcuQOb7AmNjZg9/LWbHPI8hSH3qKTzmm4BHs/DOZ4 Wgkw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; t=1700681722; x=1700768122; bh=lx3Gf8Ml5YHZ7 9DEZBtfhV6TJngHlrEmAjf3G2BUG5I=; b=HktlyKuM6aaLQ6S2eyF6AyJosR+pQ GNgRH40Ywg+gkZwQdn7moY7Y+59ZLJYiZXNuMHoNwYQeMNA+AznC17pC/OVohdY5 VjgrTYOHShDNF32knHfLUxlcUM7NrzSiR1BgduQrFf7RMpQUYSoS6ltoKwZxrj/K bot0k9SLRayF03N1tB7c29RBqOR0UpnXva1ckBwYUDFsBiwgSmdDF7GAoMo+Y24k KBfpTDhZpMIY6HZTVCG+3WfB9BUsk+Mpi9k4E5orXrkaCSgQOD0fkYVjnrhQnGo/ UqA6hynC/XUYcwf7kxAWekWr21Q5GLcWMiQItvhrcbaNMV0G7Wj+tLfNw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvkedrudehuddguddvhecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefofgggkfgjfhffhffvvefutgesthdtredtreertdenucfhrhhomhepfdet rhhnugcuuegvrhhgmhgrnhhnfdcuoegrrhhnugesrghrnhgusgdruggvqeenucggtffrrg htthgvrhhnpeffheeugeetiefhgeethfejgfdtuefggeejleehjeeutefhfeeggefhkedt keetffenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpe grrhhnugesrghrnhgusgdruggv X-ME-Proxy: Feedback-ID: i56a14606:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id 6E100B60089; Wed, 22 Nov 2023 14:35:21 -0500 (EST) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.9.0-alpha0-1234-gac66594aae-fm-20231122.001-gac66594a MIME-Version: 1.0 Message-Id: In-Reply-To: <20231122182419.30633-2-fancer.lancer@gmail.com> References: <20231122182419.30633-1-fancer.lancer@gmail.com> <20231122182419.30633-2-fancer.lancer@gmail.com> Date: Wed, 22 Nov 2023 20:35:01 +0100 From: "Arnd Bergmann" To: "Serge Semin" , "Thomas Bogendoerfer" , "Andrew Morton" , "Mike Rapoport" , "Matthew Wilcox" , "Tiezhu Yang" , "Huacai Chen" , "Yinglu Yang" , "Jiaxun Yang" Cc: "Alexey Malahov" , "Aleksandar Rikalo" , "Aleksandar Rikalo" , "Dragan Mladjenovic" , "Chao-ying Fu" , "Marc Zyngier" , linux-mips@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/7] mips: dmi: Fix early remap on MIPS32 Content-Type: text/plain X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Wed, 22 Nov 2023 11:35:55 -0800 (PST) On Wed, Nov 22, 2023, at 19:23, Serge Semin wrote: > dmi_early_remap() has been defined as ioremap_cache() which on MIPS32 gets > to be converted to the VM-based mapping. DMI early remapping is performed > at the setup_arch() stage with no VM available. So calling the > dmi_early_remap() for MIPS32 causes the system to crash at the early boot > time. Fix that by converting dmi_early_remap() to the uncached remapping > which is always available on both 32 and 64-bits MIPS systems. > > Fixes: be8fa1cb444c ("MIPS: Add support for Desktop Management Interface (DMI)") > Signed-off-by: Serge Semin > --- > arch/mips/include/asm/dmi.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/mips/include/asm/dmi.h b/arch/mips/include/asm/dmi.h > index 27415a288adf..525aad1572d1 100644 > --- a/arch/mips/include/asm/dmi.h > +++ b/arch/mips/include/asm/dmi.h > @@ -5,7 +5,7 @@ > #include > #include > > -#define dmi_early_remap(x, l) ioremap_cache(x, l) > +#define dmi_early_remap(x, l) ioremap_uc(x, l) Please don't use ioremap_uc() in new code, we are in the (long) process of removing it from the kernel for everything except x86-32, and it already returns NULL on most of them. Would the normal ioremap() work for you here? It seems to do the same thing as ioremap_uc() on mips and a couple of other architectures that have not yet killed it off. Arnd