From patch 2.1.83

Trever Adams (
Sat, 31 Jan 1998 01:48:19 -0600

Referring to the below patch couldn't/shouldn't the line be

if (local_irq_count[this_cpu] || local_bh_count[this_cpu])
goto scheduling_in_interrupt;

instead of what is found below? (Please note I am trying to become a
Kernel hacker, most of my programming experience is in small games and
porting small apps.)

Or is this totally erroneous to the coding style used?

diff -u --recursive --new-file v2.1.82/linux/kernel/sched.c
@@ -389,6 +389,8 @@
this_cpu = smp_processor_id();
if (local_irq_count[this_cpu])
goto scheduling_in_interrupt;
+ if (local_bh_count[this_cpu])
+ goto scheduling_in_interrupt;
release_kernel_lock(prev, this_cpu, lock_depth);
if (bh_active & bh_mask)

Trever Adams