2001-04-15 08:23:38

by Swivel

[permalink] [raw]
Subject: small bug/oversight found in 2.4.3

drivers/char/char.c, line 247
create_proc_read_entry() is called regardless of the definition of
CONFIG_PROC_FS, simply wrap call with #ifdef CONFIG_PROC_FS and #endif.

Cheers,
Vito Caputo



2001-04-15 08:32:29

by Jeff Garzik

[permalink] [raw]
Subject: Re: small bug/oversight found in 2.4.3

Swivel wrote:
>
> drivers/char/char.c, line 247
> create_proc_read_entry() is called regardless of the definition of
> CONFIG_PROC_FS, simply wrap call with #ifdef CONFIG_PROC_FS and #endif.

create_proc_read_entry exists, as a static inline no-op, without
CONFIG_PROC_FS.

Typically you want to change the driver-local function passed to
create_proc_read_entry to be a static inline no-op for the
!CONFIG_PROC_FS case.

--
Jeff Garzik | "Give a man a fish, and he eats for a day. Teach a
Building 1024 | man to fish, and a US Navy submarine will make sure
MandrakeSoft | he's never hungry again." -- Chris Neufeld

2001-04-15 08:48:00

by Alexander Viro

[permalink] [raw]
Subject: Re: small bug/oversight found in 2.4.3



On Sun, 15 Apr 2001, Jeff Garzik wrote:

> Swivel wrote:
> >
> > drivers/char/char.c, line 247
> > create_proc_read_entry() is called regardless of the definition of
> > CONFIG_PROC_FS, simply wrap call with #ifdef CONFIG_PROC_FS and #endif.
>
> create_proc_read_entry exists, as a static inline no-op, without
> CONFIG_PROC_FS.

... while drivers/char/char.c doesn't exist at all.