smartmontools SVN Rev 5640
Utility to control and monitor storage systems with "S.M.A.R.T."
Classes | Macros | Functions | Variables
farmcmds.h File Reference
#include <stdint.h>
#include "atacmds.h"
#include "dev_interface.h"
#include "knowndrives.h"
#include "static_assert.h"
Include dependency graph for farmcmds.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  ataFarmHeader
 
struct  ataFarmDriveInformation
 
struct  ataFarmWorkloadStatistics
 
struct  ataFarmErrorStatistics
 
struct  ataFarmEnvironmentStatistics
 
struct  ataFarmReliabilityStatistics
 
struct  ataFarmLog
 
struct  scsiFarmPageHeader
 
struct  scsiFarmParameterHeader
 
struct  scsiFarmHeader
 
struct  scsiFarmDriveInformation
 
struct  scsiFarmWorkloadStatistics
 
struct  scsiFarmErrorStatistics
 
struct  scsiFarmEnvironmentStatistics
 
struct  scsiFarmReliabilityStatistics
 
struct  scsiFarmDriveInformation2
 
struct  scsiFarmEnvironmentStatistics2
 
struct  scsiFarmByHead
 
struct  scsiFarmByActuator
 
struct  scsiFarmByActuatorFLED
 
struct  scsiFarmByActuatorReallocation
 
struct  scsiFarmLog
 

Macros

#define ATTR_PACKED_FARM
 

Functions

 STATIC_ASSERT (sizeof(ataFarmHeader)==72)
 
 STATIC_ASSERT (sizeof(ataFarmDriveInformation)==376)
 
 STATIC_ASSERT (sizeof(ataFarmWorkloadStatistics)==168)
 
 STATIC_ASSERT (sizeof(ataFarmErrorStatistics)==952)
 
 STATIC_ASSERT (sizeof(ataFarmEnvironmentStatistics)==256)
 
 STATIC_ASSERT (sizeof(ataFarmReliabilityStatistics)==8880)
 
 STATIC_ASSERT (sizeof(ataFarmLog)==72+376+168+952+256+8880)
 
 STATIC_ASSERT (sizeof(scsiFarmPageHeader)==4)
 
 STATIC_ASSERT (sizeof(scsiFarmParameterHeader)==4)
 
 STATIC_ASSERT (sizeof(scsiFarmHeader)==76)
 
 STATIC_ASSERT (sizeof(scsiFarmDriveInformation)==252)
 
 STATIC_ASSERT (sizeof(scsiFarmWorkloadStatistics)==148)
 
 STATIC_ASSERT (sizeof(scsiFarmErrorStatistics)==236)
 
 STATIC_ASSERT (sizeof(scsiFarmEnvironmentStatistics)==212)
 
 STATIC_ASSERT (sizeof(scsiFarmReliabilityStatistics)==236)
 
 STATIC_ASSERT (sizeof(scsiFarmDriveInformation2)==108)
 
 STATIC_ASSERT (sizeof(scsiFarmEnvironmentStatistics2)==68)
 
 STATIC_ASSERT (sizeof(scsiFarmByHead)==(4+(20 *8)))
 
 STATIC_ASSERT (sizeof(scsiFarmByActuator)==188)
 
 STATIC_ASSERT (sizeof(scsiFarmByActuatorFLED)==236)
 
 STATIC_ASSERT (sizeof(scsiFarmByActuatorReallocation)==164)
 
 STATIC_ASSERT (sizeof(scsiFarmLog)==4+76+252+148+236+212+236+108+68+(47 *((8 *20)+4))+188 *4+236 *4+164 *4)
 
bool ataIsSeagate (const ata_identify_device &drive, const drive_settings *dbentry)
 
bool ataReadFarmLog (ata_device *device, ataFarmLog &farmLog, unsigned nsectors)
 
bool scsiIsSeagate (char *scsi_vendor)
 
bool scsiReadFarmLog (scsi_device *device, scsiFarmLog &farmLog)
 

Variables

struct scsiFarmHeader ATTR_PACKED_FARM
 

Macro Definition Documentation

◆ ATTR_PACKED_FARM

