* Rescan IDE interface when no IDE devices are present
@ 2006-07-16 19:12 Daniel De Graaf
2006-07-16 19:25 ` Benjamin Herrenschmidt
0 siblings, 1 reply; 6+ messages in thread
From: Daniel De Graaf @ 2006-07-16 19:12 UTC (permalink / raw)
To: linux-kernel
My laptop has only one IDE interface (/dev/hdc), which means there are
no valid IDE block devices which can be used for HDIO_SCAN_HWIF ioctl
to scan for the insertion of my CD-ROM drive.
Are there alternate methods of invoking this ioctl, or for creating an
open filehandle where it can be used?
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Rescan IDE interface when no IDE devices are present
2006-07-16 19:12 Rescan IDE interface when no IDE devices are present Daniel De Graaf
@ 2006-07-16 19:25 ` Benjamin Herrenschmidt
2006-07-16 20:03 ` Daniel De Graaf
0 siblings, 1 reply; 6+ messages in thread
From: Benjamin Herrenschmidt @ 2006-07-16 19:25 UTC (permalink / raw)
To: Daniel De Graaf; +Cc: linux-kernel
On Sun, 2006-07-16 at 14:12 -0500, Daniel De Graaf wrote:
> My laptop has only one IDE interface (/dev/hdc), which means there are
> no valid IDE block devices which can be used for HDIO_SCAN_HWIF ioctl
> to scan for the insertion of my CD-ROM drive.
>
> Are there alternate methods of invoking this ioctl, or for creating an
> open filehandle where it can be used?
If you have ide1, you have both hdc and hdd (slave of hdc) unles sit's
not really IDE ...
Ben.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Rescan IDE interface when no IDE devices are present
2006-07-16 19:25 ` Benjamin Herrenschmidt
@ 2006-07-16 20:03 ` Daniel De Graaf
2006-07-16 20:24 ` Joshua Hudson
2006-07-26 1:28 ` Alan Cox
0 siblings, 2 replies; 6+ messages in thread
From: Daniel De Graaf @ 2006-07-16 20:03 UTC (permalink / raw)
To: Benjamin Herrenschmidt; +Cc: linux-kernel
On 7/16/06, Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
> If you have ide1, you have both hdc and hdd (slave of hdc) unles sit's
> not really IDE ...
>
> Ben.
Yes, I have /dev/hdd, but no device is ever present there. I also have
/dev/sda for the SATA hard disk, but do not think it is useful for
HDIO_SCAN_HWIF or HWIO_UNREGISTER_HWIF ioctls.
- Daniel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Rescan IDE interface when no IDE devices are present
2006-07-16 20:03 ` Daniel De Graaf
@ 2006-07-16 20:24 ` Joshua Hudson
2006-07-26 1:28 ` Alan Cox
1 sibling, 0 replies; 6+ messages in thread
From: Joshua Hudson @ 2006-07-16 20:24 UTC (permalink / raw)
To: linux-kernel
I wonder if its like my laptop: hdc is hard disk, hda is cdrom, and in
this case removable so it is necessary to scan for ide0 when inserting
cdrom.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Rescan IDE interface when no IDE devices are present
2006-07-16 20:03 ` Daniel De Graaf
2006-07-16 20:24 ` Joshua Hudson
@ 2006-07-26 1:28 ` Alan Cox
2006-07-26 1:57 ` Daniel De Graaf
1 sibling, 1 reply; 6+ messages in thread
From: Alan Cox @ 2006-07-26 1:28 UTC (permalink / raw)
To: Daniel De Graaf; +Cc: Benjamin Herrenschmidt, linux-kernel
On Sul, 2006-07-16 at 15:03 -0500, Daniel De Graaf wrote:
> On 7/16/06, Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
> > If you have ide1, you have both hdc and hdd (slave of hdc) unles sit's
> > not really IDE ...
> >
> > Ben.
>
> Yes, I have /dev/hdd, but no device is ever present there. I also have
> /dev/sda for the SATA hard disk, but do not think it is useful for
> HDIO_SCAN_HWIF or HWIO_UNREGISTER_HWIF ioctls.
There isn't. Feel free to write a module to do it (see how the ioctl
handles it and follow the same logic). Its at best a hack. libata is
trying to add proper hotplug for ATA/SATA.
Alan
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Rescan IDE interface when no IDE devices are present
2006-07-26 1:28 ` Alan Cox
@ 2006-07-26 1:57 ` Daniel De Graaf
0 siblings, 0 replies; 6+ messages in thread
From: Daniel De Graaf @ 2006-07-26 1:57 UTC (permalink / raw)
To: linux-kernel; +Cc: Benjamin Herrenschmidt, Alan Cox
On 7/25/06, Alan Cox <alan@lxorguk.ukuu.org.uk> wrote:
> On Sul, 2006-07-16 at 15:03 -0500, Daniel De Graaf wrote:
> > On 7/16/06, Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
> > > If you have ide1, you have both hdc and hdd (slave of hdc) unles sit's
> > > not really IDE ...
> > >
> > > Ben.
> >
> > Yes, I have /dev/hdd, but no device is ever present there. I also have
> > /dev/sda for the SATA hard disk, but do not think it is useful for
> > HDIO_SCAN_HWIF or HWIO_UNREGISTER_HWIF ioctls.
>
> There isn't. Feel free to write a module to do it (see how the ioctl
> handles it and follow the same logic). Its at best a hack. libata is
> trying to add proper hotplug for ATA/SATA.
>
> Alan
I wrote a module to do the register/unregister through a /proc file.
It currently only works on ide1; the constants in scan_hw and unreg_hw
should be made to depend on the value written to the /proc if other
interfaces are needed. Available at
http://danieldegraaf.afraid.org/linux/ide_proc_register.c
Daniel
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2006-07-26 1:57 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-16 19:12 Rescan IDE interface when no IDE devices are present Daniel De Graaf
2006-07-16 19:25 ` Benjamin Herrenschmidt
2006-07-16 20:03 ` Daniel De Graaf
2006-07-16 20:24 ` Joshua Hudson
2006-07-26 1:28 ` Alan Cox
2006-07-26 1:57 ` Daniel De Graaf
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.