softirq.h
上传用户:lgb322
上传日期:2013-02-24
资源大小:30529k
文件大小:1k
源码类别:

嵌入式Linux

开发平台:

Unix_Linux

  1. /* softirq.h: 64-bit Sparc soft IRQ support.
  2.  *
  3.  * Copyright (C) 1997, 1998 David S. Miller (davem@caip.rutgers.edu)
  4.  */
  5. #ifndef __SPARC64_SOFTIRQ_H
  6. #define __SPARC64_SOFTIRQ_H
  7. #include <asm/atomic.h>
  8. #include <asm/hardirq.h>
  9. #include <asm/system.h> /* for membar() */
  10. #define local_bh_disable() (local_bh_count(smp_processor_id())++)
  11. #define __local_bh_enable() (local_bh_count(smp_processor_id())--)
  12. #define local_bh_enable()   
  13. do { if (!--local_bh_count(smp_processor_id()) && 
  14.  softirq_pending(smp_processor_id())) {   
  15. do_softirq();   
  16. __sti();   
  17.      }   
  18. } while (0)
  19. #define in_softirq() (local_bh_count(smp_processor_id()) != 0)
  20. #endif /* !(__SPARC64_SOFTIRQ_H) */