diff options
Diffstat (limited to 'drivers/tty/amiserial.c')
-rw-r--r-- | drivers/tty/amiserial.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/tty/amiserial.c b/drivers/tty/amiserial.c index e27360652d..8c964da75f 100644 --- a/drivers/tty/amiserial.c +++ b/drivers/tty/amiserial.c @@ -1578,7 +1578,13 @@ static void __exit amiga_serial_remove(struct platform_device *pdev) free_irq(IRQ_AMIGA_RBF, state); } -static struct platform_driver amiga_serial_driver = { +/* + * amiga_serial_remove() lives in .exit.text. For drivers registered via + * module_platform_driver_probe() this is ok because they cannot get unbound at + * runtime. So mark the driver struct with __refdata to prevent modpost + * triggering a section mismatch warning. + */ +static struct platform_driver amiga_serial_driver __refdata = { .remove_new = __exit_p(amiga_serial_remove), .driver = { .name = "amiga-serial", |