struct scsiFarmByActuatorReallocation ATTR_PACKED_FARM

Definition at line 19 of file farmcmds.h.

Function Documentation

◆ ataIsSeagate()

bool ataIsSeagate ( const ata_identify_device drive,
const drive_settings dbentry 
)

Definition at line 33 of file farmcmds.cpp.

◆ ataReadFarmLog()

bool ataReadFarmLog ( ata_device device,
ataFarmLog farmLog,
unsigned  nsectors 
)

Definition at line 56 of file farmcmds.cpp.

◆ scsiIsSeagate()

bool scsiIsSeagate ( char *  scsi_vendor)

Definition at line 149 of file farmcmds.cpp.

◆ scsiReadFarmLog()

bool scsiReadFarmLog ( scsi_device device,
scsiFarmLog farmLog 
)

Definition at line 162 of file farmcmds.cpp.

◆ STATIC_ASSERT() [1/22]

STATIC_ASSERT ( sizeof(ataFarmDriveInformation = =376)

◆ STATIC_ASSERT() [2/22]

STATIC_ASSERT ( sizeof(ataFarmEnvironmentStatistics = =256)

◆ STATIC_ASSERT() [3/22]

STATIC_ASSERT ( sizeof(ataFarmErrorStatistics = =952)

◆ STATIC_ASSERT() [4/22]

STATIC_ASSERT ( sizeof(ataFarmHeader = =72)

◆ STATIC_ASSERT() [5/22]

STATIC_ASSERT ( sizeof(ataFarmLog = =72+376+168+952+256+8880)

◆ STATIC_ASSERT() [6/22]

STATIC_ASSERT ( sizeof(ataFarmReliabilityStatistics = =8880)

◆ STATIC_ASSERT() [7/22]

STATIC_ASSERT ( sizeof(ataFarmWorkloadStatistics = =168)

◆ STATIC_ASSERT() [8/22]

STATIC_ASSERT ( sizeof(scsiFarmByActuator = =188)

◆ STATIC_ASSERT() [9/22]

STATIC_ASSERT ( sizeof(scsiFarmByActuatorFLED = =236)

◆ STATIC_ASSERT() [10/22]

STATIC_ASSERT ( sizeof(scsiFarmByActuatorReallocation = =164)

◆ STATIC_ASSERT() [11/22]

STATIC_ASSERT ( sizeof(scsiFarmByHead = =(4+(20 *8)))

◆ STATIC_ASSERT() [12/22]

STATIC_ASSERT ( sizeof(scsiFarmDriveInformation = =252)

◆ STATIC_ASSERT() [13/22]

STATIC_ASSERT ( sizeof(scsiFarmDriveInformation2 = =108)

◆ STATIC_ASSERT() [14/22]

STATIC_ASSERT ( sizeof(scsiFarmEnvironmentStatistics = =212)

◆ STATIC_ASSERT() [15/22]

STATIC_ASSERT ( sizeof(scsiFarmEnvironmentStatistics2 = =68)

◆ STATIC_ASSERT() [16/22]

STATIC_ASSERT ( sizeof(scsiFarmErrorStatistics = =236)

◆ STATIC_ASSERT() [17/22]

STATIC_ASSERT ( sizeof(scsiFarmHeader = =76)

◆ STATIC_ASSERT() [18/22]

STATIC_ASSERT ( sizeof(scsiFarmLog = =4+76+252+148+236+212+236+108+68+(47 *((8 *20)+4))+188 *4+236 *4+164 *4)

◆ STATIC_ASSERT() [19/22]

STATIC_ASSERT ( sizeof(scsiFarmPageHeader = =4)

◆ STATIC_ASSERT() [20/22]

STATIC_ASSERT ( sizeof(scsiFarmParameterHeader = =4)

◆ STATIC_ASSERT() [21/22]

STATIC_ASSERT ( sizeof(scsiFarmReliabilityStatistics = =236)

◆ STATIC_ASSERT() [22/22]

STATIC_ASSERT ( sizeof(scsiFarmWorkloadStatistics = =148)

Variable Documentation

◆ ATTR_PACKED_FARM

struct scsiFarmByActuatorReallocation ATTR_PACKED_FARM