[Bug 854814] Re: cd drive lock does not work after oneiric upgrade

Tim Booth 854814 at bugs.launchpad.net
Sun Feb 10 16:05:36 UTC 2013


Seems to me that "/lib/udev/cdrom_id --eject-media $device" as called by
/lib/udev/rules.d/60-cdrom_id.rules is trying too hard.  It should
respect the lock flag on the device, maybe with a "--force" option to
eject regardless.  Anyway this is surely a udev bug not a kernel bug.

TIM

** Package changed: linux (Ubuntu) => udev (Ubuntu)

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to udev in Ubuntu.
https://bugs.launchpad.net/bugs/854814

Title:
  cd drive lock does not work after oneiric upgrade

Status in “udev” package in Ubuntu:
  Triaged

Bug description:
  Because the eject button on my laptop's CD drive is highly susceptible
  to being pressed accidentally, I use "eject -i 1" to lock the CD drive
  from being ejected when the button is pressed.

  After upgrading to oneiric, this stopped working. stracing eject shows
  that it is correctly finding the /dev/sr0 node, opening it, and
  ioctl'ing it correctly, but if I press the eject button afterwards,
  the drive still ejects.

  
  access("/dev/cdrom", F_OK)              = 0
  readlink("/dev/cdrom", "sr0", 4095)     = 3
  lstat("/dev", {st_mode=S_IFDIR|0755, st_size=4280, ...}) = 0
  lstat("/dev/sr0", {st_mode=S_IFBLK|0660, st_rdev=makedev(11, 0), ...}) = 0
  readlink("/dev/sr0", 0x7fff9b7355e8, 4095) = -1 EINVAL (Invalid argument)
  stat("/dev/sr0", {st_mode=S_IFBLK|0660, st_rdev=makedev(11, 0), ...}) = 0
  open("/etc/mtab", O_RDONLY)             = 3
  fstat(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
  mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fc535d19000
  read(3, "rootfs / rootfs rw 0 0\nsysfs /sy"..., 1024) = 1020
  stat("rootfs", 0x7fff9b738900)          = -1 ENOENT (No such file or directory)
  stat("sysfs", 0x7fff9b738900)           = -1 ENOENT (No such file or directory)
  stat("proc", 0x7fff9b738900)            = -1 ENOENT (No such file or directory)
  stat("udev", 0x7fff9b738900)            = -1 ENOENT (No such file or directory)
  stat("devpts", 0x7fff9b738900)          = -1 ENOENT (No such file or directory)
  stat("tmpfs", 0x7fff9b738900)           = -1 ENOENT (No such file or directory)
  stat("fusectl", 0x7fff9b738900)         = -1 ENOENT (No such file or directory)
  stat("/dev/disk/by-uuid/328dbf84-b767-4ad8-bd64-4a34b08d3c23", {st_mode=S_IFBLK|0660, st_rdev=makedev(8, 1), ...}) = 0
  stat("none", 0x7fff9b738900)            = -1 ENOENT (No such file or directory)
  stat("none", 0x7fff9b738900)            = -1 ENOENT (No such file or directory)
  stat("none", 0x7fff9b738900)            = -1 ENOENT (No such file or directory)
  stat("none", 0x7fff9b738900)            = -1 ENOENT (No such file or directory)
  stat("none", 0x7fff9b738900)            = -1 ENOENT (No such file or directory)
  stat("binfmt_misc", 0x7fff9b738900)     = -1 ENOENT (No such file or directory)
  stat("gvfs-fuse-daemon", 0x7fff9b738900) = -1 ENOENT (No such file or directory)
  read(3, "", 1024)                       = 0
  close(3)                                = 0
  munmap(0x7fc535d19000, 4096)            = 0
  open("/etc/fstab", O_RDONLY)            = 3
  fstat(3, {st_mode=S_IFREG|0644, st_size=671, ...}) = 0
  mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fc535d19000
  read(3, "# /etc/fstab: static file system"..., 4096) = 671
  read(3, "", 4096)                       = 0
  close(3)                                = 0
  munmap(0x7fc535d19000, 4096)            = 0
  stat("/dev/sr0", {st_mode=S_IFBLK|0660, st_rdev=makedev(11, 0), ...}) = 0
  geteuid()                               = 1000
  open("/dev/sr0", O_RDWR|O_NONBLOCK)     = 3
  ioctl(3, CDROM_LOCKDOOR, 0x1)           = 0
  fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
  mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fc535d19000
  write(1, "CD-Drive may NOT be ejected with"..., 47CD-Drive may NOT be ejected with device button
  ) = 47
  exit_group(0)                           = ?

  ProblemType: Bug
  DistroRelease: Ubuntu 11.10
  Package: linux-image-3.0.0-11-generic 3.0.0-11.18
  ProcVersionSignature: Ubuntu 3.0.0-11.18-generic 3.0.4
  Uname: Linux 3.0.0-11-generic x86_64
  AlsaVersion: Advanced Linux Sound Architecture Driver Version 1.0.24.
  AplayDevices:
   **** List of PLAYBACK Hardware Devices ****
   card 0: PCH [HDA Intel PCH], device 0: CONEXANT Analog [CONEXANT Analog]
     Subdevices: 1/1
     Subdevice #0: subdevice #0
  ApportVersion: 1.23-0ubuntu1
  Architecture: amd64
  ArecordDevices:
   **** List of CAPTURE Hardware Devices ****
   card 0: PCH [HDA Intel PCH], device 0: CONEXANT Analog [CONEXANT Analog]
     Subdevices: 1/1
     Subdevice #0: subdevice #0
  AudioDevicesInUse:
   USER        PID ACCESS COMMAND
   /dev/snd/controlC0:  evan       2036 F.... pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  Card0.Amixer.info:
   Card hw:0 'PCH'/'HDA Intel PCH at 0xd2620000 irq 47'
     Mixer name	: 'Conexant CX20590'
     Components	: 'HDA:14f1506e,17aa21ce,00100000'
     Controls      : 8
     Simple ctrls  : 5
  Card29.Amixer.info:
   Card hw:29 'ThinkPadEC'/'ThinkPad Console Audio Control at EC reg 0x30, fw unknown'
     Mixer name	: 'ThinkPad EC (unknown)'
     Components	: ''
     Controls      : 1
     Simple ctrls  : 1
  Card29.Amixer.values:
   Simple mixer control 'Console',0
     Capabilities: pswitch pswitch-joined penum
     Playback channels: Mono
     Mono: Playback [off]
  CheckboxSubmission: d27dbc9ce66475289526ca4b283ec487
  CheckboxSystem: bb422ca46d02494cdbc459927a98bc2f
  Date: Tue Sep 20 08:50:04 2011
  HibernationDevice: RESUME=UUID=9322ffe7-f8c0-4ca1-a8f6-b972b86dd64a
  InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release amd64 (20110427.1)
  MachineType: LENOVO 41786VU
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.0.0-11-generic root=UUID=328dbf84-b767-4ad8-bd64-4a34b08d3c23 ro quiet splash disable_ipv6=1 vt.handoff=7
  RelatedPackageVersions:
   linux-restricted-modules-3.0.0-11-generic N/A
   linux-backports-modules-3.0.0-11-generic  N/A
   linux-firmware                            1.60
  SourcePackage: linux
  StagingDrivers: mei
  UpgradeStatus: Upgraded to oneiric on 2011-09-18 (2 days ago)
  dmi.bios.date: 03/31/2011
  dmi.bios.vendor: LENOVO
  dmi.bios.version: 83ET53WW (1.23 )
  dmi.board.asset.tag: Not Available
  dmi.board.name: 41786VU
  dmi.board.vendor: LENOVO
  dmi.board.version: Not Available
  dmi.chassis.asset.tag: No Asset Information
  dmi.chassis.type: 10
  dmi.chassis.vendor: LENOVO
  dmi.chassis.version: Not Available
  dmi.modalias: dmi:bvnLENOVO:bvr83ET53WW(1.23):bd03/31/2011:svnLENOVO:pn41786VU:pvrThinkPadT420:rvnLENOVO:rn41786VU:rvrNotAvailable:cvnLENOVO:ct10:cvrNotAvailable:
  dmi.product.name: 41786VU
  dmi.product.version: ThinkPad T420
  dmi.sys.vendor: LENOVO

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/udev/+bug/854814/+subscriptions




More information about the foundations-bugs mailing list