Indentation: Various indentation fixes
Fixed indentation using indent tool in the src/drivers/i2c tree Change-Id: I5b396e5753544aff13ac5d16afc59e193a6b1da1 Signed-off-by: Vikram Narayanan <vikram186@gmail.com> Reviewed-on: http://review.coreboot.org/506 Tested-by: build bot (Jenkins) Reviewed-by: Kerry Sheh <shekairui@gmail.com> Reviewed-by: Marc Jones <marcj303@gmail.com>
This commit is contained in:
committed by
Marc Jones
parent
7bfd22e4c6
commit
0786bc6ad8
@ -24,16 +24,15 @@ static void adm1026_enable_monitoring(device_t dev);
|
|||||||
|
|
||||||
static void adm1026_init(device_t dev)
|
static void adm1026_init(device_t dev)
|
||||||
{
|
{
|
||||||
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C)
|
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C) {
|
||||||
{
|
|
||||||
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
||||||
if( dev->bus->dev->path.type == DEVICE_PATH_I2C) smbus_set_link(dev); // it is under mux
|
if (dev->bus->dev->path.type == DEVICE_PATH_I2C)
|
||||||
|
smbus_set_link(dev); // it is under mux
|
||||||
adm1026_enable_monitoring(dev);
|
adm1026_enable_monitoring(dev);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
static void adm1026_enable_monitoring(device_t dev)
|
static void adm1026_enable_monitoring(device_t dev)
|
||||||
{
|
{
|
||||||
int result;
|
int result;
|
||||||
@ -47,6 +46,7 @@ static void adm1026_enable_monitoring(device_t dev)
|
|||||||
printk(BIOS_DEBUG, "ADM1026: monitoring would not enable");
|
printk(BIOS_DEBUG, "ADM1026: monitoring would not enable");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void adm1026_noop(device_t dummy)
|
static void adm1026_noop(device_t dummy)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -47,7 +47,6 @@ static void adm1027_init(device_t dev)
|
|||||||
smbus_set_link(dev); // it is under mux
|
smbus_set_link(dev); // it is under mux
|
||||||
adm1027_enable_monitoring(dev);
|
adm1027_enable_monitoring(dev);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -9,16 +9,14 @@
|
|||||||
|
|
||||||
static void i2cmux_set_link(device_t dev, unsigned int link)
|
static void i2cmux_set_link(device_t dev, unsigned int link)
|
||||||
{
|
{
|
||||||
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C)
|
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C) {
|
||||||
{
|
|
||||||
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
||||||
smbus_write_byte(dev, 0x01, 1 << link); // output value
|
smbus_write_byte(dev, 0x01, 1 << link); // output value
|
||||||
smbus_write_byte(dev, 0x03, 0); // all output
|
smbus_write_byte(dev, 0x03, 0); // all output
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
static void i2cmux_noop(device_t dummy)
|
static void i2cmux_noop(device_t dummy)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -9,15 +9,13 @@
|
|||||||
|
|
||||||
static void i2cmux2_set_link(device_t dev, unsigned int link)
|
static void i2cmux2_set_link(device_t dev, unsigned int link)
|
||||||
{
|
{
|
||||||
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C)
|
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C) {
|
||||||
{
|
|
||||||
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
||||||
smbus_send_byte(dev, link); // output value
|
smbus_send_byte(dev, link); // output value
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
static void i2cmux2_noop(device_t dummy)
|
static void i2cmux2_noop(device_t dummy)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@ -7,23 +7,21 @@
|
|||||||
#include <cpu/x86/msr.h>
|
#include <cpu/x86/msr.h>
|
||||||
#include "chip.h"
|
#include "chip.h"
|
||||||
|
|
||||||
|
|
||||||
static void lm63_init(device_t dev)
|
static void lm63_init(device_t dev)
|
||||||
{
|
{
|
||||||
int result;
|
int result;
|
||||||
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C)
|
if (dev->enabled && dev->path.type == DEVICE_PATH_I2C) {
|
||||||
{
|
|
||||||
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
if (ops_smbus_bus(get_pbus_smbus(dev))) {
|
||||||
if( dev->bus->dev->path.type == DEVICE_PATH_I2C) smbus_set_link(dev); // it is under mux
|
if (dev->bus->dev->path.type == DEVICE_PATH_I2C)
|
||||||
|
smbus_set_link(dev); // it is under mux
|
||||||
result = smbus_read_byte(dev, 0x03);
|
result = smbus_read_byte(dev, 0x03);
|
||||||
// result &= ~0x04;
|
// result &= ~0x04;
|
||||||
result |= 0x04;
|
result |= 0x04;
|
||||||
smbus_write_byte(dev, 0x03, result & 0xff); // config lm63
|
smbus_write_byte(dev, 0x03, result & 0xff); // config lm63
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
static void lm63_noop(device_t dummy)
|
static void lm63_noop(device_t dummy)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user