mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-13 03:20:00 +03:00
No D cache and remove Tx IRQ handler
This commit is contained in:
parent
63847f907a
commit
0c6ac159b5
1 changed files with 0 additions and 37 deletions
|
@ -280,46 +280,9 @@ FAST_IRQ_HANDLER static void spiRxIrqHandler(dmaChannelDescriptor_t* descriptor)
|
||||||
|
|
||||||
spiInternalStopDMA(dev);
|
spiInternalStopDMA(dev);
|
||||||
|
|
||||||
#ifdef __DCACHE_PRESENT
|
|
||||||
#ifdef STM32H7
|
|
||||||
if (bus->curSegment->u.buffers.rxData &&
|
|
||||||
((bus->curSegment->u.buffers.rxData < &_dmaram_start__) || (bus->curSegment->u.buffers.rxData >= &_dmaram_end__))) {
|
|
||||||
#else
|
|
||||||
if (bus->curSegment->u.buffers.rxData) {
|
|
||||||
#endif
|
|
||||||
// Invalidate the D cache covering the area into which data has been read
|
|
||||||
SCB_InvalidateDCache_by_Addr(
|
|
||||||
(uint32_t *)((uint32_t)bus->curSegment->u.buffers.rxData & ~CACHE_LINE_MASK),
|
|
||||||
(((uint32_t)bus->curSegment->u.buffers.rxData & CACHE_LINE_MASK) +
|
|
||||||
bus->curSegment->len - 1 + CACHE_LINE_SIZE) & ~CACHE_LINE_MASK);
|
|
||||||
}
|
|
||||||
#endif // __DCACHE_PRESENT
|
|
||||||
|
|
||||||
spiIrqHandler(dev);
|
spiIrqHandler(dev);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
// Interrupt handler for SPI transmit DMA completion
|
|
||||||
FAST_IRQ_HANDLER static void spiTxIrqHandler(dmaChannelDescriptor_t* descriptor)
|
|
||||||
{
|
|
||||||
const extDevice_t *dev = (const extDevice_t *)descriptor->userParam;
|
|
||||||
|
|
||||||
if (!dev) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
busDevice_t *bus = dev->bus;
|
|
||||||
|
|
||||||
spiInternalStopDMA(dev);
|
|
||||||
|
|
||||||
if (bus->curSegment->negateCS) {
|
|
||||||
// Negate Chip Select
|
|
||||||
IOHi(dev->busType_u.spi.csnPin);
|
|
||||||
}
|
|
||||||
|
|
||||||
spiIrqHandler(dev);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
extern dmaChannelDescriptor_t dmaDescriptors[];
|
extern dmaChannelDescriptor_t dmaDescriptors[];
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue