coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
superio.c File Reference
#include <device/device.h>
#include <device/pnp.h>
#include <pc80/keyboard.h>
#include <option.h>
#include <superio/ite/common/env_ctrl.h>
#include <superio/conf_mode.h>
#include <types.h>
#include "chip.h"
#include "it8720f.h"
Include dependency graph for superio.c:

Go to the source code of this file.

Macros

#define MAINBOARD_POWER_OFF   0
 
#define MAINBOARD_POWER_ON   1
 
#define MAINBOARD_POWER_KEEP   2
 

Functions

static void power_control_init (struct device *dev)
 
static void it8720f_init (struct device *dev)
 
static void enable_dev (struct device *dev)
 

Variables

static struct device_operations ops
 
static struct pnp_info pnp_dev_info []
 
struct chip_operations superio_ite_it8720f_ops
 

Macro Definition Documentation

◆ MAINBOARD_POWER_KEEP

#define MAINBOARD_POWER_KEEP   2

Definition at line 16 of file superio.c.

◆ MAINBOARD_POWER_OFF

#define MAINBOARD_POWER_OFF   0

Definition at line 14 of file superio.c.

◆ MAINBOARD_POWER_ON

#define MAINBOARD_POWER_ON   1

Definition at line 15 of file superio.c.

Function Documentation

◆ enable_dev()

static void enable_dev ( struct device dev)
static

Definition at line 109 of file superio.c.

References ARRAY_SIZE, ops, pnp_dev_info, and pnp_enable_devices().

Here is the call graph for this function:

◆ it8720f_init()

◆ power_control_init()

static void power_control_init ( struct device dev)
static

Definition at line 18 of file superio.c.

References get_uint_option(), IT8720F_EC_PCR1, IT8720F_EC_PCR2, MAINBOARD_POWER_KEEP, MAINBOARD_POWER_OFF, MAINBOARD_POWER_ON, pnp_enter_conf_mode(), pnp_exit_conf_mode(), pnp_read_config(), pnp_set_logical_device(), pnp_write_config(), and value.

Referenced by it8720f_init().

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ ops

struct device_operations ops
static
Initial value:
= {
.read_resources = pnp_read_resources,
.set_resources = pnp_set_resources,
.enable_resources = pnp_enable_resources,
.enable = pnp_enable,
.init = it8720f_init,
.ops_pnp_mode = &pnp_conf_mode_870155_aa,
}
const struct pnp_mode_ops pnp_conf_mode_870155_aa
Definition: conf_mode.c:229
static void it8720f_init(struct device *dev)
Definition: superio.c:43
void pnp_enable(struct device *dev)
Definition: pnp_device.c:181
void pnp_read_resources(struct device *dev)
Definition: pnp_device.c:114
void pnp_set_resources(struct device *dev)
Definition: pnp_device.c:157
void pnp_enable_resources(struct device *dev)
Definition: pnp_device.c:173

Definition at line 43 of file superio.c.

Referenced by enable_dev().

◆ pnp_dev_info

struct pnp_info pnp_dev_info[]
static

Definition at line 43 of file superio.c.

Referenced by enable_dev().

◆ superio_ite_it8720f_ops

struct chip_operations superio_ite_it8720f_ops
Initial value:
= {
.enable_dev = enable_dev,
}
static void enable_dev(struct device *dev)
Definition: superio.c:109

Definition at line 109 of file superio.c.