mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Suresh Siddha <suresh.b.siddha@intel.com>
To: Yinghai Lu <yinghai@kernel.org>
Cc: Ingo Molnar <mingo@elte.hu>, Thomas Gleixner <tglx@linutronix.de>,
	"H. Peter Anvin" <hpa@zytor.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Gleb Natapov <gleb@redhat.com>,
	"Pallipadi, Venkatesh" <venkatesh.pallipadi@intel.com>
Subject: Re: [PATCH] x86: move dmar_table_init out of enable_IR
Date: Mon, 17 Aug 2009 15:53:16 -0700	[thread overview]
Message-ID: <1250549596.2709.254.camel@sbs-t61.sc.intel.com> (raw)
In-Reply-To: <4A89C1CE.9040501@kernel.org>

On Mon, 2009-08-17 at 13:47 -0700, Yinghai Lu wrote:
> Suresh Siddha wrote:
> > 
> > We can remove this ifdef check, as dmar_table_init() already handles
> > the !config_intr_remap
> > 
> > Also, at this error condition, we should simply return if the cpu has no
> > x2apic support. There is no x2apic support and we failed to enable
> > interrupt-remapping. No need to go further down.
> 
> like this ?
> 
> ---
>  arch/x86/kernel/apic/apic.c |    9 +++------
>  1 file changed, 3 insertions(+), 6 deletions(-)
> 
> Index: linux-2.6/arch/x86/kernel/apic/apic.c
> ===================================================================
> --- linux-2.6.orig/arch/x86/kernel/apic/apic.c
> +++ linux-2.6/arch/x86/kernel/apic/apic.c
> @@ -1392,14 +1392,11 @@ void __init enable_IR_x2apic(void)
>  	unsigned long flags;
>  	struct IO_APIC_route_entry **ioapic_entries = NULL;
>  	int ret, x2apic_enabled = 0;
> -	int dmar_table_init_ret = 0;
> +	int dmar_table_init_ret;
>  
> -#ifdef CONFIG_INTR_REMAP
>  	dmar_table_init_ret = dmar_table_init();
> -	if (dmar_table_init_ret)
> -		pr_debug("dmar_table_init() failed with %d:\n",
> -				dmar_table_init_ret);
> -#endif
> +	if (dmar_table_init_ret && !x2apic_supported())
> +		return;
>  
>  	ioapic_entries = alloc_ioapic_entries();
>  	if (!ioapic_entries) {

Ack.


  reply	other threads:[~2009-08-17 22:54 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-17 17:53 Yinghai Lu
     [not found] ` <20090817180924.GA8599@elte.hu>
2009-08-17 18:19   ` Yinghai Lu
2009-08-17 18:33     ` Suresh Siddha
2009-08-17 20:47       ` Yinghai Lu
2009-08-17 22:53         ` Suresh Siddha [this message]
2009-08-17 19:25     ` [tip:x86/apic] x86, apic: Move dmar_table_init() out of enable_IR() tip-bot for Yinghai Lu

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=1250549596.2709.254.camel@sbs-t61.sc.intel.com \
    --to=suresh.b.siddha@intel.com \
    --cc=gleb@redhat.com \
    --cc=hpa@zytor.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=peterz@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=venkatesh.pallipadi@intel.com \
    --cc=yinghai@kernel.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

Powered by JetHome