Re: Linux-2.5.28

David S. Miller (davem@redhat.com)
Wed, 24 Jul 2002 22:59:21 -0700 (PDT)


From: torvalds@transmeta.com (Linus Torvalds)
Date: Thu, 25 Jul 2002 06:02:04 +0000 (UTC)

It gets a bit more complicated partly because you could nest cli/sti,
and you can't nest spinlocks, but on the whole none of it is "rocket
science".

Actually the "rocket science" part is that these "cli()" users in the
unmaintained net stacks also want cli() to shut up input packet
processing as well as TIMER_BH.

This means they assume that cli() means "nobody can even look at the
existence of any of the timers". Ie. they do this to ensure they
can simply del_timer and there is no possibility someone sits inside
of the actual handler.

Of course del_timer_sync can be used to deal with that specific
case. But this specific example is just the tip of the iceberg.

I really think it is unwise to even imply that this kind of cli/sti
fixup can be done in some mindless manner, it really can't :-)
-
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/