diff options
Diffstat (limited to 'arch/arm/mach-omap2/board-devkit8000.c')
-rw-r--r-- | arch/arm/mach-omap2/board-devkit8000.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/board-devkit8000.c b/arch/arm/mach-omap2/board-devkit8000.c index ca4d521947ac..f8303f7bbe76 100644 --- a/arch/arm/mach-omap2/board-devkit8000.c +++ b/arch/arm/mach-omap2/board-devkit8000.c | |||
@@ -33,6 +33,7 @@ | |||
33 | #include <linux/i2c/twl.h> | 33 | #include <linux/i2c/twl.h> |
34 | 34 | ||
35 | #include <mach/hardware.h> | 35 | #include <mach/hardware.h> |
36 | #include <mach/id.h> | ||
36 | #include <asm/mach-types.h> | 37 | #include <asm/mach-types.h> |
37 | #include <asm/mach/arch.h> | 38 | #include <asm/mach/arch.h> |
38 | #include <asm/mach/map.h> | 39 | #include <asm/mach/map.h> |
@@ -556,6 +557,9 @@ static struct platform_device omap_dm9000_dev = { | |||
556 | 557 | ||
557 | static void __init omap_dm9000_init(void) | 558 | static void __init omap_dm9000_init(void) |
558 | { | 559 | { |
560 | unsigned char *eth_addr = omap_dm9000_platdata.dev_addr; | ||
561 | struct omap_die_id odi; | ||
562 | |||
559 | if (gpio_request(OMAP_DM9000_GPIO_IRQ, "dm9000 irq") < 0) { | 563 | if (gpio_request(OMAP_DM9000_GPIO_IRQ, "dm9000 irq") < 0) { |
560 | printk(KERN_ERR "Failed to request GPIO%d for dm9000 IRQ\n", | 564 | printk(KERN_ERR "Failed to request GPIO%d for dm9000 IRQ\n", |
561 | OMAP_DM9000_GPIO_IRQ); | 565 | OMAP_DM9000_GPIO_IRQ); |
@@ -563,6 +567,16 @@ static void __init omap_dm9000_init(void) | |||
563 | } | 567 | } |
564 | 568 | ||
565 | gpio_direction_input(OMAP_DM9000_GPIO_IRQ); | 569 | gpio_direction_input(OMAP_DM9000_GPIO_IRQ); |
570 | |||
571 | /* init the mac address using DIE id */ | ||
572 | omap_get_die_id(&odi); | ||
573 | |||
574 | eth_addr[0] = 0x02; /* locally administered */ | ||
575 | eth_addr[1] = odi.id_1 & 0xff; | ||
576 | eth_addr[2] = (odi.id_0 & 0xff000000) >> 24; | ||
577 | eth_addr[3] = (odi.id_0 & 0x00ff0000) >> 16; | ||
578 | eth_addr[4] = (odi.id_0 & 0x0000ff00) >> 8; | ||
579 | eth_addr[5] = (odi.id_0 & 0x000000ff); | ||
566 | } | 580 | } |
567 | 581 | ||
568 | static struct platform_device *devkit8000_devices[] __initdata = { | 582 | static struct platform_device *devkit8000_devices[] __initdata = { |