* [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09
@ 2014-10-09 13:40 Paolo Bonzini
2014-10-09 13:40 ` [Qemu-devel] [PULL v3 22/28] accel: Create accel object when initializing machine Paolo Bonzini
2014-10-09 15:48 ` [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09 Peter Maydell
0 siblings, 2 replies; 3+ messages in thread
From: Paolo Bonzini @ 2014-10-09 13:40 UTC (permalink / raw)
To: qemu-devel
The following changes since commit 1831e150606a221898bf46ffaf0453e9952cbbc4:
Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2014-09-30 16:45:35 +0100)
are available in the git repository at:
git://github.com/bonzini/qemu.git tags/for-upstream
for you to fetch changes up to 5008e5b7b817b5ea2b788203122cd50e7c16e599:
qemu-char: Fix reconnect socket error reporting (2014-10-09 15:36:15 +0200)
----------------------------------------------------------------
Four changes here. Polling for reconnection of character devices,
the QOMification of accelerators, a fix for -kernel support on x86, and one
for a recently-introduced virtio-scsi optimization.
----------------------------------------------------------------
Corey Minyard (9):
qemu-char: Make the filename size for a chardev a #define
qemu-char: Rework qemu_chr_open_socket() for reconnect
qemu-char: Move some items into TCPCharDriver
qemu-char: set socket filename to disconnected when not connected
qemu-char: Add reconnecting to client sockets
qemu-char: Print the remote and local addresses for a socket
qemu-error: Add error_vreport()
qemu-sockets: Add error to non-blocking connect handler
qemu-char: Fix reconnect socket error reporting
Eduardo Habkost (17):
vl.c: Small coding style fix
accel: Move accel code to accel.c
accel: Create AccelType typedef
accel: Simplify configure_accelerator() using AccelType *acc variable
accel: Move accel name lookup to separate function
accel: Use QOM classes for accel types
accel: Make AccelClass.available() optional
accel: Report unknown accelerator as "not found" instead of "does not exist"
accel: Move KVM accel registration to kvm-all.c
accel: Move Xen registration code to xen-common.c
accel: Move qtest accel registration to qtest.c
accel: Remove tcg_available() function
accel: Move accel init/allowed code to separate function
accel: Rename 'init' method to 'init_machine'
accel: Pass MachineState object to accel init functions
accel: Create accel object when initializing machine
kvm: Make KVMState be the TYPE_KVM_ACCEL instance struct
Paolo Bonzini (2):
linuxboot: compute initrd loading address
virtio-scsi: fix use-after-free of VirtIOSCSIReq
Makefile.objs | 1 +
accel.c | 157 ++++++++++++++++++
arch_init.c | 5 -
hw/scsi/virtio-scsi.c | 9 +-
include/hw/boards.h | 4 +-
include/hw/xen/xen.h | 1 -
include/qemu/error-report.h | 1 +
include/qemu/sockets.h | 2 +-
include/qemu/typedefs.h | 1 +
include/sysemu/accel.h | 62 ++++++++
include/sysemu/arch_init.h | 1 -
include/sysemu/kvm.h | 2 -
include/sysemu/qtest.h | 1 -
kvm-all.c | 40 ++++-
kvm-stub.c | 5 -
migration-tcp.c | 4 +-
migration-unix.c | 4 +-
pc-bios/linuxboot.bin | Bin 1024 -> 1024 bytes
pc-bios/optionrom/linuxboot.S | 47 +++++-
pc-bios/optionrom/optionrom.h | 21 ++-
qapi-schema.json | 15 +-
qemu-char.c | 359 ++++++++++++++++++++++++++++++++----------
qemu-options.hx | 20 ++-
qtest.c | 27 +++-
util/qemu-error.c | 23 ++-
util/qemu-sockets.c | 20 ++-
vl.c | 83 +---------
xen-common-stub.c | 6 -
xen-common.c | 25 ++-
29 files changed, 711 insertions(+), 235 deletions(-)
create mode 100644 accel.c
create mode 100644 include/sysemu/accel.h
--
1.8.3.1
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Qemu-devel] [PULL v3 22/28] accel: Create accel object when initializing machine
2014-10-09 13:40 [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09 Paolo Bonzini
@ 2014-10-09 13:40 ` Paolo Bonzini
2014-10-09 15:48 ` [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09 Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Paolo Bonzini @ 2014-10-09 13:40 UTC (permalink / raw)
To: qemu-devel; +Cc: Eduardo Habkost
From: Eduardo Habkost <ehabkost@redhat.com>
Create an actual TYPE_ACCEL object when initializing a machine. This
will allow accelerator classes to implement some initialization on
instance_init, and to save state on the TYPE_ACCEL object.
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
accel.c | 7 +++++++
include/hw/boards.h | 2 ++
2 files changed, 9 insertions(+)
diff --git a/accel.c b/accel.c
index 6087ab3..74e41da 100644
--- a/accel.c
+++ b/accel.c
@@ -32,6 +32,7 @@
#include "sysemu/qtest.h"
#include "hw/xen/xen.h"
#include "qom/object.h"
+#include "hw/boards.h"
int tcg_tb_size;
static bool tcg_allowed = true;
@@ -60,11 +61,17 @@ static AccelClass *accel_find(const char *opt_name)
static int accel_init_machine(AccelClass *acc, MachineState *ms)
{
+ ObjectClass *oc = OBJECT_CLASS(acc);
+ const char *cname = object_class_get_name(oc);
+ AccelState *accel = ACCEL(object_new(cname));
int ret;
+ ms->accelerator = accel;
*(acc->allowed) = true;
ret = acc->init_machine(ms);
if (ret < 0) {
+ ms->accelerator = NULL;
*(acc->allowed) = false;
+ object_unref(OBJECT(accel));
}
return ret;
}
diff --git a/include/hw/boards.h b/include/hw/boards.h
index 0058c49..6a60c3c 100644
--- a/include/hw/boards.h
+++ b/include/hw/boards.h
@@ -5,6 +5,7 @@
#include "qemu/typedefs.h"
#include "sysemu/blockdev.h"
+#include "sysemu/accel.h"
#include "hw/qdev.h"
#include "qom/object.h"
@@ -131,6 +132,7 @@ struct MachineState {
char *kernel_cmdline;
char *initrd_filename;
const char *cpu_model;
+ AccelState *accelerator;
};
#endif
--
1.8.3.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09
2014-10-09 13:40 [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09 Paolo Bonzini
2014-10-09 13:40 ` [Qemu-devel] [PULL v3 22/28] accel: Create accel object when initializing machine Paolo Bonzini
@ 2014-10-09 15:48 ` Peter Maydell
1 sibling, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2014-10-09 15:48 UTC (permalink / raw)
To: Paolo Bonzini; +Cc: QEMU Developers
On 9 October 2014 14:40, Paolo Bonzini <pbonzini@redhat.com> wrote:
> The following changes since commit 1831e150606a221898bf46ffaf0453e9952cbbc4:
>
> Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2014-09-30 16:45:35 +0100)
>
> are available in the git repository at:
>
>
> git://github.com/bonzini/qemu.git tags/for-upstream
>
> for you to fetch changes up to 5008e5b7b817b5ea2b788203122cd50e7c16e599:
>
> qemu-char: Fix reconnect socket error reporting (2014-10-09 15:36:15 +0200)
>
> ----------------------------------------------------------------
> Four changes here. Polling for reconnection of character devices,
> the QOMification of accelerators, a fix for -kernel support on x86, and one
> for a recently-introduced virtio-scsi optimization.
>
> ----------------------------------------------------------------
Applied, thanks. PS: where we end up doing multiple versions
of a pullreq it would be helpful to add a version indication
to the tag name or the tag commit message or both, so it's
easier for me to be sure I have the right one (and it gets
recorded in the git commit history).
thanks
-- PMM
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-10-09 15:49 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-10-09 13:40 [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09 Paolo Bonzini
2014-10-09 13:40 ` [Qemu-devel] [PULL v3 22/28] accel: Create accel object when initializing machine Paolo Bonzini
2014-10-09 15:48 ` [Qemu-devel] [PULL v3 00/28] Changes for 2014-10-09 Peter Maydell
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).