Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755917AbbGGIRk (ORCPT ); Tue, 7 Jul 2015 04:17:40 -0400 Received: from TYO200.gate.nec.co.jp ([210.143.35.50]:37804 "EHLO tyo200.gate.nec.co.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752935AbbGGIRc (ORCPT ); Tue, 7 Jul 2015 04:17:32 -0400 From: Taichi Kageyama To: "gregkh@linuxfoundation.org" CC: "linux-serial@vger.kernel.org" , "jslaby@suse.cz" , "linux-kernel@vger.kernel.org" , "prarit@redhat.com" , Naoya Horiguchi Subject: Re: [PATCH 0/2] serial: 8250: Workaround to avoid irq=0 for console Thread-Topic: [PATCH 0/2] serial: 8250: Workaround to avoid irq=0 for console Thread-Index: AQHQn3XM4Pt7XBRbREauQ4fcrjoxh53PQ/YA Date: Tue, 7 Jul 2015 08:13:59 +0000 Message-ID: <559B8A48.5060004@cp.jp.nec.com> References: <55717224.9060104@cp.jp.nec.com> In-Reply-To: <55717224.9060104@cp.jp.nec.com> Accept-Language: en-US, ja-JP Content-Language: ja-JP X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.34.108.73] Content-Type: text/plain; charset="utf-8" Content-ID: <88C84985DF982344B370394D0F6E0671@gisp.nec.co.jp> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by mail.home.local id t678HjWP013586 Content-Length: 2346 Lines: 56 On 2015/06/05 18:55, Taichi Kageyama wrote: > This patch set provides a workaround to avoid the following problem. > It's based on Linux 4.1-rc3 mainstream kernel. > I've tested this patch set on x86-64 machine and KVM. > > Problem > -------------------------- > There're cases where autoconfig_irq() fails during boot. > In these cases, the console doesn't work in interrupt mode, > the mode cannot be changed anymore, and "input overrun" > (which can make operation mistakes) happens easily. > This problem happens with high rate every boot once it occurs > because the boot sequence is always almost same. > I saw the original problem on RHEL6.6. > > Fix > -------------------------- > serial: 8250: Fix autoconfig_irq() to avoid race conditions > Fix one of autoconfig_irq() failure case. > serial: 8250: Allow to skip autoconfig_irq() for a console > Provide a workaround to avoid other autoconfig_irq() failure cases. > > Conditions of Reproduction > -------------------------- > - Build with CONFIG_SERIAL_8250_DETECT_IRQ. > - Need non-PnP console serial or PnP console with no CONFIG_SERIAL_8250_PNP > - Kick printk() repeatedly on the CPU which can handle an interrupt > from a console serial during autoconfig_irq(). The CPU is basically cpu0. > - Disable the interrupt of the CPU for longer during autoconfig_irq(). > > Note > -------------------------- > Ideally, I think autoconfig_irq() should be fixed completely, > but it's hard from the following points > as long as auto_irq algorithm is used. > - How long it should wait for an interrrupt > - How to assure the interrupt of the CPU enabled during auto_irq > - How to know which CPU can handle an interrupt from a serial. > > Do you have any other idea? > In my opinion, providing a workaround is better than > applying big changes to the old function for legacy devices. > > Taichi Kageyama (2): > serial: 8250: Fix autoconfig_irq() to avoid race conditions > serial: 8250: Allow to skip autoconfig_irq() for a console > > drivers/tty/serial/8250/8250_core.c | 23 +++++++++++++++++++++++ > 1 files changed, 23 insertions(+), 0 deletions(-) > Could you review this patch set? Thanks, Taichi????{.n?+???????+%?????ݶ??w??{.n?+????{??G?????{ay?ʇڙ?,j??f???h?????????z_??(?階?ݢj"???m??????G????????????&???~???iO???z??v?^?m???? ????????I?