1 diff -urN linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/ds1302.c linux-2.6.19.2/arch/cris/arch-v10/drivers/ds1302.c
2 --- linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/ds1302.c 2007-05-28 22:35:23.000000000 +0200
3 +++ linux-2.6.19.2/arch/cris/arch-v10/drivers/ds1302.c 2007-05-28 22:55:40.000000000 +0200
5 #include <linux/delay.h>
7 #include <linux/capability.h>
9 +#include <linux/device.h>
10 #include <asm/uaccess.h>
11 #include <asm/system.h>
12 #include <asm/arch/svinto.h>
18 +static struct class *rtc_class;
21 static int __init ds1302_register(void)
25 ds1302_name, RTC_MAJOR_NR);
31 + rtc_class = class_create(THIS_MODULE, "rtc");
32 + class_device_create(rtc_class, NULL,
33 + MKDEV(RTC_MAJOR_NR, 0),
41 diff -urN linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/eeprom.c linux-2.6.19.2/arch/cris/arch-v10/drivers/eeprom.c
42 --- linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/eeprom.c 2007-05-28 22:35:23.000000000 +0200
43 +++ linux-2.6.19.2/arch/cris/arch-v10/drivers/eeprom.c 2007-05-28 23:03:45.000000000 +0200
45 #include <linux/delay.h>
46 #include <linux/interrupt.h>
47 #include <linux/wait.h>
48 +#include <linux/device.h>
49 #include <asm/uaccess.h>
55 /* eeprom init call. Probes for different eeprom models. */
57 +static struct class *eep_class;
60 int __init eeprom_init(void)
63 eeprom_name, EEPROM_MAJOR_NR);
69 + eep_class = class_create(THIS_MODULE, "eep");
70 + class_device_create(eep_class, NULL, MKDEV(EEPROM_MAJOR, 0), NULL, "eeprom");
74 printk("EEPROM char device v0.3, (c) 2000 Axis Communications AB\n");
77 diff -urN linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/gpio.c linux-2.6.19.2/arch/cris/arch-v10/drivers/gpio.c
78 --- linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/gpio.c 2007-05-28 22:35:23.000000000 +0200
79 +++ linux-2.6.19.2/arch/cris/arch-v10/drivers/gpio.c 2007-05-28 22:59:27.000000000 +0200
81 #include <linux/poll.h>
82 #include <linux/init.h>
83 #include <linux/interrupt.h>
84 +#include <linux/device.h>
86 #include <asm/etraxgpio.h>
87 #include <asm/arch/svinto.h>
90 /* main driver initialization routine, called from mem.c */
93 +static struct class *gpio_class;
104 + gpio_class = class_create(THIS_MODULE, "gpio");
105 + class_device_create(gpio_class, NULL, MKDEV(GPIO_MAJOR, 0), NULL, "gpioa");
106 + class_device_create(gpio_class, NULL, MKDEV(GPIO_MAJOR, 1), NULL, "gpiob");
107 + class_device_create(gpio_class, NULL, MKDEV(GPIO_MAJOR, 2), NULL, "leds");
108 + class_device_create(gpio_class, NULL, MKDEV(GPIO_MAJOR, 3), NULL, "gpiog");
112 #if defined (CONFIG_ETRAX_CSP0_LEDS) || defined (CONFIG_ETRAX_PA_LEDS) || defined (CONFIG_ETRAX_PB_LEDS)
114 diff -urN linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/pcf8563.c linux-2.6.19.2/arch/cris/arch-v10/drivers/pcf8563.c
115 --- linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/pcf8563.c 2007-05-28 22:35:23.000000000 +0200
116 +++ linux-2.6.19.2/arch/cris/arch-v10/drivers/pcf8563.c 2007-05-28 23:09:02.000000000 +0200
118 #include <linux/ioctl.h>
119 #include <linux/delay.h>
120 #include <linux/bcd.h>
121 +#include <linux/device.h>
123 #include <asm/uaccess.h>
124 #include <asm/system.h>
130 +static struct class *pcf8563_class;
134 pcf8563_register(void)
137 "device.\n", PCF8563_NAME, PCF8563_MAJOR);
141 + pcf8563_class = class_create(THIS_MODULE, "pcf8563");
142 + class_device_create(pcf8563_class, NULL, MKDEV(PCF8563_MAJOR, 0), NULL, "rtc");
145 printk(KERN_INFO "%s Real-Time Clock Driver, %s\n", PCF8563_NAME,
147 diff -urN linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/sync_serial.c linux-2.6.19.2/arch/cris/arch-v10/drivers/sync_serial.c
148 --- linux-2.6.19.2.orig/arch/cris/arch-v10/drivers/sync_serial.c 2007-05-28 22:35:23.000000000 +0200
149 +++ linux-2.6.19.2/arch/cris/arch-v10/drivers/sync_serial.c 2007-05-28 23:06:41.000000000 +0200
151 #include <asm/uaccess.h>
152 #include <asm/system.h>
153 #include <asm/sync_serial.h>
154 +#include <linux/device.h>
156 #include <asm/arch/io_interface_mux.h>
158 /* The receiver is a bit tricky beacuse of the continuous stream of data.*/
160 .open = sync_serial_open,
161 .release = sync_serial_release
164 +static struct class *syncser_class;
167 static int __init etrax_sync_serial_init(void)
170 printk("unable to get major for synchronous serial port\n");
174 + syncser_class = class_create(THIS_MODULE, "syncser");
175 + class_device_create(syncser_class, NULL, MKDEV(SYNC_SERIAL_MAJOR, 0), NULL, "syncser0");
176 + class_device_create(syncser_class, NULL, MKDEV(SYNC_SERIAL_MAJOR, 1), NULL, "syncser1");
179 /* Deselect synchronous serial ports while configuring. */
180 SETS(gen_config_ii_shadow, R_GEN_CONFIG_II, sermode1, async);