tepla.c 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /*
  2. * File: arch/blackfin/mach-bf561/tepla.c
  3. *
  4. * Copyright 2004-2007 Analog Devices Inc.
  5. * Only SMSC91C1111 was registered, may do more later.
  6. *
  7. * Copyright 2005 National ICT Australia (NICTA), Aidan Williams <aidan@nicta.com.au>
  8. * Thanks to Jamey Hicks.
  9. *
  10. * This program is free software; you can redistribute it and/or modify
  11. * it under the terms of the GNU General Public License version 2 as
  12. * published by the Free Software Foundation.
  13. */
  14. #include <linux/device.h>
  15. #include <linux/platform_device.h>
  16. #include <linux/irq.h>
  17. const char bfin_board_name[] = "Tepla-BF561";
  18. /*
  19. * Driver needs to know address, irq and flag pin.
  20. */
  21. static struct resource smc91x_resources[] = {
  22. {
  23. .start = 0x2C000300,
  24. .end = 0x2C000320,
  25. .flags = IORESOURCE_MEM,
  26. }, {
  27. .start = IRQ_PROG_INTB,
  28. .end = IRQ_PROG_INTB,
  29. .flags = IORESOURCE_IRQ|IORESOURCE_IRQ_HIGHLEVEL,
  30. }, {
  31. .start = IRQ_PF7,
  32. .end = IRQ_PF7,
  33. .flags = IORESOURCE_IRQ|IORESOURCE_IRQ_HIGHLEVEL,
  34. },
  35. };
  36. static struct platform_device smc91x_device = {
  37. .name = "smc91x",
  38. .id = 0,
  39. .num_resources = ARRAY_SIZE(smc91x_resources),
  40. .resource = smc91x_resources,
  41. };
  42. static struct platform_device *tepla_devices[] __initdata = {
  43. &smc91x_device,
  44. };
  45. static int __init tepla_init(void)
  46. {
  47. printk(KERN_INFO "%s(): registering device resources\n", __func__);
  48. return platform_add_devices(tepla_devices, ARRAY_SIZE(tepla_devices));
  49. }
  50. arch_initcall(tepla_init);