Trivial patches for 2 to 7 November
These patches were mostly submitted during the 1.3 hard freeze. I'll catch up with the new trivial patches next week.
The following changes since commit 80625b97b52836b944a6438e8e3e9d992e6a00b6:
xilinx_uartlite: Accept input after rx FIFO pop (2012-12-05 09:20:36 +0100)
are available in the git repository at:
git://github.com/stefanha/qemu.git trivial-patches
for you to fetch changes up to 654598c944aa31cdbea435bd468055af9c918d16:
pc_sysfw: Plug memory leak on pc_fw_add_pflash_drv() error path (2012-12-07 12:34:12 +0100)
----------------------------------------------------------------
Markus Armbruster (2):
Clean up pci_drive_hot_add()'s use of BlockInterfaceType
pc_sysfw: Plug memory leak on pc_fw_add_pflash_drv() error path
Michal Privoznik (1):
qemu-options: Fix space at EOL
Petar Jovanovic (2):
target-mips: Fix incorrect code and test for INSV
target-mips: Fix incorrect shift for SHILO and SHILOV
Peter Crosthwaite (2):
sd: Send debug printfery to stderr not stdout
arm: a9mpcore: remove un-used ptimer_iomem field
Peter Maydell (1):
configure: Remove stray debug output
Richard Henderson (3):
target-alpha: Remove t0, t1 from CPUAlphaState
target-m68k: Remove t1 from CPUM68KState
target-sparc: Remove t0, t1 from CPUSPARCState
Stefan Weil (4):
Fix spelling (prefered -> preferred)
Fix comments (adress -> address, layed -> laid, wierd -> weird)
s390x: Spelling fixes (endianess -> endianness, occured -> occurred)
Fix spelling in comments and documentationconfigure | 4 +--- hw/a9mpcore.c | 1 - hw/device-hotplug.c | 11 ++++------- hw/pc_sysfw.c | 4 +++- hw/pci-hotplug.c | 7 +++---- hw/s390x/sclp.h | 4 ++-- hw/s390x/sclpconsole.c | 4 ++-- hw/sd.c | 4 ++-- hw/usb.h | 6 +++--- net/tap-win32.c | 7 ++++--- qemu-options.hx | 2 +- slirp/ip_icmp.c | 2 +- sysemu.h | 3 +-- target-alpha/cpu.h | 7 ------- target-m68k/cpu.h | 3 --- target-mips/dsp_helper.c | 19 ++++++++++--------- target-sparc/cpu.h | 1 - tcg/tcg.h | 4 ++-- tests/qemu-iotests/iotests.py | 2 +- tests/tcg/mips/mips32-dsp/insv.c | 2 +- tests/tcg/mips/mips32-dsp/shilo.c | 18 ++++++++++++++++++ tests/tcg/mips/mips32-dsp/shilov.c | 20 ++++++++++++++++++++ uri.c | 4 ++-- 23 files changed, 81 insertions(+), 58 deletions(-)
Signature · 1 line
1.8.0.1
PATCH 1/13 sd: Send debug printfery to stderr not stdout
From: Peter Crosthwaite <[email protected]>
Some debug printfs for SD are coming up in stdout. Redirected them to stderr instead.
--- hw/sd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
hw/sd.c +2 -2
@@ -1439,8 +1439,8 @@ send_response:int i;DPRINTF ("Response:" );for (i =0 ; i < rsplen; i++) -printf (" %02x" , response[i]); -printf (" state %d\n" , sd->state); +fprintf (stderr," %02x" , response[i]); +fprintf (stderr," state %d\n" , sd->state); }else {DPRINTF ("No response %d\n" , sd->state); }
Signature · 1 line
1.8.0.1
PATCH 2/13 configure: Remove stray debug output
In reply to Stefan HajnocziFrom: Peter Maydell <[email protected]>
Rather than printing a message saying we're silently falling back to gthread coroutines when running on MacOS, actually do it silently.
--- configure | 2 -- 1 file changed, 2 deletions(-)
configure +0 -2
@@ -2969,8 +2969,6 @@ EOF else coroutine_backend=gthread fi - else - echo "Silently falling back into gthread backend under darwin" fi elif test "$coroutine" = "gthread" ; then coroutine_backend=gthread
Signature · 1 line
1.8.0.1
PATCH 3/13 Fix spelling (prefered -> preferred)
In reply to Stefan HajnocziFrom: Stefan Weil <[email protected]>
--- configure | 2 +- net/tap-win32.c | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-)
configure +1 -1
@@ -2130,7 +2130,7 @@ if test "$pixman" = "system"; then else if test ! -d ${source_path}/pixman/pixman; then echo "ERROR: pixman not present. Your options:" - echo " (1) Prefered: Install the pixman devel package (any recent" + echo " (1) Preferred: Install the pixman devel package (any recent" echo " distro should have packages as Xorg needs pixman too)." echo " (2) Fetch the pixman submodule, using:" echo " git submodule update --init pixman"
net/tap-win32.c +4 -3
@@ -565,7 +565,7 @@ static void tap_win32_free_buffer(tap_win32_overlapped_t *overlapped, }static int tap_win32_open (tap_win32_overlapped_t **phandle, -const char *prefered_name) +const char *preferred_name) {char device_path[256 ];char device_guid[0x100 ];
@@ -581,8 +581,9 @@ static int tap_win32_open(tap_win32_overlapped_t **phandle,DWORD version_len;DWORD idThread; -if (prefered_name !=NULL ) -snprintf (name_buffer,sizeof (name_buffer),"%s" , prefered_name); +if (preferred_name !=NULL ) { +snprintf (name_buffer,sizeof (name_buffer),"%s" , preferred_name); + } rc =get_device_guid (device_guid,sizeof (device_guid), name_buffer,sizeof (name_buffer));if (rc)
Signature · 1 line
1.8.0.1
PATCH 4/13 Fix comments (adress -> address, layed -> laid, wierd -> weird)
In reply to Stefan HajnocziFrom: Stefan Weil <[email protected]>
Remove also a duplicated 'the'.
--- slirp/ip_icmp.c | 2 +- tcg/tcg.h | 4 ++-- uri.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-)
slirp/ip_icmp.c +1 -1
@@ -352,7 +352,7 @@ icmp_error(struct mbuf *msrc, u_char type, u_char code, int minsize, ip->ip_ttl =MAXTTL ; ip->ip_p =IPPROTO_ICMP ; - ip->ip_dst = ip->ip_src;/* ip adresses */ + ip->ip_dst = ip->ip_src;/* ip addresses */ ip->ip_src = m->slirp->vhost_addr; (void )ip_output ((struct socket *)NULL , m);
tcg/tcg.h +2 -2
@@ -290,8 +290,8 @@ typedef int TCGv_i64;#define TCG_CALL_DUMMY_TCGV MAKE_TCGV_I32(-1)#define TCG_CALL_DUMMY_ARG ((TCGArg)(-1)) -/* Conditions. Note that these are layed out for easy manipulation by -the the functions below: +/* Conditions. Note that these are laid out for easy manipulation by +the functions below: bit 0 is used for inverting; bit 1 is signed, bit 2 is unsigned,
uri.c +2 -2
@@ -432,7 +432,7 @@ rfc3986_parse_host(URI *uri, const char **str) host = cur;/* -* IPv6 and future adressing scheme are enclosed between brackets +* IPv6 and future addressing scheme are enclosed between brackets */ if (*cur =='[' ) { cur++;
@@ -1917,7 +1917,7 @@ done:* http://site1.com/docs/pic1.gif http://site1.com/docs/pic1.gif * * -* Note: if the URI reference is really wierd or complicated, it may be +* Note: if the URI reference is really weird or complicated, it may be * worthwhile to first convert it into a "nice" one by calling * uri_resolve (using 'base') before calling this routine, * since this routine (for reasonable efficiency) assumes URI has
Signature · 1 line
1.8.0.1
PATCH 5/13 s390x: Spelling fixes (endianess -> endianness, occured -> occurred)
In reply to Stefan HajnocziFrom: Stefan Weil <[email protected]>
Replace also "write into" by "write to".
--- hw/s390x/sclp.h | 4 ++-- hw/s390x/sclpconsole.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
hw/s390x/sclp.h +2 -2
@@ -51,7 +51,7 @@/* * Normally packed structures are not the right thing to do, since all code -* must take care of endianess. We cant use ldl_phys and friends for two +* must take care of endianness. We cannot use ldl_phys and friends for two * reasons, though: * - some of the embedded structures below the SCCB can appear multiple times * at different locations, so there is no fixed offset
@@ -60,7 +60,7 @@* alter the structure while we parse it. We cannot use ldl_p and friends * either without doing pointer arithmetics * So we have to double check that all users of sclp data structures use the -* right endianess wrappers. +* right endianness wrappers. */ typedef struct SCCBHeader { uint16_t length;
hw/s390x/sclpconsole.c +2 -2
@@ -179,8 +179,8 @@ static int read_event_data(SCLPEvent *event, EventBufferHeader *evt_buf_hdr, }/* triggered by SCLP's write_event_data -* - write console data into character layer -* returns < 0 if an error occured +* - write console data to character layer +* returns < 0 if an error occurred */ static ssize_t write_console_data (SCLPEvent *event,const uint8_t *buf,size_t len)
Signature · 1 line
1.8.0.1
PATCH 6/13 target-alpha: Remove t0, t1 from CPUAlphaState
In reply to Stefan HajnocziFrom: Richard Henderson <[email protected]>
These fields are no longer (or were never?) used.
--- target-alpha/cpu.h | 7 ------- 1 file changed, 7 deletions(-)
target-alpha/cpu.h +0 -7
@@ -280,13 +280,6 @@ struct CPUAlphaState {struct QEMUTimer *alarm_timer;uint64_t alarm_expire; -#if TARGET_LONG_BITS >HOST_LONG_BITS -/* temporary fixed-point registers -* used to emulate 64 bits target on 32 bits hosts -*/ -target_ulong t0, t1; -#endif -/* Those resources are used only in QEMU core */ CPU_COMMON
Signature · 1 line
1.8.0.1
PATCH 7/13 target-m68k: Remove t1 from CPUM68KState
In reply to Stefan HajnocziFrom: Richard Henderson <[email protected]>
This field is no longer used.
--- target-m68k/cpu.h | 3 --- 1 file changed, 3 deletions(-)
target-m68k/cpu.h +0 -3
@@ -103,9 +103,6 @@ typedef struct CPUM68KState {uint32_t rambar0;uint32_t cacr; -/* ??? remove this. */ -uint32_t t1; -int pending_vector;int pending_level;
Signature · 1 line
1.8.0.1
PATCH 8/13 target-sparc: Remove t0, t1 from CPUSPARCState
In reply to Stefan HajnocziFrom: Richard Henderson <[email protected]>
These fields are no longer used.
--- target-sparc/cpu.h | 1 - 1 file changed, 1 deletion(-)
target-sparc/cpu.h +0 -1
@@ -392,7 +392,6 @@ struct CPUSPARCState {target_ulong cc_dst;uint32_t cc_op; -target_ulong t0, t1;/* temporaries live across basic blocks */ target_ulong cond;/* conditional branch result (XXX: save it in a temporary register when possible) */
Signature · 1 line
1.8.0.1
PATCH 9/13 arm: a9mpcore: remove un-used ptimer_iomem field
In reply to Stefan HajnocziFrom: Peter Crosthwaite <[email protected]>
I'm guessing this is a hangover from a previous coreification of the mptimer sub-module. This field is completely unused - removed.
--- hw/a9mpcore.c | 1 - 1 file changed, 1 deletion(-)
hw/a9mpcore.c +0 -1
@@ -19,7 +19,6 @@ typedef struct a9mp_priv_state {uint32_t old_timer_status[8 ];uint32_t num_cpu;MemoryRegion scu_iomem; -MemoryRegion ptimer_iomem;MemoryRegion container;DeviceState *mptimer;DeviceState *gic;
Signature · 1 line
1.8.0.1
PATCH 10/13 Clean up pci_drive_hot_add()'s use of BlockInterfaceType
In reply to Stefan HajnocziFrom: Markus Armbruster <[email protected]>
pci_drive_hot_add() parameter type has the wrong type: int instead of BlockInterfaceType. It's actually redundant, so we can just drop it.
--- hw/device-hotplug.c | 11 ++++------- hw/pci-hotplug.c | 7 +++---- sysemu.h | 3 +-- 3 files changed, 8 insertions(+), 13 deletions(-)
hw/device-hotplug.c +4 -7
@@ -49,18 +49,16 @@ DriveInfo *add_init_drive(const char *optstr) }#if !defined(TARGET_I386 ) -int pci_drive_hot_add (Monitor *mon,const QDict *qdict, -DriveInfo *dinfo,int type) +int pci_drive_hot_add (Monitor *mon,const QDict *qdict,DriveInfo *dinfo) {/* On non-x86 we don't do PCI hotplug */ -monitor_printf (mon,"Can't hot-add drive to type %d\n" , type); +monitor_printf (mon,"Can't hot-add drive to type %d\n" , dinfo->type);return -1 ; }#endif void drive_hot_add (Monitor *mon,const QDict *qdict) { -int type;DriveInfo *dinfo =NULL ;const char *opts =qdict_get_str (qdict,"opts" );
@@ -72,14 +70,13 @@ void drive_hot_add(Monitor *mon, const QDict *qdict)monitor_printf (mon,"Parameter addr not supported\n" ); goto err; } - type = dinfo->type; -switch (type) { +switch (dinfo->type) {case IF_NONE :monitor_printf (mon,"OK\n" );break ;default : -if (pci_drive_hot_add (mon, qdict, dinfo, type)) { +if (pci_drive_hot_add (mon, qdict, dinfo)) { goto err; } }
hw/pci-hotplug.c +3 -4
@@ -111,15 +111,14 @@ static int scsi_hot_add(Monitor *mon, DeviceState *adapter,return 0 ; } -int pci_drive_hot_add (Monitor *mon,const QDict *qdict, -DriveInfo *dinfo,int type) +int pci_drive_hot_add (Monitor *mon,const QDict *qdict,DriveInfo *dinfo) {int dom, pci_bus;unsigned slot;PCIDevice *dev;const char *pci_addr =qdict_get_str (qdict,"pci_addr" ); -switch (type) { +switch (dinfo->type) {case IF_SCSI :if (pci_read_devaddr (mon, pci_addr, &dom, &pci_bus, &slot)) { goto err;
@@ -135,7 +134,7 @@ int pci_drive_hot_add(Monitor *mon, const QDict *qdict, }break ;default : -monitor_printf (mon,"Can't hot-add drive to type %d\n" , type); +monitor_printf (mon,"Can't hot-add drive to type %d\n" , dinfo->type); goto err; }
sysemu.h +1 -2
@@ -145,8 +145,7 @@ extern unsigned int nb_prom_envs;/* pci-hotplug */ void pci_device_hot_add (Monitor *mon,const QDict *qdict); -int pci_drive_hot_add (Monitor *mon,const QDict *qdict, -DriveInfo *dinfo,int type); +int pci_drive_hot_add (Monitor *mon,const QDict *qdict,DriveInfo *dinfo);void do_pci_device_hot_remove (Monitor *mon,const QDict *qdict);/* generic hotplug */
Signature · 1 line
1.8.0.1
PATCH 11/13 Fix spelling in comments and documentation
In reply to Stefan HajnocziFrom: Stefan Weil <[email protected]>
These spelling bugs were found by codespell:
supressing -> suppressing
transfered -> transferred
--- hw/usb.h | 6 +++--- tests/qemu-iotests/iotests.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)
hw/usb.h +3 -3
@@ -282,7 +282,7 @@ typedef struct USBDeviceClass {* Called from handle_packet(). * * Status gets stored in p->status, and if p->status == USB_RET_SUCCESS -* then the number of bytes transfered is stored in p->actual_length +* then the number of bytes transferred is stored in p->actual_length */ void (*handle_control)(USBDevice *dev,USBPacket *p,int request,int value,int index,int length,uint8_t *data);
@@ -292,7 +292,7 @@ typedef struct USBDeviceClass {* Called from handle_packet(). * * Status gets stored in p->status, and if p->status == USB_RET_SUCCESS -* then the number of bytes transfered is stored in p->actual_length +* then the number of bytes transferred is stored in p->actual_length */ void (*handle_data)(USBDevice *dev,USBPacket *p);
@@ -358,7 +358,7 @@ struct USBPacket {bool short_not_ok;bool int_req;int status;/* USB_RET_* status code */ -int actual_length;/* Number of bytes actually transfered */ +int actual_length;/* Number of bytes actually transferred */ /* Internal use by the USB layer. */ USBPacketState state;USBCombinedPacket *combined;
tests/qemu-iotests/iotests.py +1 -1
@@ -43,7 +43,7 @@ def qemu_img(*args): return subprocess.call(qemu_img_args + list(args), stdin=devnull, stdout=devnull) def qemu_img_verbose(*args): - '''Run qemu-img without supressing its output and return the exit code''' + '''Run qemu-img without suppressing its output and return the exit code''' return subprocess.call(qemu_img_args + list(args)) def qemu_io(*args):
Signature · 1 line
1.8.0.1
PATCH 12/13 qemu-options: Fix space at EOL
In reply to Stefan HajnocziFrom: Michal Privoznik <[email protected]>
There's no need to add a space at the end of line. Moreover, it can make problems in some projects that store the help output into a file (and run couple of tests based on that) and have space at EOL forbidden.
--- qemu-options.hx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
qemu-options.hx +1 -1
@@ -1331,7 +1331,7 @@ DEF("net", HAS_ARG, QEMU_OPTION_net, " connect the host TAP network interface to VLAN 'n'\n" #else "-net tap[,vlan=n][,name=str][,fd=h][,ifname=name][,script=file][,downscript=dfile][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off][,vhostfd=h][,vhostforce=on|off]\n" - " connect the host TAP network interface to VLAN 'n' \n" + " connect the host TAP network interface to VLAN 'n'\n" " use network scripts 'file' (default=" DEFAULT_NETWORK_SCRIPT ")\n" " to configure it and 'dfile' (default=" DEFAULT_NETWORK_DOWN_SCRIPT ")\n" " to deconfigure it\n"
Signature · 1 line
1.8.0.1
PATCH 13/13 pc_sysfw: Plug memory leak on pc_fw_add_pflash_drv() error path
In reply to Stefan HajnocziFrom: Markus Armbruster <[email protected]>
Harmless, because we the error inevitably leads to another, fatal one in pc_system_flash_init(): PC system firmware (pflash) not available. Fix it anyway.
--- hw/pc_sysfw.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
hw/pc_sysfw.c +3 -1
@@ -98,7 +98,9 @@ static void pc_fw_add_pflash_drv(void)return ; } -drive_init (opts, machine->use_scsi); +if (!drive_init (opts, machine->use_scsi)) { +qemu_opts_del (opts); + } } static void pc_system_flash_init(MemoryRegion *rom_memory,
Signature · 1 line
1.8.0.1
Quoted 11 lines · Stefan Hajnoczi
These patches were mostly submitted during the 1.3 hard freeze. I'll catch up with the new trivial patches next week.
The following changes since commit
80625b97b52836b944a6438e8e3e9d992e6a00b6:
xilinx_uartlite: Accept input after rx FIFO pop (2012-12-05 09:20:36 +0100)are available in the git repository at:
git://github.com/stefanha/qemu.gittrivial-patches
Pulled. Thanks.
Regards,
Anthony Liguori
Quoted 61 lines
for you to fetch changes up to
654598c944aa31cdbea435bd468055af9c918d16:
pc_sysfw: Plug memory leak onpc_fw_add_pflash_drv()error path (2012-12-07 12:34:12 +0100)----------------------------------------------------------------
Markus Armbruster (2):
Clean up pci_drive_hot_add()'s use of BlockInterfaceType
pc_sysfw: Plug memory leak onpc_fw_add_pflash_drv()error pathMichal Privoznik (1):
qemu-options: Fix space at EOLPetar Jovanovic (2):
target-mips: Fix incorrect code and test for INSV
target-mips: Fix incorrect shift for SHILO and SHILOVPeter Crosthwaite (2):
sd: Send debug printfery to stderr not stdout
arm: a9mpcore: remove un-usedptimer_iomemfieldPeter Maydell (1):
configure: Remove stray debug outputRichard Henderson (3):
target-alpha: Remove t0, t1 from CPUAlphaState
target-m68k: Remove t1 from CPUM68KState
target-sparc: Remove t0, t1 from CPUSPARCStateStefan Weil (4):
Fix spelling (prefered -> preferred) Fix comments (adress -> address, layed -> laid, wierd -> weird) s390x: Spelling fixes (endianess -> endianness, occured -> occurred) Fix spelling in comments and documentationconfigure | 4 +--- hw/a9mpcore.c | 1 - hw/device-hotplug.c | 11 ++++------- hw/pc_sysfw.c | 4 +++- hw/pci-hotplug.c | 7 +++---- hw/s390x/sclp.h | 4 ++-- hw/s390x/sclpconsole.c | 4 ++-- hw/sd.c | 4 ++-- hw/usb.h | 6 +++--- net/tap-win32.c | 7 ++++--- qemu-options.hx | 2 +- slirp/ip_icmp.c | 2 +- sysemu.h | 3 +-- target-alpha/cpu.h | 7 ------- target-m68k/cpu.h | 3 --- target-mips/dsp_helper.c | 19 ++++++++++--------- target-sparc/cpu.h | 1 - tcg/tcg.h | 4 ++-- tests/qemu-iotests/iotests.py | 2 +- tests/tcg/mips/mips32-dsp/insv.c | 2 +- tests/tcg/mips/mips32-dsp/shilo.c | 18 ++++++++++++++++++ tests/tcg/mips/mips32-dsp/shilov.c | 20 ++++++++++++++++++++ uri.c | 4 ++-- 23 files changed, 81 insertions(+), 58 deletions(-)Signature · 1 line
1.8.0.1