From a1c2bbc87b227dbf8e00b9684544eff9c861fcf7 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Wed, 14 Sep 2016 11:57:53 +0200 Subject: bt-hci-csr: drop unused argument Signed-off-by: Paolo Bonzini Signed-off-by: Michael Tokarev --- include/hw/bt.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/hw/bt.h b/include/hw/bt.h index 963f330138..2fa22bdab6 100644 --- a/include/hw/bt.h +++ b/include/hw/bt.h @@ -128,7 +128,7 @@ enum { __csrhci_pins, }; qemu_irq *csrhci_pins_get(CharDriverState *chr); -CharDriverState *uart_hci_init(qemu_irq wakeup); +CharDriverState *uart_hci_init(void); /* bt-l2cap.c */ struct bt_l2cap_device_s; -- cgit v1.2.3 From cb57fb37051b11d04f1ddce736b0ec3f936e978e Mon Sep 17 00:00:00 2001 From: Wei Yang Date: Sat, 5 Mar 2016 13:47:08 +0000 Subject: bitmap: refine and move BITMAP_{FIRST/LAST}_WORD_MASK According to linux kernel commit <89c1e79eb30> ("linux/bitmap.h: improve BITMAP_{LAST,FIRST}_WORD_MASK"), these two macro could be improved. This patch takes this change and also move them all in header file. Signed-off-by: Wei Yang Signed-off-by: Michael Tokarev --- include/qemu/bitmap.h | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'include') diff --git a/include/qemu/bitmap.h b/include/qemu/bitmap.h index 7247f14788..63ea2d0b1e 100644 --- a/include/qemu/bitmap.h +++ b/include/qemu/bitmap.h @@ -57,11 +57,8 @@ * find_next_bit(addr, nbits, bit) Position next set bit in *addr >= bit */ -#define BITMAP_LAST_WORD_MASK(nbits) \ - ( \ - ((nbits) % BITS_PER_LONG) ? \ - (1UL<<((nbits) % BITS_PER_LONG))-1 : ~0UL \ - ) +#define BITMAP_FIRST_WORD_MASK(start) (~0UL << ((start) & (BITS_PER_LONG - 1))) +#define BITMAP_LAST_WORD_MASK(nbits) (~0UL >> (-(nbits) & (BITS_PER_LONG - 1))) #define DECLARE_BITMAP(name,bits) \ unsigned long name[BITS_TO_LONGS(bits)] -- cgit v1.2.3