diff options
author | Magnus Damm <damm@opensource.se> | 2010-02-25 06:10:54 -0500 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2010-02-26 01:30:08 -0500 |
commit | 6b3b55750b0de4a4ff2742efd34ff74665fa4e2f (patch) | |
tree | e489bcf779e2e4272d47e6bbde62e02f5d048028 /arch/sh/boards | |
parent | 2839bd61f671d3debf9ef0893a0470fd97b2e2ce (diff) |
sh: ecovec build fix for CONFIG_I2C=n
Allow building the ecovec board support code
even though I2C support is disabled.
Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/boards')
-rw-r--r-- | arch/sh/boards/mach-ecovec24/setup.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/sh/boards/mach-ecovec24/setup.c b/arch/sh/boards/mach-ecovec24/setup.c index 3248406ea7ff..39ed8722d11a 100644 --- a/arch/sh/boards/mach-ecovec24/setup.c +++ b/arch/sh/boards/mach-ecovec24/setup.c | |||
@@ -794,6 +794,7 @@ static struct platform_device *ecovec_devices[] __initdata = { | |||
794 | &irda_device, | 794 | &irda_device, |
795 | }; | 795 | }; |
796 | 796 | ||
797 | #ifdef CONFIG_I2C | ||
797 | #define EEPROM_ADDR 0x50 | 798 | #define EEPROM_ADDR 0x50 |
798 | static u8 mac_read(struct i2c_adapter *a, u8 command) | 799 | static u8 mac_read(struct i2c_adapter *a, u8 command) |
799 | { | 800 | { |
@@ -836,6 +837,12 @@ static void __init sh_eth_init(struct sh_eth_plat_data *pd) | |||
836 | msleep(10); | 837 | msleep(10); |
837 | } | 838 | } |
838 | } | 839 | } |
840 | #else | ||
841 | static void __init sh_eth_init(struct sh_eth_plat_data *pd) | ||
842 | { | ||
843 | pr_err("unable to read sh_eth MAC address\n"); | ||
844 | } | ||
845 | #endif | ||
839 | 846 | ||
840 | #define PORT_HIZA 0xA4050158 | 847 | #define PORT_HIZA 0xA4050158 |
841 | #define IODRIVEA 0xA405018A | 848 | #define IODRIVEA 0xA405018A |