lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 24 Oct 2012 16:36:13 +0530
From:	Vinod Koul <vkoul@...radead.org>
To:	Wei Yongjun <weiyj.lk@...il.com>
Cc:	vinod.koul@...el.com, djbw@...com, yongjun_wei@...ndmicro.com.cn,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] pch_dma: use module_pci_driver to simplify the code

On Wed, 2012-10-10 at 21:04 +0800, Wei Yongjun wrote:
> From: Wei Yongjun <yongjun_wei@...ndmicro.com.cn>
> 
> Use the module_pci_driver() macro to make the code simpler
> by eliminating module_init and module_exit calls.
> 
> dpatch engine is used to auto generate this patch.
> (https://github.com/weiyj/dpatch)
> 
> Signed-off-by: Wei Yongjun <yongjun_wei@...ndmicro.com.cn>
> ---
>  drivers/dma/pch_dma.c | 13 +------------
>  1 file changed, 1 insertion(+), 12 deletions(-)
> 
> diff --git a/drivers/dma/pch_dma.c b/drivers/dma/pch_dma.c
> index 987ab5c..b405916 100644
> --- a/drivers/dma/pch_dma.c
> +++ b/drivers/dma/pch_dma.c
> @@ -1029,18 +1029,7 @@ static struct pci_driver pch_dma_driver = {
>  #endif
>  };
>  
> -static int __init pch_dma_init(void)
> -{
> -	return pci_register_driver(&pch_dma_driver);
> -}
> -
> -static void __exit pch_dma_exit(void)
> -{
> -	pci_unregister_driver(&pch_dma_driver);
> -}
> -
> -module_init(pch_dma_init);
> -module_exit(pch_dma_exit);
> +module_pci_driver(pch_dma_driver);
>  
>  MODULE_DESCRIPTION("Intel EG20T PCH / LAPIS Semicon ML7213/ML7223/ML7831 IOH "
>  		   "DMA controller driver");
> 
> 
Applied thanks

-- 
Vinod Koul
Intel Corp.

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