linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Anton Blanchard <anton@samba.org>
To: Mohan Kumar M <mohan@in.ibm.com>
Cc: linuxppc-dev@ozlabs.org, Nathan Lynch <ntl@pobox.com>,
	fastboot@lists.osdl.org
Subject: Re: [RFC] Fix for interrupt distribution
Date: Fri, 17 Nov 2006 02:36:16 +1100	[thread overview]
Message-ID: <20061116153616.GA670@krispykreme> (raw)
In-Reply-To: <20061116125637.GB13004@in.ibm.com>

 
Hi,

Thanks for fixing this problem. One thing I noticed in the patch:

> +	np = cpuid_to_of_node(boot_cpuid);
> +	BUG_ON(!np);
> +	ireg = get_property(np, "ibm,ppc-interrupt-gserver#s", &ilen);
> +	hcpuid = get_hard_smp_processor_id(boot_cpuid);
> +
> +	if (ireg[0] == hcpuid)
> +		default_distrib_server = ireg[1];
> +	else
> +		default_distrib_server = ireg[3];

While this will work on current firmware it would be more robust to loop
through interrupt-gserver#s until you find your cpuid. For example we
set up multiple interrupt-gserver#s entries in the lab so we can have
chip, node local and global targets:

ibm,ppc-interrupt-server#s
	00000002 00000003

ibm,ppc-interrupt-gserver#s
	00000002 000000ff 00000003 000000ff 00000002 000000f7
	00000003 000000f7 00000002 000000d7
	00000003 000000d7

We always put the global target at the end (0xd7 in this case) because
the current code in Linux just grabs the last entry in the array to get
the global server. So the question is, do we look for the first or the
last entry that matches your cpuid to find the global server?

It might be worth getting something added to the architecture (PAPR) to
clear it up. To match what current Linux does, we would want servers to
go from including the least to the most cpus, so the global one is at
the end.

Anton

  reply	other threads:[~2006-11-16 15:36 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-30 18:04 [RFC] Fix for interrupt distribution Mohan Kumar M
2006-10-30 18:17 ` Nathan Lynch
2006-10-31 11:05   ` Mohan Kumar M
2006-11-06 22:46     ` Nathan Lynch
2006-11-16 12:56       ` Mohan Kumar M
2006-11-16 15:36         ` Anton Blanchard [this message]
2006-11-17  4:57           ` Mohan Kumar M
2006-11-17 12:12           ` Mohan Kumar M
2006-11-29  9:10             ` [PATCH] " Mohan Kumar M

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=20061116153616.GA670@krispykreme \
    --to=anton@samba.org \
    --cc=fastboot@lists.osdl.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=mohan@in.ibm.com \
    --cc=ntl@pobox.com \
    /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).