<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Apr 15, 2016 at 1:29 AM, Gadre Nayan <span dir="ltr"><<a href="mailto:gadrenayan@gmail.com" target="_blank">gadrenayan@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Dear all,<br>
<br>
I am trying to test a dummy UIO driver to get timer interrupt events<br>
in Userspace.<br>
<br>
I register the UIO driver as a platform driver:<br>
<br>
static struct platform_device *uio_dummy_device;<br>
<br>
static struct device_driver uio_dummy_driver = {<br>
.name = "uio_dummy",<br>
.bus = &platform_bus_type,<br>
.probe = uio_dummy_probe,<br>
.remove = uio_dummy_remove,<br>
.shutdown = uio_dummy_shutdown,<br>
};<br>
<br>
/*<br>
* Main initialization/remove routines<br>
*/<br>
static int __init uio_dummy_init(void)<br>
{<br>
printk("uio_dummy_init( )\n" );<br>
uio_dummy_device = platform_device_register_simple("uio_dummy", -1,<br>
NULL, 0);<br>
if (IS_ERR(uio_dummy_device))<br>
return PTR_ERR(uio_dummy_device);<br>
<br>
return driver_register(&uio_dummy_driver);<br>
}<br>
<br>
So after the driver_register() My probe should be called but it isn't.<br></blockquote><div><br></div><div>yes but did you register the device in your device tree or your boot file? </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Why is this happening.<br>
<br>
Thanks<br>
Nayan<br>
<br>
_______________________________________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org">Kernelnewbies@kernelnewbies.org</a><br>
<a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" rel="noreferrer" target="_blank">http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
</blockquote></div><br></div></div>