diff options
Diffstat (limited to 'cmd/sbc_harness')
-rw-r--r-- | cmd/sbc_harness/hw/w5500.c | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/cmd/sbc_harness/hw/w5500.c b/cmd/sbc_harness/hw/w5500.c index d896480..7bb9895 100644 --- a/cmd/sbc_harness/hw/w5500.c +++ b/cmd/sbc_harness/hw/w5500.c @@ -56,10 +56,10 @@ /* Part 1: Block ID. */ #define CTL_MASK_BLOCK 0b11111000 -#define _CTL_BLOCK_RES (0b00000) -#define _CTL_BLOCK_REG (0b01000) -#define _CTL_BLOCK_TX (0b10000) -#define _CTL_BLOCK_RX (0b11000) +#define _CTL_BLOCK_RES 0b00000 +#define _CTL_BLOCK_REG 0b01000 +#define _CTL_BLOCK_TX 0b10000 +#define _CTL_BLOCK_RX 0b11000 #define CTL_BLOCK_SOCK(n,part) (((n)<<5)|(_CTL_BLOCK_##part)) #define CTL_BLOCK_COMMON_REG CTL_BLOCK_SOCK(0,RES) @@ -431,14 +431,14 @@ struct libnet_listener *w5500_listen(struct w5500 *chip, uint8_t socknum, uint16 /* accept() *******************************************************************/ -#define ASSERT_LISTENER() \ +#define ASSERT_LISTENER() \ struct _w5500_listener *self = (struct _w5500_listener *)_self; \ - assert(self); \ - \ - struct w5500 *chip = self->chip; \ - uint8_t socknum = self->socknum; \ - assert(chip); \ - assert(socknum < 8) \ + assert(self); \ + \ + struct w5500 *chip = self->chip; \ + uint8_t socknum = self->socknum; \ + assert(chip); \ + assert(socknum < 8) static struct libnet_conn *w5500_accept(struct libnet_listener *_self) { ASSERT_LISTENER(); @@ -470,7 +470,6 @@ static struct libnet_conn *w5500_accept(struct libnet_listener *_self) { assert(chip); \ assert(socknum < 8) - static ssize_t w5500_write(struct libnet_conn *_self, void *buf, size_t count) { ASSERT_CONN(); assert(buf); |