altos: Don't access cc1120 SPI bus during recv after abort has started
[fw/altos] / src / drivers / ao_cc1120.c
index 6b8005852c9bea9ca49ba02b994b0a5717066cf9..f9fc6b2dc2a5c8fda902869f8887451fb087475e 100644 (file)
@@ -3,7 +3,8 @@
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
  *
  * This program is distributed in the hope that it will be useful, but
  * WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -998,6 +999,8 @@ ao_radio_rx_isr(void)
 {
        uint8_t d;
 
+       if (ao_radio_abort)
+               return;
        if (rx_task_id) {
                if (ao_radio_try_select(rx_task_id)) {
                        ++rx_fast_start;