linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Ryan Arnold <rsa@us.ibm.com>
To: Olof Johansson <olof@lixom.net>
Cc: linuxppc-dev@ozlabs.org, paulus@samba.org
Subject: Re: [PATCH] powerpc: Quiet hvc_console console output on failed opens
Date: Thu, 07 Sep 2006 15:38:58 -0500	[thread overview]
Message-ID: <1157661538.25088.235.camel@localhost.localdomain> (raw)
In-Reply-To: <20060907151808.2295ad9a@localhost.localdomain>

On Thu, 2006-09-07 at 15:18 -0500, Olof Johansson wrote:
> Hi,
> 
> Please consider for the 2.6.19 queue:
> 
> 
> 
> No other tty driver will print on the console when the open of it fails.
> 
> On systems that happen to be configured for both ttyS0 and hvc0 console,
> this will keep flooding the console output.  This is most likely to
> happen with systems booted between with and without hypervisor from the
> same filesystem.
> 
> Let's just remove it. When it's really needed (i.e. when the open fails
> and someone is trying to debug it), noone will see the output anyway. And
> init will report the opens failing in due time through the syslog.
> 
> 
> Signed-off-by: Olof Johansson <olof@lixom.net>
> 
> Index: merge/drivers/char/hvc_console.c
> ===================================================================
> --- merge.orig/drivers/char/hvc_console.c
> +++ merge/drivers/char/hvc_console.c
> @@ -320,10 +320,8 @@ static int hvc_open(struct tty_struct *t
>  	struct kobject *kobjp;
>  
>  	/* Auto increments kobject reference if found. */
> -	if (!(hp = hvc_get_by_index(tty->index))) {
> -		printk(KERN_WARNING "hvc_console: tty open failed, no vty associated with tty.\n");
> +	if (!(hp = hvc_get_by_index(tty->index)))
>  		return -ENODEV;
> -	}
>  
>  	spin_lock_irqsave(&hp->lock, flags);
>  	/* Check and then increment for fast path open. */

This seems like a good fix to me.  I think it is a debug artifact
anyway.

-- 
Ryan S. Arnold <rsa@us.ibm.com>
IBM Linux Technology Center
Linux on Power Toolchain

  reply	other threads:[~2006-09-07 20:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-09-07 20:18 [PATCH] powerpc: Quiet hvc_console console output on failed opens Olof Johansson
2006-09-07 20:38 ` Ryan Arnold [this message]
2006-09-07 23:20   ` Paul Mackerras
2006-09-11 19:13     ` Ryan Arnold

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1157661538.25088.235.camel@localhost.localdomain \
    --to=rsa@us.ibm.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=olof@lixom.net \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).