aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-floppy.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/ide-floppy.c')
-rw-r--r--drivers/ide/ide-floppy.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c
index 7ae662334835..0faae3098295 100644
--- a/drivers/ide/ide-floppy.c
+++ b/drivers/ide/ide-floppy.c
@@ -385,7 +385,7 @@ static int ide_floppy_get_capacity(ide_drive_t *drive)
385 struct gendisk *disk = floppy->disk; 385 struct gendisk *disk = floppy->disk;
386 struct ide_atapi_pc pc; 386 struct ide_atapi_pc pc;
387 u8 *cap_desc; 387 u8 *cap_desc;
388 u8 header_len, desc_cnt; 388 u8 pc_buf[256], header_len, desc_cnt;
389 int i, rc = 1, blocks, length; 389 int i, rc = 1, blocks, length;
390 390
391 drive->bios_cyl = 0; 391 drive->bios_cyl = 0;
@@ -395,6 +395,9 @@ static int ide_floppy_get_capacity(ide_drive_t *drive)
395 drive->capacity64 = 0; 395 drive->capacity64 = 0;
396 396
397 ide_floppy_create_read_capacity_cmd(&pc); 397 ide_floppy_create_read_capacity_cmd(&pc);
398 pc.buf = &pc_buf[0];
399 pc.buf_size = sizeof(pc_buf);
400
398 if (ide_queue_pc_tail(drive, disk, &pc)) { 401 if (ide_queue_pc_tail(drive, disk, &pc)) {
399 printk(KERN_ERR PFX "Can't get floppy parameters\n"); 402 printk(KERN_ERR PFX "Can't get floppy parameters\n");
400 return 1; 403 return 1;