tty: vt: use printk_once

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
Marcin Slusarz
2009-08-09 21:54:03 +02:00
committed by Live-CD User
parent e92166517e
commit 9074d963f4
2 changed files with 2 additions and 8 deletions

View File

@@ -2129,11 +2129,7 @@ static int do_con_write(struct tty_struct *tty, const unsigned char *buf, int co
currcons = vc->vc_num;
if (!vc_cons_allocated(currcons)) {
/* could this happen? */
static int error = 0;
if (!error) {
error = 1;
printk("con_write: tty %d not allocated\n", currcons+1);
}
printk_once("con_write: tty %d not allocated\n", currcons+1);
release_console_sem();
return 0;
}