Skip to content

Commit

Permalink
Merge remote-tracking branch 'remotes/vivier2/tags/trivial-branch-for…
Browse files Browse the repository at this point in the history
…-6.0-pull-request' into staging

Pull request

# gpg: Signature made Wed 10 Mar 2021 21:56:09 GMT
# gpg:                using RSA key CD2F75DDC8E3A4DC2E4F5173F30C38BD3F2FBE3C
# gpg:                issuer "laurent@vivier.eu"
# gpg: Good signature from "Laurent Vivier <lvivier@redhat.com>" [full]
# gpg:                 aka "Laurent Vivier <laurent@vivier.eu>" [full]
# gpg:                 aka "Laurent Vivier (Red Hat) <lvivier@redhat.com>" [full]
# Primary key fingerprint: CD2F 75DD C8E3 A4DC 2E4F  5173 F30C 38BD 3F2F BE3C

* remotes/vivier2/tags/trivial-branch-for-6.0-pull-request: (22 commits)
  sysemu: Let VMChangeStateHandler take boolean 'running' argument
  sysemu/runstate: Let runstate_is_running() return bool
  hw/lm32/Kconfig: Have MILKYMIST select LM32_DEVICES
  hw/lm32/Kconfig: Rename CONFIG_LM32 -> CONFIG_LM32_DEVICES
  hw/lm32/Kconfig: Introduce CONFIG_LM32_EVR for lm32-evr/uclinux boards
  qemu-common.h: Update copyright string to 2021
  tests/fp/fp-test: Replace the word 'blacklist'
  qemu-options: Replace the word 'blacklist'
  seccomp: Replace the word 'blacklist'
  scripts/tracetool: Replace the word 'whitelist'
  ui: Replace the word 'whitelist'
  virtio-gpu: Adjust code space style
  exec/memory: Use struct Object typedef
  fuzz-test: remove unneccessary debugging flags
  net: Use id_generate() in the network subsystem, too
  MAINTAINERS: Fix the location of tools manuals
  vhost_user_gpu: Drop dead check for g_malloc() failure
  backends/dbus-vmstate: Fix short read error handling
  target/hexagon/gen_tcg_funcs: Fix a typo
  hw/elf_ops: Fix a typo
  ...

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
  • Loading branch information
