Because core-capability releated features are model-specific and KVM
won't support it, remove the core-capability in CPU model to avoid the
warning message.
Signed-off-by: Chenyi Qiang
---
target/i386/cpu.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/target/i386/cpu.c b
On 27/08/2021 08.08, Philippe Mathieu-Daudé wrote:
Commit 155e1c82ed0 deprecated the raspi2/raspi3 machine names.
Use the recommended new names: raspi2b and raspi3b.
Signed-off-by: Philippe Mathieu-Daudé
---
docs/devel/qgraph.rst | 38 -
tests/qtest/
Patch 1:
https://lore.kernel.org/qemu-devel/20210825195438.914387-2-ehabk...@redhat.com/
Patch 2 removes one more feature (core-capability) in Snowridge-v4 CPU
model based on previous patch.
Chenyi Qiang (2):
target/i386: Remove split lock detect in Snowridge CPU model
target/i386: Remove co
At present, there's no mechanism intelligent enough to virtualize split
lock detection correctly. Remove it in Snowridge CPU model to avoid the
feature exposure.
Signed-off-by: Chenyi Qiang
Message-Id: <20210630012053.10098-1-chenyi.qi...@intel.com>
Signed-off-by: Eduardo Habkost
---
target/i38
On Aug 27 08:24, Philippe Mathieu-Daudé wrote:
> +Markus
>
> On 8/27/21 7:48 AM, Klaus Jensen wrote:
> > On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> >> Currently qemu_vfio_dma_map() displays errors on stderr.
> >> When using management interface, this information is simply
> >> lost. Pass qem
On 8/27/21 7:57 AM, Klaus Jensen wrote:
> On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
>> Have qemu_vfio_find_fixed_iova() and qemu_vfio_find_temp_iova()
>> propagate eventual errors to callers.
>>
>> Suggested-by: Klaus Jensen
>> Signed-off-by: Philippe Mathieu-Daudé
>> ---
>> util/vfio-helpe
+Markus
On 8/27/21 7:48 AM, Klaus Jensen wrote:
> On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
>> Currently qemu_vfio_dma_map() displays errors on stderr.
>> When using management interface, this information is simply
>> lost. Pass qemu_vfio_dma_map() an Error** handle so it can
>> propagate the
Commit 155e1c82ed0 deprecated the raspi2/raspi3 machine names.
Use the recommended new names: raspi2b and raspi3b.
Signed-off-by: Philippe Mathieu-Daudé
---
docs/devel/qgraph.rst | 38 -
tests/qtest/libqos/qgraph.h | 6 ++--
tests/qtest/libq
On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> To simplify qemu_vfio_dma_map():
> - reduce 'ret' (returned value) scope by returning errno directly,
> - remove the goto 'out' label.
>
> Signed-off-by: Philippe Mathieu-Daudé
Reviewed-by: Klaus Jensen
signature.asc
Description: PGP signature
Remove the raspi2/raspi3 machine aliases,
deprecated since commit 155e1c82ed0.
Signed-off-by: Philippe Mathieu-Daudé
---
docs/about/deprecated.rst | 7 ---
docs/about/removed-features.rst | 7 +++
hw/arm/raspi.c | 2 --
3 files changed, 7 insertions(+), 9 deletions
Since v2:
- updated "Since 6.1" -> "Since 6.2"
Peter reported CI failure [*] but I can't reproduce:
https://gitlab.com/philmd/qemu/-/pipelines/360227279
Since v1:
- renamed tests (Peter)
[*]
https://lore.kernel.org/qemu-devel/CAFEAcA8PLvMUEzyu=sn4bn4mu30w1aaju+t+i__5jnb0qmz...@mail.gmail.com/
On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> Have qemu_vfio_find_fixed_iova() and qemu_vfio_find_temp_iova()
> propagate eventual errors to callers.
>
> Suggested-by: Klaus Jensen
> Signed-off-by: Philippe Mathieu-Daudé
> ---
> util/vfio-helpers.c | 14 ++
> 1 file changed, 10 i
On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> Extract qemu_vfio_water_mark_reached() for readability,
> and have it provide an error hint it its Error* handle.
>
> Suggested-by: Klaus Jensen
> Signed-off-by: Philippe Mathieu-Daudé
Reviewed-by: Klaus Jensen
signature.asc
Description: PGP s
On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> Pass qemu_vfio_do_mapping() an Error* argument so it can propagate
> any error to callers. Replace error_report() which only report
> to the monitor by the more generic error_setg_errno().
>
> Reviewed-by: Fam Zheng
> Reviewed-by: Stefan Hajnoczi
On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> nvme_create_queue_pair() does not return a boolean value (indicating
> eventual error) but a pointer, and is inconsistent in how it fills the
> error handler. To fulfill callers expectations, always set an error
> message on failure.
>
> Reported-by
On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> Instead of displaying the error on stderr, use error_report()
> which also report to the monitor.
>
> Reviewed-by: Fam Zheng
> Reviewed-by: Stefan Hajnoczi
> Signed-off-by: Philippe Mathieu-Daudé
Reviewed-by: Klaus Jensen
signature.asc
Descri
On Aug 26 21:50, Philippe Mathieu-Daudé wrote:
> Currently qemu_vfio_dma_map() displays errors on stderr.
> When using management interface, this information is simply
> lost. Pass qemu_vfio_dma_map() an Error** handle so it can
> propagate the error to callers.
>
> Reviewed-by: Fam Zheng
> Revie
Macro ERRP_GUARD() is only needed when we want to dereference @errp or
pass it to error_prepend() or error_append_hint(). Delete superfluous
ones.
Signed-off-by: Markus Armbruster
Message-Id: <20210720125408.387910-15-arm...@redhat.com>
Acked-by: Michael S. Tsirkin
---
hw/remote/mpqemu-link.c
Fixes: 2500fb423adb17995485de0b4d507cf2f09e3a7f
Cc: Aravinda Prasad
Cc: Ganesh Goudar
Cc: David Gibson
Signed-off-by: Markus Armbruster
Message-Id: <20210720125408.387910-3-arm...@redhat.com>
Acked-by: Michael S. Tsirkin
Reviewed-by: Philippe Mathieu-Daudé
---
hw/ppc/spapr_events.c | 3 +--
vhost_user_get_config() can fail without setting an error. Unclean.
Its caller vhost_dev_get_config() compensates by substituting a
generic error then. Goes back to commit 50de51387f "vhost:
Distinguish errors in vhost_dev_get_config()".
Clean up by moving the generic error from vhost_dev_get_co
Most callers check the return value. Some check whether it set an
error. Functionally equivalent, but the former tends to be easier on
the eyes, so do that everywhere.
Prior art: commit c6ecec43b2 "qemu-option: Check return value instead
of @err where convenient".
Signed-off-by: Markus Armbrust
The Error ** argument must be NULL, &error_abort, &error_fatal, or a
pointer to a variable containing NULL. Passing an argument of the
latter kind twice without clearing it in between is wrong: if the
first call sets an error, it no longer points to NULL for the second
call.
pci_proxy_dev_realize
Commit b673eab4e2 "multifd: Make multifd_load_setup() get an Error
parameter" changed migration_incoming_setup() to take an Error **
argument, and adjusted the callers accordingly. It neglected to
change adjust multifd_load_setup(): it still exit()s on error. Clean
that up.
The error now gets pr
We did this with scripts/coccinelle/use-error_fatal.cocci before, in
commit 50beeb68094 and 007b06578ab. This commit cleans up rarer
variations that don't seem worth matching with Coccinelle.
Cc: Thomas Huth
Cc: Cornelia Huck
Cc: Peter Xu
Cc: Juan Quintela
Cc: Stefan Hajnoczi
Cc: Paolo Bonzi
vhost_user_backend_init() can fail without setting an error. Unclean.
Its caller vhost_dev_init() compensates by substituting a generic
error then. Goes back to commit 28770ff935 "vhost: Distinguish errors
in vhost_backend_init()".
Clean up by moving the generic error from vhost_dev_init() to al
There is nothing to delete after migrate_add_blocker() failed. Trying
anyway is safe, but useless. Don't.
Cc: Sunil Muthuswamy
Cc: Kamil Rytarowski
Cc: Reinoud Zandijk
Signed-off-by: Markus Armbruster
Message-Id: <20210720125408.387910-9-arm...@redhat.com>
Reviewed-by: Reinoud Zandijk
Acked
invtsc_mig_blocker has static storage duration. When a CPU with
certain features is initialized, and invtsc_mig_blocker is still null,
we add a migration blocker and store it in invtsc_mig_blocker.
The object is freed when migrate_add_blocker() fails, leaving
invtsc_mig_blocker dangling. It is n
When migrate_add_blocker(blocker, &err) is followed by
error_propagate(errp, err), we can often just as well do
migrate_add_blocker(..., errp). This is the case in
vfio_migration_probe().
Prior art: commit 386f6c07d2 "error: Avoid error_propagate() after
migrate_add_blocker()".
Cc: Kirti Wankhed
The Error ** argument must be NULL, &error_abort, &error_fatal, or a
pointer to a variable containing NULL. Passing an argument of the
latter kind twice without clearing it in between is wrong: if the
first call sets an error, it no longer points to NULL for the second
call.
machine_parse_propert
Cc: Michael S. Tsirkin
Signed-off-by: Markus Armbruster
Message-Id: <20210720125408.387910-6-arm...@redhat.com>
Acked-by: Michael S. Tsirkin
---
hw/scsi/vhost-scsi.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/hw/scsi/vhost-scsi.c b/hw/scsi/vhost-scsi.c
index 8c611bf
Stillborn in commit 0ebf007dda "hw/i386: Introduce the microvm machine
type".
Cc: Sergio Lopez
Signed-off-by: Markus Armbruster
Message-Id: <20210720125408.387910-12-arm...@redhat.com>
Reviewed-by: Sergio Lopez
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: Pankaj Gupta
Acked-by: Michael S.
spapr_mce_req_event() makes an effort to prevent migration from
degrading the reporting of FWNMIs. It adds a migration blocker when
it receives one, and deletes it when it's done handling it. This is a
best effort.
Commit 2500fb423a "migration: Include migration support for machine
check handlin
The following changes since commit c83fcfaf8a54d0d034bd0edf7bbb3b0d16669be9:
Merge remote-tracking branch 'remotes/armbru/tags/pull-qapi-2021-08-26' into
staging (2021-08-26 13:42:34 +0100)
are available in the Git repository at:
git://repo.or.cz/qemu/armbru.git tags/pull-error-2021-08-26
On 8/26/21 11:12 PM, i...@bsdimp.com wrote:
> From: Colin Percival
>
> Previously it was impossible to emulate a program with a file name
> different from its argv[0]. With this change, you can run
> qemu -0 fakename realname args
> which runs the program "realname" with an argv of "fakename
On 8/26/21 11:11 PM, i...@bsdimp.com wrote:
> From: Warner Losh
>
> cpu_copy shouldbe called when processes are creating new threads. It
Typo "should be"
> copies the current state of the CPU to a new cpu state needed for the
> new thread.
>
> Signed-off-by: Stacey Son
> Signed-off-by: Warner
On 8/26/21 11:11 PM, i...@bsdimp.com wrote:
> From: Warner Losh
>
> LOW_ELF_STACK doesn't exist on FreeBSD and likely never will. Remove it.
> Likewise, remove an #if 0 block that's not useful
>
> Signed-off-by: Warner Losh
> Reviewed-by: Richard Henderson
> ---
> bsd-user/elfload.c | 20
On 8/26/21 11:11 PM, i...@bsdimp.com wrote:
> From: Warner Losh
>
> Move the CPU functons into target_arch_cpu.c that are unique to each
Typo "functions"
> CPU. These are defined in target_arch.h.
>
> Signed-off-by: Stacey Son
> Signed-off-by: Warner Losh
> Reviewed-by: Richard Henderson
>
On 8/26/21 11:11 PM, i...@bsdimp.com wrote:
> From: Warner Losh
>
> All compilers for some time have supported this. Follow linux-user
Please insert: "(see 24cb36a61c6: "configure: Make NPTL non-optional")"
> and
> eliminate the #define THREAD and unconditionally insert __thread where
> needed
On 8/26/21 11:11 PM, i...@bsdimp.com wrote:
> From: Warner Losh
>
> Remove still-born a.out support. The BSDs switched from a.out to ELF 20+ years
> ago. It's out of scope for bsd-user, and what little support there was would
> simply wind up at a not-implemented message. Simplify the whole mess
On 8/26/21 11:11 PM, i...@bsdimp.com wrote:
> From: Warner Losh
>
> Pass the bsd_param into loader_exec, and adjust.
Missing the "why" justification.
Anyway,
Reviewed-by: Philippe Mathieu-Daudé
> Signed-off-by: Warner Losh
> Reviewed-by: Richard Henderson
> ---
> bsd-user/bsdload.c | 37 ++
On 8/26/21 11:11 PM, i...@bsdimp.com wrote:
> From: Warner Losh
>
> Move the arcitecture specific defines to target_arch_elf.h and delete
Typo "architecture"
> them from elfload.c. unifdef as appropriate for i386 vs x86_64
"un-ifdef" or untangle?
> versions. Add the copyright/license comments
在 2021/8/26 下午2:25, Jonah Palmer 写道:
Hi Jason, could I get your thoughts on this implementation question below?
I'm not too sure on how I should proceed determining if vhost is
active or not.
Thank you!
Jonah
On 7/26/21 5:33 AM, Jonah Palmer wrote:
On 7/22/21 5:22 AM, Jason Wang wrot
On Thu, Aug 26, 2021 at 11:14:44AM -0300, matheus.fe...@eldorado.org.br wrote:
> From: Matheus Ferst
>
> The definition of struct Int128 is currently independent of the host
> endianness, causing different results when using the member s128 of
> union ppc_vsr_t in big-endian builds with CONFIG_IN
On Thu, Aug 26, 2021 at 11:56:54AM -0300, matheus.fe...@eldorado.org.br wrote:
> From: Matheus Ferst
>
> PPC gdbstub code has two possible swaps of the 64-bit elements of AVR
> registers: in gdb_get_avr_reg/gdb_set_avr_reg (based on msr_le) and in
> gdb_get_reg128/ldq_p (based on TARGET_WORDS_BIG
On Thu, Aug 26, 2021 at 11:34:59AM +0400, Marc-André Lureau wrote:
> Hi
>
> On Thu, Aug 26, 2021 at 7:11 AM David Gibson
> wrote:
>
> > On Thu, Aug 26, 2021 at 12:11:17AM +0400, Marc-André Lureau wrote:
> > > Hi
> > >
> > > On Thu, Aug 26, 2021 at 12:00 AM Peter Maydell > >
> > > wrote:
> > >
>
> -Original Message-
> From: Peter Maydell [mailto:peter.mayd...@linaro.org]
> Sent: Thursday, August 26, 2021 11:57 PM
> To: Li, Chunming
> Cc: eric.au...@redhat.com; Liu, Renwei; qemu-...@nongnu.org; Wen,
> Jianxian; qemu-devel@nongnu.org
> Subject: Re: [PATCH] hw/arm/smmuv3: Support no
These patches implement SEV-SNP along with CPUID enforcement support for QEMU,
and are also available at:
https://github.com/mdroth/qemu/commits/snp-rfc-v2-upstream
They are based on the initial RFC submitted by Brijesh:
https://lore.kernel.org/qemu-devel/20210722000259.ykepl7t6ptua7...@amd.
New EPYC CPUs versions require small changes to their cache_info's.
Because current QEMU x86 CPU definition does not support cache
versions, we would have to declare a new CPU type for each such case.
To avoid this duplication, the patch allows new cache_info pointers to
be specificed for a new CPU
From: Brijesh Singh
During the SNP guest launch sequence, a special secrets and cpuid page
needs to be populated by the SEV-SNP firmware. The secrets page contains
the VM Platform Communication Key (VMPCKs) used by the guest to send and
receive secure messages to the PSP. And CPUID page will cont
This patch introduces new EPYC cpu versions: EPYC-v4, EPYC-Rome-v3,
and EPYC-Milan-v2. The only difference vs. older models is an updated
cache_info with the 'complex_indexing' bit unset, since this bit is
not currently defined for AMD and may cause problems should it be used
for something else in
From: Brijesh Singh
The SNP_LAUNCH_START is called first to create a cryptographic launch
context within the firmware.
Signed-off-by: Brijesh Singh
Signed-off-by: Michael Roth
---
target/i386/sev.c| 29 -
target/i386/trace-events | 1 +
2 files changed, 29
From: Brijesh Singh
SEV-SNP support relies on a different set of properties/state than the
existing 'sev-guest' object. This patch introduces the 'sev-snp-guest'
object, which can be used to configure an SEV-SNP guest. For example,
a default-configured SEV-SNP guest with no additional information
SNP guests will rely on this bit to determine certain feature support.
Signed-off-by: Michael Roth
---
target/i386/cpu.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 97e250e876..f0b441f692 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@
From: Brijesh Singh
When SEV-SNP is enabled, the KVM_SNP_INIT command is used to initialize
the platform. The command checks whether SNP is enabled in the KVM, if
enabled then it allocates a new ASID from the SNP pool and calls the
firmware to initialize the all the resources.
Signed-off-by: Bri
Currently all SEV/SEV-ES functionality is managed through a single
'sev-guest' QOM type. With upcoming support for SEV-SNP, taking this
same approach won't work well since some of the properties/state
managed by 'sev-guest' is not applicable to SEV-SNP, which will instead
rely on a new QOM type wit
From: Brijesh Singh
The KVM_SEV_SNP_LAUNCH_UPDATE command is used for encrypting the bios
image used for booting the SEV-SNP guest.
Signed-off-by: Brijesh Singh
Signed-off-by: Michael Roth
---
hw/i386/pc_sysfw.c | 7 ---
include/sysemu/sev.h | 2 +-
target/i386/sev-stub.c |
From: Brijesh Singh
Sync the kvm.h with the kernel to include the SNP specific commands.
Signed-off-by: Brijesh Singh
Signed-off-by: Michael Roth
---
linux-headers/linux/kvm.h | 50 +++
1 file changed, 50 insertions(+)
diff --git a/linux-headers/linux/kvm.
Most of the current 'query-sev' command is relevant to both legacy
SEV/SEV-ES guests and SEV-SNP guests, with 2 exceptions:
- 'policy' is a 64-bit field for SEV-SNP, not 32-bit, and
the meaning of the bit positions has changed
- 'handle' is not relevant to SEV-SNP
To address this, this pa
SEV-SNP firmware allows a special guest page to be populated with a
table of guest CPUID values so that they can be validated through
firmware before being loaded into encrypted guest memory where they can
be used in place of hypervisor-provided values[1].
As part of SEV-SNP guest initialization,
As of now we have a knob "-o xattr/no_xattr" which either enables
all xattrs or disables all xattrs.
We need something more fine grained where we can selectively disable
only certain xattrs (and not all).
For example, in some cases we want to disable "security.selinux"
xattr. This is equivalent t
From: Warner Losh
Signed-off-by: Warner Losh
Acked-by: Richard Henderson
---
bsd-user/main.c | 17 +
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/bsd-user/main.c b/bsd-user/main.c
index 57669ad7b7..d60a0a7ee2 100644
--- a/bsd-user/main.c
+++ b/bsd-user/main.c
@
From: Warner Losh
LOW_ELF_STACK doesn't exist on FreeBSD and likely never will. Remove it.
Likewise, remove an #if 0 block that's not useful
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/elfload.c | 20
1 file changed, 20 deletions(-)
diff --git
From: Warner Losh
target_reg_t is the normal register. target_fpreg_t is the floating
point registers. target_copy_regs copies the registers out of CPU
context for things like core dumps.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/i386/ta
From: Warner Losh
Update the debugging code for new features and different targets.
Signed-off-by: Mikaël Urankar
Signed-off-by: Sean Bruno
Signed-off-by: Kyle Evans
Signed-off-by: Warner Losh
Acked-by: Richard Henderson
---
bsd-user/mmap.c | 45
From: Warner Losh
cpu_model and cpu_type will be used future commits, so move them from
main() scoped to file scoped.
Signed-off-by: Warner Losh
Acked-by: Richard Henderson
---
bsd-user/main.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/bsd-user/main.c b/bsd-user/m
From: Colin Percival
Previously it was impossible to emulate a program with a file name
different from its argv[0]. With this change, you can run
qemu -0 fakename realname args
which runs the program "realname" with an argv of "fakename args".
Signed-off-by: Colin Percival
Signed-off-by: W
From: Warner Losh
Move OS-dependent defines into target_os_elf.h. Move the architectural
dependent stuff into target_arch_elf.h. Adjust elfload.c to use
target_create_elf_tables instead of create_elf_tables.
Signed-off-by: Warner Losh
Signed-off-by: Stacey Son
Signed-off-by: Kyle Evans
Signed
From: Warner Losh
Factor out load_elf_sections and is_target_elf_binary out of
load_elf_interp.
Signed-off-by: Mikaël Urankar
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
---
bsd-user/elfload.c | 350 +
1 file changed, 164 insertions(+), 18
From: Warner Losh
For 32-bit platforms, pass in up to 256k of args. For 64-bit, bump that
to 512k.
Signed-off-by: Kyle Evans
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/qemu.h | 15 +++
1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/bsd-
From: Warner Losh
Rewrite target definnitions to interface with the FreeBSD system calls.
This covers basic types (time_t, iovec, umtx_time, timespec, timeval,
rusage, rwusage) and basic defines (mmap, rusage). Also included are
FreeBSD version-specific variations.
Signed-off-by: Stacey Son
Sig
From: Warner Losh
Update target_arch_elf.h to remove thread_init. Move its contents to
target_arch_thread.h and rename to target_thread_init(). Update
elfload.c to call it. Create thread_os_thread.h to hold the os specific
parts of the thread and threat manipulation routines. Currently, it just
i
We need capability to block security.selinux xattr and return EOPNOTSUPP.
That way guest SELinux thinks filesystem does not support selinux
xattr and falls back to some default label (virtiofs_t) for the
virtiofs filesystem instance.
So add a generic option "-o block_xattr=", which can allow user
From: Warner Losh
Eliminate the x86 specific stack stuff in favor of more generic control
over the process size:
target_maxtsiz max text size
target_dfldsiz initial data size limit
target_maxdsiz max data size
target_dflssiz initial stack size limit
target_maxssiz max sta
From: Warner Losh
Target specific values for vm parameters and details.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/freebsd/target_os_vmparam.h | 38 ++
bsd-user/i386/target_arch_vmparam.h | 46 ++
From: Warner Losh
Save the path to the qemu emulator. This will be used later when we have
a more complete implementation of exec.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Acked-by: Richard Henderson
---
bsd-user/main.c | 21 +
bsd-user/qemu.h | 1 +
2 files
Right now we have capability to block "system.posix_acl_access" and
"system.posix_acl_default" xattrs. But we have sort of hardcoded these
two values and its not generic.
Now we want to support blocking of arbitrary xattr as passed in
by user. So let us keep an array of blocked xattrs and consult
From: Warner Losh
Include host-os.h from main.c to pick up the default OS to emulate. Set
that default in main().
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/freebsd/host-os.h | 2 ++
bsd-user/main.c| 4 +++-
bsd-user/netbsd/h
From: Warner Losh
Update the reserved base based on what platform we're on, as well as the
start of the mmap range. Update routines that find va ranges to interact
with the reserved ranges as well as properly align the mapping (this is
especially important for targets whose page size does not mat
From: Warner Losh
Move cpu_loop() into target_cpu_loop(), and put that in
target_arch_cpu.h for each architecture.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
---
bsd-user/i386/target_arch_cpu.c | 1 +
bsd-user/i386/target_arch_cpu.h | 208 ++
bsd-user/main.c
From: Warner Losh
Implement the internlock in fork_start() and fork_end() to properly cope
with atomic operations and to safely keep state for parent and child
processes.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/main.c | 23
On 26/08/2021 21:07, Philippe Mathieu-Daudé wrote:
Simplify by always passing a MemoryRegion property to the device.
Doing so we can move the AddressSpace field to the device struct,
removing need for heap allocation.
Update the MicroVM machine to pass the default system memory instead
of a NUL
From: Warner Losh
Include more header files to match bsd-user fork.
Signed-off-by: Warner Losh
---
bsd-user/qemu.h | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/bsd-user/qemu.h b/bsd-user/qemu.h
index 5e4cbb40d4..55d71130bb 100644
--- a/bsd-user/qemu.h
+++ b/bsd-use
From: Warner Losh
Reduce the number of ifdefs by always calling the swapping routine, but
making them empty when swapping isn't needed.
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/elfload.c | 97 ++
1 file changed, 47 inse
From: Warner Losh
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/bsdload.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/bsd-user/bsdload.c b/bsd-user/bsdload.c
index 6aefc7a28b..5b3c061a45 100644
--- a/bsd-user/bsdload.c
+++ b/bsd-user/bsdload.c
@@ -19,8 +19,6 @
From: Warner Losh
Add a stubbed-out version of the bsd-user fork's core dump support. This
allows elfload.c to be almost the same between what's upstream and
what's in qemu-project upstream w/o the burden of reviewing the core
dump support.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
From: Warner Losh
cpu_copy shouldbe called when processes are creating new threads. It
copies the current state of the CPU to a new cpu state needed for the
new thread.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Signed-off-by: Justin Hibbits
Reviewed-by: Richard Henderson
---
bsd-
From: Warner Losh
All compilers for some time have supported this. Follow linux-user and
eliminate the #define THREAD and unconditionally insert __thread where
needed.
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/main.c | 2 +-
bsd-user/qemu.h | 10 +-
2 fil
From: Warner Losh
Use the PATH to find the executable given a bare argument. We need to do
this so we can implement mixing native and emulated binaries (e.g.,
execing a x86 native binary from an emulated arm binary to optimize
parts of the build). By finding the binary, we will know how to exec i
From: Warner Losh
Add FreeBSD, NetBSD and OpenBSD values for the various signal info types
and defines to decode different signals to discover more information
about the specific signal types.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Acked-by: Richard Henderson
---
bsd-user/freeb
From: Warner Losh
Remove still-born a.out support. The BSDs switched from a.out to ELF 20+ years
ago. It's out of scope for bsd-user, and what little support there was would
simply wind up at a not-implemented message. Simplify the whole mess by removing
it entirely. Should future support be requ
From: Warner Losh
Various style fixes to elfload.c that were too painful to make earlier
in this series.
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/elfload.c | 210 ++---
1 file changed, 105 insertions(+), 105 deletions(-)
d
From: Warner Losh
Move all of the stack initialization into target_os_stack.h. Each BSD
sets up processes a little differently.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/freebsd/target_os_stack.h | 180 +
bsd-
From: Warner Losh
The linux kernel supports a number of different ELF binaries. The Linux userland
emulator inheritted some of that. And we inheritted it from there. However, for
BSD there's only one kind of ELF file supported per platform, so there's no need
to cope with historical quirks. Simpl
From: Warner Losh
It was incorrect to subtract off the size of an unsigned int here. In
bsd-user fork, this change was made when moving the arch specific items
to specific files. The size in BSD that's available for the arguments
does not need a return address subtracted from it.
Signed-off-by
From: Warner Losh
This file evolved over the years to capture the user/kernel interfaces,
including those that changed over time.
Signed-off-by: Stacey Son
Signed-off-by: Michal Meloun
Signed-off-by: Warner Losh
Acked-by: Richard Henderson
---
bsd-user/freebsd/target_os_user.h | 429 +++
From: Warner Losh
Pass the bsd_param into loader_exec, and adjust.
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/bsdload.c | 37 +++--
bsd-user/main.c| 7 ++-
bsd-user/qemu.h| 3 ++-
3 files changed, 27 insertions(+), 20 d
From: Warner Losh
Move the CPU functons into target_arch_cpu.c that are unique to each
CPU. These are defined in target_arch.h.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/i386/target_arch.h | 31 +
bsd-user/i386/target_a
From: Warner Losh
Move the arcitecture specific defines to target_arch_elf.h and delete
them from elfload.c. unifdef as appropriate for i386 vs x86_64
versions. Add the copyright/license comments, and guard ifdefs.
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/elfload
From: Warner Losh
Add a stubbed out version of setup_sigtramp. This is not yet used for
x86, but is used for other architectures. This will be connected in
future commits.
Signed-off-by: Stacey Son
Signed-off-by: Warner Losh
Reviewed-by: Richard Henderson
---
bsd-user/i386/target_arch_sigtra
From: Warner Losh
This series of patches gets me to the point that I can run "Hello World" on i386
and x86_64. This is for static binaries only, that are relatively small, but
it's better than the 100% instant mmap failre that is the current state of all
things bsd-user in upstream qemu. Future p
1 - 100 of 319 matches
Mail list logo