Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1450345 > unrolled thread

[PATCH v2 0/3] Fix dump-capture kernel hangs with notsc

Started byWei Jiangang <weijg.fnst@cn.fujitsu.com>
First post2016-07-26 05:10 +0200
Last post2016-08-02 16:30 +0200
Articles 5 — 4 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH v2 0/3] Fix dump-capture kernel hangs with notsc Wei Jiangang <weijg.fnst@cn.fujitsu.com> - 2016-07-26 05:10 +0200
    Re: [PATCH v2 0/3] Fix dump-capture kernel hangs with notsc "Wei, Jiangang" <weijg.fnst@cn.fujitsu.com> - 2016-08-01 08:50 +0200
      Re: [PATCH v2 0/3] Fix dump-capture kernel hangs with notsc ebiederm@xmission.com (Eric W. Biederman) - 2016-08-01 22:20 +0200
        Re: [PATCH v2 0/3] Fix dump-capture kernel hangs with notsc "Wei, Jiangang" <weijg.fnst@cn.fujitsu.com> - 2016-08-02 10:00 +0200
          Re: [PATCH v2 0/3] Fix dump-capture kernel hangs with notsc "bhe@redhat.com" <bhe@redhat.com> - 2016-08-02 16:30 +0200

#1450345 — [PATCH v2 0/3] Fix dump-capture kernel hangs with notsc

FromWei Jiangang <weijg.fnst@cn.fujitsu.com>
Date2016-07-26 05:10 +0200
Subject[PATCH v2 0/3] Fix dump-capture kernel hangs with notsc
Message-ID<rZ0UN-53b-3@gated-at.bofh.it>
v2:
Just about the commit ("x86/apic: Improved the setting of interrupt
 mode for bsp")

- Unify the name
  s/virtual_wire_via_*/virt_wire_through_*
- Add check for PIC mode
  suggested-by Baoquan He <bhe@redhat.com>
- Add check enable/disable flag for IO-APIC
  suggested-by Xunlei Pang <xpang@redhat.com>
- Update comments

v1:
The goal is to fix dump-capture kernel with notsc option hangs
in calibrate_delay_converge()

Wei Jiangang (3):
  x86/apic: Remove "focus disabled" for 64bit case
  x86/apic: Update comment about disabling processor focus
  x86/apic: Improved the setting of interrupt mode for bsp

 arch/x86/include/asm/io_apic.h |  5 ++++
 arch/x86/kernel/apic/apic.c    | 63 +++++++++++++++++++++++++++++++++++++++---
 arch/x86/kernel/apic/io_apic.c | 28 +++++++++++++++++++
 3 files changed, 92 insertions(+), 4 deletions(-)

-- 
1.9.3

[toc] | [next] | [standalone]


#1453007

From"Wei, Jiangang" <weijg.fnst@cn.fujitsu.com>
Date2016-08-01 08:50 +0200
Message-ID<s1fcZ-2Ly-1@gated-at.bofh.it>
In reply to#1450345
Ping ...
May I ask for some community attention to this series?
I purpose is fixing  the dump-capture kernel hangs in
calibrate_delay_converge() while specifying notsc.

Thanks in advance.
wei
On Tue, 2016-07-26 at 10:59 +0800, Wei Jiangang wrote:
> v2:
> Just about the commit ("x86/apic: Improved the setting of interrupt
>  mode for bsp")
> 
> - Unify the name
>   s/virtual_wire_via_*/virt_wire_through_*
> - Add check for PIC mode
>   suggested-by Baoquan He <bhe@redhat.com>
> - Add check enable/disable flag for IO-APIC
>   suggested-by Xunlei Pang <xpang@redhat.com>
> - Update comments
> 
> v1:
> The goal is to fix dump-capture kernel with notsc option hangs
> in calibrate_delay_converge()
> 
> Wei Jiangang (3):
>   x86/apic: Remove "focus disabled" for 64bit case
>   x86/apic: Update comment about disabling processor focus
>   x86/apic: Improved the setting of interrupt mode for bsp
> 
>  arch/x86/include/asm/io_apic.h |  5 ++++
>  arch/x86/kernel/apic/apic.c    | 63 +++++++++++++++++++++++++++++++++++++++---
>  arch/x86/kernel/apic/io_apic.c | 28 +++++++++++++++++++
>  3 files changed, 92 insertions(+), 4 deletions(-)
> 



[toc] | [prev] | [next] | [standalone]


#1453437

Fromebiederm@xmission.com (Eric W. Biederman)
Date2016-08-01 22:20 +0200
Message-ID<s1rQR-2HG-1@gated-at.bofh.it>
In reply to#1453007
"Wei, Jiangang" <weijg.fnst@cn.fujitsu.com> writes:

> Ping ...
> May I ask for some community attention to this series?
> I purpose is fixing  the dump-capture kernel hangs in
> calibrate_delay_converge() while specifying notsc.

Did you not see my reply to patch 3/3?

The short version of my feedback is that you seem to be fixing a case
that should not exist.  So the good fix is to skip completely past
virtual wire mode and into full apic mode as soon as possible.

For a subset of cases the code already supports that.

Eric

[toc] | [prev] | [next] | [standalone]


#1453650

From"Wei, Jiangang" <weijg.fnst@cn.fujitsu.com>
Date2016-08-02 10:00 +0200
Message-ID<s1CMh-1vQ-13@gated-at.bofh.it>
In reply to#1453437
Hi Eric,

Thanks for your reply firstly.

On Mon, 2016-08-01 at 12:09 -0500, Eric W. Biederman wrote:
> "Wei, Jiangang" <weijg.fnst@cn.fujitsu.com> writes:
> 
> > Ping ...
> > May I ask for some community attention to this series?
> > I purpose is fixing  the dump-capture kernel hangs in
> > calibrate_delay_converge() while specifying notsc.
> 
> Did you not see my reply to patch 3/3?

Yes, I read your email and made a reply
(https://lkml.org/lkml/2016/7/26/112) . I put forward several questions
in that letter, but no feedback...

> 
> The short version of my feedback is that you seem to be fixing a case
> that should not exist.  So the good fix is to skip completely past
> virtual wire mode and into full apic mode as soon as possible.

I am afraid that there are some disagreements between us.

1)  The case that dump-capture kernel boot up with the disabled APIC is
very real, and the bug can be reproduced 100%.  I want to emphasize that
there is no guarantee of the interrupt mode of APIC and status of local
APIC, Especially for the dump-capture kernel that won't through the BIOS
phrase. That's why I do more check in init_bsp_APIC(), not only depends
on the MP tables which be generated before the first kernel boots up.

Make a point here, The BIOS must disable interrupts to all processors
and set the APICs to the system initial state before giving control to
the operating system. That means APICs won't be reset to initial state
without BIOS phrase.

2)  Your proposal (switch into full apic mode as soon as possible) seems
to contradict the Intel Spec, "An MP operating system is booted under
either one of the two PC/AT-compatible modes. Later the operating system
switches to Symmetric I/O Mode **as it enters multiprocessor mode**."
And in other words, the BSP should be in PIC mode or Virtual wire mode
in startup stage.

3)  The apic initialization codes maybe need a overhaul, but it goes out
the scope of this patch. I focus on fixing kdump failure with notsc. And
the apic initialization codes has no modification for a long time and
can be regard as stable.  Overhaul of it increases the chances of
hitting a bug.

