Anthony Liguori | 13 Oct 20:58
Picon
Favicon

[COMMIT 930f3fe] Add some chipset doc links

From: Blue Swirl <blauwirbel@...>

Signed-off-by: Blue Swirl <blauwirbel@...>

diff --git a/hw/apb_pci.c b/hw/apb_pci.c
index 72f15af..43be7ce 100644
--- a/hw/apb_pci.c
+++ b/hw/apb_pci.c
@@ -39,6 +39,15 @@ do { printf("APB: " fmt , ## __VA_ARGS__); } while (0)
 #define APB_DPRINTF(fmt, ...)
 #endif

+/*
+ * Chipset docs:
+ * PBM: "UltraSPARC IIi User's Manual",
+ * http://www.sun.com/processors/manuals/805-0087.pdf
+ *
+ * APB: "Advanced PCI Bridge (APB) User's Manual",
+ * http://www.sun.com/processors/manuals/805-1251.pdf
+ */
+
 typedef target_phys_addr_t pci_addr_t;
 #include "pci_host.h"

diff --git a/hw/m48t59.c b/hw/m48t59.c
index 0f45071..d5a91aa 100644
--- a/hw/m48t59.c
+++ b/hw/m48t59.c
@@ -41,6 +41,14 @@
  * alarm and a watchdog timer and related control registers. In the
(Continue reading)

Anthony Liguori | 13 Oct 19:03
Picon
Favicon

[COMMIT 3723cd0] sparc64: fix done instruction pc

From: Igor V. Kovalenko <igor.v.kovalenko@...>

Fix done instruction to resume with pc=tnpc, npc=tnpc+4

Signed-off-by: Igor V. Kovalenko <igor.v.kovalenko@...>
Signed-off-by: Blue Swirl <blauwirbel@...>

diff --git a/target-sparc/op_helper.c b/target-sparc/op_helper.c
index 8992d1c..a1ada8b 100644
--- a/target-sparc/op_helper.c
+++ b/target-sparc/op_helper.c
@@ -3318,7 +3318,7 @@ void helper_done(void)
 {
     trap_state* tsptr = cpu_tsptr(env);

-    env->pc = tsptr->tpc;
+    env->pc = tsptr->tnpc;
     env->npc = tsptr->tnpc + 4;
     PUT_CCR(env, tsptr->tstate >> 32);
     env->asi = (tsptr->tstate >> 24) & 0xff;

Anthony Liguori | 13 Oct 19:03
Picon
Favicon

[COMMIT 6a8a280] user: fix libuser build messages

From: Blue Swirl <blauwirbel@...>

Signed-off-by: Blue Swirl <blauwirbel@...>

diff --git a/Makefile b/Makefile
index 7d4d75c..04e21bb 100644
--- a/Makefile
+++ b/Makefile
@@ -59,7 +59,7 @@ $(filter %-softmmu,$(SUBDIR_RULES)): libqemu_common.a
 $(filter %-user,$(SUBDIR_RULES)): libuser.a

 libuser.a:
-	$(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C libuser V="$(V)" TARGET_DIR="$*/" all,)
+	$(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C libuser V="$(V)" TARGET_DIR="libuser/" all,)

 ROMSUBDIR_RULES=$(patsubst %,romsubdir-%, $(ROMS))
 romsubdir-%:

Anthony Liguori | 13 Oct 16:17
Picon
Favicon

[COMMIT 1a4ea1e] qemu: allow pulseaudio to be the default

From: Michael S. Tsirkin <mst@...>

We're seeing various issues with the SDL audio backend and want to
switch to the pulseaudio backend. See e.g.

  https://bugzilla.redhat.com/495964
  https://bugzilla.redhat.com/519540
  https://bugzilla.redhat.com/496627

The pulseaudio backend seems to work well, so we should allow it to be
selected as the default.

Signed-off-by: Mark McLoughlin <markmc@...>
Signed-off-by: Michael S. Tsirkin <mst@...>
Signed-off-by: malc <av1474@...>

diff --git a/audio/paaudio.c b/audio/paaudio.c
index 18292eb..9118ece 100644
--- a/audio/paaudio.c
+++ b/audio/paaudio.c
@@ -519,7 +519,7 @@ struct audio_driver pa_audio_driver = {
     .init           = qpa_audio_init,
     .fini           = qpa_audio_fini,
     .pcm_ops        = &qpa_pcm_ops,
-    .can_be_default = 0,
+    .can_be_default = 1,
     .max_voices_out = INT_MAX,
     .max_voices_in  = INT_MAX,
     .voice_size_out = sizeof (PAVoiceOut),

(Continue reading)

Anthony Liguori | 12 Oct 17:19
Picon
Favicon

[COMMIT d549db5] unlock iothread mutex before running kvm ioctl

From: Glauber Costa <glommer@...>

Without this, kvm will hold the mutex while it issues its run ioctl,
and never be able to step out of it, causing a deadlock.

Patchworks-ID: 35359
Signed-off-by: Glauber Costa <glommer@...>
Signed-off-by: Anthony Liguori <aliguori@...>

diff --git a/kvm-all.c b/kvm-all.c
index 5ea0dd8..48ae26c 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -605,7 +605,9 @@ int kvm_cpu_exec(CPUState *env)
         }

         kvm_arch_pre_run(env, run);
+        qemu_mutex_unlock_iothread();
         ret = kvm_vcpu_ioctl(env, KVM_RUN, 0);
+        qemu_mutex_lock_iothread();
         kvm_arch_post_run(env, run);

         if (ret == -EINTR || ret == -EAGAIN) {
diff --git a/qemu-common.h b/qemu-common.h
index 12e7dd0..820dd37 100644
--- a/qemu-common.h
+++ b/qemu-common.h
@@ -146,6 +146,9 @@ char *qemu_strndup(const char *str, size_t size);
 void *get_mmap_addr(unsigned long size);

(Continue reading)

Anthony Liguori | 12 Oct 17:19
Picon
Favicon

[COMMIT 3c178e7] rom loader: fix sparc -kernel boot.

From: Gerd Hoffmann <kraxel@...>

Changes:
(1) register pstrcpy_targphys() in rom list, it is used for kernel
command lines by a number of architectures.
(2) add rom_ptr() function to get a pointer for applying changes
to loaded images.  Needed for example to tell the linux kernel
where it finds the initrd image by updating the header.
(3) make sparc use rom_ptr for initrd setup.

booting sparc-test works now, and 'info roms' shows this:

(qemu) info roms
addr=0000000000000000 size=0x2a3828 mem=ram name="phdr #0: vmlinux-2.6.11+tcx"
addr=00000000007ff000 size=0x00000e mem=ram name="cmdline"
addr=0000000000800000 size=0x400000 mem=ram name="/root/qemu-test/sparc-test/linux.img"
addr=0000000070000000 size=0x0e4000 mem=rom name="phdr #0: /home/kraxel/projects/qemu/build-zfull/pc-bios/openbios-sparc32"

reboot via 'system_reset' works too.

Patchworks-ID: 35262
Signed-off-by: Gerd Hoffmann <kraxel@...>
Signed-off-by: Anthony Liguori <aliguori@...>

diff --git a/hw/axis_dev88.c b/hw/axis_dev88.c
index d6f14bc..1a66649 100644
--- a/hw/axis_dev88.c
+++ b/hw/axis_dev88.c
@@ -365,7 +365,7 @@ void axisdev88_init (ram_addr_t ram_size,
             /* Let the kernel know we are modifying the cmdline.  */
(Continue reading)

Anthony Liguori | 12 Oct 17:19
Picon
Favicon

[COMMIT 0cde1b4] ide: cmd646 ->unit has just the value that we want

From: Juan Quintela <quintela@...>

Patchworks-ID: 35307
Signed-off-by: Juan Quintela <quintela@...>
Signed-off-by: Anthony Liguori <aliguori@...>

diff --git a/hw/ide/cmd646.c b/hw/ide/cmd646.c
index eb5a2e9..3b5362d 100644
--- a/hw/ide/cmd646.c
+++ b/hw/ide/cmd646.c
@@ -94,7 +94,7 @@ static uint32_t bmdma_readb(void *opaque, uint32_t addr)
         val = bm->status;
         break;
     case 3:
-        if (bm == &pci_dev->bmdma[0]) {
+        if (bm->unit == 0) {
             val = pci_dev->dev.config[UDIDETCR0];
         } else {
             val = pci_dev->dev.config[UDIDETCR1];
@@ -127,7 +127,7 @@ static void bmdma_writeb(void *opaque, uint32_t addr, uint32_t val)
         bm->status = (val & 0x60) | (bm->status & 1) | (bm->status & ~val & 0x06);
         break;
     case 3:
-        if (bm == &pci_dev->bmdma[0])
+        if (bm->unit == 0)
             pci_dev->dev.config[UDIDETCR0] = val;
         else
             pci_dev->dev.config[UDIDETCR1] = val;

(Continue reading)

Anthony Liguori | 12 Oct 17:19
Picon
Favicon

[COMMIT 2ca2078] Fixed wacom emulation

From: François Revol <revol@...>

- for absolute mode, scale coordinates to the real device maximum values,
since some drivers (on Haiku and Linux at least) need them as such,
and the HID descriptor is boggus on some models anyway,
- keep the coordinates even when no button is pressed, on real tablet
the pen is sensed on the surface even without direct contact,
and drivers expect this,
- map left button to pressure according to what the Haiku driver wants,
- map the right button to the pen button,
- map the middle button to the eraser,
- use asynchronous reporting as the hid code does, stops the Haiku driver
(and probably others) from spending 50% cpu polling for changes.

Signed-off-by: François Revol <revol@...>
Signed-off-by: Anthony Liguori <aliguori@...>

diff --git a/hw/usb-wacom.c b/hw/usb-wacom.c
index 3ea7241..fa97db2 100644
--- a/hw/usb-wacom.c
+++ b/hw/usb-wacom.c
@@ -50,6 +50,8 @@ typedef struct USBWacomState {
         WACOM_MODE_HID = 1,
         WACOM_MODE_WACOM = 2,
     } mode;
+    uint8_t idle;
+    int changed;
 } USBWacomState;

 static const uint8_t qemu_wacom_dev_descriptor[] = {
(Continue reading)

Anthony Liguori | 12 Oct 17:19
Picon
Favicon

[COMMIT b96bf49] rom loader: also try filename as-is.

From: Gerd Hoffmann <kraxel@...>

In case qemu_find_file fails try to open the file as-is.

Patchworks-ID: 35263
Signed-off-by: Gerd Hoffmann <kraxel@...>
Signed-off-by: Anthony Liguori <aliguori@...>

diff --git a/hw/loader.c b/hw/loader.c
index f38b994..7aa1a67 100644
--- a/hw/loader.c
+++ b/hw/loader.c
@@ -559,8 +559,7 @@ int rom_add_file(const char *file,
     rom->name = qemu_strdup(file);
     rom->path = qemu_find_file(QEMU_FILE_TYPE_BIOS, rom->name);
     if (rom->path == NULL) {
-        fprintf(stderr, "Could not find option rom '%s'\n", rom->name);
-        goto err;
+        rom->path = strdup(file);
     }

     fd = open(rom->path, O_RDONLY | O_BINARY);

Anthony Liguori | 12 Oct 17:19
Picon
Favicon

[COMMIT 7e07831] ide: 'secondary' field is only used by cmd646

From: Juan Quintela <quintela@...>

Patchworks-ID: 35303
Signed-off-by: Juan Quintela <quintela@...>
Signed-off-by: Anthony Liguori <aliguori@...>

diff --git a/hw/ide/pci.h b/hw/ide/pci.h
index 690d057..9377503 100644
--- a/hw/ide/pci.h
+++ b/hw/ide/pci.h
@@ -7,7 +7,7 @@ typedef struct PCIIDEState {
     PCIDevice dev;
     IDEBus bus[2];
     BMDMAState bmdma[2];
-    uint32_t secondary;
+    uint32_t secondary; /* used only for cmd646 */
 } PCIIDEState;

 void bmdma_cmd_writeb(void *opaque, uint32_t addr, uint32_t val);

Anthony Liguori | 12 Oct 17:19
Picon
Favicon

[COMMIT 61f58e5] ide: cmd646 we can get the pci device withcontainer_of

From: Juan Quintela <quintela@...>

Patchworks-ID: 35305
Signed-off-by: Juan Quintela <quintela@...>
Signed-off-by: Anthony Liguori <aliguori@...>

diff --git a/hw/ide/cmd646.c b/hw/ide/cmd646.c
index 2107209..eb5a2e9 100644
--- a/hw/ide/cmd646.c
+++ b/hw/ide/cmd646.c
@@ -68,10 +68,19 @@ static void ide_map(PCIDevice *pci_dev, int region_num,
     }
 }

+static PCIIDEState *pci_from_bm(BMDMAState *bm)
+{
+    if (bm->unit == 0) {
+        return container_of(bm, PCIIDEState, bmdma[0]);
+    } else {
+        return container_of(bm, PCIIDEState, bmdma[1]);
+    }
+}
+
 static uint32_t bmdma_readb(void *opaque, uint32_t addr)
 {
     BMDMAState *bm = opaque;
-    PCIIDEState *pci_dev;
+    PCIIDEState *pci_dev = pci_from_bm(bm);
     uint32_t val;

(Continue reading)


Gmane