aboutsummaryrefslogtreecommitdiff
path: root/hw
diff options
context:
space:
mode:
authorBlue Swirl <blauwirbel@gmail.com>2010-09-18 07:01:48 +0000
committerBlue Swirl <blauwirbel@gmail.com>2010-09-18 07:01:48 +0000
commit3ffd710e12ce64478abc027e92fe94e1089ac91c (patch)
treeac9c7acb10abd4ecee917c2ed7b1f770f8126963 /hw
parenta21493e00952e5d7cd948951f2677b0d0e465ccd (diff)
downloadqemu-3ffd710e12ce64478abc027e92fe94e1089ac91c.zip
qemu-3ffd710e12ce64478abc027e92fe94e1089ac91c.tar.gz
qemu-3ffd710e12ce64478abc027e92fe94e1089ac91c.tar.bz2
Use gcc warning flag -Wempty-body
If the compiler supports the warning flag -Wempty-body, use it. Adjust the code to avoid the warnings. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Diffstat (limited to 'hw')
-rw-r--r--hw/omap_i2c.c5
-rw-r--r--hw/omap_mmc.c5
-rw-r--r--hw/pxa2xx.c5
-rw-r--r--hw/soc_dma.c5
4 files changed, 12 insertions, 8 deletions
diff --git a/hw/omap_i2c.c b/hw/omap_i2c.c
index d7c1888..d133977 100644
--- a/hw/omap_i2c.c
+++ b/hw/omap_i2c.c
@@ -190,8 +190,9 @@ static uint32_t omap_i2c_read(void *opaque, target_phys_addr_t addr)
if (s->rxlen > 2)
s->fifo >>= 16;
s->rxlen -= 2;
- } else
- /* XXX: remote access (qualifier) error - what's that? */;
+ } else {
+ /* XXX: remote access (qualifier) error - what's that? */
+ }
if (!s->rxlen) {
s->stat &= ~(1 << 3); /* RRDY */
if (((s->control >> 10) & 1) && /* MST */
diff --git a/hw/omap_mmc.c b/hw/omap_mmc.c
index 15cbf06..9d167ff 100644
--- a/hw/omap_mmc.c
+++ b/hw/omap_mmc.c
@@ -559,8 +559,9 @@ static void omap_mmc_cover_cb(void *opaque, int line, int level)
if (!host->cdet_state && level) {
host->status |= 0x0002;
omap_mmc_interrupts_update(host);
- if (host->cdet_wakeup)
- /* TODO: Assert wake-up */;
+ if (host->cdet_wakeup) {
+ /* TODO: Assert wake-up */
+ }
}
if (host->cdet_state != level) {
diff --git a/hw/pxa2xx.c b/hw/pxa2xx.c
index 88f61c0..6e04645 100644
--- a/hw/pxa2xx.c
+++ b/hw/pxa2xx.c
@@ -1877,8 +1877,9 @@ static void pxa2xx_fir_write(void *opaque, target_phys_addr_t addr,
s->control[0] = value;
if (!(value & (1 << 4))) /* RXE */
s->rx_len = s->rx_start = 0;
- if (!(value & (1 << 3))) /* TXE */
- /* Nop */;
+ if (!(value & (1 << 3))) { /* TXE */
+ /* Nop */
+ }
s->enable = value & 1; /* ITR */
if (!s->enable)
s->status[0] = 0;
diff --git a/hw/soc_dma.c b/hw/soc_dma.c
index e116e63..23ec516 100644
--- a/hw/soc_dma.c
+++ b/hw/soc_dma.c
@@ -192,12 +192,13 @@ static void soc_dma_ch_freq_update(struct dma_s *s)
if (s->enabled_count)
/* We completely ignore channel priorities and stuff */
s->channel_freq = s->soc.freq / s->enabled_count;
- else
+ else {
/* TODO: Signal that we want to disable the functional clock and let
* the platform code decide what to do with it, i.e. check that
* auto-idle is enabled in the clock controller and if we are stopping
* the clock, do the same with any parent clocks that had only one
- * user keeping them on and auto-idle enabled. */;
+ * user keeping them on and auto-idle enabled. */
+ }
}
void soc_dma_set_request(struct soc_dma_ch_s *ch, int level)