* IDE driver assined IRQ for disabled IDE channel
@ 2008-07-25 5:31 TAKADA Yoshihito
2008-07-26 11:58 ` Bartlomiej Zolnierkiewicz
0 siblings, 1 reply; 6+ messages in thread
From: TAKADA Yoshihito @ 2008-07-25 5:31 UTC (permalink / raw)
To: linux-ide
Hi.
In kernel 2.6.26, I disable the secoundary IDE via BIOS. But kernel assigned IRQ to secondary IDE.
I saw /proc/interrupts:
- /proc/interrupts of 2.6.25
CPU0
0: 232213 XT-PIC-XT timer
1: 388 XT-PIC-XT i8042
2: 0 XT-PIC-XT cascade
3: 1 XT-PIC-XT
4: 305 XT-PIC-XT
5: 1 XT-PIC-XT
7: 1 XT-PIC-XT
8: 0 XT-PIC-XT rtc0
9: 1 XT-PIC-XT
10: 1 XT-PIC-XT
11: 1 XT-PIC-XT
12: 110 XT-PIC-XT i8042
14: 5640 XT-PIC-XT ide0
15: 35 XT-PIC-XT yenta, ohci_hcd:usb1
NMI: 0 Non-maskable interrupts
TRM: 0 Thermal event interrupts
SPU: 0 Spurious interrupts
ERR: 0
IRQ15 doesn't assigned for ide1.
- /proc/interrupts of 2.6.26
CPU0
0: 213884 XT-PIC-XT timer
1: 197 XT-PIC-XT i8042
2: 0 XT-PIC-XT cascade
3: 1 XT-PIC-XT
4: 309 XT-PIC-XT
5: 1 XT-PIC-XT
7: 2 XT-PIC-XT
8: 0 XT-PIC-XT rtc0
9: 1 XT-PIC-XT
10: 1 XT-PIC-XT
11: 1 XT-PIC-XT
12: 110 XT-PIC-XT i8042
14: 5621 XT-PIC-XT ide0
15: 0 XT-PIC-XT ide1
NMI: 0 Non-maskable interrupts
TRM: 0 Thermal event interrupts
SPU: 0 Spurious interrupts
ERR: 1
However, kernel 2.6.26 assinged IRQ15 for ide1. And yenta and ohci
(USB host controller) couldn't assign an IRQ.
dmesg are:
Yenta: CardBus bridge found at 0000:00:01.0 [0000:0000]
Yenta: no PCI IRQ, CardBus support disabled for this socket.
Yenta: check your BIOS CardBus, BIOS IRQ or ACPI settings.
ohci_hcd: 2006 August 04 USB 1.1 'Open' Host Controller (OHCI) Driver
ohci_hcd 0000:00:13.0: OHCI Host Controller
ohci_hcd 0000:00:13.0: new USB bus registered, assigned bus number 1
ohci_hcd 0000:00:13.0: request interrupt 15 failed
ohci_hcd 0000:00:13.0: USB bus 1 deregistered
ohci_hcd 0000:00:13.0: init 0000:00:13.0 fail, -16
ohci_hcd: probe of 0000:00:13.0 failed with error -16
Signed-off-by: TAKADA Yoshihito <takada@mbf.nifty.com>
diff -Narup a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c
--- a/drivers/ide/ide-probe.c 2008-07-25 13:21:37.000000000 +0900
+++ b/drivers/ide/ide-probe.c 2008-07-25 13:42:38.000000000 +0900
@@ -1546,6 +1546,8 @@ int ide_device_add_all(u8 *idx, const st
continue;
hwif = &ide_hwifs[idx[i]];
+ if (!hwif->present)
+ continue;
if (hwif_init(hwif) == 0) {
printk(KERN_INFO "%s: failed to initialize IDE "
@@ -1582,12 +1584,11 @@ int ide_device_add_all(u8 *idx, const st
continue;
hwif = &ide_hwifs[idx[i]];
-
- ide_sysfs_register_port(hwif);
- ide_proc_register_port(hwif);
-
- if (hwif->present)
+ if (hwif->present) {
+ ide_sysfs_register_port(hwif);
+ ide_proc_register_port(hwif);
ide_proc_port_register_devices(hwif);
+ }
}
return rc;
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: IDE driver assined IRQ for disabled IDE channel
2008-07-25 5:31 IDE driver assined IRQ for disabled IDE channel TAKADA Yoshihito
@ 2008-07-26 11:58 ` Bartlomiej Zolnierkiewicz
2008-07-27 1:51 ` TAKADA Yoshihito
0 siblings, 1 reply; 6+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2008-07-26 11:58 UTC (permalink / raw)
To: TAKADA Yoshihito; +Cc: linux-ide
Hi,
On Friday 25 July 2008, TAKADA Yoshihito wrote:
> Hi.
> In kernel 2.6.26, I disable the secoundary IDE via BIOS. But kernel assigned IRQ to secondary IDE.
> I saw /proc/interrupts:
> - /proc/interrupts of 2.6.25
> CPU0
> 0: 232213 XT-PIC-XT timer
> 1: 388 XT-PIC-XT i8042
> 2: 0 XT-PIC-XT cascade
> 3: 1 XT-PIC-XT
> 4: 305 XT-PIC-XT
> 5: 1 XT-PIC-XT
> 7: 1 XT-PIC-XT
> 8: 0 XT-PIC-XT rtc0
> 9: 1 XT-PIC-XT
> 10: 1 XT-PIC-XT
> 11: 1 XT-PIC-XT
> 12: 110 XT-PIC-XT i8042
> 14: 5640 XT-PIC-XT ide0
> 15: 35 XT-PIC-XT yenta, ohci_hcd:usb1
> NMI: 0 Non-maskable interrupts
> TRM: 0 Thermal event interrupts
> SPU: 0 Spurious interrupts
> ERR: 0
>
> IRQ15 doesn't assigned for ide1.
>
> - /proc/interrupts of 2.6.26
> CPU0
> 0: 213884 XT-PIC-XT timer
> 1: 197 XT-PIC-XT i8042
> 2: 0 XT-PIC-XT cascade
> 3: 1 XT-PIC-XT
> 4: 309 XT-PIC-XT
> 5: 1 XT-PIC-XT
> 7: 2 XT-PIC-XT
> 8: 0 XT-PIC-XT rtc0
> 9: 1 XT-PIC-XT
> 10: 1 XT-PIC-XT
> 11: 1 XT-PIC-XT
> 12: 110 XT-PIC-XT i8042
> 14: 5621 XT-PIC-XT ide0
> 15: 0 XT-PIC-XT ide1
> NMI: 0 Non-maskable interrupts
> TRM: 0 Thermal event interrupts
> SPU: 0 Spurious interrupts
> ERR: 1
>
> However, kernel 2.6.26 assinged IRQ15 for ide1. And yenta and ohci
> (USB host controller) couldn't assign an IRQ.
>
> dmesg are:
> Yenta: CardBus bridge found at 0000:00:01.0 [0000:0000]
> Yenta: no PCI IRQ, CardBus support disabled for this socket.
> Yenta: check your BIOS CardBus, BIOS IRQ or ACPI settings.
>
> ohci_hcd: 2006 August 04 USB 1.1 'Open' Host Controller (OHCI) Driver
> ohci_hcd 0000:00:13.0: OHCI Host Controller
> ohci_hcd 0000:00:13.0: new USB bus registered, assigned bus number 1
> ohci_hcd 0000:00:13.0: request interrupt 15 failed
> ohci_hcd 0000:00:13.0: USB bus 1 deregistered
> ohci_hcd 0000:00:13.0: init 0000:00:13.0 fail, -16
> ohci_hcd: probe of 0000:00:13.0 failed with error -16
Could you please post the full dmesg?
The second IDE port should be skipped by the corresponding host driver
if disabled in BIOS (it could be that this particular host driver neeeds
fixing).
> Signed-off-by: TAKADA Yoshihito <takada@mbf.nifty.com>
>
> diff -Narup a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c
> --- a/drivers/ide/ide-probe.c 2008-07-25 13:21:37.000000000 +0900
> +++ b/drivers/ide/ide-probe.c 2008-07-25 13:42:38.000000000 +0900
> @@ -1546,6 +1546,8 @@ int ide_device_add_all(u8 *idx, const st
> continue;
>
> hwif = &ide_hwifs[idx[i]];
> + if (!hwif->present)
> + continue;
Unfortunately we can't fix it this way as this will cause regression
for other people (we now want ports with no devices attached to be also
registered to allow warm-plugging of IDE devices).
BTW sorry for breaking things for you with every major kernel release ;)
(any chance that you give linux-next kernels a test drive from time to
time so we catch such problems early?)
> if (hwif_init(hwif) == 0) {
> printk(KERN_INFO "%s: failed to initialize IDE "
> @@ -1582,12 +1584,11 @@ int ide_device_add_all(u8 *idx, const st
> continue;
>
> hwif = &ide_hwifs[idx[i]];
> -
> - ide_sysfs_register_port(hwif);
> - ide_proc_register_port(hwif);
> -
> - if (hwif->present)
> + if (hwif->present) {
> + ide_sysfs_register_port(hwif);
> + ide_proc_register_port(hwif);
> ide_proc_port_register_devices(hwif);
> + }
> }
>
> return rc;
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: IDE driver assined IRQ for disabled IDE channel
2008-07-26 11:58 ` Bartlomiej Zolnierkiewicz
@ 2008-07-27 1:51 ` TAKADA Yoshihito
2008-07-27 13:56 ` Bartlomiej Zolnierkiewicz
0 siblings, 1 reply; 6+ messages in thread
From: TAKADA Yoshihito @ 2008-07-27 1:51 UTC (permalink / raw)
To: bzolnier; +Cc: linux-ide
[-- Attachment #1: Type: Text/Plain, Size: 624 bytes --]
From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: Re: IDE driver assined IRQ for disabled IDE channel
Date: Sat, 26 Jul 2008 13:58:59 +0200
Hi. Thanks for your reply.
> Could you please post the full dmesg?
Ok. Attached it.
> Unfortunately we can't fix it this way as this will cause regression
> for other people (we now want ports with no devices attached to be also
> registered to allow warm-plugging of IDE devices).
ide_probe_port() returns -ENODEV, so hwif->present clear to 0.
I think hwif->present mean IDE channel is exist/enabled. Doesn't mean
connected devices(disks, CD-ROM drives and others).
[-- Attachment #2: dmesgs.tar.gz --]
[-- Type: Application/Octet-Stream, Size: 4476 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: IDE driver assined IRQ for disabled IDE channel
2008-07-27 1:51 ` TAKADA Yoshihito
@ 2008-07-27 13:56 ` Bartlomiej Zolnierkiewicz
2008-07-30 17:57 ` TAKADA Yoshihito
0 siblings, 1 reply; 6+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2008-07-27 13:56 UTC (permalink / raw)
To: TAKADA Yoshihito; +Cc: linux-ide
On Sunday 27 July 2008, TAKADA Yoshihito wrote:
> From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
> Subject: Re: IDE driver assined IRQ for disabled IDE channel
> Date: Sat, 26 Jul 2008 13:58:59 +0200
>
> Hi. Thanks for your reply.
>
> > Could you please post the full dmesg?
>
> Ok. Attached it.
Thank you.
dmesg-2.6.26:
...
PCI: PCI BIOS revision 2.10 entry at 0xfb9a0, last bus=0
PCI: Using configuration type 1 for base access
Setting up standard PCI resources
...
Uniform Multi-Platform E-IDE driver
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
ide_generic: please use "probe_mask=0x3f" module parameter for probing all legacy ISA IDE ports
Probing IDE interface ide0...
hda: IC25N030ATCS04-0, ATA DISK drive
Probing IDE interface ide1...
ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
ide1 at 0x170-0x177,0x376 on irq 15
...
ide_generic has no enablebits checking but 'ide_generic.probe_mask=1'
kernel parameter can be used to limit probing to the first port only.
However shouldn't a designated IDE PCI host driver be used instead?
[ if this is Cx5520 PCI IDE, the cs5520 host driver misses enablebits
checking, untested fix attached ]
> > Unfortunately we can't fix it this way as this will cause regression
> > for other people (we now want ports with no devices attached to be also
> > registered to allow warm-plugging of IDE devices).
>
> ide_probe_port() returns -ENODEV, so hwif->present clear to 0.
> I think hwif->present mean IDE channel is exist/enabled. Doesn't mean
> connected devices(disks, CD-ROM drives and others).
It used to mean both because the port was registered only if there
were devices connected to it but it is no longer a case (seems like
->present documentation in ide.h is out of date now and needs fixing).
From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: [PATCH] cs5520: add enablebits checking
Based on sparse comments in OpenFirmware code
(no Cx5510/Cx5520 datasheet here).
Cc: TAKADA Yoshihito <takada@mbf.nifty.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
---
drivers/ide/pci/cs5520.c | 1 +
1 file changed, 1 insertion(+)
Index: b/drivers/ide/pci/cs5520.c
===================================================================
--- a/drivers/ide/pci/cs5520.c
+++ b/drivers/ide/pci/cs5520.c
@@ -123,6 +123,7 @@ static const struct ide_dma_ops cs5520_d
#define DECLARE_CS_DEV(name_str) \
{ \
.name = name_str, \
+ .enablebits = { {0x60, 0x01, 0x01}, {0x60, 0x02, 0x02} }, \
.port_ops = &cs5520_port_ops, \
.dma_ops = &cs5520_dma_ops, \
.host_flags = IDE_HFLAG_ISA_PORTS | \
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: IDE driver assined IRQ for disabled IDE channel
2008-07-27 13:56 ` Bartlomiej Zolnierkiewicz
@ 2008-07-30 17:57 ` TAKADA Yoshihito
2008-08-02 16:28 ` Bartlomiej Zolnierkiewicz
0 siblings, 1 reply; 6+ messages in thread
From: TAKADA Yoshihito @ 2008-07-30 17:57 UTC (permalink / raw)
To: bzolnier; +Cc: linux-ide
From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: Re: IDE driver assined IRQ for disabled IDE channel
Date: Sun, 27 Jul 2008 15:56:52 +0200
> ide_generic has no enablebits checking but 'ide_generic.probe_mask=1'
> kernel parameter can be used to limit probing to the first port only.
Ok, I understood.
> However shouldn't a designated IDE PCI host driver be used instead?
I feel drivers/ide/cs5520 is unstable with TuxOnIce. So I use ide_generic
instead of cs5520 and looked at the state
> [ if this is Cx5520 PCI IDE, the cs5520 host driver misses enablebits
> checking, untested fix attached ]
Yes, My little box has cs5520. I applied the patch, it works fine.
dmesg says:
Uniform Multi-Platform E-IDE driver
ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
Cyrix 5520: IDE controller (0x1078:0x0002 rev 0x00) at PCI slot 0000:00:12.0
PCI: Setting latency timer of device 0000:00:12.0 to 64
Cyrix 5520: IDE port disabled
ide0: BM-DMA at 0x5000-0x5007
Probing IDE interface ide0...
hda: IC25N030ATCS04-0, ATA DISK drive
> ide_generic has no enablebits checking but 'ide_generic.probe_mask=1'
> kernel parameter can be used to limit probing to the first port only.
Ok, I understood.
> However shouldn't a designated IDE PCI host driver be used instead?
I feel drivers/ide/cs5520 is unstable with TuxOnIce. So I use ide_generic
instead of cs5520 and looked at the state.
> > ide_probe_port() returns -ENODEV, so hwif->present clear to 0.
> > I think hwif->present mean IDE channel is exist/enabled. Doesn't mean
> > connected devices(disks, CD-ROM drives and others).
>
> It used to mean both because the port was registered only if there
> were devices connected to it but it is no longer a case (seems like
> ->present documentation in ide.h is out of date now and needs fixing).
I see too.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: IDE driver assined IRQ for disabled IDE channel
2008-07-30 17:57 ` TAKADA Yoshihito
@ 2008-08-02 16:28 ` Bartlomiej Zolnierkiewicz
0 siblings, 0 replies; 6+ messages in thread
From: Bartlomiej Zolnierkiewicz @ 2008-08-02 16:28 UTC (permalink / raw)
To: TAKADA Yoshihito; +Cc: linux-ide
On Wednesday 30 July 2008, TAKADA Yoshihito wrote:
> From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
> Subject: Re: IDE driver assined IRQ for disabled IDE channel
> Date: Sun, 27 Jul 2008 15:56:52 +0200
>
> > ide_generic has no enablebits checking but 'ide_generic.probe_mask=1'
> > kernel parameter can be used to limit probing to the first port only.
>
> Ok, I understood.
>
> > However shouldn't a designated IDE PCI host driver be used instead?
>
> I feel drivers/ide/cs5520 is unstable with TuxOnIce. So I use ide_generic
> instead of cs5520 and looked at the state
This may be because cs5520 lacks proper PCI Power Management support
(which will be addressed really soon - 2.6.27-rc1 has the needed
infrastructure and I will post the follow up patch addding it today).
> > [ if this is Cx5520 PCI IDE, the cs5520 host driver misses enablebits
> > checking, untested fix attached ]
>
> Yes, My little box has cs5520. I applied the patch, it works fine.
> dmesg says:
>
> Uniform Multi-Platform E-IDE driver
> ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=xx
> Cyrix 5520: IDE controller (0x1078:0x0002 rev 0x00) at PCI slot 0000:00:12.0
> PCI: Setting latency timer of device 0000:00:12.0 to 64
> Cyrix 5520: IDE port disabled
> ide0: BM-DMA at 0x5000-0x5007
> Probing IDE interface ide0...
> hda: IC25N030ATCS04-0, ATA DISK drive
Thanks, for testing it.
I'll push the fix to Linus and once it is in I'll ping the -stable
team to merge 2.6.26 version.
Thanks,
Bart
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2008-08-02 17:09 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-25 5:31 IDE driver assined IRQ for disabled IDE channel TAKADA Yoshihito
2008-07-26 11:58 ` Bartlomiej Zolnierkiewicz
2008-07-27 1:51 ` TAKADA Yoshihito
2008-07-27 13:56 ` Bartlomiej Zolnierkiewicz
2008-07-30 17:57 ` TAKADA Yoshihito
2008-08-02 16:28 ` Bartlomiej Zolnierkiewicz
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).