smartmontools SVN Rev 5645
Utility to control and monitor storage systems with "S.M.A.R.T."
Macros | Enumerations | Functions | Variables
smartctl.h File Reference
#include "json.h"
#include "utility.h"
Include dependency graph for smartctl.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define SMARTCTL_H_CVSID   "$Id: smartctl.h 5200 2021-02-07 14:19:40Z chrfranke $\n"
 
#define FAILCMD   (0x01<<0)
 
#define FAILDEV   (0x01<<1)
 
#define FAILPOWER   (0x01<<1)
 
#define FAILID   (0x01<<1)
 
#define FAILSMART   (0x01<<2)
 
#define FAILSTATUS   (0x01<<3)
 
#define FAILATTR   (0x01<<4)
 
#define FAILAGE   (0x01<<5)
 
#define FAILERR   (0x01<<6)
 
#define FAILLOG   (0x01<<7)
 

Enumerations

enum  failure_type { OPTIONAL_CMD , MANDATORY_CMD }
 

Functions

void failuretest (failure_type type, int returnvalue)
 
void print_on ()
 
void print_off ()
 
void jout (const char *fmt,...) __attribute_format_printf(1
 
void void jinf (const char *fmt,...) __attribute_format_printf(1
 
void void void jwrn (const char *fmt,...) __attribute_format_printf(1
 
void void void void jerr (const char *fmt,...) __attribute_format_printf(1
 
void void void void void jout_startup_datetime (const char *prefix)
 

Variables

bool failuretest_conservative
 
unsigned char failuretest_permissive
 
bool printing_is_switchable
 
bool printing_is_off
 
json jglb
 

Macro Definition Documentation

◆ FAILAGE

#define FAILAGE   (0x01<<5)

Definition at line 43 of file smartctl.h.

◆ FAILATTR

#define FAILATTR   (0x01<<4)

Definition at line 39 of file smartctl.h.

◆ FAILCMD

#define FAILCMD   (0x01<<0)

Definition at line 21 of file smartctl.h.

◆ FAILDEV

#define FAILDEV   (0x01<<1)

Definition at line 24 of file smartctl.h.

◆ FAILERR

#define FAILERR   (0x01<<6)

Definition at line 46 of file smartctl.h.

◆ FAILID

#define FAILID   (0x01<<1)

Definition at line 30 of file smartctl.h.

◆ FAILLOG

#define FAILLOG   (0x01<<7)

Definition at line 49 of file smartctl.h.

◆ FAILPOWER

#define FAILPOWER   (0x01<<1)

Definition at line 27 of file smartctl.h.

◆ FAILSMART

#define FAILSMART   (0x01<<2)

Definition at line 33 of file smartctl.h.

◆ FAILSTATUS

#define FAILSTATUS   (0x01<<3)

Definition at line 36 of file smartctl.h.

◆ SMARTCTL_H_CVSID

#define SMARTCTL_H_CVSID   "$Id: smartctl.h 5200 2021-02-07 14:19:40Z chrfranke $\n"

Definition at line 16 of file smartctl.h.

Enumeration Type Documentation

◆ failure_type

Enumerator
OPTIONAL_CMD 
MANDATORY_CMD 

Definition at line 56 of file smartctl.h.

Function Documentation

◆ failuretest()

void failuretest ( failure_type  type,
int  returnvalue 
)

Definition at line 1462 of file smartctl.cpp.

◆ jerr()

void void void void jerr ( const char *  fmt,
  ... 
)

◆ jinf()

void void jinf ( const char *  fmt,
  ... 
)

◆ jout()

void jout ( const char *  fmt,
  ... 
)

◆ jout_startup_datetime()

void void void void void jout_startup_datetime ( const char *  prefix)

Definition at line 1450 of file smartctl.cpp.

◆ jwrn()

void void void jwrn ( const char *  fmt,
  ... 
)

◆ print_off()

void print_off ( )
inline

Definition at line 79 of file smartctl.h.

◆ print_on()

void print_on ( )
inline

Definition at line 74 of file smartctl.h.

Variable Documentation

◆ failuretest_conservative

bool failuretest_conservative
extern

Definition at line 1456 of file smartctl.cpp.

◆ failuretest_permissive

unsigned char failuretest_permissive
extern

Definition at line 1457 of file smartctl.cpp.

◆ jglb

json jglb
extern

Definition at line 53 of file smartctl.cpp.

◆ printing_is_off

bool printing_is_off
extern

Definition at line 50 of file smartctl.cpp.

◆ printing_is_switchable

bool printing_is_switchable
extern

Definition at line 49 of file smartctl.cpp.