From 467a065384f0d50cbf2d100b55b58168ec98f0d3 Mon Sep 17 00:00:00 2001 From: Stefan Reinauer Date: Sun, 25 Apr 2010 14:37:18 +0000 Subject: no warnings days. Signed-off-by: Stefan Reinauer Acked-by: Stefan Reinauer git-svn-id: svn://svn.coreboot.org/coreboot/trunk@5493 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- src/southbridge/amd/amd8111/amd8111_early_smbus.c | 9 +++++---- src/southbridge/amd/cs5536/cs5536_smbus2.h | 18 ++++++++---------- 2 files changed, 13 insertions(+), 14 deletions(-) (limited to 'src/southbridge/amd') diff --git a/src/southbridge/amd/amd8111/amd8111_early_smbus.c b/src/southbridge/amd/amd8111/amd8111_early_smbus.c index 11aa6f750e..e6d70847ea 100644 --- a/src/southbridge/amd/amd8111/amd8111_early_smbus.c +++ b/src/southbridge/amd/amd8111/amd8111_early_smbus.c @@ -26,22 +26,23 @@ static void enable_smbus(void) print_spew("SMBus controller enabled\n"); } -static int smbus_recv_byte(unsigned device) +static inline int smbus_recv_byte(unsigned device) { return do_smbus_recv_byte(SMBUS_IO_BASE, device); } -static int smbus_send_byte(unsigned device, unsigned char val) +static inline int smbus_send_byte(unsigned device, unsigned char val) { return do_smbus_send_byte(SMBUS_IO_BASE, device, val); } -static int smbus_read_byte(unsigned device, unsigned address) +static inline int smbus_read_byte(unsigned device, unsigned address) { return do_smbus_read_byte(SMBUS_IO_BASE, device, address); } -static int smbus_write_byte(unsigned device, unsigned address, unsigned char val) +static inline int smbus_write_byte(unsigned device, unsigned address, unsigned char val) { return do_smbus_write_byte(SMBUS_IO_BASE, device, address, val); } + diff --git a/src/southbridge/amd/cs5536/cs5536_smbus2.h b/src/southbridge/amd/cs5536/cs5536_smbus2.h index 6e50a8cc84..3613b3d37b 100644 --- a/src/southbridge/amd/cs5536/cs5536_smbus2.h +++ b/src/southbridge/amd/cs5536/cs5536_smbus2.h @@ -253,18 +253,16 @@ static void _doread(unsigned smbus_io_base, unsigned char device, printk(BIOS_DEBUG, "SMBUS READ ERROR (%d): %d\n", index, ret); } -static unsigned char do_smbus_read_byte(unsigned smbus_io_base, - unsigned char device, - unsigned char address) +static inline unsigned char do_smbus_read_byte(unsigned smbus_io_base, + unsigned char device, unsigned char address) { unsigned char val = 0; _doread(smbus_io_base, device, address, &val, sizeof(val)); return val; } -static unsigned short do_smbus_read_word(unsigned smbus_io_base, - unsigned char device, - unsigned char address) +static inline unsigned short do_smbus_read_word(unsigned smbus_io_base, + unsigned char device, unsigned char address) { unsigned short val = 0; _doread(smbus_io_base, device, address, (unsigned char *)&val, @@ -304,15 +302,15 @@ static int _dowrite(unsigned smbus_io_base, unsigned char device, return -1; } -static int do_smbus_write_byte(unsigned smbus_io_base, unsigned char device, - unsigned char address, unsigned char data) +static inline int do_smbus_write_byte(unsigned smbus_io_base, + unsigned char device, unsigned char address, unsigned char data) { return _dowrite(smbus_io_base, device, address, (unsigned char *)&data, 1); } -static int do_smbus_write_word(unsigned smbus_io_base, unsigned char device, - unsigned char address, unsigned short data) +static inline int do_smbus_write_word(unsigned smbus_io_base, + unsigned char device, unsigned char address, unsigned short data) { return _dowrite(smbus_io_base, device, address, (unsigned char *)&data, 2); -- cgit v1.2.3