All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/6] Fix cdrom autoclose
@ 2017-12-14 15:13 Michal Suchanek
  2017-12-14 15:13 ` [PATCH 1/6] delay: add poll_event_interruptible Michal Suchanek
                   ` (6 more replies)
  0 siblings, 7 replies; 28+ messages in thread
From: Michal Suchanek @ 2017-12-14 15:13 UTC (permalink / raw)
  To: Jens Axboe, Jonathan Corbet, Borislav Petkov, Tim Waugh,
	David S. Miller, James E.J. Bottomley, Martin K. Petersen,
	Michal Suchanek, Christophe JAILLET, Kees Cook, John Stultz,
	Thomas Gleixner, Russell King, Greg Kroah-Hartman,
	Philippe Ombredanne, linux-doc, linux-kernel, linux-ide,
	linux-scsi

Hello,

there is cdrom autoclose feature that is supposed to close the tray, wait for
the disc to become ready, and then open the device.

This used to work in ancient times. Then in old times there was a hack in
util-linux which worked around the breakage which probably resulted from
switching to scsi emulation.

Currently util-linux maintainer refuses to merge another hack on the basis that
kernel still has the feature so it should be fixed there. Indeed, to implement
this feature effectively from userspace one would need to know when the CD-ROM
is in the "drive becoming ready" state which is knowledge that never leaves the
hardware-specific driver and is passed neither to userspace nor the generic
cdrom driver.

So this patchset fixes the kernel autoclose implementation in cdrom.c and to
do so reports the "drive becoming ready" state from the harware specific
drivers.

Michal Suchanek (6):
  delay: add poll_event_interruptible
  cdrom: factor out common open_for_* code
  cdrom: wait for tray to close
  cdrom: introduce CDS_DRIVE_ERROR
  Documentetion: cdrom: introduce CDS_DRIVE_ERROR
  cdrom: wait for drive to become ready

 Documentation/cdrom/cdrom-standard.tex |   8 ++-
 Documentation/cdrom/ide-cd             |   6 ++
 Documentation/ioctl/cdrom.txt          |   1 +
 drivers/block/paride/pcd.c             |   2 +-
 drivers/cdrom/cdrom.c                  | 124 ++++++++++++++++-----------------
 drivers/cdrom/gdrom.c                  |   2 +-
 drivers/ide/ide-cd_ioctl.c             |  12 ++--
 drivers/scsi/sr_ioctl.c                |   2 +-
 include/linux/delay.h                  |  12 ++++
 include/uapi/linux/cdrom.h             |   1 +
 10 files changed, 99 insertions(+), 71 deletions(-)

-- 
2.13.6


^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~2019-10-23 12:19 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-14 15:13 [PATCH 0/6] Fix cdrom autoclose Michal Suchanek
2017-12-14 15:13 ` [PATCH 1/6] delay: add poll_event_interruptible Michal Suchanek
2017-12-14 15:13 ` [PATCH 2/6] cdrom: factor out common open_for_* code Michal Suchanek
2017-12-14 15:13 ` [PATCH 3/6] cdrom: wait for tray to close Michal Suchanek
2017-12-15 17:20   ` Michal Suchánek
2017-12-14 15:13 ` [PATCH 4/6] cdrom: introduce CDS_DRIVE_ERROR Michal Suchanek
2017-12-14 15:13 ` [PATCH 5/6] Documentetion: " Michal Suchanek
2017-12-14 15:13 ` [PATCH 6/6] cdrom: wait for drive to become ready Michal Suchanek
2018-01-26 16:58 ` [PATCH resend 0/6] Fix cdrom autoclose Michal Suchanek
2018-01-26 16:58   ` [PATCH resend 1/6] delay: add poll_event_interruptible Michal Suchanek
2018-01-29 17:00     ` Bart Van Assche
2018-01-29 17:00       ` Bart Van Assche
2018-01-26 16:58   ` [PATCH resend 2/6] cdrom: factor out common open_for_* code Michal Suchanek
2018-01-29 17:02     ` Bart Van Assche
2018-01-29 17:02       ` Bart Van Assche
2018-01-26 16:58   ` [PATCH resend 3/6] cdrom: wait for tray to close Michal Suchanek
2018-01-29 17:05     ` Bart Van Assche
2018-01-29 17:05       ` Bart Van Assche
2018-01-31 18:20       ` Michal Suchánek
2018-01-31 18:20         ` Michal Suchánek
2019-10-23 12:19       ` Michal Suchánek
2018-01-26 16:58   ` [PATCH resend 4/6] cdrom: introduce CDS_DRIVE_ERROR Michal Suchanek
2018-01-26 16:58   ` [PATCH resend 5/6] Documentetion: " Michal Suchanek
2018-01-26 16:58   ` [PATCH resend 6/6] cdrom: wait for drive to become ready Michal Suchanek
2018-01-29 17:11     ` Bart Van Assche
2018-01-29 17:11       ` Bart Van Assche
2018-01-26 20:04   ` [PATCH resend 0/6] Fix cdrom autoclose James Bottomley
2018-01-27 22:53     ` Michal Suchánek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.