pm215 committed Mar 11, 2021
2 parents f4abdf3 + 538f049 commit 6f34661
Show file tree
Hide file tree
Showing 79 changed files with 147 additions and 134 deletions.
10 changes: 5 additions & 5 deletions MAINTAINERS
Expand Up @@ -1869,7 +1869,7 @@ S: Odd Fixes
F: hw/9pfs/
X: hw/9pfs/xen-9p*
F: fsdev/
F: docs/interop/virtfs-proxy-helper.rst
F: docs/tools/virtfs-proxy-helper.rst
F: tests/qtest/virtio-9p-test.c
T: git https://gitlab.com/gkurz/qemu.git 9p-next
T: git https://github.com/cschoenebeck/qemu.git 9p.next
Expand Down Expand Up @@ -1900,7 +1900,7 @@ S: Supported
F: tools/virtiofsd/*
F: hw/virtio/vhost-user-fs*
F: include/hw/virtio/vhost-user-fs.h
F: docs/interop/virtiofsd.rst
F: docs/tools/virtiofsd.rst

virtio-input
M: Gerd Hoffmann <kraxel@redhat.com>
Expand Down Expand Up @@ -2214,7 +2214,7 @@ F: block/
F: hw/block/
F: include/block/
F: qemu-img*
F: docs/interop/qemu-img.rst
F: docs/tools/qemu-img.rst
F: qemu-io*
F: tests/qemu-iotests/
F: util/qemu-progress.c
Expand Down Expand Up @@ -2671,7 +2671,7 @@ F: qapi/trace.json
F: scripts/tracetool.py
F: scripts/tracetool/
F: scripts/qemu-trace-stap*
F: docs/interop/qemu-trace-stap.rst
F: docs/tools/qemu-trace-stap.rst
F: docs/devel/tracing.txt
T: git https://github.com/stefanha/qemu.git tracing

Expand Down Expand Up @@ -3066,7 +3066,7 @@ F: include/block/nbd*
F: qemu-nbd.*
F: blockdev-nbd.c
F: docs/interop/nbd.txt
F: docs/interop/qemu-nbd.rst
F: docs/tools/qemu-nbd.rst
T: git https://repo.or.cz/qemu/ericb.git nbd
T: git https://src.openvz.org/scm/~vsementsov/qemu.git nbd

Expand Down
2 changes: 1 addition & 1 deletion accel/xen/xen-all.c
Expand Up @@ -122,7 +122,7 @@ static void xenstore_record_dm_state(struct xs_handle *xs, const char *state)
}


static void xen_change_state_handler(void *opaque, int running,
static void xen_change_state_handler(void *opaque, bool running,
RunState state)
{
if (running) {
Expand Down
2 changes: 1 addition & 1 deletion audio/audio.c
Expand Up @@ -1540,7 +1540,7 @@ static int audio_driver_init(AudioState *s, struct audio_driver *drv,
}
}

static void audio_vm_change_state_handler (void *opaque, int running,
static void audio_vm_change_state_handler (void *opaque, bool running,
RunState state)
{
AudioState *s = opaque;
Expand Down
5 changes: 4 additions & 1 deletion backends/dbus-vmstate.c
Expand Up @@ -229,7 +229,10 @@ static int dbus_vmstate_post_load(void *opaque, int version_id)
&bytes_read, NULL, &err)) {
goto error;
}
g_return_val_if_fail(bytes_read == len, -1);
if (bytes_read != len) {
error_report("%s: Short read", __func__);
return -1;
}
id[len] = 0;

trace_dbus_vmstate_loading(id);
Expand Down
2 changes: 1 addition & 1 deletion block/block-backend.c
Expand Up @@ -163,7 +163,7 @@ static const char *blk_root_get_name(BdrvChild *child)
return blk_name(child->opaque);
}

static void blk_vm_state_changed(void *opaque, int running, RunState state)
static void blk_vm_state_changed(void *opaque, bool running, RunState state)
{
Error *local_err = NULL;
BlockBackend *blk = opaque;
Expand Down
2 changes: 1 addition & 1 deletion default-configs/devices/lm32-softmmu.mak
Expand Up @@ -8,5 +8,5 @@ CONFIG_SEMIHOSTING=y

# Boards:
#
CONFIG_LM32=y
CONFIG_LM32_EVR=y
CONFIG_MILKYMIST=y
2 changes: 1 addition & 1 deletion disas/nanomips.cpp
Expand Up @@ -837,7 +837,7 @@ int NMD::Disassemble(const uint16 * data, std::string & dis,
* an ASE attribute and the requested version
* not having that attribute
*/
dis = "ASE attribute missmatch";
dis = "ASE attribute mismatch";
return -5;
}
disassembly_function dis_fn = table[i].disassembly;
Expand Down
2 changes: 1 addition & 1 deletion gdbstub.c
Expand Up @@ -2754,7 +2754,7 @@ void gdb_set_stop_cpu(CPUState *cpu)
}

#ifndef CONFIG_USER_ONLY
static void gdb_vm_state_change(void *opaque, int running, RunState state)
static void gdb_vm_state_change(void *opaque, bool running, RunState state)
{
CPUState *cpu = gdbserver_state.c_cpu;
g_autoptr(GString) buf = g_string_new(NULL);
Expand Down
2 changes: 1 addition & 1 deletion hw/block/pflash_cfi01.c
Expand Up @@ -1014,7 +1014,7 @@ void pflash_cfi01_legacy_drive(PFlashCFI01 *fl, DriveInfo *dinfo)
loc_pop(&loc);
}

static void postload_update_cb(void *opaque, int running, RunState state)
static void postload_update_cb(void *opaque, bool running, RunState state)
{
PFlashCFI01 *pfl = opaque;

Expand Down
2 changes: 1 addition & 1 deletion hw/block/virtio-blk.c
Expand Up @@ -870,7 +870,7 @@ static void virtio_blk_dma_restart_bh(void *opaque)
virtio_blk_process_queued_requests(s, true);
}

