# System not finding cdrom device

## flip387

Hello Everyone,

I have been looking through the forums as well as searching the net for quite abit now without much success on my system. The issue is my DVD device is not being recognized by the system.

My DVD drive is a I/O Magic DVDRW 16x which many people reported working without a hitch with the standard ide-cdrom module.

Below is some of my config and logs.

---- udev generated automatic -----

gentoo-minimal ~ # cat /etc/udev/rules.d/70-persistent-cd.rules 

# This file was automatically generated by the /lib/udev/write_cd_rules

# program, run by the cd-aliases-generator.rules rules file.

#

# You can modify it, as long as you keep each rule on a single

# line, and set the $GENERATED variable.

# IDE_16X (pci-0000:00:14.1-scsi-0:0:0:0)

ENV{ID_CDROM}=="?*", ENV{ID_PATH}=="pci-0000:00:14.1-scsi-0:0:0:0", SYMLINK+="cdrom", ENV{GENERATED}="1"

ENV{ID_CDROM}=="?*", ENV{ID_PATH}=="pci-0000:00:14.1-scsi-0:0:0:0", SYMLINK+="cdrw", ENV{GENERATED}="1"

ENV{ID_CDROM}=="?*", ENV{ID_PATH}=="pci-0000:00:14.1-scsi-0:0:0:0", SYMLINK+="dvd", ENV{GENERATED}="1"

-

--- lspci -----

gentoo-minimal ~ # lspci 

00:00.0 Host bridge: Advanced Micro Devices [AMD] RS780 Host Bridge Alternate

00:02.0 PCI bridge: Advanced Micro Devices [AMD] RS780 PCI to PCI bridge (ext gfx port 0)

00:0a.0 PCI bridge: Advanced Micro Devices [AMD] RS780 PCI to PCI bridge (PCIE port 5)

00:11.0 SATA controller: ATI Technologies Inc SB700/SB800 SATA Controller [IDE mode]

00:12.0 USB Controller: ATI Technologies Inc SB700/SB800 USB OHCI0 Controller

00:12.1 USB Controller: ATI Technologies Inc SB700 USB OHCI1 Controller

00:12.2 USB Controller: ATI Technologies Inc SB700/SB800 USB EHCI Controller

00:13.0 USB Controller: ATI Technologies Inc SB700/SB800 USB OHCI0 Controller

00:13.1 USB Controller: ATI Technologies Inc SB700 USB OHCI1 Controller

00:13.2 USB Controller: ATI Technologies Inc SB700/SB800 USB EHCI Controller

00:14.0 SMBus: ATI Technologies Inc SBx00 SMBus Controller (rev 3c)

00:14.1 IDE interface: ATI Technologies Inc SB700/SB800 IDE Controller

00:14.2 Audio device: ATI Technologies Inc SBx00 Azalia (Intel HDA)

00:14.3 ISA bridge: ATI Technologies Inc SB700/SB800 LPC host controller

00:14.4 PCI bridge: ATI Technologies Inc SBx00 PCI to PCI Bridge

00:14.5 USB Controller: ATI Technologies Inc SB700/SB800 USB OHCI2 Controller

00:18.0 Host bridge: Advanced Micro Devices [AMD] Family 10h [Opteron, Athlon64, Sempron] HyperTransport Configuration

00:18.1 Host bridge: Advanced Micro Devices [AMD] Family 10h [Opteron, Athlon64, Sempron] Address Map

00:18.2 Host bridge: Advanced Micro Devices [AMD] Family 10h [Opteron, Athlon64, Sempron] DRAM Controller

00:18.3 Host bridge: Advanced Micro Devices [AMD] Family 10h [Opteron, Athlon64, Sempron] Miscellaneous Control

00:18.4 Host bridge: Advanced Micro Devices [AMD] Family 10h [Opteron, Athlon64, Sempron] Link Control

01:00.0 VGA compatible controller: nVidia Corporation GeForce 8800 GTS 512 (rev a2)

02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 02)

03:0e.0 FireWire (IEEE 1394): Texas Instruments TSB43AB23 IEEE-1394a-2000 Controller (PHY/Link)

---

Seems the above udev is refering to device (ENV{ID_PATH}=="pci-0000:00:14.1-scsi-0:0:0:0",), I could be wrong though

00:14.1 IDE interface: ATI Technologies Inc SB700/SB800 IDE Controller

