cm3/common.h: Cast addr in BBIO_xx() macros. BBIO_xx has 4 byte size.
This commit is contained in:
parent
6de1b50c4e
commit
8b4ac9775e
|
@ -54,10 +54,10 @@
|
||||||
|
|
||||||
/* Generic bit-band I/O accessor functions */
|
/* Generic bit-band I/O accessor functions */
|
||||||
#define BBIO_SRAM(addr, bit) \
|
#define BBIO_SRAM(addr, bit) \
|
||||||
MMIO8(((addr) & 0x0FFFFF) * 32 + 0x22000000 + (bit) * 4)
|
MMIO32((((uint32_t)addr) & 0x0FFFFF) * 32 + 0x22000000 + (bit) * 4)
|
||||||
|
|
||||||
#define BBIO_PERIPH(addr, bit) \
|
#define BBIO_PERIPH(addr, bit) \
|
||||||
MMIO8(((addr) & 0x0FFFFF) * 32 + 0x42000000 + (bit) * 4)
|
MMIO32((((uint32_t)addr) & 0x0FFFFF) * 32 + 0x42000000 + (bit) * 4)
|
||||||
|
|
||||||
/* Generic bit definition */
|
/* Generic bit definition */
|
||||||
#define BIT0 (1<<0)
|
#define BIT0 (1<<0)
|
||||||
|
|
Loading…
Reference in New Issue