[PATCH] uml: mostly const a structure

The chan_opts structure is mostly const, and needs no locking.  Comment the
lack of locking on the one field that can change.

Make all the other fields const.  It turned out that console_open_chan didn't
use its chan_opts argument, so that is deleted from the function and its
callers.

Signed-off-by: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Jeff Dike
2007-02-10 01:44:06 -08:00
committed by Linus Torvalds
parent 99b0278f95
commit a52f362f86
5 changed files with 11 additions and 11 deletions

View File

@@ -38,6 +38,7 @@ static void ssl_announce(char *dev_name, int dev)
dev_name);
}
/* Almost const, except that xterm_title may be changed in an initcall */
static struct chan_opts opts = {
.announce = ssl_announce,
.xterm_title = "Serial Line #%d",
@@ -171,7 +172,7 @@ static int ssl_console_setup(struct console *co, char *options)
{
struct line *line = &serial_lines[co->index];
return console_open_chan(line, co, &opts);
return console_open_chan(line, co);
}
static struct console ssl_cons = {