* Main initialization/remove routines */ static int __init uio_dummy_init(void) { printk("uio_dummy_init( )\n" ); uio_dummy_device = platform_device_register_simple("uio_dummy", -1, NULL, 0);
You also need to register the UIO driver by calling uio_register_device() after populating your "struct uio_info" appropriately.
Why are you using a platform driver and device on x86? That's not going to work at all, as your device doesn't have an irq. Please use this on a "real" device that has an interrupt assigned to it.
If it's only for learning purpose, I guess one can skip registering a IRQ handler and use UIO_IRQ_CUSTOM, right? I did something similar for testing a UIO hotplug bug once. I used to fake an IRQ event from a timer by using uio_event_notify(). https://github.com/mandeepsandhu/uio-hotplug-test/blob/master/uio_fake_hotpl... Although, I'm not sure if the OP wants to do something similar HTH, -mandeep
hope this helps,
greg k-h
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies