Re: [Ubuntu PATCH] CDROMEJECT cannot eject some devices

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2006-07-03 at 13:46 -0700, Randy Dunlap wrote:
> -			err = blk_send_start_stop(q, bd_disk, 0x02);
> +			err = 0;
> +
> +			err |= blk_send_allow_medium_removal(q, bd_disk);

This piece is clearly wrong.  If the medium has physically been locked
(and the lock is managed by the cdrom layer) then we don't want to be
overriding it.  It should be up to the user or the tools to figure out
who has it open or mounted and take the appropriate action.

> +			err |= blk_send_start_stop(q, bd_disk, 0x01);

And this looks unnecessary.  Why does the device need to be started to
eject its medium?

> +			err |= blk_send_start_stop(q, bd_disk, 0x02);

James


-
: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux