Re: [PATCH] pcmcia: Add __init/__exit annotations to module init/exit funcs
From: Dominik Brodowski
Date: Fri Sep 23 2022 - 02:22:04 EST
Am Thu, Sep 22, 2022 at 07:23:23PM +0800 schrieb Xiu Jianfeng:
> Add missing __init/__exit annotations to module init/exit funcs.
>
> Signed-off-by: Xiu Jianfeng <xiujianfeng@xxxxxxxxxx>
Applied to the pcmcia tree, sans the patch to vrc4171_card.c which is
already on its way out of the kernel.
Thanks,
Dominik
> ---
> drivers/pcmcia/i82092.c | 4 ++--
> drivers/pcmcia/vrc4171_card.c | 4 ++--
> 2 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/pcmcia/i82092.c b/drivers/pcmcia/i82092.c
> index 192c9049d654..a335748bdef5 100644
> --- a/drivers/pcmcia/i82092.c
> +++ b/drivers/pcmcia/i82092.c
> @@ -661,12 +661,12 @@ static int i82092aa_set_mem_map(struct pcmcia_socket *socket,
> return 0;
> }
>
> -static int i82092aa_module_init(void)
> +static int __init i82092aa_module_init(void)
> {
> return pci_register_driver(&i82092aa_pci_driver);
> }
>
> -static void i82092aa_module_exit(void)
> +static void __exit i82092aa_module_exit(void)
> {
> pci_unregister_driver(&i82092aa_pci_driver);
> if (sockets[0].io_base > 0)
> diff --git a/drivers/pcmcia/vrc4171_card.c b/drivers/pcmcia/vrc4171_card.c
> index 177d77892144..ebaeb582539a 100644
> --- a/drivers/pcmcia/vrc4171_card.c
> +++ b/drivers/pcmcia/vrc4171_card.c
> @@ -699,7 +699,7 @@ static struct platform_driver vrc4171_card_driver = {
> },
> };
>
> -static int vrc4171_card_init(void)
> +static int __init vrc4171_card_init(void)
> {
> int retval;
>
> @@ -733,7 +733,7 @@ static int vrc4171_card_init(void)
> return 0;
> }
>
> -static void vrc4171_card_exit(void)
> +static void __exit vrc4171_card_exit(void)
> {
> free_irq(vrc4171_irq, vrc4171_sockets);
> vrc4171_remove_sockets();
> --
> 2.17.1
>