From: Bjorn Helgaas <bjorn.helgaas@hp.com>
To: linux-os@analogic.com
Cc: David Vrabel <dvrabel@cantab.net>, aryix <aryix@softhome.net>,
lug-list@lugmen.org.ar,
Linux kernel <linux-kernel@vger.kernel.org>
Subject: Re: dmesg: PCI interrupts are no longer routed automatically.........
Date: Wed, 05 Jan 2005 10:13:56 -0700 [thread overview]
Message-ID: <1104945236.4046.25.camel@eeyore> (raw)
In-Reply-To: <Pine.LNX.4.61.0501050640430.12879@chaos.analogic.com>
On Wed, 2005-01-05 at 07:06 -0500, linux-os wrote:
> The temporary work-around is....
> pci_enable_device(pdev);
> save_irq = pdev->irq;
> pci_disable_device(pdev); // Turn back off.
>
> init_bars(....);
> request_irq(save_irq,...) // Put ISR in place
>
> pci_write_config_byte(pdev, PCI_CACHE_LINE_SIZE, 0x08);
> pci_write_config_byte(pdev, PCI_LATENCY_TIMER, 0x40);
> pci_set_dma_mask(pdev, 0x00000000ffffffffULL);
> pci_set_drvdata(pdev, NULL);
> pci_set_power_state(pdev, 0);
> pci_set_master(pdev);
> pci_set_mwi(pdev);
> pci_write_config_dword(pdev, PCI_COMMAND, PCI_CONFIG);
>
> .... configure chip-specific stuff, clear interrupts, etc.
> pci_enable_device(dev);
So prior to 2.6.10, you did something like this?
request_irq(pdev->irq, ...);
pci_write_config_byte(pdev, PCI_CACHE_LINE_SIZE, 0x08);
pci_write_config_byte(pdev, PCI_LATENCY_TIMER, 0x40);
...
pci_enable_device(pdev);
What sort of interrupts does the device generate before it's
enabled? I can't find anything in the PCI spec that actually
prohibits interrupts before the driver starts up the device,
but it does seem strange.
You wouldn't want your ISR mucking around with a half-initialized
device, so does it have to check a "device_configured" flag
or something?
next prev parent reply other threads:[~2005-01-05 17:14 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-12-29 9:55 dmesg: PCI interrupts are no longer routed automatically aryix
2005-01-04 18:18 ` Bjorn Helgaas
2005-01-04 18:53 ` linux-os
2005-01-04 19:41 ` Bjorn Helgaas
2005-01-04 19:55 ` linux-os
2005-01-05 9:40 ` David Vrabel
2005-01-05 12:06 ` linux-os
2005-01-05 17:13 ` Bjorn Helgaas [this message]
2005-01-05 18:15 ` linux-os
2005-01-10 21:38 ` Bjorn Helgaas
2005-01-10 22:03 ` linux-os
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=1104945236.4046.25.camel@eeyore \
--to=bjorn.helgaas@hp.com \
--cc=aryix@softhome.net \
--cc=dvrabel@cantab.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-os@analogic.com \
--cc=lug-list@lugmen.org.ar \
/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).