1*4882a593Smuzhiyun /*
2*4882a593Smuzhiyun * mcf8390.c -- platform support for 8390 ethernet on many boards
3*4882a593Smuzhiyun *
4*4882a593Smuzhiyun * (C) Copyright 2012, Greg Ungerer <gerg@uclinux.org>
5*4882a593Smuzhiyun *
6*4882a593Smuzhiyun * This file is subject to the terms and conditions of the GNU General Public
7*4882a593Smuzhiyun * License. See the file COPYING in the main directory of this archive
8*4882a593Smuzhiyun * for more details.
9*4882a593Smuzhiyun */
10*4882a593Smuzhiyun
11*4882a593Smuzhiyun #include <linux/kernel.h>
12*4882a593Smuzhiyun #include <linux/module.h>
13*4882a593Smuzhiyun #include <linux/init.h>
14*4882a593Smuzhiyun #include <linux/resource.h>
15*4882a593Smuzhiyun #include <linux/platform_device.h>
16*4882a593Smuzhiyun #include <asm/mcf8390.h>
17*4882a593Smuzhiyun
18*4882a593Smuzhiyun static struct resource mcf8390_resources[] = {
19*4882a593Smuzhiyun {
20*4882a593Smuzhiyun .start = NE2000_ADDR,
21*4882a593Smuzhiyun .end = NE2000_ADDR + NE2000_ADDRSIZE - 1,
22*4882a593Smuzhiyun .flags = IORESOURCE_MEM,
23*4882a593Smuzhiyun },
24*4882a593Smuzhiyun {
25*4882a593Smuzhiyun .start = NE2000_IRQ_VECTOR,
26*4882a593Smuzhiyun .end = NE2000_IRQ_VECTOR,
27*4882a593Smuzhiyun .flags = IORESOURCE_IRQ,
28*4882a593Smuzhiyun },
29*4882a593Smuzhiyun };
30*4882a593Smuzhiyun
mcf8390_platform_init(void)31*4882a593Smuzhiyun static int __init mcf8390_platform_init(void)
32*4882a593Smuzhiyun {
33*4882a593Smuzhiyun platform_device_register_simple("mcf8390", -1, mcf8390_resources,
34*4882a593Smuzhiyun ARRAY_SIZE(mcf8390_resources));
35*4882a593Smuzhiyun return 0;
36*4882a593Smuzhiyun }
37*4882a593Smuzhiyun
38*4882a593Smuzhiyun arch_initcall(mcf8390_platform_init);
39