# Firewire device not added as disk [Solved]

## eidolon

Hello,

I have an external Firewire CD/DVD RW - I can boot LiveCD's from it, so presumably it works ok with the BIOS drivers, but as soon as it gets into my Linux OS, it won't show up as a new disk (tried both hotplugging w/ rescan_scsi_bus.sh and rebooting with it plugged in).

All the IEEE kernel modules are modprobed (ieee1394, ohci1394 & sbp2), drive whirrs into life, /proc/scsi/scsi shows the drive present on scsi bus, dmesg shows the drive name & no errors, but then nothing... fdisk -l shows nothing but my HDD. USB drives work fine.

Is there a kernel config setting I've missed? Unfortunately I only have remote access from work, and the drive is not plugged in (so I can't post any error messages at the mo), but let me know if you need any info & I'll try and get it.

Any help greatly appreciated, thanks.Last edited by eidolon on Fri Oct 30, 2009 6:37 pm; edited 1 time in total

----------

## gringo

probably a stupid question but do you have scsi cdrom support in your kernel ?

can we have a look to your kernel config ? 

does the device actually appear in /dev once it is plugged in ? If the answer is no, then this smells like udev is doing sth. wrong.

cheers

----------

## eidolon

Yeah, looks like it (though I never thought to check until you mentioned it).

I'm guessing you don't want a dump of the entire kernel config, so here's ieee/scsi related switches.

