Skip to content

Commit

Permalink
sh: ecovec build fix for CONFIG_I2C=n
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Magnus Damm authored and Paul Mundt committed Feb 26, 2010
1 parent 2839bd6 commit 6b3b557
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions arch/sh/boards/mach-ecovec24/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -794,6 +794,7 @@ static struct platform_device *ecovec_devices[] __initdata = {
&irda_device,
};

#ifdef CONFIG_I2C
#define EEPROM_ADDR 0x50
static u8 mac_read(struct i2c_adapter *a, u8 command)
{
Expand Down Expand Up @@ -836,6 +837,12 @@ static void __init sh_eth_init(struct sh_eth_plat_data *pd)
msleep(10);
}
}
#else
static void __init sh_eth_init(struct sh_eth_plat_data *pd)
{
pr_err("unable to read sh_eth MAC address\n");
}
#endif

#define PORT_HIZA 0xA4050158
#define IODRIVEA 0xA405018A
Expand Down

0 comments on commit 6b3b557

Please sign in to comment.