![]() |
coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
|
#include <delay.h>
#include <timer.h>
#include <console/console.h>
#include <device/device.h>
#include <device/i2c_bus.h>
#include "lm96000.h"
#include "chip.h"
Go to the source code of this file.
Functions | |
static int | lm96000_read (struct device *const dev, const u8 reg) |
static int | lm96000_write (struct device *const dev, const u8 reg, const u8 value) |
static int | lm96000_update (struct device *const dev, const u8 reg, const u8 clear_mask, const u8 set_mask) |
static u8 | lm96000_to_low_limit (const enum lm96000_vin ref, const u16 limit) |
static u8 | lm96000_to_high_limit (const enum lm96000_vin ref, const u16 limit) |
static void | lm96000_set_vin_limits (struct device *const dev, const struct drivers_i2c_lm96000_config *const config) |
static void | lm96000_set_temp_limits (struct device *const dev, const struct drivers_i2c_lm96000_config *const config) |
static u16 | lm96000_rpm_to_tach (const u16 rpm) |
static void | lm96000_set_fan_limits (struct device *const dev, const struct drivers_i2c_lm96000_config *const config) |
static u8 | lm96000_to_duty (const u8 duty_cycle) |
static void | lm96000_configure_pwm (struct device *const dev, const unsigned int fan, const struct lm96000_fan_config *const config) |
static void | lm96000_configure_temp_zone (struct device *const dev, const unsigned int zone, const struct lm96000_temp_zone *const config) |
static void | lm96000_init (struct device *const dev) |
static void | lm96000_enable (struct device *const dev) |
Variables | |
static const unsigned int | ref_mv [] = { 2500, 2250, 3300, 5000, 12000 } |
static struct device_operations | lm96000_ops |
struct chip_operations | drivers_i2c_lm96000_ops |
|
static |
Definition at line 102 of file lm96000.c.
References config, LM96000_FAN_CFG, LM96000_FAN_CFG_MODE_MASK, LM96000_FAN_CFG_MODE_SHIFT, LM96000_FAN_CFG_PWM_INVERT, LM96000_FAN_CFG_SPINUP_MASK, LM96000_FAN_DUTY, LM96000_FAN_FREQ, LM96000_FAN_FREQ_MASK, LM96000_FAN_HOTTEST_123, LM96000_FAN_HOTTEST_23, LM96000_FAN_MANUAL, LM96000_FAN_MIN_PWM, LM96000_FAN_ZONE_1_AUTO, LM96000_FAN_ZONE_2_AUTO, LM96000_FAN_ZONE_3_AUTO, LM96000_PWM_94HZ, LM96000_TACH_MODE_FAN_MASK, LM96000_TACH_MODE_FAN_SHIFT, LM96000_TACH_MONITOR_MODE, lm96000_to_duty(), lm96000_update(), and lm96000_write().
Referenced by lm96000_init().
|
static |
Definition at line 138 of file lm96000.c.
References ARRAY_SIZE, config, LM96000_FAN_MIN, LM96000_FAN_MIN_OFF, lm96000_update(), lm96000_write(), LM96000_ZONE_HYST_MASK, LM96000_ZONE_HYST_SHIFT, LM96000_ZONE_HYSTERESIS, LM96000_ZONE_RANGE, LM96000_ZONE_RANGE_MASK, LM96000_ZONE_RANGE_SHIFT, LM96000_ZONE_SMOOTH, LM96000_ZONE_SMOOTH_EN, LM96000_ZONE_SMOOTH_MASK, LM96000_ZONE_TEMP_LOW, and LM96000_ZONE_TEMP_PANIC.
Referenced by lm96000_init().
Definition at line 172 of file lm96000.c.
References BIOS_DEBUG, BIOS_INFO, device::chip_info, config, LM96000_CONFIG, lm96000_configure_pwm(), lm96000_configure_temp_zone(), LM96000_FAN_IGNORE, LM96000_PWM_CTL_CNT, lm96000_read(), LM96000_READY, lm96000_set_fan_limits(), lm96000_set_temp_limits(), lm96000_set_vin_limits(), LM96000_START, LM96000_TEMP_ZONE_CNT, lm96000_update(), mdelay(), printk, stopwatch_expired(), and stopwatch_init_msecs_expire().
Definition at line 12 of file lm96000.c.
References i2c_dev_readb_at().
Referenced by lm96000_init().
Definition at line 80 of file lm96000.c.
Referenced by lm96000_set_fan_limits().
|
static |
Definition at line 85 of file lm96000.c.
References config, LM96000_FAN_IN_CNT, LM96000_FAN_LOW_LIMIT, lm96000_rpm_to_tach(), and lm96000_write().
Referenced by lm96000_init().
|
static |
Definition at line 64 of file lm96000.c.
References config, LM96000_TEMP_HIGH_LIMIT, LM96000_TEMP_IN_CNT, LM96000_TEMP_LOW_LIMIT, and lm96000_write().
Referenced by lm96000_init().
|
static |
Definition at line 48 of file lm96000.c.
References config, lm96000_to_high_limit(), lm96000_to_low_limit(), LM96000_VIN_CNT, LM96000_VIN_HIGH_LIMIT, LM96000_VIN_LOW_LIMIT, and lm96000_write().
Referenced by lm96000_init().
Definition at line 97 of file lm96000.c.
Referenced by lm96000_configure_pwm().
|
static |
Definition at line 41 of file lm96000.c.
References DIV_ROUND_UP, and ref_mv.
Referenced by lm96000_set_vin_limits().
|
static |
Definition at line 34 of file lm96000.c.
References ref_mv.
Referenced by lm96000_set_vin_limits().
|
inlinestatic |
Definition at line 23 of file lm96000.c.
References i2c_dev_readb_at(), i2c_dev_writeb_at(), and val.
Referenced by lm96000_configure_pwm(), lm96000_configure_temp_zone(), and lm96000_init().
Definition at line 17 of file lm96000.c.
References i2c_dev_writeb_at(), and value.
Referenced by lm96000_configure_pwm(), lm96000_configure_temp_zone(), lm96000_set_fan_limits(), lm96000_set_temp_limits(), and lm96000_set_vin_limits().
struct chip_operations drivers_i2c_lm96000_ops |
|
static |
|
static |
Definition at line 32 of file lm96000.c.
Referenced by lm96000_to_high_limit(), and lm96000_to_low_limit().