lkml.org 
[lkml]   [2000]   [Oct]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 2.4.0-test9 i810_rng compilation failure


On Tue, 3 Oct 2000, Rasmus Andersen wrote:

> On Tue, Oct 03, 2000 at 08:20:12PM +0000, Graham Murray wrote:
> > i810_rng.c does not compile when not a module. It fails at line 384,
> > which looks as though it should only be included when being built as a
> > module.
>
> This patch fixes this. Could the maintainer comment? Is there a better
> way to do this?
>
>
> --- linux-240-test9-clean/drivers/char/i810_rng.c Tue Oct 3 22:12:37 2000
> +++ linux/drivers/char/i810_rng.c Tue Oct 3 22:36:01 2000
> @@ -380,7 +380,7 @@
> rng_hw_enabled = 1;
> MOD_INC_USE_COUNT;
> } else {
> -#ifndef __alpha__
> +#if !defined(__alpha__) && defined (CONFIG_MODULE)
> if (GET_USE_COUNT (THIS_MODULE) > 0)
> MOD_DEC_USE_COUNT;
> if (GET_USE_COUNT (THIS_MODULE) == 0)
>


This patch looks ok to me.

That entire #if is a hack. GET_USE_COUNT kills the Alpha build.
Further, all module-related stuff should ideally work when built into
the kernel, without ifdefs.

Jeff




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

\
 
 \ /
  Last update: 2005-03-22 12:39    [W:0.018 / U:3.496 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site