]> git.ipfire.org Git - thirdparty/qemu.git/commit
linux-user/riscv: Fix handling of cpu mask in riscv_hwprobe syscall
authorRichard Henderson <richard.henderson@linaro.org>
Sat, 8 Mar 2025 22:58:40 +0000 (14:58 -0800)
committerMichael Tokarev <mjt@tls.msk.ru>
Mon, 24 Mar 2025 04:49:26 +0000 (07:49 +0300)
commitd83b61f59c809d3447127f880dd65944180ce478
treee542fe1df0d09d8a61b53f9997f451f7780d6e25
parent803a6864efd2513fa560e3e9a840b87d5b44dc3f
linux-user/riscv: Fix handling of cpu mask in riscv_hwprobe syscall

The third argument of the syscall contains the size of the
cpu mask in bytes, not bits.  Nor is the size rounded up to
a multiple of sizeof(abi_ulong).

Cc: qemu-stable@nongnu.org
Reported-by: Andreas Schwab <schwab@suse.de>
Fixes: 9e1c7d982d7 ("linux-user/riscv: Add syscall riscv_hwprobe")
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-ID: <20250308225902.1208237-3-richard.henderson@linaro.org>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
(cherry picked from commit 1a010d22b7adecf0fb1c069e1e535af1aa51e9cf)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
linux-user/syscall.c