static void virtio_blk_dma_restart_cb(void *opaque, int running,
static void virtio_blk_dma_restart_cb(void *opaque, bool running,
RunState state)
{
VirtIOBlock *s = opaque;
Expand Down
4 changes: 2 additions & 2 deletions hw/char/meson.build
Expand Up @@ -8,8 +8,8 @@ softmmu_ss.add(when: 'CONFIG_IMX', if_true: files('imx_serial.c'))
softmmu_ss.add(when: 'CONFIG_IPACK', if_true: files('ipoctal232.c'))
softmmu_ss.add(when: 'CONFIG_ISA_BUS', if_true: files('parallel-isa.c'))
softmmu_ss.add(when: 'CONFIG_ISA_DEBUG', if_true: files('debugcon.c'))
softmmu_ss.add(when: 'CONFIG_LM32', if_true: files('lm32_juart.c'))
softmmu_ss.add(when: 'CONFIG_LM32', if_true: files('lm32_uart.c'))
softmmu_ss.add(when: 'CONFIG_LM32_DEVICES', if_true: files('lm32_juart.c'))
softmmu_ss.add(when: 'CONFIG_LM32_DEVICES', if_true: files('lm32_uart.c'))
softmmu_ss.add(when: 'CONFIG_MILKYMIST', if_true: files('milkymist-uart.c'))
softmmu_ss.add(when: 'CONFIG_NRF51_SOC', if_true: files('nrf51_uart.c'))
softmmu_ss.add(when: 'CONFIG_PARALLEL', if_true: files('parallel.c'))
Expand Down
2 changes: 1 addition & 1 deletion hw/display/qxl.c
Expand Up @@ -1992,7 +1992,7 @@ static void qxl_dirty_surfaces(PCIQXLDevice *qxl)
}
}