```
# cat /usr/src/linux/.config | grep -i "scsi\|ieee\|iso9660\|blk_dev_sr"

CONFIG_CISS_SCSI_TAPE=y

# SCSI device support

CONFIG_SCSI=y

CONFIG_SCSI_DMA=y

CONFIG_SCSI_TGT=m

CONFIG_SCSI_NETLINK=y

CONFIG_SCSI_PROC_FS=y

# SCSI support type (disk, tape, CD-ROM)

CONFIG_BLK_DEV_SR=y

CONFIG_BLK_DEV_SR_VENDOR=y

# Some SCSI devices (e.g. CD jukebox) support multiple LUNs

CONFIG_SCSI_MULTI_LUN=y

CONFIG_SCSI_CONSTANTS=y

CONFIG_SCSI_LOGGING=y

CONFIG_SCSI_SCAN_ASYNC=y

CONFIG_SCSI_WAIT_SCAN=m

# SCSI Transports

CONFIG_SCSI_SPI_ATTRS=m

CONFIG_SCSI_FC_ATTRS=m

CONFIG_SCSI_FC_TGT_ATTRS=y

CONFIG_SCSI_ISCSI_ATTRS=y

CONFIG_SCSI_SAS_ATTRS=m

CONFIG_SCSI_SAS_LIBSAS=m

CONFIG_SCSI_SAS_ATA=y

CONFIG_SCSI_SAS_HOST_SMP=y

# CONFIG_SCSI_SAS_LIBSAS_DEBUG is not set

CONFIG_SCSI_SRP_ATTRS=m

CONFIG_SCSI_SRP_TGT_ATTRS=y

CONFIG_SCSI_LOWLEVEL=y

CONFIG_ISCSI_TCP=y

CONFIG_SCSI_3W_9XXX=m

CONFIG_SCSI_7000FASST=m

CONFIG_SCSI_ACARD=m

CONFIG_SCSI_AHA152X=m

CONFIG_SCSI_AHA1542=m

CONFIG_SCSI_AACRAID=m

CONFIG_SCSI_AIC7XXX=m

# CONFIG_SCSI_AIC7XXX_OLD is not set

CONFIG_SCSI_AIC79XX=m

CONFIG_SCSI_AIC94XX=m

CONFIG_SCSI_DPT_I2O=m

CONFIG_SCSI_ADVANSYS=m

CONFIG_SCSI_IN2000=m

CONFIG_SCSI_ARCMSR=m

# CONFIG_SCSI_ARCMSR_AER is not set

# CONFIG_SCSI_MPT2SAS is not set

CONFIG_SCSI_HPTIOP=m

CONFIG_SCSI_BUSLOGIC=m

# CONFIG_SCSI_FLASHPOINT is not set

CONFIG_SCSI_DMX3191D=m

CONFIG_SCSI_DTC3280=m

CONFIG_SCSI_EATA=m

CONFIG_SCSI_EATA_TAGGED_QUEUE=y

CONFIG_SCSI_EATA_LINKED_COMMANDS=y

CONFIG_SCSI_EATA_MAX_TAGS=16

CONFIG_SCSI_FUTURE_DOMAIN=m

CONFIG_SCSI_GDTH=m

CONFIG_SCSI_GENERIC_NCR5380=m

CONFIG_SCSI_GENERIC_NCR5380_MMIO=m

CONFIG_SCSI_GENERIC_NCR53C400=y

CONFIG_SCSI_IPS=m

CONFIG_SCSI_INITIO=m

CONFIG_SCSI_INIA100=m

CONFIG_SCSI_PPA=m

CONFIG_SCSI_IMM=m

# CONFIG_SCSI_IZIP_EPP16 is not set

# CONFIG_SCSI_IZIP_SLOW_CTR is not set

# CONFIG_SCSI_MVSAS is not set

CONFIG_SCSI_NCR53C406A=m

CONFIG_SCSI_STEX=m

CONFIG_SCSI_SYM53C8XX_2=m

CONFIG_SCSI_SYM53C8XX_DMA_ADDRESSING_MODE=1

CONFIG_SCSI_SYM53C8XX_DEFAULT_TAGS=16

CONFIG_SCSI_SYM53C8XX_MAX_TAGS=64

CONFIG_SCSI_SYM53C8XX_MMIO=y

CONFIG_SCSI_IPR=m

CONFIG_SCSI_IPR_TRACE=y

CONFIG_SCSI_IPR_DUMP=y

CONFIG_SCSI_PAS16=m

CONFIG_SCSI_QLOGIC_FAS=m

CONFIG_SCSI_QLOGIC_1280=m

CONFIG_SCSI_QLA_FC=m

CONFIG_SCSI_QLA_ISCSI=m

CONFIG_SCSI_LPFC=m

# CONFIG_SCSI_LPFC_DEBUG_FS is not set

CONFIG_SCSI_SYM53C416=m

CONFIG_SCSI_DC395x=m

CONFIG_SCSI_DC390T=m

CONFIG_SCSI_T128=m

CONFIG_SCSI_U14_34F=m

CONFIG_SCSI_U14_34F_TAGGED_QUEUE=y

CONFIG_SCSI_U14_34F_LINKED_COMMANDS=y

CONFIG_SCSI_U14_34F_MAX_TAGS=8

CONFIG_SCSI_ULTRASTOR=m

CONFIG_SCSI_NSP32=m

# CONFIG_SCSI_DEBUG is not set

CONFIG_SCSI_SRP=m

CONFIG_SCSI_LOWLEVEL_PCMCIA=y

CONFIG_PCMCIA_NINJA_SCSI=m

CONFIG_SCSI_DH=y

# CONFIG_SCSI_DH_RDAC is not set

# CONFIG_SCSI_DH_HP_SW is not set

# CONFIG_SCSI_DH_EMC is not set

# CONFIG_SCSI_DH_ALUA is not set

# CONFIG_SCSI_OSD_INITIATOR is not set

# IEEE 1394 (FireWire) support

CONFIG_IEEE1394=m

CONFIG_IEEE1394_OHCI1394=m

CONFIG_IEEE1394_PCILYNX=m

CONFIG_IEEE1394_SBP2=m

# CONFIG_IEEE1394_SBP2_PHYS_DMA is not set

CONFIG_IEEE1394_ETH1394_ROM_ENTRY=y

CONFIG_IEEE1394_ETH1394=m

CONFIG_IEEE1394_RAWIO=m

CONFIG_IEEE1394_VIDEO1394=m

CONFIG_IEEE1394_DV1394=m

# CONFIG_IEEE1394_VERBOSEDEBUG is not set

CONFIG_I2O_SCSI=m

# NOTE: USB_STORAGE depends on SCSI but BLK_DEV_SD may

# CONFIG_ISCSI_IBFT_FIND is not set

CONFIG_ISO9660_FS=y
```

I'll check to see if anything gets added to /dev tonight...

----------

## eidolon

As promised, some debugging output:

After modprobing the 3 ieee modules, dmesg:

