[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <ABD0E28F-0839-4C6F-A0BD-999A28A6803A@niasdigital.com>
Date: Thu, 2 Sep 2010 09:33:47 +1000
From: Ben Nizette <bn@...sdigital.com>
To: Armin Steinhoff <armin@...inhoff.de>
Cc: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [UIO] SMX UIO interface
On 01/09/2010, at 5:22 PM, Armin Steinhoff wrote:
> Hi Ben,
>
> I have a question about the SMX UIO Interface.
>
> In the SMX module you are reading the data of the platform resourses:
>
> regs = platform_get_resource(dev, IORESOURCE_MEM, 0);
> if (!regs) {
> dev_err(&dev->dev, "No memory resource specified\n");
> goto out_free;
> }
>
> But who sets these data initially ?
Who ever sets up the platform device that will bind to this driver, usually the board code (eg on avr32 arch/avr32/boards/*/setup.c, ARM is somewhere under arch/arm/mach-*/ I think).
The board code would create an array of struct resource with the appropriate memory regions and an IRQ entry, create a struct platform_device with the right content to bind to that driver, set the platform_device .resource field to the previously created array then call platform_device_register() to kick things off.
--Ben.
>
> Cheers
>
> --Armin
>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists