diff options
| author | tyustli <[email protected]> | 2019-08-16 11:56:26 +0800 |
|---|---|---|
| committer | tyustli <[email protected]> | 2019-08-16 12:14:30 +0800 |
| commit | c81eebcd5d8a36e69afbe94319abaa8a04fca3f8 (patch) | |
| tree | 7a74d1f2678f6b7a0e729e1c1dbeac60e8cce72d /components/drivers/include | |
| parent | 3b252d5b9721bb7cc649dad832507937efc1e96c (diff) | |
[bsp] [stm32] fix drv_can.c
Diffstat (limited to 'components/drivers/include')
| -rw-r--r-- | components/drivers/include/drivers/can.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/drivers/include/drivers/can.h b/components/drivers/include/drivers/can.h index c61fb19eaa..d4fcc845b4 100644 --- a/components/drivers/include/drivers/can.h +++ b/components/drivers/include/drivers/can.h @@ -221,7 +221,7 @@ struct rt_can_msg rt_uint32_t rsv : 1; rt_uint32_t len : 8; rt_uint32_t priv : 8; - rt_uint32_t hdr : 8; + rt_int32_t hdr : 8; rt_uint32_t reserved : 8; rt_uint8_t data[8]; }; @@ -252,7 +252,7 @@ struct rt_can_rx_fifo #define RT_CAN_EVENT_RX_IND 0x01 /* Rx indication */ #define RT_CAN_EVENT_TX_DONE 0x02 /* Tx complete */ -#define RT_CAN_EVENT_TX_FAIL 0x03 /* Tx complete */ +#define RT_CAN_EVENT_TX_FAIL 0x03 /* Tx fail */ #define RT_CAN_EVENT_RX_TIMEOUT 0x05 /* Rx timeout */ #define RT_CAN_EVENT_RXOF_IND 0x06 /* Rx overflow */ @@ -278,7 +278,7 @@ struct rt_can_ops int (*recvmsg)(struct rt_can_device *can, void *buf, rt_uint32_t boxno); }; -rt_err_t rt_hw_can_register(struct rt_can_device *can, +rt_err_t rt_hw_can_register(struct rt_can_device *can, const char *name, const struct rt_can_ops *ops, void *data); |