```
# cat dmesg|tail -n13

ohci1394 0000:0a:09.1: PCI INT A -> GSI 20 (level, low) -> IRQ 20

ohci1394: fw-host0: OHCI-1394 1.1 (PCI): IRQ=[20]  MMIO=[d0206000-d02067ff]  Max Packet=[2048]  IR/IT contexts=[4/8]

ieee1394: Node added: ID:BUS[0-00:1023]  GUID[0010100305116715]

ieee1394: Host added: ID:BUS[0-01:1023]  GUID[00c09f0000d7cc76]

scsi2 : SBP-2 IEEE-1394

ieee1394: sbp2: Logged into SBP-2 device

ieee1394: sbp2: Node 0-00:1023: Max speed [S400] - Max payload [2048]

scsi 2:0:0:0: CD-ROM            MATSHITA DVD-RAM UJ-850S  1.20 PQ: 0 ANSI: 0

sr0: scsi3-mmc drive: 24x/24x writer dvd-ram cd/rw xa/form2 cdda tray

Uniform CD-ROM driver Revision: 3.20

sr 2:0:0:0: Attached scsi CD-ROM sr0

sd 0:0:0:0: Attached scsi generic sg0 type 0

sr 2:0:0:0: Attached scsi generic sg1 type 5
```

rescan-scsi-bus output:

```
# cat rescan_bus_output 

Host adapter 0 (ata_piix) found.

Host adapter 1 (ata_piix) found.

Host adapter 2 (sbp2) found.

Scanning SCSI subsystem for new devices

Scanning host 0 channels 0 for  SCSI target IDs  0 1 2 3 4 5 6 7, all LUNs

Scanning for device 0 0 0 0 ...

OLD: Host: scsi0 Channel: 00 Id: 00 Lun: 00

      Vendor: ATA      Model: Hitachi HTS54161 Rev: SBDO

      Type:   Direct-Access                    ANSI SCSI revision: 05

Scanning host 1 channels 0 for  SCSI target IDs  0 1 2 3 4 5 6 7, all LUNs

Scanning host 2 channels 0 for  SCSI target IDs  0 1 2 3 4 5 6 7, all LUNs

Scanning for device 2 0 0 0 ...

OLD: Host: scsi2 Channel: 00 Id: 00 Lun: 00

      Vendor: MATSHITA Model: DVD-RAM UJ-850S  Rev: 1.20

      Type:   CD-ROM                           ANSI SCSI revision: -1

Report Luns command not supported (support mandatory in SPC-3)

Scanning for device 2 0 0 0 ...

OLD: Host: scsi2 Channel: 00 Id: 00 Lun: 00

      Vendor: MATSHITA Model: DVD-RAM UJ-850S  Rev: 1.20

      Type:   CD-ROM                           ANSI SCSI revision: -1

0 new device(s) found.               

0 device(s) removed
```

dmesg after running rescan-scsi-bus:

```
scsi_alloc_sdev: Allocation failure during SCSI scanning, some SCSI devices might not be configured

scsi_alloc_sdev: Allocation failure during SCSI scanning, some SCSI devices might not be configured

scsi_alloc_sdev: Allocation failure during SCSI scanning, some SCSI devices might not be configured

scsi_alloc_sdev: Allocation failure during SCSI scanning, some SCSI devices might not be configured

scsi_alloc_sdev: Allocation failure during SCSI scanning, some SCSI devices might not be configured

scsi_alloc_sdev: Allocation failure during SCSI scanning, some SCSI devices might not be configured

scsi_alloc_sdev: Allocation failure during SCSI scanning, some SCSI devices might not be configured
```

I guess the clue is in the last message, but I'm not really seeing anything of much help on google. cdrom is in /dev, but its just a symlink to sr0.

Any suggestions greatly appreciated...

Thanks

----------

## Nerevar

Looks like you're using the legacy firewire driver stack (or at least you didn't show the new one by grepping for FIREWIRE in your .config).

You might try the new one and see if that works out better.

----------

## eidolon

No joy sadly - tried the "experimental" firewire-core, firewire-ohci, firewire-sbp2 kernels modules and I get exactly the same result.

Any other suggestions?

----------

## Nerevar

It's no longer marked as experimental in 2.6.31, so it might be worth upgrading. What kernel version are you running? If you just have storage devices which are firewire, did you try building only the new driver stack?

----------

## eidolon

Currently running 2.6.30, so .31 might be an idea but I don't hold out a lot of hope to be honest. The configuration that I've got now is just the new stack.

----------

## Monkeh

It's a CD drive, not an HDD. fdisk won't show it. It's present and usable as /dev/sr0, as the dmesg output shows.

----------

## eidolon

well that's rather embarrassing!   :Embarassed:   I don't know why but for some reason I expected it to show up on fdisk like a usb key would, so I knew what to mount.

So problem solved then - I'm being a complete tit!

Thanks for your help

----------

