blob: 6c58f01b358a1064db6a869ee2cbac52b4b8ba0a [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
2 * linux/arch/arm/mach-sa1100/neponset.c
Linus Torvalds1da177e2005-04-16 15:20:36 -07003 */
Russell King9590e892012-01-24 22:36:47 +00004#include <linux/err.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07005#include <linux/init.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07006#include <linux/ioport.h>
Russell Kingced8d212012-01-24 22:22:18 +00007#include <linux/irq.h>
Russell King92e617d2012-01-24 22:13:00 +00008#include <linux/kernel.h>
Russell Kingae14c2e2012-01-24 22:10:02 +00009#include <linux/module.h>
Russell Kingd052d1b2005-10-29 19:07:23 +010010#include <linux/platform_device.h>
Russell King51f93392012-01-24 23:29:47 +000011#include <linux/pm.h>
Russell King92e617d2012-01-24 22:13:00 +000012#include <linux/serial_core.h>
Russell Kingae14c2e2012-01-24 22:10:02 +000013#include <linux/slab.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070014
Linus Torvalds1da177e2005-04-16 15:20:36 -070015#include <asm/mach-types.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070016#include <asm/mach/map.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070017#include <asm/mach/serial_sa1100.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -070018#include <asm/hardware/sa1111.h>
19#include <asm/sizes.h>
20
Russell King92e617d2012-01-24 22:13:00 +000021#include <mach/hardware.h>
22#include <mach/assabet.h>
23#include <mach/neponset.h>
Rob Herringf314f332012-02-24 00:06:51 +010024#include <mach/irqs.h>
Russell King92e617d2012-01-24 22:13:00 +000025
Russell Kingced8d212012-01-24 22:22:18 +000026#define NEP_IRQ_SMC91X 0
27#define NEP_IRQ_USAR 1
28#define NEP_IRQ_SA1111 2
29#define NEP_IRQ_NR 3
30
Russell Kingf942b0f2012-01-29 11:19:06 +000031#define WHOAMI 0x00
32#define LEDS 0x10
33#define SWPK 0x20
34#define IRR 0x24
35#define KP_Y_IN 0x80
36#define KP_X_OUT 0x90
37#define NCR_0 0xa0
38#define MDM_CTL_0 0xb0
39#define MDM_CTL_1 0xb4
40#define AUD_CTL 0xc0
41
42#define IRR_ETHERNET (1 << 0)
43#define IRR_USAR (1 << 1)
44#define IRR_SA1111 (1 << 2)
45
46#define MDM_CTL0_RTS1 (1 << 0)
47#define MDM_CTL0_DTR1 (1 << 1)
48#define MDM_CTL0_RTS2 (1 << 2)
49#define MDM_CTL0_DTR2 (1 << 3)
50
51#define MDM_CTL1_CTS1 (1 << 0)
52#define MDM_CTL1_DSR1 (1 << 1)
53#define MDM_CTL1_DCD1 (1 << 2)
54#define MDM_CTL1_CTS2 (1 << 3)
55#define MDM_CTL1_DSR2 (1 << 4)
56#define MDM_CTL1_DCD2 (1 << 5)
57
58#define AUD_SEL_1341 (1 << 0)
59#define AUD_MUTE_1341 (1 << 1)
60
Russell Kingbab50a32012-01-26 11:50:23 +000061extern void sa1110_mb_disable(void);
62
Russell Kingae14c2e2012-01-24 22:10:02 +000063struct neponset_drvdata {
Russell Kingf942b0f2012-01-29 11:19:06 +000064 void __iomem *base;
Russell King9590e892012-01-24 22:36:47 +000065 struct platform_device *sa1111;
66 struct platform_device *smc91x;
Russell Kingced8d212012-01-24 22:22:18 +000067 unsigned irq_base;
Russell Kingae14c2e2012-01-24 22:10:02 +000068#ifdef CONFIG_PM_SLEEP
69 u32 ncr0;
70 u32 mdm_ctl_0;
71#endif
72};
73
Russell Kingf942b0f2012-01-29 11:19:06 +000074static void __iomem *nep_base;
75
Russell King6ad1b612012-01-16 09:31:47 +000076void neponset_ncr_frob(unsigned int mask, unsigned int val)
77{
Russell Kingf942b0f2012-01-29 11:19:06 +000078 void __iomem *base = nep_base;
Russell King6ad1b612012-01-16 09:31:47 +000079
Russell Kingf942b0f2012-01-29 11:19:06 +000080 if (base) {
81 unsigned long flags;
82 unsigned v;
83
84 local_irq_save(flags);
85 v = readb_relaxed(base + NCR_0);
86 writeb_relaxed((v & ~mask) | val, base + NCR_0);
87 local_irq_restore(flags);
88 } else {
89 WARN(1, "nep_base unset\n");
90 }
Russell King6ad1b612012-01-16 09:31:47 +000091}
92
Linus Torvalds1da177e2005-04-16 15:20:36 -070093static void neponset_set_mctrl(struct uart_port *port, u_int mctrl)
94{
Russell Kingf942b0f2012-01-29 11:19:06 +000095 void __iomem *base = nep_base;
96 u_int mdm_ctl0;
Linus Torvalds1da177e2005-04-16 15:20:36 -070097
Russell Kingf942b0f2012-01-29 11:19:06 +000098 if (!base)
99 return;
100
101 mdm_ctl0 = readb_relaxed(base + MDM_CTL_0);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700102 if (port->mapbase == _Ser1UTCR0) {
103 if (mctrl & TIOCM_RTS)
104 mdm_ctl0 &= ~MDM_CTL0_RTS2;
105 else
106 mdm_ctl0 |= MDM_CTL0_RTS2;
107
108 if (mctrl & TIOCM_DTR)
109 mdm_ctl0 &= ~MDM_CTL0_DTR2;
110 else
111 mdm_ctl0 |= MDM_CTL0_DTR2;
112 } else if (port->mapbase == _Ser3UTCR0) {
113 if (mctrl & TIOCM_RTS)
114 mdm_ctl0 &= ~MDM_CTL0_RTS1;
115 else
116 mdm_ctl0 |= MDM_CTL0_RTS1;
117
118 if (mctrl & TIOCM_DTR)
119 mdm_ctl0 &= ~MDM_CTL0_DTR1;
120 else
121 mdm_ctl0 |= MDM_CTL0_DTR1;
122 }
123
Russell Kingf942b0f2012-01-29 11:19:06 +0000124 writeb_relaxed(mdm_ctl0, base + MDM_CTL_0);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700125}
126
127static u_int neponset_get_mctrl(struct uart_port *port)
128{
Russell Kingf942b0f2012-01-29 11:19:06 +0000129 void __iomem *base = nep_base;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700130 u_int ret = TIOCM_CD | TIOCM_CTS | TIOCM_DSR;
Russell Kingf942b0f2012-01-29 11:19:06 +0000131 u_int mdm_ctl1;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700132
Russell Kingf942b0f2012-01-29 11:19:06 +0000133 if (!base)
134 return ret;
135
136 mdm_ctl1 = readb_relaxed(base + MDM_CTL_1);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700137 if (port->mapbase == _Ser1UTCR0) {
138 if (mdm_ctl1 & MDM_CTL1_DCD2)
139 ret &= ~TIOCM_CD;
140 if (mdm_ctl1 & MDM_CTL1_CTS2)
141 ret &= ~TIOCM_CTS;
142 if (mdm_ctl1 & MDM_CTL1_DSR2)
143 ret &= ~TIOCM_DSR;
144 } else if (port->mapbase == _Ser3UTCR0) {
145 if (mdm_ctl1 & MDM_CTL1_DCD1)
146 ret &= ~TIOCM_CD;
147 if (mdm_ctl1 & MDM_CTL1_CTS1)
148 ret &= ~TIOCM_CTS;
149 if (mdm_ctl1 & MDM_CTL1_DSR1)
150 ret &= ~TIOCM_DSR;
151 }
152
153 return ret;
154}
155
Russell Kingcdea4602007-05-30 17:48:45 +0100156static struct sa1100_port_fns neponset_port_fns __devinitdata = {
Linus Torvalds1da177e2005-04-16 15:20:36 -0700157 .set_mctrl = neponset_set_mctrl,
158 .get_mctrl = neponset_get_mctrl,
159};
160
Russell King71045522012-01-16 00:17:41 +0000161/*
Russell King92e617d2012-01-24 22:13:00 +0000162 * Install handler for Neponset IRQ. Note that we have to loop here
163 * since the ETHERNET and USAR IRQs are level based, and we need to
164 * ensure that the IRQ signal is deasserted before returning. This
165 * is rather unfortunate.
166 */
Russell Kingced8d212012-01-24 22:22:18 +0000167static void neponset_irq_handler(unsigned int irq, struct irq_desc *desc)
Russell King92e617d2012-01-24 22:13:00 +0000168{
Russell Kingced8d212012-01-24 22:22:18 +0000169 struct neponset_drvdata *d = irq_desc_get_handler_data(desc);
Russell King92e617d2012-01-24 22:13:00 +0000170 unsigned int irr;
171
172 while (1) {
173 /*
174 * Acknowledge the parent IRQ.
175 */
176 desc->irq_data.chip->irq_ack(&desc->irq_data);
177
178 /*
179 * Read the interrupt reason register. Let's have all
180 * active IRQ bits high. Note: there is a typo in the
181 * Neponset user's guide for the SA1111 IRR level.
182 */
Russell Kingf942b0f2012-01-29 11:19:06 +0000183 irr = readb_relaxed(d->base + IRR);
184 irr ^= IRR_ETHERNET | IRR_USAR;
Russell King92e617d2012-01-24 22:13:00 +0000185
186 if ((irr & (IRR_ETHERNET | IRR_USAR | IRR_SA1111)) == 0)
187 break;
188
189 /*
190 * Since there is no individual mask, we have to
191 * mask the parent IRQ. This is safe, since we'll
192 * recheck the register for any pending IRQs.
193 */
194 if (irr & (IRR_ETHERNET | IRR_USAR)) {
195 desc->irq_data.chip->irq_mask(&desc->irq_data);
196
197 /*
198 * Ack the interrupt now to prevent re-entering
199 * this neponset handler. Again, this is safe
200 * since we'll check the IRR register prior to
201 * leaving.
202 */
203 desc->irq_data.chip->irq_ack(&desc->irq_data);
204
Russell Kingced8d212012-01-24 22:22:18 +0000205 if (irr & IRR_ETHERNET)
206 generic_handle_irq(d->irq_base + NEP_IRQ_SMC91X);
Russell King92e617d2012-01-24 22:13:00 +0000207
Russell Kingced8d212012-01-24 22:22:18 +0000208 if (irr & IRR_USAR)
209 generic_handle_irq(d->irq_base + NEP_IRQ_USAR);
Russell King92e617d2012-01-24 22:13:00 +0000210
211 desc->irq_data.chip->irq_unmask(&desc->irq_data);
212 }
213
Russell Kingced8d212012-01-24 22:22:18 +0000214 if (irr & IRR_SA1111)
215 generic_handle_irq(d->irq_base + NEP_IRQ_SA1111);
Russell King92e617d2012-01-24 22:13:00 +0000216 }
217}
218
Russell Kingced8d212012-01-24 22:22:18 +0000219/* Yes, we really do not have any kind of masking or unmasking */
Russell King71045522012-01-16 00:17:41 +0000220static void nochip_noop(struct irq_data *irq)
221{
222}
223
224static struct irq_chip nochip = {
225 .name = "neponset",
226 .irq_ack = nochip_noop,
227 .irq_mask = nochip_noop,
228 .irq_unmask = nochip_noop,
229};
230
Russell King92e617d2012-01-24 22:13:00 +0000231static struct sa1111_platform_data sa1111_info = {
Russell King07be45f2012-01-26 13:34:21 +0000232 .disable_devs = SA1111_DEVID_PS2_MSE,
Russell King92e617d2012-01-24 22:13:00 +0000233};
234
Russell Kingcdea4602007-05-30 17:48:45 +0100235static int __devinit neponset_probe(struct platform_device *dev)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700236{
Russell Kingae14c2e2012-01-24 22:10:02 +0000237 struct neponset_drvdata *d;
Russell Kingf942b0f2012-01-29 11:19:06 +0000238 struct resource *nep_res, *sa1111_res, *smc91x_res;
Russell Kingced8d212012-01-24 22:22:18 +0000239 struct resource sa1111_resources[] = {
240 DEFINE_RES_MEM(0x40000000, SZ_8K),
241 { .flags = IORESOURCE_IRQ },
242 };
Russell King9590e892012-01-24 22:36:47 +0000243 struct platform_device_info sa1111_devinfo = {
244 .parent = &dev->dev,
245 .name = "sa1111",
246 .id = 0,
247 .res = sa1111_resources,
248 .num_res = ARRAY_SIZE(sa1111_resources),
249 .data = &sa1111_info,
250 .size_data = sizeof(sa1111_info),
251 .dma_mask = 0xffffffffUL,
252 };
Russell Kingced8d212012-01-24 22:22:18 +0000253 struct resource smc91x_resources[] = {
254 DEFINE_RES_MEM_NAMED(SA1100_CS3_PHYS,
255 0x02000000, "smc91x-regs"),
256 DEFINE_RES_MEM_NAMED(SA1100_CS3_PHYS + 0x02000000,
257 0x02000000, "smc91x-attrib"),
258 { .flags = IORESOURCE_IRQ },
259 };
Russell King9590e892012-01-24 22:36:47 +0000260 struct platform_device_info smc91x_devinfo = {
261 .parent = &dev->dev,
262 .name = "smc91x",
263 .id = 0,
264 .res = smc91x_resources,
265 .num_res = ARRAY_SIZE(smc91x_resources),
266 };
Russell Kingb6bdfcf2012-01-24 23:05:08 +0000267 int ret, irq;
268
Russell Kingf942b0f2012-01-29 11:19:06 +0000269 if (nep_base)
270 return -EBUSY;
271
Russell Kingb6bdfcf2012-01-24 23:05:08 +0000272 irq = ret = platform_get_irq(dev, 0);
273 if (ret < 0)
274 goto err_alloc;
Russell Kingae14c2e2012-01-24 22:10:02 +0000275
Russell Kingf942b0f2012-01-29 11:19:06 +0000276 nep_res = platform_get_resource(dev, IORESOURCE_MEM, 0);
Russell Kingd2e539a2012-01-24 23:17:37 +0000277 smc91x_res = platform_get_resource(dev, IORESOURCE_MEM, 1);
278 sa1111_res = platform_get_resource(dev, IORESOURCE_MEM, 2);
Russell Kingf942b0f2012-01-29 11:19:06 +0000279 if (!nep_res || !smc91x_res || !sa1111_res) {
Russell Kingd2e539a2012-01-24 23:17:37 +0000280 ret = -ENXIO;
281 goto err_alloc;
282 }
283
Russell Kingae14c2e2012-01-24 22:10:02 +0000284 d = kzalloc(sizeof(*d), GFP_KERNEL);
285 if (!d) {
286 ret = -ENOMEM;
287 goto err_alloc;
288 }
289
Russell Kingf942b0f2012-01-29 11:19:06 +0000290 d->base = ioremap(nep_res->start, SZ_4K);
291 if (!d->base) {
292 ret = -ENOMEM;
293 goto err_ioremap;
294 }
295
296 if (readb_relaxed(d->base + WHOAMI) != 0x11) {
297 dev_warn(&dev->dev, "Neponset board detected, but wrong ID: %02x\n",
298 readb_relaxed(d->base + WHOAMI));
299 ret = -ENODEV;
300 goto err_id;
301 }
302
Russell Kingced8d212012-01-24 22:22:18 +0000303 ret = irq_alloc_descs(-1, IRQ_BOARD_START, NEP_IRQ_NR, -1);
304 if (ret <= 0) {
305 dev_err(&dev->dev, "unable to allocate %u irqs: %d\n",
306 NEP_IRQ_NR, ret);
307 if (ret == 0)
308 ret = -ENOMEM;
309 goto err_irq_alloc;
310 }
Linus Torvalds1da177e2005-04-16 15:20:36 -0700311
Russell Kingced8d212012-01-24 22:22:18 +0000312 d->irq_base = ret;
313
314 irq_set_chip_and_handler(d->irq_base + NEP_IRQ_SMC91X, &nochip,
315 handle_simple_irq);
316 set_irq_flags(d->irq_base + NEP_IRQ_SMC91X, IRQF_VALID | IRQF_PROBE);
317 irq_set_chip_and_handler(d->irq_base + NEP_IRQ_USAR, &nochip,
318 handle_simple_irq);
319 set_irq_flags(d->irq_base + NEP_IRQ_USAR, IRQF_VALID | IRQF_PROBE);
320 irq_set_chip(d->irq_base + NEP_IRQ_SA1111, &nochip);
321
Russell Kingb6bdfcf2012-01-24 23:05:08 +0000322 irq_set_irq_type(irq, IRQ_TYPE_EDGE_RISING);
323 irq_set_handler_data(irq, d);
324 irq_set_chained_handler(irq, neponset_irq_handler);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700325
326 /*
Russell Kingced8d212012-01-24 22:22:18 +0000327 * We would set IRQ_GPIO25 to be a wake-up IRQ, but unfortunately
328 * something on the Neponset activates this IRQ on sleep (eth?)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700329 */
330#if 0
Russell Kingb6bdfcf2012-01-24 23:05:08 +0000331 enable_irq_wake(irq);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700332#endif
333
Russell Kingced8d212012-01-24 22:22:18 +0000334 dev_info(&dev->dev, "Neponset daughter board, providing IRQ%u-%u\n",
335 d->irq_base, d->irq_base + NEP_IRQ_NR - 1);
Russell Kingf942b0f2012-01-29 11:19:06 +0000336 nep_base = d->base;
Linus Torvalds1da177e2005-04-16 15:20:36 -0700337
Russell Kingced8d212012-01-24 22:22:18 +0000338 sa1100_register_uart_fns(&neponset_port_fns);
339
Russell Kingbab50a32012-01-26 11:50:23 +0000340 /* Ensure that the memory bus request/grant signals are setup */
341 sa1110_mb_disable();
342
Russell Kingced8d212012-01-24 22:22:18 +0000343 /* Disable GPIO 0/1 drivers so the buttons work on the Assabet */
Russell Kingf942b0f2012-01-29 11:19:06 +0000344 writeb_relaxed(NCR_GP01_OFF, d->base + NCR_0);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700345
Russell Kingd2e539a2012-01-24 23:17:37 +0000346 sa1111_resources[0].parent = sa1111_res;
Russell Kingced8d212012-01-24 22:22:18 +0000347 sa1111_resources[1].start = d->irq_base + NEP_IRQ_SA1111;
348 sa1111_resources[1].end = d->irq_base + NEP_IRQ_SA1111;
Russell King9590e892012-01-24 22:36:47 +0000349 d->sa1111 = platform_device_register_full(&sa1111_devinfo);
Russell Kingced8d212012-01-24 22:22:18 +0000350
Russell Kingd2e539a2012-01-24 23:17:37 +0000351 smc91x_resources[0].parent = smc91x_res;
352 smc91x_resources[1].parent = smc91x_res;
Russell Kingced8d212012-01-24 22:22:18 +0000353 smc91x_resources[2].start = d->irq_base + NEP_IRQ_SMC91X;
354 smc91x_resources[2].end = d->irq_base + NEP_IRQ_SMC91X;
Russell King9590e892012-01-24 22:36:47 +0000355 d->smc91x = platform_device_register_full(&smc91x_devinfo);
356
Russell Kingae14c2e2012-01-24 22:10:02 +0000357 platform_set_drvdata(dev, d);
358
359 return 0;
360
Russell Kingced8d212012-01-24 22:22:18 +0000361 err_irq_alloc:
Russell Kingf942b0f2012-01-29 11:19:06 +0000362 err_id:
363 iounmap(d->base);
364 err_ioremap:
Russell Kingced8d212012-01-24 22:22:18 +0000365 kfree(d);
Russell Kingae14c2e2012-01-24 22:10:02 +0000366 err_alloc:
367 return ret;
368}
369
370static int __devexit neponset_remove(struct platform_device *dev)
371{
372 struct neponset_drvdata *d = platform_get_drvdata(dev);
Russell Kingb6bdfcf2012-01-24 23:05:08 +0000373 int irq = platform_get_irq(dev, 0);
Russell Kingae14c2e2012-01-24 22:10:02 +0000374
Russell King9590e892012-01-24 22:36:47 +0000375 if (!IS_ERR(d->sa1111))
376 platform_device_unregister(d->sa1111);
377 if (!IS_ERR(d->smc91x))
378 platform_device_unregister(d->smc91x);
Russell Kingb6bdfcf2012-01-24 23:05:08 +0000379 irq_set_chained_handler(irq, NULL);
Russell Kingced8d212012-01-24 22:22:18 +0000380 irq_free_descs(d->irq_base, NEP_IRQ_NR);
Russell Kingf942b0f2012-01-29 11:19:06 +0000381 nep_base = NULL;
382 iounmap(d->base);
Russell Kingae14c2e2012-01-24 22:10:02 +0000383 kfree(d);
384
Linus Torvalds1da177e2005-04-16 15:20:36 -0700385 return 0;
386}
387
Russell King51f93392012-01-24 23:29:47 +0000388#ifdef CONFIG_PM_SLEEP
389static int neponset_suspend(struct device *dev)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700390{
Russell King51f93392012-01-24 23:29:47 +0000391 struct neponset_drvdata *d = dev_get_drvdata(dev);
Russell Kingae14c2e2012-01-24 22:10:02 +0000392
Russell Kingf942b0f2012-01-29 11:19:06 +0000393 d->ncr0 = readb_relaxed(d->base + NCR_0);
394 d->mdm_ctl_0 = readb_relaxed(d->base + MDM_CTL_0);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700395
396 return 0;
397}
398
Russell King51f93392012-01-24 23:29:47 +0000399static int neponset_resume(struct device *dev)
Linus Torvalds1da177e2005-04-16 15:20:36 -0700400{
Russell King51f93392012-01-24 23:29:47 +0000401 struct neponset_drvdata *d = dev_get_drvdata(dev);
Russell Kingae14c2e2012-01-24 22:10:02 +0000402
Russell Kingf942b0f2012-01-29 11:19:06 +0000403 writeb_relaxed(d->ncr0, d->base + NCR_0);
404 writeb_relaxed(d->mdm_ctl_0, d->base + MDM_CTL_0);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700405
406 return 0;
407}
408
Russell King51f93392012-01-24 23:29:47 +0000409static const struct dev_pm_ops neponset_pm_ops = {
410 .suspend_noirq = neponset_suspend,
411 .resume_noirq = neponset_resume,
412 .freeze_noirq = neponset_suspend,
413 .restore_noirq = neponset_resume,
414};
415#define PM_OPS &neponset_pm_ops
Linus Torvalds1da177e2005-04-16 15:20:36 -0700416#else
Russell King51f93392012-01-24 23:29:47 +0000417#define PM_OPS NULL
Linus Torvalds1da177e2005-04-16 15:20:36 -0700418#endif
419
Russell King3ae5eae2005-11-09 22:32:44 +0000420static struct platform_driver neponset_device_driver = {
Linus Torvalds1da177e2005-04-16 15:20:36 -0700421 .probe = neponset_probe,
Russell Kingae14c2e2012-01-24 22:10:02 +0000422 .remove = __devexit_p(neponset_remove),
Russell King3ae5eae2005-11-09 22:32:44 +0000423 .driver = {
424 .name = "neponset",
Russell King398e58d2012-01-24 23:33:28 +0000425 .owner = THIS_MODULE,
Russell King51f93392012-01-24 23:29:47 +0000426 .pm = PM_OPS,
Russell King3ae5eae2005-11-09 22:32:44 +0000427 },
Linus Torvalds1da177e2005-04-16 15:20:36 -0700428};
429
Linus Torvalds1da177e2005-04-16 15:20:36 -0700430static int __init neponset_init(void)
431{
Russell Kingbab50a32012-01-26 11:50:23 +0000432 return platform_driver_register(&neponset_device_driver);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700433}
434
435subsys_initcall(neponset_init);