* [PATCH -next] RISC-V: hwprobe: Always use u64 for extension bits
@ 2023-11-01 14:19 Andrew Jones
2023-12-07 15:20 ` patchwork-bot+linux-riscv
0 siblings, 1 reply; 2+ messages in thread
From: Andrew Jones @ 2023-11-01 14:19 UTC (permalink / raw)
To: linux-riscv
Cc: paul.walmsley, palmer, aou, evan, conor.dooley, Anup Patel,
kernel test robot
Extensions are getting added quickly and their hwprobe bits will soon
exceed 31 (which pair values accommodate, since they're of type u64).
However, in one tree, where a bunch of extensions got merged prior to
zicboz, zicboz already got pushed to bit 32. Pushing it exposed a
32-bit compilation bug, since unsigned long was used instead of u64.
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202310311801.hxduISrr-lkp@intel.com/
Fixes: 9c7646d5ffd2 ("RISC-V: hwprobe: Expose Zicboz extension and its block size")
Signed-off-by: Andrew Jones <ajones@ventanamicro.com>
---
arch/riscv/kernel/sys_riscv.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/riscv/kernel/sys_riscv.c b/arch/riscv/kernel/sys_riscv.c
index c712037dbe10..a2ca5b7756a5 100644
--- a/arch/riscv/kernel/sys_riscv.c
+++ b/arch/riscv/kernel/sys_riscv.c
@@ -169,7 +169,7 @@ static void hwprobe_isa_ext0(struct riscv_hwprobe *pair,
pair->value &= ~missing;
}
-static bool hwprobe_ext0_has(const struct cpumask *cpus, unsigned long ext)
+static bool hwprobe_ext0_has(const struct cpumask *cpus, u64 ext)
{
struct riscv_hwprobe pair;
--
2.41.0
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH -next] RISC-V: hwprobe: Always use u64 for extension bits
2023-11-01 14:19 [PATCH -next] RISC-V: hwprobe: Always use u64 for extension bits Andrew Jones
@ 2023-12-07 15:20 ` patchwork-bot+linux-riscv
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+linux-riscv @ 2023-12-07 15:20 UTC (permalink / raw)
To: Andrew Jones
Cc: linux-riscv, paul.walmsley, palmer, aou, evan, conor.dooley,
apatel, lkp
Hello:
This patch was applied to riscv/linux.git (fixes)
by Palmer Dabbelt <palmer@rivosinc.com>:
On Wed, 1 Nov 2023 15:19:09 +0100 you wrote:
> Extensions are getting added quickly and their hwprobe bits will soon
> exceed 31 (which pair values accommodate, since they're of type u64).
> However, in one tree, where a bunch of extensions got merged prior to
> zicboz, zicboz already got pushed to bit 32. Pushing it exposed a
> 32-bit compilation bug, since unsigned long was used instead of u64.
>
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202310311801.hxduISrr-lkp@intel.com/
> Fixes: 9c7646d5ffd2 ("RISC-V: hwprobe: Expose Zicboz extension and its block size")
> Signed-off-by: Andrew Jones <ajones@ventanamicro.com>
>
> [...]
Here is the summary with links:
- [-next] RISC-V: hwprobe: Always use u64 for extension bits
https://git.kernel.org/riscv/c/777c0d761be7
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-12-07 15:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-01 14:19 [PATCH -next] RISC-V: hwprobe: Always use u64 for extension bits Andrew Jones
2023-12-07 15:20 ` patchwork-bot+linux-riscv
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).