re-scan ide devices

Egervary Gergely (mauzi@aquarius.poli.hu)
Mon, 5 Jul 1999 18:07:34 +0200 (CEST)


hy,

when I'm trying to re-scan the IDE devices, I get Input/output error,
meaning ide_register() function fails... why, and how to fix?

kernel: 2.2.10

void
rescan_hwif(int channel)
{
int fd;
int ide[][3] =
{
{0x1f0,0x3f6,14},{0x170,0x376,15}
};

fd=open("/dev/hda", O_RDONLY);
ioctl(fd, HDIO_SCAN_HWIF, ide[channel]);
perror("ioctl");
close(fd);
}

thanks,

mauzi

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/