Linux Kernel
3.7.1
|
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/init.h>
#include <linux/err.h>
#include <linux/slab.h>
#include <linux/i2c.h>
#include <linux/hwmon.h>
#include <linux/hwmon-sysfs.h>
#include <linux/jiffies.h>
#include <linux/i2c/ltc4245.h>
Go to the source code of this file.
Data Structures | |
struct | ltc4245_data |
Macros | |
#define | LTC4245_VOLTAGE(name, ltc4245_cmd_idx) |
#define | LTC4245_CURRENT(name, ltc4245_cmd_idx) |
#define | LTC4245_POWER(name, ltc4245_cmd_idx) |
#define | LTC4245_ALARM(name, mask, reg) |
#define | LTC4245_GPIO_VOLTAGE(name, gpio_num) |
Enumerations | |
enum | ltc4245_cmd { LTC4245_STATUS = 0x00, LTC4245_ALERT = 0x01, LTC4245_CONTROL = 0x02, LTC4245_ON = 0x03, LTC4245_FAULT1 = 0x04, LTC4245_FAULT2 = 0x05, LTC4245_GPIO = 0x06, LTC4245_ADCADR = 0x07, LTC4245_12VIN = 0x10, LTC4245_12VSENSE = 0x11, LTC4245_12VOUT = 0x12, LTC4245_5VIN = 0x13, LTC4245_5VSENSE = 0x14, LTC4245_5VOUT = 0x15, LTC4245_3VIN = 0x16, LTC4245_3VSENSE = 0x17, LTC4245_3VOUT = 0x18, LTC4245_VEEIN = 0x19, LTC4245_VEESENSE = 0x1a, LTC4245_VEEOUT = 0x1b, LTC4245_GPIOADC = 0x1c } |
#define LTC4245_CURRENT | ( | name, | |
ltc4245_cmd_idx | |||
) |
#define LTC4245_GPIO_VOLTAGE | ( | name, | |
gpio_num | |||
) |
#define LTC4245_POWER | ( | name, | |
ltc4245_cmd_idx | |||
) |
#define LTC4245_VOLTAGE | ( | name, | |
ltc4245_cmd_idx | |||
) |
enum ltc4245_cmd |
LTC4245_ALARM | ( | in1_min_alarm | , |
(1<< 0) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | in2_min_alarm | , |
(1<< 1) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | in3_min_alarm | , |
(1<< 2) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | in4_min_alarm | , |
(1<< 3) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | curr1_max_alarm | , |
(1<< 4) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | curr2_max_alarm | , |
(1<< 5) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | curr3_max_alarm | , |
(1<< 6) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | curr4_max_alarm | , |
(1<< 7) | , | ||
LTC4245_FAULT1 | |||
) |
LTC4245_ALARM | ( | in5_min_alarm | , |
(1<< 0) | , | ||
LTC4245_FAULT2 | |||
) |
LTC4245_ALARM | ( | in6_min_alarm | , |
(1<< 1) | , | ||
LTC4245_FAULT2 | |||
) |
LTC4245_ALARM | ( | in7_min_alarm | , |
(1<< 2) | , | ||
LTC4245_FAULT2 | |||
) |
LTC4245_ALARM | ( | in8_min_alarm | , |
(1<< 3) | , | ||
LTC4245_FAULT2 | |||
) |
LTC4245_CURRENT | ( | curr1_input | , |
LTC4245_12VSENSE | |||
) |
LTC4245_CURRENT | ( | curr2_input | , |
LTC4245_5VSENSE | |||
) |
LTC4245_CURRENT | ( | curr3_input | , |
LTC4245_3VSENSE | |||
) |
LTC4245_CURRENT | ( | curr4_input | , |
LTC4245_VEESENSE | |||
) |
LTC4245_GPIO_VOLTAGE | ( | in9_input | , |
0 | |||
) |
LTC4245_GPIO_VOLTAGE | ( | in10_input | , |
1 | |||
) |
LTC4245_GPIO_VOLTAGE | ( | in11_input | , |
2 | |||
) |
LTC4245_POWER | ( | power1_input | , |
LTC4245_12VSENSE | |||
) |
LTC4245_POWER | ( | power2_input | , |
LTC4245_5VSENSE | |||
) |
LTC4245_POWER | ( | power3_input | , |
LTC4245_3VSENSE | |||
) |
LTC4245_POWER | ( | power4_input | , |
LTC4245_VEESENSE | |||
) |
LTC4245_VOLTAGE | ( | in1_input | , |
LTC4245_12VIN | |||
) |
LTC4245_VOLTAGE | ( | in2_input | , |
LTC4245_5VIN | |||
) |
LTC4245_VOLTAGE | ( | in3_input | , |
LTC4245_3VIN | |||
) |
LTC4245_VOLTAGE | ( | in4_input | , |
LTC4245_VEEIN | |||
) |
LTC4245_VOLTAGE | ( | in5_input | , |
LTC4245_12VOUT | |||
) |
LTC4245_VOLTAGE | ( | in6_input | , |
LTC4245_5VOUT | |||
) |
LTC4245_VOLTAGE | ( | in7_input | , |
LTC4245_3VOUT | |||
) |
LTC4245_VOLTAGE | ( | in8_input | , |
LTC4245_VEEOUT | |||
) |
MODULE_AUTHOR | ( | "Ira W. Snyder <[email protected]>" | ) |
MODULE_DESCRIPTION | ( | "LTC4245 driver" | ) |
MODULE_DEVICE_TABLE | ( | i2c | , |
ltc4245_id | |||
) |
module_i2c_driver | ( | ltc4245_driver | ) |
MODULE_LICENSE | ( | "GPL" | ) |