Commit dceb2f49 authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] compile fixes

	sbpcd.c: removes bogus duplicate definition of sbpcd_lock, use of
CURRENT (we are using private queue) and call of invalidate_buffers() in
->media_changed() (caller does it itself).  That went in a changeset from
davej - looks like a merge problem...
	sr.c: braino in ifdefed printk - s/disk/cd->disk/.  Thanks to jejb
for spotting that one...
parent b1084bc3
......@@ -470,8 +470,6 @@ MODULE_PARM(max_drives, "i");
#define NUM_PROBE (sizeof(sbpcd) / sizeof(int))
static spinlock_t sbpcd_lock = SPIN_LOCK_UNLOCKED;
/*==========================================================================*/
#define INLINE inline
......@@ -4869,13 +4867,12 @@ static void do_sbpcd_request(request_queue_t * q)
return;
req = elv_next_request(q); /* take out our request so no other */
if (req -> sector == -1)
end_request(req, 0);
spin_unlock_irq(q->queue_lock);
down(&ioctl_read_sem);
if (rq_data_dir(CURRENT) != READ)
if (rq_data_dir(elv_next_request(q)) != READ)
{
msg(DBG_INF, "bad cmd %d\n", req->cmd[0]);
goto err_done;
......@@ -5935,8 +5932,8 @@ static int sbpcd_media_changed(struct cdrom_device_info *cdi, int disc_nr)
{
p->CD_changed=0;
msg(DBG_CHK,"medium changed (drive %s)\n", cdi->name);
invalidate_buffers(full_dev);
current_drive->diskstate_flags &= ~toc_bit;
/* we *don't* need invalidate here, it's done by caller */
current_drive->diskstate_flags &= ~cd_size_bit;
#if SAFE_MIXED
current_drive->has_data=0;
......
......@@ -250,7 +250,7 @@ static int sr_init_command(Scsi_Cmnd * SCpnt)
int block=0, this_count, s_size, timeout = SR_TIMEOUT;
Scsi_CD *cd = SCpnt->request->rq_disk->private_data;
SCSI_LOG_HLQUEUE(1, printk("Doing sr request, dev = %s, block = %d\n", disk->disk_name, block));
SCSI_LOG_HLQUEUE(1, printk("Doing sr request, dev = %s, block = %d\n", cd->disk->disk_name, block));
if (!cd->device || !cd->device->online) {
SCSI_LOG_HLQUEUE(2, printk("Finishing %ld sectors\n", SCpnt->request->nr_sectors));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment