From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 863E8C77B7E for ; Thu, 25 May 2023 18:38:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241948AbjEYSiJ (ORCPT ); Thu, 25 May 2023 14:38:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51576 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241950AbjEYShd (ORCPT ); Thu, 25 May 2023 14:37:33 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1941019BE; Thu, 25 May 2023 11:36:09 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id AFE90648C9; Thu, 25 May 2023 18:34:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A5218C433EF; Thu, 25 May 2023 18:34:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1685039675; bh=DrIOmp9TaBfRxEIlICSLUZcRJY6bSl9wUv6235PC/mg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ew0Kz7b17tzre7oddcgXM0es3TJHSnP1qfVA/nH8iW91M++/vM2kQKDtHT/3hGMdN dHmXNPS3JQyhbCqCiA+lHmKt0n1dz7jEkau9CSaa3trdKb9GT+2gxXTYzgV4NVhOJA YeD8289NEiUY0PnZHCL4cTLYjY/ceKRvOCSyBmPtcgew1158sUVov3wxo/JKWVHSFl 6UBukxxV94ja64mR3MRH976em5gYnWOHn8vYBjROZid0as2FVY5k5HetHY6SWQahHW qg/IazzZgRehpu3Z+2wdm0FTCwdAo+dArgGlmDoEQ49wKDMHFmU4rajmpbidh4IvAB A096tV7Vo27CQ== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Linus Walleij , Will Deacon , Sasha Levin , catalin.marinas@arm.com, akpm@linux-foundation.org, mhocko@suse.com, joey.gouly@arm.com, peterx@redhat.com, hca@linux.ibm.com, jannh@google.com, mike.kravetz@oracle.com, willy@infradead.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH AUTOSEL 6.3 44/67] arm64: vdso: Pass (void *) to virt_to_page() Date: Thu, 25 May 2023 14:31:21 -0400 Message-Id: <20230525183144.1717540-44-sashal@kernel.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230525183144.1717540-1-sashal@kernel.org> References: <20230525183144.1717540-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Linus Walleij [ Upstream commit b0abde80620f42d1ceb3de5e4c1a49cdd5628229 ] Like the other calls in this function virt_to_page() expects a pointer, not an integer. 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 this up with an explicit cast. Signed-off-by: Linus Walleij Link: http://lists.infradead.org/pipermail/linux-arm-kernel/2023-May/832583.html Signed-off-by: Will Deacon Signed-off-by: Sasha Levin --- arch/arm64/kernel/vdso.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/kernel/vdso.c b/arch/arm64/kernel/vdso.c index 0119dc91abb5d..d9e1355730ef5 100644 --- a/arch/arm64/kernel/vdso.c +++ b/arch/arm64/kernel/vdso.c @@ -288,7 +288,7 @@ static int aarch32_alloc_kuser_vdso_page(void) memcpy((void *)(vdso_page + 0x1000 - kuser_sz), __kuser_helper_start, kuser_sz); - aarch32_vectors_page = virt_to_page(vdso_page); + aarch32_vectors_page = virt_to_page((void *)vdso_page); return 0; } -- 2.39.2