linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: ebiederm@xmission.com (Eric W. Biederman)
To: Max Staudt <mstaudt@suse.de>
Cc: "Theodore Ts'o" <tytso@mit.edu>,
	One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>,
	Greg KH <gregkh@linuxfoundation.org>,
	linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] 8250: option 'force_polling' for buggy IRQs
Date: Thu, 28 Jul 2016 13:40:29 -0500	[thread overview]
Message-ID: <87mvl1hahu.fsf@x220.int.ebiederm.org> (raw)
In-Reply-To: <f02610c6-5607-9fdf-23af-5b05d604f473@suse.de> (Max Staudt's message of "Thu, 28 Jul 2016 11:59:20 +0200")

Max Staudt <mstaudt@suse.de> writes:

> On 07/27/2016 03:33 PM, Theodore Ts'o wrote:
>
>> I wonder if it would just be simpler to make it be a CONFIG option
>> which causes the irq value to zero in arch/x86/include/asm/serial.h?
>
> Alan hit the nail on the head in his reply to your email: I can't set the IRQ in
> the system configuration. The other option is to compile a custom kernel for this
> system, but that's exactly what I'd like to avoid.
>
> My motivation for this patch is to have a boot time option that allows *any*
> kernel to boot on this broken hardware. This allows for console boot on a broken
> machine even when the machine has never been used in serial console mode before,
> and thus the hardware bug has not been discovered before either.

*Scratches my head*

There is already generic handling for this (that triggers polling) in
the irq code if an irq is screaming.  I am assuming the problem is that
your irq never fires?

Serial consoles are already polled for output.  So nothing should
care until userspace starts, and the full serial driver initializes.

Hmm.

The irq code already has handling for some of these situations,
and if that handling is not sufficient I suspect we could pretty
easily extend it for this case.

For irqs that are screaming we disable them and then poll them.
There there are the "irqfixup" and "irqpoll" command line options
that when an irq is received the code tries all of the irq handlers.

So I suspect either "irqfixup" or "irqpoll" would handle this for you.
If not I am certain a small tweak to some of that code would work.

That should be enough to get a system booted for debugging purposes,
which is the point here.  At which point you can dig in figure out what
is wrong and get the problem design fixed.

Eric

  parent reply	other threads:[~2016-07-28 18:53 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-25 17:36 [PATCH] 8250: option 'force_polling' for buggy IRQs Max Staudt
2016-07-25 17:47 ` Greg KH
2016-07-26 11:42   ` Max Staudt
2016-07-26 15:08     ` Greg KH
2016-07-26 16:18       ` Max Staudt
2016-07-27 12:09         ` One Thousand Gnomes
2016-07-27 12:14           ` Max Staudt
2016-07-27 13:33             ` Theodore Ts'o
2016-07-27 20:01               ` One Thousand Gnomes
2016-07-28  9:59               ` Max Staudt
2016-07-28 14:47                 ` Greg KH
2016-07-28 16:01                   ` Theodore Ts'o
2016-07-28 18:40                 ` Eric W. Biederman [this message]
2016-07-29  9:23                   ` One Thousand Gnomes
2016-07-29  9:58                     ` Max Staudt
2016-07-29 17:38                       ` Eric W. Biederman
2016-08-01 15:27                         ` One Thousand Gnomes
2016-07-25 18:19 ` kbuild test robot
2016-07-26 11:47   ` [PATCHv2] " Max Staudt
2016-07-26 11:54   ` [PATCHv3] " Max Staudt

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=87mvl1hahu.fsf@x220.int.ebiederm.org \
    --to=ebiederm@xmission.com \
    --cc=gnomes@lxorguk.ukuu.org.uk \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=mstaudt@suse.de \
    --cc=tytso@mit.edu \
    /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).