Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp4421420rwd; Tue, 23 May 2023 07:32:49 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5aPhmsrQpYCfVkZfJ3SFTPtqAllm09/Nz19POAjgqGC8Rl1xpcg/LAc97vmGPsFAI3O5Zm X-Received: by 2002:a05:6a21:918c:b0:100:3964:6cb with SMTP id tp12-20020a056a21918c00b00100396406cbmr12160738pzb.40.1684852369170; Tue, 23 May 2023 07:32:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684852369; cv=none; d=google.com; s=arc-20160816; b=U4wud04h6VLIOdfn+moi+nDGixc61GheIRQGZnKF4EtnFhrxiSskQ22lQcIrQkVMdw 6f4RFo8PjooqrqR+n9d2YeRsMts644aIb8RVVvUI2SkVzGQGitch2ZaGH8j7Ayde42wC bFubNJpL7ncYtju0apOcfa1axDi8YkWadbqtXOmw0D+vUTsE7TLZpQupBOFC9BbZN4IY DF6u3WnIryVSCQnh1VHts+XQKJYToVvjGIEQ7d2eEXobAUfc8mT+7SswYkeCbh+s20Ck A7JJtl15iwaDFuvvBtPtXgpFR4P0Tj82wBrVLejWRNz6glI4tCyCSJRumu6fg27jNAGz L5ug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=2CPc/Vm/Ur0JOy8kF/L6fs0qWXc+VKBrwCqiZQE3hiQ=; b=MT1tk74HN6fl9gQe7nBAiF/zVfO9gAlctG3h7Y3foqJvC3Tkg8TAWV7GdipFtxnOtt ItPFHdo1kWmC2wk9My6PFl97h2k0ToPDikhxgovAFrR9YYR/VVGZnWWlk78he7RnTkne YNDUsMeg3aG9gTpn9/YSxUN1Gjuz033J2ilj8RK9v5A3ma6ReQVqCim0pvQlMa5etXs8 fw1rhNhnuKgrlqzw+46tRS8x8aLbLImuCK78UDO4axwhSNnhqwUTshdCY16L9hxXW0HF nup0qbwGxIR/0WadU6f0IPVAV0DV2lDaNS0hzCFA0WRufEQbvqGFV/Y3KVEo61Rd9M0H CGfw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=DHx5ZxV7; 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=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z22-20020a63b916000000b005342409bdcasi6394897pge.723.2023.05.23.07.32.36; Tue, 23 May 2023 07:32:49 -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=@linaro.org header.s=google header.b=DHx5ZxV7; 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=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237123AbjEWOHR (ORCPT + 99 others); Tue, 23 May 2023 10:07:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46458 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237105AbjEWOGv (ORCPT ); Tue, 23 May 2023 10:06:51 -0400 Received: from mail-lf1-f42.google.com (mail-lf1-f42.google.com [209.85.167.42]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7BF3BFA for ; Tue, 23 May 2023 07:06:49 -0700 (PDT) Received: by mail-lf1-f42.google.com with SMTP id 2adb3069b0e04-4f4b2bc1565so2255528e87.2 for ; Tue, 23 May 2023 07:06:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1684850748; x=1687442748; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=2CPc/Vm/Ur0JOy8kF/L6fs0qWXc+VKBrwCqiZQE3hiQ=; b=DHx5ZxV7p8BhGcgtHBETWYRJd1dP/RkZ+YUCwCVosoC2AbBpe5sHXnMZMwMfxH0y90 XzQe0bQlxKytbPkvQ7V2w5JMdAcALyzlLbnEu6FgCRgXy4OrpPkT/mSWek9ZWrsZAiWH t18h2rnk6uTfqGPlKFgZORYwPzN9BqAyYgP2fxRMHyNsWSDezmeWQlLl3RvNoS0at2N4 zwQ3dB33a/q/dRZ6aJBGgNr9dIXjla+n0UxG3C1sJgM5T6M4GTED+bWcwU/Qj9vEwFAM ENMA+EKO7SMaOA+g+taxuDmYjq5EjwmFMZZGZfVYtGGJEuSMfUR23VvC7Y2vQbS5i/pL sqIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684850748; x=1687442748; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2CPc/Vm/Ur0JOy8kF/L6fs0qWXc+VKBrwCqiZQE3hiQ=; b=b4WcrwPIjoqPo/3V91gHBMK8fd2EIdDiBQDQitFlmCThVMOzK6MNxq6fCIY04v4izO wXGl1o+E3Ip1vsBtYTV2D83ADaQKfsIJSCASkaepZqbjNo7/i5vWSX3+NVKlWwX9XdZX xF49U+XEgh5giKGOZ1NEItXGUFx3/O6wuUyKBWmfuCDtOrlwCpz2CTcZ4W1xN9F23Hw7 A1un6B5k0vAQsdOQfjgW/68u6CH+FBs4jB1AYhHseqfBpoFf8pKWjLxXx+Ur12v8ouPh KmhJ9KhBwW+AtE2q33ADwMgZ/SrLiEdGCUC+8jxHlMuCXg/nGf1A/6+8W86iJIqh7Y3k xq0Q== X-Gm-Message-State: AC+VfDwrcZ7zmzxnZH0/SYP2k+lFdkcorJbr8fQ4srz2u3MklNmfGqNk zJCnRQu/8eOWPyccBxL+HAIG7w== X-Received: by 2002:a05:6512:259:b0:4f0:1124:8b2a with SMTP id b25-20020a056512025900b004f011248b2amr4733118lfo.46.1684850747942; Tue, 23 May 2023 07:05:47 -0700 (PDT) Received: from [127.0.1.1] ([85.235.12.238]) by smtp.gmail.com with ESMTPSA id h28-20020ac2597c000000b004e9bf853c27sm1346562lfp.70.2023.05.23.07.05.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 May 2023 07:05:47 -0700 (PDT) From: Linus Walleij Date: Tue, 23 May 2023 16:05:27 +0200 Subject: [PATCH v3 03/12] ARC: init: Pass a pointer to virt_to_pfn() in init MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20230503-virt-to-pfn-v6-4-rc1-v3-3-a16c19c03583@linaro.org> References: <20230503-virt-to-pfn-v6-4-rc1-v3-0-a16c19c03583@linaro.org> In-Reply-To: <20230503-virt-to-pfn-v6-4-rc1-v3-0-a16c19c03583@linaro.org> To: Andrew Morton , Geert Uytterhoeven , Vineet Gupta , Catalin Marinas , Will Deacon , Arnd Bergmann , Russell King , Greg Ungerer Cc: linux-mm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-snps-arc@lists.infradead.org, linux-fsdevel@vger.kernel.org, linux-cifs@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-arch@vger.kernel.org, Linus Walleij X-Mailer: b4 0.12.1 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=ham 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: X-Mailing-List: linux-kernel@vger.kernel.org Functions that work on a pointer to virtual memory such as virt_to_pfn() and users of that function such as virt_to_page() are supposed to pass a pointer to virtual memory, ideally a (void *) or other pointer. However since many architectures implement virt_to_pfn() as a macro, this function becomes polymorphic and accepts both a (unsigned long) and a (void *). Fix up the offending call in arch/arc with an explicit cast. Signed-off-by: Linus Walleij --- arch/arc/mm/init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arc/mm/init.c b/arch/arc/mm/init.c index 2b89b6c53801..9f64d729c9f8 100644 --- a/arch/arc/mm/init.c +++ b/arch/arc/mm/init.c @@ -87,7 +87,7 @@ void __init setup_arch_memory(void) setup_initial_init_mm(_text, _etext, _edata, _end); /* first page of system - kernel .vector starts here */ - min_low_pfn = virt_to_pfn(CONFIG_LINUX_RAM_BASE); + min_low_pfn = virt_to_pfn((void *)CONFIG_LINUX_RAM_BASE); /* Last usable page of low mem */ max_low_pfn = max_pfn = PFN_DOWN(low_mem_start + low_mem_sz); -- 2.34.1