Re: Patch to make serial module shut up.

Tom Grigg (st588@bayou.uh.edu)
Mon, 29 Apr 1996 07:56:19 -0500 (CDT)


On Sun, 28 Apr 1996, Russ Steffen wrote:

> I finally got sick of the the serial driver (which I have as a module)
> babbling at the console every time it's inserted. So, I made this
> patch that that adds a KERN_INFO priority to the "normal" printk's
> in the serial module.
>
> --- linux-1.3.x/drivers/char/serial.c.RRS Sun Apr 28 10:24:34 1996
> +++ linux-1.3.x/drivers/char/serial.c Sun Apr 28 10:35:15 1996
> @@ -2448,15 +2448,15 @@
> */
> static void show_serial_version(void)
> {
> - printk("%s version %s with", serial_name, serial_version);
> + printk( KERN_INFO "%s version %s with", serial_name, serial_version);
> #ifdef CONFIG_HUB6
> - printk(" HUB-6");
> + printk( KERN_INFO " HUB-6");
> #define SERIAL_OPT
> #endif
> #ifdef SERIAL_OPT
> - printk(" enabled\n");
> + printk( KERN_INFO " enabled\n");

[ snip ]

I think you've put KERN_INFO in way too many places. It should only be in
those printk()s that start a new line, otherwise you start getting lots of
strings with <6> (or whatever the value KERN_INFO is) in your log files.

Please see the patch I posted here yesterday to fix the problems with the
serial driver compiled as a module. That patch also added KERN_INFO to the
necessary printk()s.

Hopefully my patch will be in 1.3.97.... Linus?

--
Tom Grigg
st588@jetson.uh.edu
http://www.egr.uh.edu/~eac64750/tom/