Commit Graph

6 Commits

Author SHA1 Message Date
Andrew Tridgell 91c741ef07 HAL_ChibiOS: use a non-blocking lock for UART shared DMA
we can have multiple UARTs on the same thread sharing the same DMA TX
channel. That can lead to deadlock with blocking locks on DMA. This
makes UART requests for DMA locks non-blocking to fix the issue
2018-03-02 21:39:38 +11:00
Andrew Tridgell 875008f2a6 HAL_ChibiOS: lock all DMA channels on reboot
this fixes a problem with the ICM-20789 on I2C where a reboot while the bus is active
leaves the IMU in a dead state where it can't be recovered without a power cycle.
2018-02-08 17:36:33 +11:00
Andrew Tridgell 41758348e5 HAL_ChibiOS: added checking of lock state in shared_dma
and use lock around check for tx completion in UART handler
2018-02-07 20:33:45 +11:00
Andrew Tridgell f14a847b97 HAL_ChibiOS: rename classes to remove 'Chibi'
it is redundent as all classes are in ChibiOS namespace, and makes the
code harder to read
2018-01-15 11:46:02 +11:00
Andrew Tridgell 755eca31c2 HAL_Chibios: don't unregister shared DMA
the shared DMA handle is a property of the bus, not the device, so
should not be unregistered when the device is removed
2018-01-15 11:46:02 +11:00
Andrew Tridgell 8b6bab7b17 HAL_Chibios: added ChibiOS HAL
this is based on initial work by Sid, reset here for easier merging
2018-01-15 11:46:02 +11:00