--

--- startup messages --

gentoo-minimal ~ # dmesg | grep CD-ROM

[    0.594872] pcd: No CD-ROM drive found

--

And some of my .conf for my 2.6.32-gentoo-r7 Kernel

gentoo-minimal ~ # cat /usr/src/linux-2.6.32-gentoo-r7/.config | egrep "=y" | egrep "SCSI|ATA"

CONFIG_RELOCATABLE=y

CONFIG_IDE_ATAPI=y

CONFIG_IDE_GD_ATA=y

CONFIG_SCSI=y

CONFIG_SCSI_DMA=y

CONFIG_SCSI_PROC_FS=y

CONFIG_SCSI_CONSTANTS=y

CONFIG_SCSI_SPI_ATTRS=y

CONFIG_ATA=y

CONFIG_ATA_VERBOSE_ERROR=y

CONFIG_ATA_ACPI=y

CONFIG_SATA_PMP=y

CONFIG_SATA_AHCI=y

CONFIG_ATA_SFF=y

CONFIG_ATA_PIIX=y

CONFIG_PATA_AMD=y

CONFIG_ATA_GENERIC=y

CONFIG_PATA_MPIIX=y

CONFIG_PATA_OLDPIIX=y

CONFIG_PATA_RZ1000=y

CONFIG_PATA_SERVERWORKS=y

CONFIG_PATA_SCH=y

CONFIG_DEBUG_RODATA=y

---

Any help will be much appreciated, however please go a bit easy on my I'm still a bit green when it comes to Gentoo.

Thanks

Jeffrey-

----------

## erik258

Hmmm... I'm assuming you have a SATA drive and that the CD-Rom device is the only thing on your PATA bus.  

I think you failed to install the driver for your 

 *Quote:*   

> 
> 
> ```
> 00:14.1 IDE interface: ATI Technologies Inc SB700/SB800 IDE Controller
> ```
> ...

 

If I'm not mistaken, you want CONFIG_PATA_SIS for this particular hardware.  

Incidentally, you may also note that you have support for a number of devices your system doesn't have.  

 *Quote:*   

> 
> 
> ```
> 
> CONFIG_ATA_PIIX=y
> ...

 

It doesn't appear that you hvae any of those devices. (Even though you have an AMD southbridge, you still have a SiS ide controller.  The rest are mostly Intel.  I'm a little surprised that CONFIG_ATA_GENERIC didn't pick it up.   )

Furthermore, I suspect you have CONFIG_IDE (ATA/ATAPI/MFM/RLL support (DEPRECATED) in your kernel.  There's nothing wrong with that, except that these drivers are deprecated and will probably be removed in the not too distant future.  I would recommend turning it off, and using CONFIG_ATA (Serial ATA and Parallel ATA drivers) exclusively.  

Finally, you may need CONFIG_BLK_DEV_SR, scsi cd-rom drive support, but I'm not sure about that.  I am pretty sure your device will show up as /dev/sr0 when you get it working for the same reason your hard disk shows up as sda - the new CONFIG_ATA support makes these devices look like SCSI devices even though they aren't (the same is true of usb_storage).  

Pop back into your kernel config and take a look.  Also consider building the support you think you need as a module - it's the same exact thing except you don't have to reboot to add, remove, and manipulate the driver.  I consider this a very good thing.  

Good luck!

----------

## flip387

Thank you very much for your input erik258, Ill give this a try when I get home later this evening.

As for your assumption about using all SATA devices except for this PATA CD-ROM you are absolutely correct  :Smile: 

Let you know how it goes this evening.

Jeffrey-

----------

## flip387

So far no luck.

```
jness@gentoo-minimal ~ $ grep CONFIG_PATA_SIS /usr/src/linux-2.6.32-gentoo-r7/.config

CONFIG_PATA_SIS=y
```

```
jness@gentoo-minimal ~ $ dmesg | grep CD-ROM

[    0.594380] pcd: No CD-ROM drive found

```

----------

## flip387

And its working!!!   :Very Happy: 

Able to build CONFIG_PATA_SIS as module and then worked.

Thanks erik258 you helped make my day

----------

## erik258

Oh good. Not sure why building it into kernel didn't work, but that isn't necessary unless you use the kernel on a bootable CD with no initrd. 

Glad we could get it working.

----------

