[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4EA1306B.5070001@suse.cz>
Date: Fri, 21 Oct 2011 10:42:19 +0200
From: Michal Marek <mmarek@...e.cz>
To: gxt@...c.pku.edu.cn
Cc: Axel Lin <axel.lin@...il.com>, Arnd Bergmann <arnd@...db.de>,
linux-kernel@...r.kernel.org,
Alessandro Zummo <a.zummo@...ertech.it>,
rtc-linux@...glegroups.com
Subject: Re: [PATCH] rtc: rtc-puv3: Add __devinit and __devexit markers for
probe and remove
On 21.10.2011 10:32, Michal Marek wrote:
> The warning message tries to hint at the solution. Just name the variable
>
> static struct platform_driver puv3_rtc_driver
>
> and modpost will know that this is simply a list of pointers to driver
> functions, in which case the section mismatch is OK (the init function
> will only be called at init time).
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Correction: it's actually a probe function with __devinit, which on most
setups (with CONFIG_HOTPLUG=y) can be called any time, but then on those
setups the __devinit does not cause the section to be freed.
Nevertheless, naming the variable puv3_rtc_driver is the correct solution.
Michal
--
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