Skip to content
Snippets Groups Projects
Commit 0002c3a6 authored by Philippe Mathieu-Daudé's avatar Philippe Mathieu-Daudé Committed by Jason Wang
Browse files

hw/net/smc91c111: Let smc91c111_can_receive() return a boolean


The smc91c111_can_receive() function simply returns a boolean value.

Signed-off-by: default avatarPhilippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: default avatarAlistair Francis <alistair.francis@wdc.com>
Reviewed-by: default avatarCédric Le Goater <clg@kaod.org>
Signed-off-by: default avatarJason Wang <jasowang@redhat.com>
parent 205ce567
No related branches found
No related tags found
No related merge requests found
......@@ -130,16 +130,16 @@ static void smc91c111_update(smc91c111_state *s)
qemu_set_irq(s->irq, level);
}
static int smc91c111_can_receive(smc91c111_state *s)
static bool smc91c111_can_receive(smc91c111_state *s)
{
if ((s->rcr & RCR_RXEN) == 0 || (s->rcr & RCR_SOFT_RST)) {
return 1;
return true;
}
if (s->allocated == (1 << NUM_PACKETS) - 1 ||
s->rx_fifo_len == NUM_PACKETS) {
return 0;
return false;
}
return 1;
return true;
}
static inline void smc91c111_flush_queued_packets(smc91c111_state *s)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment