From: Jesse Barnes <jbarnes@virtuousgeek.org>
To: Stefan Richter <stefanr@s5r6.in-berlin.de>,
linux-kernel@vger.kernel.org, linux-pci@atrey.karlin.mff.cuni.cz,
Greg KH <greg@kroah.com>
Subject: [PATCH] fix for Toshiba ohci1394 quirk
Date: Tue, 8 Nov 2005 20:13:02 -0800 [thread overview]
Message-ID: <200511082013.02627.jbarnes@virtuousgeek.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 976 bytes --]
After much testing and agony, I've discovered that my previous ohci1394
quirk for Toshiba laptops is not 100% reliable. It apparently fails to
do the interrupt line change either correctly or in time, since in
about 2 out of 5 boots, the kernel's irqdebug code will *still* disable
irq 11 when the ohci1394 driver is loaded (at pci_enable_device time I
think).
This patch switches things around a little in the workaround. First, it
removes the mdelay. I didn't see a need for it and my testing has
shown that it's not necessary for the quirk to work.
Secondly, instead of trying to change the interrupt line to what ACPI
tells us it should be, this patch makes the quirk use the value in the
PCI_INTERRUPT_LINE register. On this laptop at least, that seems to be
the right thing to do, though additional testing on other laptops
and/or with actual firewire devices would be appreciated.
Thanks,
Jesse
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
[-- Attachment #2: toshiba-ohci1394-fixup-fix.patch --]
[-- Type: text/x-diff, Size: 736 bytes --]
diff --git a/arch/i386/pci/fixup.c b/arch/i386/pci/fixup.c
index 3984226..eeb1b1f 100644
--- a/arch/i386/pci/fixup.c
+++ b/arch/i386/pci/fixup.c
@@ -433,9 +433,8 @@ static void __devinit pci_post_fixup_tos
return; /* only applies to certain Toshibas (so far) */
/* Restore config space on Toshiba laptops */
- mdelay(10);
pci_write_config_word(dev, PCI_CACHE_LINE_SIZE, toshiba_line_size);
- pci_write_config_word(dev, PCI_INTERRUPT_LINE, dev->irq);
+ pci_read_config_byte(dev, PCI_INTERRUPT_LINE, (u8 *)&dev->irq);
pci_write_config_dword(dev, PCI_BASE_ADDRESS_0,
pci_resource_start(dev, 0));
pci_write_config_dword(dev, PCI_BASE_ADDRESS_1,
diff --git a/drivers/ieee1394/ohci1394.c b/drivers/ieee1394/ohci1394.c
next reply other threads:[~2005-11-09 4:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-11-09 4:13 Jesse Barnes [this message]
2005-11-09 22:30 ` Jesse Barnes
2005-11-09 22:34 ` Greg KH
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=200511082013.02627.jbarnes@virtuousgeek.org \
--to=jbarnes@virtuousgeek.org \
--cc=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@atrey.karlin.mff.cuni.cz \
--cc=stefanr@s5r6.in-berlin.de \
/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
all inboxes | Powered by JetHome®