[drivers]修复can驱动编译错误 (#7708)

This commit is contained in:
xiao xie 2023-06-21 20:52:11 +08:00 committed by GitHub
parent 33f550cb65
commit ba76cb5ef7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -430,7 +430,7 @@ static rt_ssize_t can_send(struct rt_can_device *can_dev, const void *buf, rt_ui
return (rt_ssize_t)ret;
}
static int can_recv(struct rt_can_device *can_dev, void *buf, rt_uint32_t boxno)
static rt_ssize_t can_recv(struct rt_can_device *can_dev, void *buf, rt_uint32_t boxno)
{
struct imxrt_can *can;
struct rt_can_msg *pmsg;

View File

@ -351,8 +351,8 @@ struct rt_can_ops
{
rt_err_t (*configure)(struct rt_can_device *can, struct can_configure *cfg);
rt_err_t (*control)(struct rt_can_device *can, int cmd, void *arg);
int (*sendmsg)(struct rt_can_device *can, const void *buf, rt_uint32_t boxno);
int (*recvmsg)(struct rt_can_device *can, void *buf, rt_uint32_t boxno);
rt_ssize_t (*sendmsg)(struct rt_can_device *can, const void *buf, rt_uint32_t boxno);
rt_ssize_t (*recvmsg)(struct rt_can_device *can, void *buf, rt_uint32_t boxno);
};
rt_err_t rt_hw_can_register(struct rt_can_device *can,