public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Helgaas <bjorn.helgaas@hp.com>
To: acpi-devel@lists.sourceforge.net, linux-ia64@vger.kernel.org
Cc: Len Brown <len.brown@intel.com>,
	"Nakajima, Jun" <jun.nakajima@intel.com>
Subject: Re: [ACPI] [PATCH] add acpi_interrupt_to_irq
Date: Wed, 21 Jan 2004 13:18:19 -0700	[thread overview]
Message-ID: <200401211318.19330.bjorn.helgaas@hp.com> (raw)
In-Reply-To: <200401210939.08782.bjorn.helgaas@hp.com>

On Wednesday 21 January 2004 9:39 am, Bjorn Helgaas wrote:
> There's also something fishy in this area that neither the -mm5
> code nor my patch addresses.  In the acpi_os_install_interrupt_handler()
> fragment above, we do the "acpi interrupt->irq" conversion and save
> the resulting irq in acpi_irq_irq.  The only place acpi_irq_irq is
> used is in acpi_os_terminate(), where it is passed to acpi_os_remove_
> interupt_handler(), where we apply the "acpi interrupt->irq" conversion
> AGAIN.  This seems wrong.

OK, I think I understand what's wrong there.  acpi_irq_irq needs to
be the PRE-CONVERSION interrupt, like this:

    acpi_status
    acpi_os_install_interrupt_handler(u32 interrupt, OSD_HANDLER handler, void *context)
    {
	unsigned int irq;

	interrupt = acpi_fadt.sci_int;
	irq = acpi_irq_to_vector(interrupt); 
	...
        acpi_irq_irq = interrupt;
	...
	if (request_irq(irq, ...))

Then acpi_os_terminate() will pass the pre-conversion value to
acpi_os_remove_interrupt_handler(), which will apply acpi_irq_to_vector()
and everything will match.

I'll make a note to clean this up after the previous issues in the
area are straightened out.

Bjorn


  reply	other threads:[~2004-01-21 20:18 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-20 23:07 [PATCH] add acpi_interrupt_to_irq Bjorn Helgaas
     [not found] ` <200401201607.32214.bjorn.helgaas-VXdhtT5mjnY@public.gmane.org>
2004-01-21 16:39   ` Bjorn Helgaas
2004-01-21 20:18     ` Bjorn Helgaas [this message]
  -- strict thread matches above, loose matches on Subject: below --
2004-01-21 22:42 [ACPI] " Nakajima, Jun
2004-01-22  3:36 Nakajima, Jun
2004-01-22 16:38 ` [ACPI] " Bjorn Helgaas
2004-01-22 17:41 Brown, Len
2004-01-22 19:08 ` David Mosberger

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=200401211318.19330.bjorn.helgaas@hp.com \
    --to=bjorn.helgaas@hp.com \
    --cc=acpi-devel@lists.sourceforge.net \
    --cc=jun.nakajima@intel.com \
    --cc=len.brown@intel.com \
    --cc=linux-ia64@vger.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