hal: spi_v2: propagate msg passed to __spi_wakeup_isr Topic is solved

Report here problems in any of ChibiOS components. This forum is NOT for support.
Post Reply
Dron_Gus
Posts: 34
Joined: Wed Apr 22, 2020 1:03 am
Has thanked: 5 times
Been thanked: 10 times

hal: spi_v2: propagate msg passed to __spi_wakeup_isr

Post by Dron_Gus »

__spi_wakeup_isr is called from __spi_isr_complete_code with msg = MSG_OK and from __spi_isr_error_code with msg = some error code(s). Pass this msg to osalThreadResumeI and further to thread.

Code: Select all

@@ -378,7 +378,7 @@ do {                                                                        \
  */
 #define __spi_wakeup_isr(spip, msg) {                                       \
   osalSysLockFromISR();                                                     \
-  osalThreadResumeI(&(spip)->sync_transfer, MSG_OK);                        \
+  osalThreadResumeI(&(spip)->sync_transfer, msg);                           \
   osalSysUnlockFromISR();                                                   \
 }
 #else /* !SPI_USE_SYNCHRONIZATION */
Attachments
0001-hal-spi_v2-propagate-msg.zip
(710 Bytes) Downloaded 302 times
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: hal: spi_v2: propagate msg passed to __spi_wakeup_isr

Post by Giovanni »

Fixed thanks.

Giovanni
Post Reply