SMART enable early
PATCH 1/1 SMART enable early
Quoted 1 line
From ATA spec proposal 1e:
8.55.3.8 Description (SMART ENABLE OPERATIONS)
This command enables access to all SMART capabilities within the device. Prior to receipt of this command SMART data are neither monitored nor saved by the device.
You HAVE to enable SMART as early as possible to have any meaningful data. And, as best I can tell, it is never DISABLED anywhere. So once you read from /proc/.../smart_values SMART is on.
I think the patch is actually OK. Unless you can point out where in the spec I am missing something.
Tim
Signature · 4 lines
Tim Hockin Systems Software Engineer Sun Microsystems, Cobalt Server Appliances [email protected]
drivers/ide/ide-disk.c +3 -2
@@ -569,13 +569,13 @@ drive->special.b.set_multmode =1 ; } -#ifdef CONFIG_PROC_FS -static int smart_enable (ide_drive_t *drive) {return ide_wait_cmd (drive,WIN_SMART ,0 ,SMART_ENABLE ,0 ,NULL ); } +#ifdef CONFIG_PROC_FS +static int get_smart_values (ide_drive_t *drive,byte *buf) { (void )smart_enable (drive);
@@ -799,6 +799,7 @@#endif } drive->no_io_32bit = id->dword_io ?1 :0 ; + (void )smart_enable (drive); }static int idedisk_reinit (ide_drive_t *drive)