]> git.proxmox.com Git - qemu.git/commitdiff
Restore consistent formatting of audio devices
authormalc <av1474@comtv.ru>
Sat, 20 Jun 2009 01:13:29 +0000 (05:13 +0400)
committermalc <av1474@comtv.ru>
Sat, 20 Jun 2009 01:13:29 +0000 (05:13 +0400)
hw/ac97.c
hw/adlib.c
hw/cs4231a.c
hw/es1370.c
hw/sb16.c

index a70bb9074fc74ecfabb68eadb704cdd25db3d302..b911308eb67ffb840bf2744a6ab49dca488d38d8 100644 (file)
--- a/hw/ac97.c
+++ b/hw/ac97.c
@@ -278,12 +278,12 @@ static void update_sr (AC97LinkState *s, AC97BusMasterRegs *r, uint32_t new_sr)
     if (level) {
         s->glob_sta |= masks[r - s->bm_regs];
         dolog ("set irq level=1\n");
-        qemu_set_irq(s->pci_dev->irq[0], 1);
+        qemu_set_irq (s->pci_dev->irq[0], 1);
     }
     else {
         s->glob_sta &= ~masks[r - s->bm_regs];
         dolog ("set irq level=0\n");
-        qemu_set_irq(s->pci_dev->irq[0], 0);
+        qemu_set_irq (s->pci_dev->irq[0], 0);
     }
 }
 
@@ -1331,8 +1331,8 @@ int ac97_init (PCIBus *bus)
     s = &d->ac97;
     s->pci_dev = &d->dev;
     c = d->dev.config;
-    pci_config_set_vendor_id(c, PCI_VENDOR_ID_INTEL); /* ro */
-    pci_config_set_device_id(c, PCI_DEVICE_ID_INTEL_82801AA_5); /* ro */
+    pci_config_set_vendor_id (c, PCI_VENDOR_ID_INTEL); /* ro */
+    pci_config_set_device_id (c, PCI_DEVICE_ID_INTEL_82801AA_5); /* ro */
 
     c[0x04] = 0x00;      /* pcicmd pci command rw, ro */
     c[0x05] = 0x00;
@@ -1342,7 +1342,7 @@ int ac97_init (PCIBus *bus)
 
     c[0x08] = 0x01;      /* rid revision ro */
     c[0x09] = 0x00;      /* pi programming interface ro */
