From: Nathan Lynch <ntl@pobox.com>
To: Haren Myneni <haren@us.ibm.com>
Cc: Milton Miller II <miltonm@us.ibm.com>,
Paul Mackerras <paulus@samba.org>,
External List <linuxppc-dev@ozlabs.org>
Subject: Re: [PATCH] Add rtas_set_indicator_fast() for RTAS call without extended delay
Date: Wed, 26 Jul 2006 17:04:41 -0500 [thread overview]
Message-ID: <20060726220441.GZ19076@localdomain> (raw)
In-Reply-To: <44C6F521.8040609@us.ibm.com>
Haren Myneni wrote:
> diff -Naurp 2618-rc2.orig/arch/powerpc/kernel/rtas.c 2618-rc2/arch/powerpc/kernel/rtas.c
> --- 2618-rc2.orig/arch/powerpc/kernel/rtas.c 2006-07-25 19:34:11.000000000 -0700
> +++ 2618-rc2/arch/powerpc/kernel/rtas.c 2006-07-25 19:33:16.000000000 -0700
> @@ -569,6 +569,27 @@ int rtas_set_indicator(int indicator, in
> }
> EXPORT_SYMBOL(rtas_set_indicator);
>
> +/*
> + * Ignoring RTAS extended delay
> + */
> +int rtas_set_indicator_fast(int indicator, int index, int new_value)
> +{
> + int rc;
> + int token = rtas_token("set-indicator");
> +
> + if (token == RTAS_UNKNOWN_SERVICE)
> + return -ENOENT;
> +
> + rc = rtas_call(token, 3, 1, NULL, indicator, index, new_value);
> +
> + WARN_ON(rc == -2 || (rc >= 9900 && rc <= 9905));
> +
> + if (rc < 0)
> + return rtas_error_rc(rc);
> +
> + return rc;
> +}
> +
> void rtas_restart(char *cmd)
> {
> if (rtas_flash_term_hook)
> diff -Naurp 2618-rc2.orig/arch/powerpc/platforms/pseries/xics.c 2618-rc2/arch/powerpc/platforms/pseries/xics.c
> --- 2618-rc2.orig/arch/powerpc/platforms/pseries/xics.c 2006-07-25 19:34:41.000000000 -0700
> +++ 2618-rc2/arch/powerpc/platforms/pseries/xics.c 2006-07-25 19:33:36.000000000 -0700
> @@ -796,7 +796,7 @@ void xics_teardown_cpu(int secondary)
> * so leave the master cpu in the group.
> */
> if (secondary)
> - rtas_set_indicator(GLOBAL_INTERRUPT_QUEUE,
> + rtas_set_indicator_fast(GLOBAL_INTERRUPT_QUEUE,
> (1UL << interrupt_server_size) - 1 -
> default_distrib_server, 0);
> }
> @@ -813,7 +813,7 @@ void xics_migrate_irqs_away(void)
> xics_set_cpu_priority(cpu, 0);
>
> /* remove ourselves from the global interrupt queue */
> - status = rtas_set_indicator(GLOBAL_INTERRUPT_QUEUE,
> + status = rtas_set_indicator_fast(GLOBAL_INTERRUPT_QUEUE,
> (1UL << interrupt_server_size) - 1 - default_distrib_server, 0);
> WARN_ON(status < 0);
>
Looks fine to me from a quick look, but we need to use
rtas_set_indicator_fast in xics_setup_cpu as well (I think I neglected
to mention I saw the warning in the cpu up path, sorry).
next prev parent reply other threads:[~2006-07-26 22:05 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-26 4:52 [PATCH] Add rtas_set_indicator_fast() for RTAS call without extended delay Haren Myneni
2006-07-26 22:04 ` Nathan Lynch [this message]
2006-07-27 21:29 ` Haren Myneni
2006-07-31 4:04 ` Paul Mackerras
2006-07-31 4:38 ` Nathan Lynch
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=20060726220441.GZ19076@localdomain \
--to=ntl@pobox.com \
--cc=haren@us.ibm.com \
--cc=linuxppc-dev@ozlabs.org \
--cc=miltonm@us.ibm.com \
--cc=paulus@samba.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;
as well as URLs for NNTP newsgroup(s).