Commit 67e1ab5b authored by Uwe Kleine-König's avatar Uwe Kleine-König Committed by Helge Deller

fbdev: amifb: Mark driver struct with __refdata to prevent section mismatch warning

As described in the added code comment, a reference to .exit.text is ok
for drivers registered via module_platform_driver_probe(). Make this
explicit to prevent a section mismatch warning.
Signed-off-by: default avatarUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: default avatarHelge Deller <deller@gmx.de>
parent cca202a5
......@@ -3768,7 +3768,13 @@ static int __exit amifb_remove(struct platform_device *pdev)
return 0;
}
static struct platform_driver amifb_driver = {
/*
* amifb_remove() lives in .exit.text. For drivers registered via
* module_platform_driver_probe() this ok because they cannot get unboud at
* runtime. The driver needs to be marked with __refdata, otherwise modpost
* triggers a section mismatch warning.
*/
static struct platform_driver amifb_driver __refdata = {
.remove = __exit_p(amifb_remove),
.driver = {
.name = "amiga-video",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment