From eb796b1767e2c027988e753b8a4e05e3f58aa405 Mon Sep 17 00:00:00 2001 From: Martin Dalecki Date: Tue, 28 May 2002 19:14:28 -0700 Subject: [PATCH] 2.5.18 IDE 73 - Merge ide-probe.c and ide-features.c in to one single file. They are mutually doing basically the same and in esp. in case of the device ID retrieval there *is* quite a lot of code duplication between them. ide-geometry.c fits there as well. - Remove ide_xfer_verbose - it wasn't really used. - Don't allow check_partition to be more clever then the writer of a driver. It was interfering with drivers which check partitions as they go and finally if we want to spew something about it - we can do it ourself. - Eliminate ide_geninit(). We scan for partitions now inside the recently introduced attach method. register_disk() is broken by the way and 90% of places where it's used it is doing literally nothing. Either some one didn't finish some code or the code is basically just junk from the past. Anyway we grok the partitions now one by one as we detect the channels. - ide_driveid_update is gone. We don't report the drive id through /proc/ide and we don't have to update it any longer on the fly. Still someone out there complaining that it went away!? - Use the global driver spin-lock to protect data structure access in the ide_register_subdriver() function instead of blatantly disabling all interrupts. --- include/linux/hdreg.h | 9 ++++++--- include/linux/ide.h | 6 ++++-- 2 files changed, 10 insertions(+), 5 deletions(-) (limited to 'include/linux') diff --git a/include/linux/hdreg.h b/include/linux/hdreg.h index dd54c5a269f1..598827f0ee06 100644 --- a/include/linux/hdreg.h +++ b/include/linux/hdreg.h @@ -331,10 +331,13 @@ enum { #define HDIO_GETGEO_BIG_RAW 0x0331 /* */ #define __NEW_HD_DRIVE_ID -/* structure returned by HDIO_GET_IDENTITY, - * as per ANSI NCITS ATA6 rev.1b spec + +/* + * Structure returned by HDIO_GET_IDENTITY, as per ANSI NCITS ATA6 rev.1b spec. + * + * If you change something here, please remember to update fix_driveid() in + * ide/probe.c. */ -/* if you change something here remember to update ide_fix_driveid() */ struct hd_driveid { unsigned short config; /* lots of obsolete bit flags */ unsigned short cyls; /* Obsolete, "physical" cyls */ diff --git a/include/linux/ide.h b/include/linux/ide.h index 7496206e5026..312560f0c372 100644 --- a/include/linux/ide.h +++ b/include/linux/ide.h @@ -762,7 +762,6 @@ extern int ide_raw_taskfile(struct ata_device *, struct ata_taskfile *); extern int ide_cmd_ioctl(struct ata_device *drive, unsigned long arg); extern void ide_fix_driveid(struct hd_driveid *id); -extern int ide_driveid_update(struct ata_device *); extern int ide_config_drive_speed(struct ata_device *, byte); extern byte eighty_ninty_three(struct ata_device *); @@ -893,11 +892,14 @@ extern void ide_release_dma(struct ata_channel *); extern int ata_start_dma(struct ata_device *, struct request *rq); extern void ata_init_dma(struct ata_channel *, unsigned long) __init; + #endif +extern void ata_fix_driveid(struct hd_driveid *); + extern spinlock_t ide_lock; -#define DRIVE_LOCK(drive) ((drive)->queue.queue_lock) +#define DRIVE_LOCK(drive) ((drive)->queue.queue_lock) extern int drive_is_ready(struct ata_device *drive); -- cgit v1.2.3