Re: [PATCH] dss1_divert ISDN module compile fix for kernel 2.6.8.1

From: Bartlomiej Zolnierkiewicz
Date: Wed Nov 17 2004 - 21:01:54 EST


On Wed, 17 Nov 2004 19:52:54 +0100, Steffen A. Mork
<linux-dev@xxxxxxxxxx> wrote:
> Dear Linus and Bartlomiej,
>
>
>
> >>when I switched my installation from kernel 2.4 to 2.6 I
> >>recognized that the ISDN module dss1_divert was marked
> >>incompilable (config option CONFIG_CLEAN_COMPILE must
> >>be turned off). The compile problem was the obsolete using
> >>of kernel 2.4 critical sections. I replaced the cli() stuff
> >>with spinlocks as explained in the Documentation/spinlocks.txt
> >>file. After that the module compiles and runs as expected.
> >
> >
> > This looks wrong, you are using many private spinlocks instead
> > of one global spinlock.

Moreover, you must make sure that there is no other code (ie. in generic
ISDN code) doing cli() stuff on objects that you are protecting by a spinlock
etc., I've checked divert driver and it looks OK.

> OK, thank you. I went into the copy/paste trap. I corrected the patch to
> a global spinlock and tested it successfully.

Great.

> The corrected patch is applied to kernel 2.6.8.1 and should work for
> all 2.6 versions. You may also download the patch via http, too:
>
> http://ls7-www.cs.uni-dortmund.de/~mork/dss1_divert.diff
>
> Signed-off-by: Steffen A. Mork <linux-dev@xxxxxxxxxx>

Please do "interdiff" between the old and the new patch
and send it to Linus (he has already merged the old patch).

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