-    pci_config_set_class(c, PCI_CLASS_MULTIMEDIA_AUDIO); /* ro */
+    pci_config_set_class (c, PCI_CLASS_MULTIMEDIA_AUDIO); /* ro */
     c[PCI_HEADER_TYPE] = PCI_HEADER_TYPE_NORMAL; /* headtyp header type ro */
 
     c[0x10] = 0x01;      /* nabmar native audio mixer base
index ea46931bc6c8234562ae531c7026b73cf6c8c920..e1e40771a6a7a65e55866184419d977f3ecb91e2 100644 (file)
@@ -115,7 +115,7 @@ static void adlib_kill_timers (AdlibState *s)
     }
 }
 
-static IO_WRITE_PROTO(adlib_write)
+static IO_WRITE_PROTO (adlib_write)
 {
     AdlibState *s = opaque;
     int a = nport & 3;
@@ -133,7 +133,7 @@ static IO_WRITE_PROTO(adlib_write)
 #endif
 }
 
-static IO_READ_PROTO(adlib_read)
+static IO_READ_PROTO (adlib_read)
 {
     AdlibState *s = opaque;
     uint8_t data;
index d08d7c39f934ff461e253ae2bb8321142bc519e7..ab3158e34d41c5a4af0a10124309e0a3766f0415 100644 (file)
@@ -216,7 +216,7 @@ static int16_t ALawDecompressTable[256] =
       944,   912,  1008,   976,   816,   784,   880,   848
 };
 
-static void cs_reset(void *opaque)
+static void cs_reset (void *opaque)
 {
     CSState *s = opaque;
 
@@ -597,23 +597,23 @@ static int cs_dma_read (void *opaque, int nchan, int dma_pos, int dma_len)
     return dma_pos;
 }
 
-static void cs_save(QEMUFile *f, void *opaque)
+static void cs_save (QEMUFile *f, void *opaque)
 {
     CSState *s = opaque;
     unsigned int i;
     uint32_t val;
 
     for (i = 0; i < CS_REGS; i++)
-        qemu_put_be32s(f, &s->regs[i]);
+        qemu_put_be32s (f, &s->regs[i]);
 
-    qemu_put_buffer(f, s->dregs, CS_DREGS);
-    val = s->dma_running; qemu_put_be32s(f, &val);
-    val = s->audio_free;  qemu_put_be32s(f, &val);
-    val = s->transferred; qemu_put_be32s(f, &val);
-    val = s->aci_counter; qemu_put_be32s(f, &val);
+    qemu_put_buffer (f, s->dregs, CS_DREGS);
+    val = s->dma_running; qemu_put_be32s (f, &val);
+    val = s->audio_free;  qemu_put_be32s (f, &val);
+    val = s->transferred; qemu_put_be32s (f, &val);
+    val = s->aci_counter; qemu_put_be32s (f, &val);
 }
 
-static int cs_load(QEMUFile *f, void *opaque, int version_id)
+static int cs_load (QEMUFile *f, void *opaque, int version_id)
 {
     CSState *s = opaque;
     unsigned int i;
@@ -623,14 +623,14 @@ static int cs_load(QEMUFile *f, void *opaque, int version_id)
         return -EINVAL;
 
     for (i = 0; i < CS_REGS; i++)
-        qemu_get_be32s(f, &s->regs[i]);
+        qemu_get_be32s (f, &s->regs[i]);
 
-    qemu_get_buffer(f, s->dregs, CS_DREGS);
+    qemu_get_buffer (f, s->dregs, CS_DREGS);
 
-    qemu_get_be32s(f, &dma_running);
-    qemu_get_be32s(f, &val); s->audio_free  = val;
-    qemu_get_be32s(f, &val); s->transferred = val;
-    qemu_get_be32s(f, &val); s->aci_counter = val;
+    qemu_get_be32s (f, &dma_running);
+    qemu_get_be32s (f, &val); s->audio_free  = val;
+    qemu_get_be32s (f, &val); s->transferred = val;
+    qemu_get_be32s (f, &val); s->aci_counter = val;
     if (dma_running && (s->dregs[Interface_Configuration] & PEN))
         cs_reset_voices (s, s->dregs[FS_And_Playback_Data_Format]);
     return 0;
index 9a88baf6e762f72350cc2b9ac22536f4f6ac228b..af2667be414b6b3a4df4e47f9b1e297790d169c8 100644 (file)
@@ -327,7 +327,7 @@ static void es1370_update_status (ES1370State *s, uint32_t new_status)
     else {
         s->status = new_status & ~STAT_INTR;
     }
-    qemu_set_irq(s->pci_dev->irq[0], !!level);
+    qemu_set_irq (s->pci_dev->irq[0], !!level);
 }
 
 static void es1370_reset (ES1370State *s)
@@ -353,7 +353,7 @@ static void es1370_reset (ES1370State *s)
             s->dac_voice[i] = NULL;
         }
     }
-    qemu_irq_lower(s->pci_dev->irq[0]);
+    qemu_irq_lower (s->pci_dev->irq[0]);
 }
 
 static void es1370_maybe_lower_irq (ES1370State *s, uint32_t sctl)
@@ -1026,10 +1026,10 @@ int es1370_init (PCIBus *bus)
     }
 
     c = d->dev.config;
-    pci_config_set_vendor_id(c, PCI_VENDOR_ID_ENSONIQ);
-    pci_config_set_device_id(c, PCI_DEVICE_ID_ENSONIQ_ES1370);
+    pci_config_set_vendor_id (c, PCI_VENDOR_ID_ENSONIQ);
+    pci_config_set_device_id (c, PCI_DEVICE_ID_ENSONIQ_ES1370);
     c[0x07] = 2 << 1;
-    pci_config_set_class(c, PCI_CLASS_MULTIMEDIA_AUDIO);
+    pci_config_set_class (c, PCI_CLASS_MULTIMEDIA_AUDIO);
 
 #if 1
     c[0x2c] = 0x42;
index 218c0bac9da1a84cb6a3c2a7b1bc3be877c6e91d..2506d982f2e36df0f295147be425f4cc328b5b31 100644 (file)
--- a/hw/sb16.c
+++ b/hw/sb16.c
@@ -1066,14 +1066,14 @@ static void reset_mixer (SB16State *s)
     }
 }
 
-static IO_WRITE_PROTO(mixer_write_indexb)
+static IO_WRITE_PROTO (mixer_write_indexb)
 {
     SB16State *s = opaque;
     (void) nport;
     s->mixer_nreg = val;
 }
 
-static IO_WRITE_PROTO(mixer_write_datab)
+static IO_WRITE_PROTO (mixer_write_datab)
 {
     SB16State *s = opaque;
 
@@ -1129,13 +1129,13 @@ static IO_WRITE_PROTO(mixer_write_datab)
     s->mixer_regs[s->mixer_nreg] = val;
 }
 
-static IO_WRITE_PROTO(mixer_write_indexw)
+static IO_WRITE_PROTO (mixer_write_indexw)
 {
     mixer_write_indexb (opaque, nport, val & 0xff);
     mixer_write_datab (opaque, nport, (val >> 8) & 0xff);
 }
 
-static IO_READ_PROTO(mixer_read)
+static IO_READ_PROTO (mixer_read)
 {
     SB16State *s = opaque;