static void qxl_vm_change_state_handler(void *opaque, int running,
static void qxl_vm_change_state_handler(void *opaque, bool running,
RunState state)
{
PCIQXLDevice *qxl = opaque;
Expand Down
1 change: 0 additions & 1 deletion hw/display/vhost-user-gpu.c
Expand Up @@ -325,7 +325,6 @@ vhost_user_gpu_chr_read(void *opaque)
}

msg = g_malloc(VHOST_USER_GPU_HDR_SIZE + size);
g_return_if_fail(msg != NULL);

r = qemu_chr_fe_read_all(&g->vhost_chr,
(uint8_t *)&msg->payload, size);
Expand Down
3 changes: 1 addition & 2 deletions hw/display/virtio-gpu-3d.c
Expand Up @@ -438,7 +438,7 @@ void virtio_gpu_virgl_process_cmd(VirtIOGPU *g,
break;
case VIRTIO_GPU_CMD_RESOURCE_FLUSH:
virgl_cmd_resource_flush(g, cmd);
break;
break;
case VIRTIO_GPU_CMD_RESOURCE_UNREF:
virgl_cmd_resource_unref(g, cmd);
break;
Expand All @@ -456,7 +456,6 @@ void virtio_gpu_virgl_process_cmd(VirtIOGPU *g,
case VIRTIO_GPU_CMD_GET_CAPSET:
virgl_cmd_get_capset(g, cmd);
break;

case VIRTIO_GPU_CMD_GET_DISPLAY_INFO:
virtio_gpu_get_display_info(g, cmd);
break;
Expand Down
2 changes: 1 addition & 1 deletion hw/i386/kvm/clock.c
Expand Up @@ -162,7 +162,7 @@ static void do_kvmclock_ctrl(CPUState *cpu, run_on_cpu_data data)
}
}

static void kvmclock_vm_state_change(void *opaque, int running,
static void kvmclock_vm_state_change(void *opaque, bool running,
RunState state)
{
KVMClockState *s = opaque;
Expand Down
2 changes: 1 addition & 1 deletion hw/i386/kvm/i8254.c
Expand Up @@ -239,7 +239,7 @@ static void kvm_pit_irq_control(void *opaque, int n, int enable)
kvm_pit_put(pit);
}

static void kvm_pit_vm_state_change(void *opaque, int running,
static void kvm_pit_vm_state_change(void *opaque, bool running,
RunState state)
{
KVMPITState *s = opaque;
Expand Down
2 changes: 1 addition & 1 deletion hw/i386/kvmvapic.c
Expand Up @@ -748,7 +748,7 @@ static void do_vapic_enable(CPUState *cs, run_on_cpu_data data)
s->state = VAPIC_ACTIVE;
}

static void kvmvapic_vm_state_change(void *opaque, int running,
static void kvmvapic_vm_state_change(void *opaque, bool running,
RunState state)
{
MachineState *ms = MACHINE(qdev_get_machine());
Expand Down
2 changes: 1 addition & 1 deletion hw/i386/xen/xen-hvm.c
Expand Up @@ -1235,7 +1235,7 @@ static void xen_main_loop_prepare(XenIOState *state)
}


static void xen_hvm_change_state_handler(void *opaque, int running,
static void xen_hvm_change_state_handler(void *opaque, bool running,
RunState rstate)
{
XenIOState *state = opaque;
Expand Down
2 changes: 1 addition & 1 deletion hw/ide/core.c
Expand Up @@ -2677,7 +2677,7 @@ static void ide_restart_bh(void *opaque)
}
}

static void ide_restart_cb(void *opaque, int running, RunState state)
static void ide_restart_cb(void *opaque, bool running, RunState state)
{
IDEBus *bus = opaque;

Expand Down
2 changes: 1 addition & 1 deletion hw/intc/arm_gicv3_its_kvm.c
Expand Up @@ -71,7 +71,7 @@ static int kvm_its_send_msi(GICv3ITSState *s, uint32_t value, uint16_t devid)
*
* The tables get flushed to guest RAM whenever the VM gets stopped.
*/
static void vm_change_state_handler(void *opaque, int running,
static void vm_change_state_handler(void *opaque, bool running,
RunState state)
{
GICv3ITSState *s = (GICv3ITSState *)opaque;
Expand Down
2 changes: 1 addition & 1 deletion hw/intc/arm_gicv3_kvm.c
Expand Up @@ -743,7 +743,7 @@ static const ARMCPRegInfo gicv3_cpuif_reginfo[] = {
*
* The tables get flushed to guest RAM whenever the VM gets stopped.
*/
static void vm_change_state_handler(void *opaque, int running,
static void vm_change_state_handler(void *opaque, bool running,
RunState state)
{
GICv3State *s = (GICv3State *)opaque;
Expand Down
2 changes: 1 addition & 1 deletion hw/intc/meson.build
Expand Up @@ -14,7 +14,7 @@ softmmu_ss.add(when: 'CONFIG_HEATHROW_PIC', if_true: files('heathrow_pic.c'))
softmmu_ss.add(when: 'CONFIG_I8259', if_true: files('i8259_common.c', 'i8259.c'))
softmmu_ss.add(when: 'CONFIG_IMX', if_true: files('imx_avic.c', 'imx_gpcv2.c'))
softmmu_ss.add(when: 'CONFIG_IOAPIC', if_true: files('ioapic_common.c'))
softmmu_ss.add(when: 'CONFIG_LM32', if_true: files('lm32_pic.c'))
softmmu_ss.add(when: 'CONFIG_LM32_DEVICES', if_true: files('lm32_pic.c'))
softmmu_ss.add(when: 'CONFIG_OPENPIC', if_true: files('openpic.c'))
softmmu_ss.add(when: 'CONFIG_PL190', if_true: files('pl190.c'))
softmmu_ss.add(when: 'CONFIG_PUV3', if_true: files('puv3_intc.c'))
Expand Down
2 changes: 1 addition & 1 deletion hw/intc/spapr_xive_kvm.c
Expand Up @@ -504,7 +504,7 @@ static int kvmppc_xive_get_queues(SpaprXive *xive, Error **errp)
* runs again. If an interrupt was queued while the VM was stopped,
* simply generate a trigger.
*/
static void kvmppc_xive_change_state_handler(void *opaque, int running,
static void kvmppc_xive_change_state_handler(void *opaque, bool running,
RunState state)
{
SpaprXive *xive = opaque;
Expand Down
10 changes: 7 additions & 3 deletions hw/lm32/Kconfig
@@ -1,14 +1,18 @@
config LM32
config LM32_DEVICES
bool
select PTIMER
select PFLASH_CFI02

config MILKYMIST
bool
# FIXME: disabling it results in compile-time errors
select MILKYMIST_TMU2 if OPENGL && X11
select PTIMER
select PFLASH_CFI01
select FRAMEBUFFER
select SD
select USB_OHCI
select LM32_DEVICES

config LM32_EVR
bool
select LM32_DEVICES
select PFLASH_CFI02
2 changes: 1 addition & 1 deletion hw/lm32/meson.build
@@ -1,6 +1,6 @@
lm32_ss = ss.source_set()
# LM32 boards
lm32_ss.add(when: 'CONFIG_LM32', if_true: files('lm32_boards.c'))
lm32_ss.add(when: 'CONFIG_LM32_EVR', if_true: files('lm32_boards.c'))
lm32_ss.add(when: 'CONFIG_MILKYMIST', if_true: files('milkymist.c'))

hw_arch += {'lm32': lm32_ss}
2 changes: 1 addition & 1 deletion hw/misc/mac_via.c
Expand Up @@ -1098,7 +1098,7 @@ static void mac_via_init(Object *obj)
TYPE_ADB_BUS, DEVICE(obj), "adb.0");
}

static void postload_update_cb(void *opaque, int running, RunState state)
static void postload_update_cb(void *opaque, bool running, RunState state)
{
MacVIAState *m = MAC_VIA(opaque);

Expand Down
2 changes: 1 addition & 1 deletion hw/misc/trace-events
Expand Up @@ -127,7 +127,7 @@ npcm7xx_pwm_update_freq(const char *id, uint8_t index, uint32_t old_value, uint3
npcm7xx_pwm_update_duty(const char *id, uint8_t index, uint32_t old_value, uint32_t new_value) "%s pwm[%u] Update Duty: old_duty: %u, new_duty: %u"

# stm32f4xx_syscfg.c
stm32f4xx_syscfg_set_irq(int gpio, int line, int level) "Interupt: GPIO: %d, Line: %d; Level: %d"
stm32f4xx_syscfg_set_irq(int gpio, int line, int level) "Interrupt: GPIO: %d, Line: %d; Level: %d"
stm32f4xx_pulse_exti(int irq) "Pulse EXTI: %d"
stm32f4xx_syscfg_read(uint64_t addr) "reg read: addr: 0x%" PRIx64 " "
stm32f4xx_syscfg_write(uint64_t addr, uint64_t data) "reg write: addr: 0x%" PRIx64 " val: 0x%" PRIx64 ""
Expand Down
2 changes: 1 addition & 1 deletion hw/net/allwinner-sun8i-emac.c
Expand Up @@ -579,7 +579,7 @@ static uint64_t allwinner_sun8i_emac_read(void *opaque, hwaddr offset,
case REG_INT_STA: /* Interrupt Status */
value = s->int_sta;
break;
case REG_INT_EN: /* Interupt Enable */
case REG_INT_EN: /* Interrupt Enable */
value = s->int_en;
break;
case REG_TX_CTL_0: /* Transmit Control 0 */
Expand Down
2 changes: 1 addition & 1 deletion hw/net/e1000e_core.c
Expand Up @@ -3298,7 +3298,7 @@ e1000e_autoneg_resume(E1000ECore *core)
}

static void
e1000e_vm_state_change(void *opaque, int running, RunState state)
e1000e_vm_state_change(void *opaque, bool running, RunState state)
{
E1000ECore *core = opaque;

Expand Down
2 changes: 1 addition & 1 deletion hw/nvram/spapr_nvram.c
Expand Up @@ -217,7 +217,7 @@ static int spapr_nvram_pre_load(void *opaque)
return 0;
}

static void postload_update_cb(void *opaque, int running, RunState state)
static void postload_update_cb(void *opaque, bool running, RunState state)
{
SpaprNvram *nvram = opaque;

Expand Down
2 changes: 1 addition & 1 deletion hw/ppc/pnv_bmc.c
Expand Up @@ -233,7 +233,7 @@ static void hiomap_cmd(IPMIBmcSim *ibs, uint8_t *cmd, unsigned int cmd_len,
case HIOMAP_C_RESET:
case HIOMAP_C_LOCK:
default:
qemu_log_mask(LOG_GUEST_ERROR, "HIOMAP: unknow command %02X\n", cmd[2]);
qemu_log_mask(LOG_GUEST_ERROR, "HIOMAP: unknown command %02X\n", cmd[2]);
break;
}
}
Expand Down
2 changes: 1 addition & 1 deletion hw/ppc/pnv_xscom.c
Expand Up @@ -308,7 +308,7 @@ void pnv_xscom_add_subregion(PnvChip *chip, hwaddr offset, MemoryRegion *mr)
}

void pnv_xscom_region_init(MemoryRegion *mr,
struct Object *owner,
Object *owner,
const MemoryRegionOps *ops,
void *opaque,
const char *name,
Expand Down
2 changes: 1 addition & 1 deletion hw/ppc/ppc.c
Expand Up @@ -1059,7 +1059,7 @@ static void timebase_load(PPCTimebase *tb)
}
}

void cpu_ppc_clock_vm_state_change(void *opaque, int running,
void cpu_ppc_clock_vm_state_change(void *opaque, bool running,
RunState state)
{
PPCTimebase *tb = opaque;
Expand Down
2 changes: 1 addition & 1 deletion hw/ppc/ppc_booke.c
Expand Up @@ -317,7 +317,7 @@ static void ppc_booke_timer_reset_handle(void *opaque)
* action will be taken. To avoid this we always clear the watchdog state when
* state changes to running.
*/
static void cpu_state_change_handler(void *opaque, int running, RunState state)
static void cpu_state_change_handler(void *opaque, bool running, RunState state)
{
PowerPCCPU *cpu = opaque;
CPUPPCState *env = &cpu->env;
Expand Down
2 changes: 1 addition & 1 deletion hw/s390x/tod-kvm.c
Expand Up @@ -78,7 +78,7 @@ static void kvm_s390_tod_set(S390TODState *td, const S390TOD *tod, Error **errp)
}
}

static void kvm_s390_tod_vm_state_change(void *opaque, int running,
static void kvm_s390_tod_vm_state_change(void *opaque, bool running,
RunState state)
{
S390TODState *td = opaque;
Expand Down
2 changes: 1 addition & 1 deletion hw/scsi/scsi-bus.c
Expand Up @@ -181,7 +181,7 @@ void scsi_req_retry(SCSIRequest *req)
req->retry = true;
}

static void scsi_dma_restart_cb(void *opaque, int running, RunState state)
static void scsi_dma_restart_cb(void *opaque, bool running, RunState state)
{
SCSIDevice *s = opaque;

Expand Down
1 change: 1 addition & 0 deletions hw/scsi/scsi-disk.c
Expand Up @@ -2565,6 +2565,7 @@ static void scsi_disk_new_request_dump(uint32_t lun, uint32_t tag, uint8_t *buf)
int len = scsi_cdb_length(buf);
char *line_buffer, *p;

assert(len > 0 && len <= 16);
line_buffer = g_malloc(len * 5 + 1);

for (i = 0, p = line_buffer; i < len; i++) {
Expand Down
2 changes: 1 addition & 1 deletion hw/timer/meson.build
Expand Up @@ -19,7 +19,7 @@ softmmu_ss.add(when: 'CONFIG_HPET', if_true: files('hpet.c'))
softmmu_ss.add(when: 'CONFIG_I8254', if_true: files('i8254_common.c', 'i8254.c'))
softmmu_ss.add(when: 'CONFIG_IMX', if_true: files('imx_epit.c'))
softmmu_ss.add(when: 'CONFIG_IMX', if_true: files('imx_gpt.c'))
softmmu_ss.add(when: 'CONFIG_LM32', if_true: files('lm32_timer.c'))
softmmu_ss.add(when: 'CONFIG_LM32_DEVICES', if_true: files('lm32_timer.c'))
softmmu_ss.add(when: 'CONFIG_MILKYMIST', if_true: files('milkymist-sysctl.c'))
softmmu_ss.add(when: 'CONFIG_MIPS_CPS', if_true: files('mips_gictimer.c'))
softmmu_ss.add(when: 'CONFIG_MSF2', if_true: files('mss-timer.c'))
Expand Down

0 comments on commit 6f34661

Please sign in to comment.