If there's anything wrong with my understanding, please point out.

Thanks,
wei
> 
> For a subset of cases the code already supports that.
> 
> Eric
> 
> 



[toc] | [prev] | [next] | [standalone]


#1454565

From"bhe@redhat.com" <bhe@redhat.com>
Date2016-08-02 16:30 +0200
Message-ID<s1IRK-5C1-69@gated-at.bofh.it>
In reply to#1453650
On 08/02/16 at 07:45am, Wei, Jiangang wrote:
> Hi Eric,
> 
> Thanks for your reply firstly.
> 
> On Mon, 2016-08-01 at 12:09 -0500, Eric W. Biederman wrote:
> > "Wei, Jiangang" <weijg.fnst@cn.fujitsu.com> writes:
> > 
> > > Ping ...
> > > May I ask for some community attention to this series?
> > > I purpose is fixing  the dump-capture kernel hangs in
> > > calibrate_delay_converge() while specifying notsc.
> > 
> > Did you not see my reply to patch 3/3?
> 
> Yes, I read your email and made a reply
> (https://lkml.org/lkml/2016/7/26/112) . I put forward several questions
> in that letter, but no feedback...
> 
> > 
> > The short version of my feedback is that you seem to be fixing a case
> > that should not exist.  So the good fix is to skip completely past
> > virtual wire mode and into full apic mode as soon as possible.
> 
> I am afraid that there are some disagreements between us.
> 
> 1)  The case that dump-capture kernel boot up with the disabled APIC is
> very real, and the bug can be reproduced 100%.  I want to emphasize that
> there is no guarantee of the interrupt mode of APIC and status of local
> APIC, Especially for the dump-capture kernel that won't through the BIOS
> phrase. That's why I do more check in init_bsp_APIC(), not only depends
> on the MP tables which be generated before the first kernel boots up.
> 
> Make a point here, The BIOS must disable interrupts to all processors
> and set the APICs to the system initial state before giving control to
> the operating system. That means APICs won't be reset to initial state
> without BIOS phrase.
> 
> 2)  Your proposal (switch into full apic mode as soon as possible) seems
> to contradict the Intel Spec, "An MP operating system is booted under
> either one of the two PC/AT-compatible modes. Later the operating system
> switches to Symmetric I/O Mode **as it enters multiprocessor mode**."
> And in other words, the BSP should be in PIC mode or Virtual wire mode
> in startup stage.

Well, Eric has clearly told hardware-reduced ACPI platform doesn't have
legacy mode irq. It only has APIC mode. The quotation from MP spec is
very old.

I check code and think now you should investigate the current
implementation, see if APIC mode can be enabled as soon as possible.
Though it can't, detailed explanation need be given to convince people.

> 
> 3)  The apic initialization codes maybe need a overhaul, but it goes out
> the scope of this patch. I focus on fixing kdump failure with notsc. And
> the apic initialization codes has no modification for a long time and
> can be regard as stable.  Overhaul of it increases the chances of
> hitting a bug.
> If there's anything wrong with my understanding, please point out.
> 
> Thanks,
> wei
> > 
> > For a subset of cases the code already supports that.
> > 
> > Eric
> > 
> > 
> 
> 
> 

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web