[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v4 0/4] semihosting at translate time fixes
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] [PATCH v4 0/4] semihosting at translate time fixes |
Date: |
Thu, 12 Sep 2019 09:35:35 +0100 |
On Wed, 11 Sep 2019 at 14:14, Alex Bennée <address@hidden> wrote:
> It does seem a bit weird that userspace linux-user does do semihosting
> whereas EL0 in softmmu doesn't. Is that because we are effectively
> short-circuiting what a real ARM kernel would be doing for EL0?
It's because the "not for EL0" is a rather bogus attempt
at 'security' by not allowing userspace in a system emulator
to access the semihosting API, reserving it instead for
the guest OS (its EL1). This concept doesn't apply for
linux-user mode, where there is no guest EL1, and where in any
case the semihosting API doesn't allow the guest code to do
anything it couldn't do by directly making host OS syscalls.
I suspect this "not for EL0" thing is not something anybody
else's semihosting implementation does (though I haven't checked).
One idea I've vaguely thought about is an idea of a more
'safe' semihosting mode, where we only provide the calls
which we think are reasonable for a not-really-trusted
guest: so you could write to stdout but not read/write
arbitrary files on the filesystem, for instance.
thanks
-- PMM
- [Qemu-devel] [PATCH v4 0/4] semihosting at translate time fixes, Alex Bennée, 2019/09/06
- [Qemu-devel] [PATCH v4 1/4] target/arm: handle M-profile semihosting at translate time, Alex Bennée, 2019/09/06
- [Qemu-devel] [PATCH v4 4/4] atomic_template: fix indentation in GEN_ATOMIC_HELPER, Alex Bennée, 2019/09/06
- [Qemu-devel] [PATCH v4 3/4] target/arm: remove run time semihosting checks, Alex Bennée, 2019/09/06
- [Qemu-devel] [PATCH v4 2/4] target/arm: handle A-profile semihosting at translate time, Alex Bennée, 2019/09/06
- Re: [Qemu-devel] [PATCH v4 0/4] semihosting at translate time fixes, Peter Maydell, 2019/09/11