Re: calling getcpu with misaligned address causes kernel panic
Helge Deller via Bugspray Bot <[email protected]> Tue, 01 Oct 2024 16:05:07 +0000
| Newsgroups | dev.linux.lists.bugs,org.kernel.vger.linux-parisc |
|---|---|
| Message-ID | <[email protected]> |
Helge Deller writes via Kernel.org Bugzilla:
This *is* a bug in qemu.
When running on a physical box, strace shows that the kernel behaves correctly:
mmap2(NULL, 4096, PROT_READ, MAP_SHARED|MAP_ANONYMOUS, -1, 0) = 0xf9000000
getcpu(0xf9000000, 0xf9000001, NULL) = -1 EFAULT (Bad address)
exit_group(-1) = ?
+++ exited with 255 +++
On an AMD64 box I get a segfault (which seems strange?):
mmap(NULL, 4096, PROT_READ, MAP_SHARED|MAP_ANONYMOUS, -1, 0) = 0x7f2b62c73000
--- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_ACCERR, si_addr=0x7f2b62c73000} ---
+++ killed by SIGSEGV +++
Segmentation fault
qemu-user works OK.
will try qemu-system soon.
View: https://bugzilla.kernel.org/show_bug.cgi?id=219339#c2
You can reply to this message to join the discussion.
--
Deet-doot-dot, I am a bot.
Kernel.org Bugzilla (bugspray 0.1-dev)