coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
pca9538.c File Reference
#include <device/i2c_bus.h>
#include <device/device.h>
#include "pca9538.h"
#include "chip.h"
Include dependency graph for pca9538.c:

Go to the source code of this file.

Functions

uint8_t pca9538_read_input (void)
 
void pca9538_set_output (uint8_t val)
 
static void pca9538_init (struct device *dev)
 
static void pca9538_enable (struct device *dev)
 

Variables

static struct device_operations pca9538_ops
 
struct chip_operations drivers_i2c_pca9538_ops
 

Function Documentation

◆ pca9538_enable()

static void pca9538_enable ( struct device dev)
static

Definition at line 46 of file pca9538.c.

◆ pca9538_init()

static void pca9538_init ( struct device dev)
static

Definition at line 28 of file pca9538.c.

References device::chip_info, config, i2c_dev_writeb_at(), INPUT_INVERT_REG, IO_CONFIG_REG, and OUTPUT_REG.

Here is the call graph for this function:

◆ pca9538_read_input()

uint8_t pca9538_read_input ( void  )

Definition at line 9 of file pca9538.c.

References i2c_dev_readb_at(), INPUT_REG, and pca9538_get_dev().

Here is the call graph for this function:

◆ pca9538_set_output()

void pca9538_set_output ( uint8_t  val)

Definition at line 20 of file pca9538.c.

References i2c_dev_writeb_at(), OUTPUT_REG, pca9538_get_dev(), and val.

Here is the call graph for this function:

Variable Documentation

◆ drivers_i2c_pca9538_ops

struct chip_operations drivers_i2c_pca9538_ops
Initial value:
= {
.enable_dev = pca9538_enable
}
static void pca9538_enable(struct device *dev)
Definition: pca9538.c:46

Definition at line 46 of file pca9538.c.

◆ pca9538_ops

struct device_operations pca9538_ops
static
Initial value:
= {
.read_resources = noop_read_resources,
.set_resources = noop_set_resources,
.init = pca9538_init,
}
static void noop_read_resources(struct device *dev)
Standard device operations function pointers shims.
Definition: device.h:73
static void noop_set_resources(struct device *dev)
Definition: device.h:74
static void pca9538_init(struct device *dev)
Definition: pca9538.c:28

Definition at line 28 of file pca9538.c.