• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 285
  • Last Modified:

bottom half

sir ,

        We can implement a bottom half using tasklets .

    queue_task(&short_task ,&tq_immediate);

 In  "Linux device drivers " by oreilly publication . It is said about old type bottom halfs :
 
   queue_task(&short_task , &tq_immediate) ;
   mark_bh(IMMEDIATE_BH);

what is the need for mark_bh() .Even if i dont use it , Short_task is well executed .

It is also said in book:
 
 " Once a bh has been marked , it is excuted when bh_action is invoked ,which happens when tasklets are run "

Can u explain the above for clear understanding  ?


 

 
0
karana
Asked:
karana
  • 2
1 Solution
 
manish_regmiCommented:
BH  is  old and has been removed since 2.6.
Tasklets are dynamic and more flexible so i recommend you to use Tasklets.

mark_bh marks the BH as pending. The parameter is the Number i.e nth Bottom half. There are (were) 32 statically linked Old BH .

>>  " Once a bh has been marked , it is excuted when bh_action is invoked ,which happens when
>> tasklets are run "
>> Can u explain the above for clear understanding  ?
    BH is the traditional way of deferring work ie do the work at some other time. While servicing the interrupt, it is desireable to return from interrupt as soon as possible and defer the work to run at some other time. In those cases, BHs are used.

I recommend you to have the book Linux Kernel Development by Robert Love.

Regards
Manish regmi

 
0
 
manish_regmiCommented:
Robert Love's book is for 2.6 kernels.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now