mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-28 20:02:17 +00:00
ide: sanitize SELECT_MASK() usage in ide_driveid_update()
Call SELECT_MASK() after ide_fix_driveid(). Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
This commit is contained in:
parent
1bd4c1f4fe
commit
f323b80dce
1 changed files with 3 additions and 1 deletions
|
@ -340,13 +340,15 @@ int ide_driveid_update(ide_drive_t *drive)
|
|||
}
|
||||
|
||||
local_irq_save(flags);
|
||||
SELECT_MASK(drive, 0);
|
||||
tp_ops->input_data(drive, NULL, id, SECTOR_SIZE);
|
||||
(void)tp_ops->read_status(hwif); /* clear drive IRQ */
|
||||
local_irq_enable();
|
||||
local_irq_restore(flags);
|
||||
|
||||
ide_fix_driveid(id);
|
||||
|
||||
SELECT_MASK(drive, 0);
|
||||
|
||||
drive->id[ATA_ID_UDMA_MODES] = id[ATA_ID_UDMA_MODES];
|
||||
drive->id[ATA_ID_MWDMA_MODES] = id[ATA_ID_MWDMA_MODES];
|
||||
drive->id[ATA_ID_SWDMA_MODES] = id[ATA_ID_SWDMA_MODES];
|
||||
|
|
Loading…
Reference in a new issue