More CAN driver fixes: remove and unused semaphore. Looks to me that waiter counts are not being initialized
This commit is contained in:
parent
048d338808
commit
f41df38b0b
@ -704,7 +704,9 @@ int can_register(FAR const char *path, FAR struct can_dev_s *dev)
|
|||||||
|
|
||||||
/* Initialize the CAN device structure */
|
/* Initialize the CAN device structure */
|
||||||
|
|
||||||
dev->cd_ocount = 0;
|
dev->cd_ocount = 0;
|
||||||
|
dev->cd_ntxwaiters = 0;
|
||||||
|
dev->cd_nrxwaiters = 0;
|
||||||
|
|
||||||
sem_init(&dev->cd_xmit.tx_sem, 0, 0);
|
sem_init(&dev->cd_xmit.tx_sem, 0, 0);
|
||||||
sem_init(&dev->cd_recv.rx_sem, 0, 0);
|
sem_init(&dev->cd_recv.rx_sem, 0, 0);
|
||||||
|
@ -286,7 +286,6 @@ struct can_dev_s
|
|||||||
volatile uint8_t cd_ntxwaiters; /* Number of threads waiting to enqueue a message */
|
volatile uint8_t cd_ntxwaiters; /* Number of threads waiting to enqueue a message */
|
||||||
volatile uint8_t cd_nrxwaiters; /* Number of threads waiting to receive a message */
|
volatile uint8_t cd_nrxwaiters; /* Number of threads waiting to receive a message */
|
||||||
sem_t cd_closesem; /* Locks out new opens while close is in progress */
|
sem_t cd_closesem; /* Locks out new opens while close is in progress */
|
||||||
sem_t cd_recvsem; /* Used to wakeup user waiting for space in cd_recv.buffer */
|
|
||||||
struct can_txfifo_s cd_xmit; /* Describes transmit FIFO */
|
struct can_txfifo_s cd_xmit; /* Describes transmit FIFO */
|
||||||
struct can_rxfifo_s cd_recv; /* Describes receive FIFO */
|
struct can_rxfifo_s cd_recv; /* Describes receive FIFO */
|
||||||
/* List of pending RTR requests */
|
/* List of pending RTR requests */
|
||||||
|
Loading…
Reference in New Issue
Block a user