lkml.org 
[lkml]   [2005]   [May]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    Subjectspin_unlock_bh() and preempt_check_resched()
    Hi,

    I'm wondering about macros like _spin_unlock_bh(lock):
    do { \
    _raw_spin_unlock(lock); \
    preempt_enable(); \
    local_bh_enable(); \
    __release(lock); \
    } while (0)

    Is there a reason for using preempt_enable() instead of a simple
    preempt_enable_no_resched() ?

    Since we know bottom halves are disabled, preempt_schedule() will always
    return at once (preempt_count!=0), and hence preempt_check_resched() is
    useless here...

    Regards,
    Samuel
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-05-20 17:24    [W:0.020 / U:1.148 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site