libflashrom
Typedefs | Enumerations | Functions
General

Typedefs

typedef int( flashrom_log_callback) (enum flashrom_log_level, const char *format, va_list)
 

Enumerations

enum  flashrom_log_level {
  FLASHROM_MSG_ERROR = 0, FLASHROM_MSG_WARN = 1, FLASHROM_MSG_INFO = 2, FLASHROM_MSG_DEBUG = 3,
  FLASHROM_MSG_DEBUG2 = 4, FLASHROM_MSG_SPEW = 5
}
 

Functions

int flashrom_init (const int perform_selfcheck)
 Initialize libflashrom. More...
 
int flashrom_shutdown (void)
 Shut down libflashrom. More...
 
void flashrom_set_log_callback (flashrom_log_callback *const log_callback)
 Set the log callback function. More...
 

Detailed Description

Typedef Documentation

typedef int( flashrom_log_callback) (enum flashrom_log_level, const char *format, va_list)

Enumeration Type Documentation

Function Documentation

int flashrom_init ( const int  perform_selfcheck)

Initialize libflashrom.

Parameters
perform_selfcheckIf not zero, perform a self check.
Returns
0 on success
void flashrom_set_log_callback ( flashrom_log_callback *const  log_callback)

Set the log callback function.

Set a callback function which will be invoked whenever libflashrom wants to output messages. This allows frontends to do whatever they see fit with such messages, e.g. write them to syslog, or to file, or print them in a GUI window, etc.

Parameters
log_callbackPointer to the new log callback function.
int flashrom_shutdown ( void  )

Shut down libflashrom.

Returns
0 on success