scsi controller aic7xxx should set name scanner and permissions automaticly

Bug #378989 reported by HAMcZlaw on 2009-05-21
26
This bug affects 5 people
Affects Status Importance Assigned to Milestone
sane-frontends (Ubuntu)
Undecided
Unassigned

Bug Description

My scanner HP ScanJet 4c use scsi controller aic7xxx. This controller know to be scanner controller only. At the momment this controller have permissions to root only. I think it will be nice to have this controller configured with udev by default to /dev/scanner with saned group or some thing like this.

lsb_release -rd
Description: Ubuntu 9.04
Release: 9.04

apt-cache policy sane
sane:
  Installiert: (keine)
  Kandidat: 1.0.14-7
  Versions-Tabelle:
     1.0.14-7 0
        500 http://de.archive.ubuntu.com jaunty/universe Packages

udevadm info -a -p /sys/class/scsi_generic/sg3

Udevadm info starts with the device specified by the devpath and then
walks up the chain of parent devices. It prints for every device
found, all possible attributes in the udev rules key format.
A rule to match, can be composed by the attributes of the device
and the attributes from one single parent device.

  looking at device '/devices/pci0000:00/0000:00:0c.0/host3/target3:0:3/3:0:3:0/scsi_generic/sg3':
    KERNEL=="sg3"
    SUBSYSTEM=="scsi_generic"
    DRIVER==""

  looking at parent device '/devices/pci0000:00/0000:00:0c.0/host3/target3:0:3/3:0:3:0':
    KERNELS=="3:0:3:0"
    SUBSYSTEMS=="scsi"
    DRIVERS==""
    ATTRS{device_blocked}=="0"
    ATTRS{type}=="3"
    ATTRS{scsi_level}=="3"
    ATTRS{vendor}=="HP "
    ATTRS{model}=="C2520A "
    ATTRS{rev}=="3503"
    ATTRS{state}=="running"
    ATTRS{timeout}=="0"
    ATTRS{iocounterbits}=="32"
    ATTRS{iorequest_cnt}=="0x369"
    ATTRS{iodone_cnt}=="0x369"
    ATTRS{ioerr_cnt}=="0x1"
    ATTRS{modalias}=="scsi:t-0x03"
    ATTRS{evt_media_change}=="0"
    ATTRS{queue_depth}=="2"
    ATTRS{queue_type}=="none"

  looking at parent device '/devices/pci0000:00/0000:00:0c.0/host3/target3:0:3':
    KERNELS=="target3:0:3"
    SUBSYSTEMS=="scsi"
    DRIVERS==""

  looking at parent device '/devices/pci0000:00/0000:00:0c.0/host3':
    KERNELS=="host3"
    SUBSYSTEMS=="scsi"
    DRIVERS==""

  looking at parent device '/devices/pci0000:00/0000:00:0c.0':
    KERNELS=="0000:00:0c.0"
    SUBSYSTEMS=="pci"
    DRIVERS=="aic7xxx"
    ATTRS{vendor}=="0x9004"
    ATTRS{device}=="0x5078"
    ATTRS{subsystem_vendor}=="0x9004"
    ATTRS{subsystem_device}=="0x7850"
    ATTRS{class}=="0x010000"
    ATTRS{irq}=="16"
    ATTRS{local_cpus}=="ffffffff,ffffffff"
    ATTRS{local_cpulist}=="0-63"
    ATTRS{modalias}=="pci:v00009004d00005078sv00009004sd00007850bc01sc00i00"
    ATTRS{broken_parity_status}=="0"
    ATTRS{msi_bus}==""

  looking at parent device '/devices/pci0000:00':
    KERNELS=="pci0000:00"
    SUBSYSTEMS==""
    DRIVERS==""

jhansonxi (jhansonxi) wrote :

I'm also encountering this problem with a HP ScanJet 6100C. I created a udev rule to fix it.

Ian M. Stewart (ims) wrote :

Me too. My scanner is an Epson GT-7000 on SCSI PCI interface. I placed a new 45-scsi-scanner.rules in /etc/udev/rules.d

Is this the correct place? There are also rules in /lib/udev/rules.d on Jaunty.

jhansonxi (jhansonxi) wrote :

@Ian: Sorry, I wasn't subscribed to this report until now. Unofficial rules should go in "/etc/udev/rules.d". See my blog posting for more info: http://jhansonxi.blogspot.com/2009/08/writing-udev-rules-to-get-scsi-scanner.html

Roman V. Isaev (rm-isaev) wrote :

I just stumbled into this problem. Ubuntu karmic, Epson scanner GT-9000 via scsi cable. The same problem, I had to add

chown root.scanner /dev/sg3

to /etc/rc.local as workaround. I wonder why there is no fix -- this bug was filled about one year ago...

lan (lan-libero) wrote :

Same problem with an epson 1200s after upgrading from 10.04 to 10.10 ;-(

Paul Menzel (pm-debian) wrote :

For completeness. The original reporters problem is not a duplicate of bug #727696 as in 2009 upstream’s udev rule was not created with the line for that device.

Only Ian’s problem seems to be a duplicate of bug #727696.

Nevertheless this issue was fixed in upstream release 1.0.22 containing Julien Blache’s patch for the ScanJet 4c [1] – which has been applied to the package already beforehand – and indirectly also the HP ScanJet 6100C.

For completeness a patch for the ScanJet 6100C was sent to the sane-devel mailing list [2].

[1] http://anonscm.debian.org/gitweb/?p=sane/sane-backends.git;a=commitdiff;h=9b229f06b9fdca1098d7fb5181731b030fbdfccc
[2] http://lists.alioth.debian.org/pipermail/sane-devel/2013-February/030929.html

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers