]> rtime.felk.cvut.cz Git - lincan.git/blobdiff - lincan/src/can_devrtl.c
LinCAN version updated to 0.3
[lincan.git] / lincan / src / can_devrtl.c
index 812ea84a731be5de4952af924b4416ebb5f25f7e..d25072aed37cfae4fac610469568967954bdd55c 100644 (file)
@@ -3,7 +3,7 @@
  * New CAN queues by Pavel Pisa - OCERA team member
  * email:pisa@cmp.felk.cvut.cz
  * This software is released under the GPL-License.
- * Version lincan-0.2  9 Jul 2003
+ * Version lincan-0.3  17 Jun 2004
  */
 
 #ifdef CAN_WITH_RTL
@@ -16,6 +16,8 @@
 
 #include <rtl_malloc.h>
 
+can_spinlock_t can_irq_manipulation_lock;
+
 unsigned int can_rtl_isr( unsigned int irq_num, struct pt_regs *r )
 {
        struct chip_t *chip;
@@ -109,10 +111,15 @@ void * can_chip_worker_thread(void *arg)
                        for(i=0;i<chip->max_objects;i++){
                                if((obj=chip->msgobj[i])==NULL)
                                        continue;
-                               if(!can_msgobj_test_and_clear_fl(obj,TX_REQUEST))
-                                       continue;
-                               DEBUGMSG("Calling wakeup_tx\n");
-                               chip->chipspecops->wakeup_tx(chip, obj);
+                               if(can_msgobj_test_fl(obj,TX_REQUEST)) {
+                                       DEBUGMSG("Calling wakeup_tx\n");
+                                       chip->chipspecops->wakeup_tx(chip, obj);
+                               }
+                               if(can_msgobj_test_fl(obj,FILTCH_REQUEST)) {
+                                       DEBUGMSG("Calling filtch_rq\n");
+                                       if(chip->chipspecops->filtch_rq)
+                                               chip->chipspecops->filtch_rq(chip, obj);
+                               }
                        }
                        continue;
                }