UIO driver test
Gadre Nayan
gadrenayan at gmail.com
Fri Apr 15 06:01:51 EDT 2016
Hi,
I am using this on x86 machine..so no device tree...where do I have to
register elsewhere here.?
On 15 Apr 2016 2:15 p.m., "anish singh" <anish198519851985 at gmail.com> wrote:
>
>
> On Fri, Apr 15, 2016 at 1:29 AM, Gadre Nayan <gadrenayan at gmail.com> wrote:
>
>> Dear all,
>>
>> I am trying to test a dummy UIO driver to get timer interrupt events
>> in Userspace.
>>
>> I register the UIO driver as a platform driver:
>>
>> static struct platform_device *uio_dummy_device;
>>
>> static struct device_driver uio_dummy_driver = {
>> .name = "uio_dummy",
>> .bus = &platform_bus_type,
>> .probe = uio_dummy_probe,
>> .remove = uio_dummy_remove,
>> .shutdown = uio_dummy_shutdown,
>> };
>>
>> /*
>> * 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);
>> if (IS_ERR(uio_dummy_device))
>> return PTR_ERR(uio_dummy_device);
>>
>> return driver_register(&uio_dummy_driver);
>> }
>>
>> So after the driver_register() My probe should be called but it isn't.
>>
>
> yes but did you register the device in your device tree or your boot file?
>
>>
>> Why is this happening.
>>
>> Thanks
>> Nayan
>>
>> _______________________________________________
>> Kernelnewbies mailing list
>> Kernelnewbies at kernelnewbies.org
>> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20160415/654096c3/attachment.html
More information about the Kernelnewbies
mailing list