* [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver
@ 2023-01-12 13:54 Yang Yingliang
2023-01-13 21:25 ` Péter Ujfalusi
2023-01-19 14:29 ` Mark Brown
0 siblings, 2 replies; 6+ messages in thread
From: Yang Yingliang @ 2023-01-12 13:54 UTC (permalink / raw)
To: alsa-devel; +Cc: tiwai, lgirdwood, broonie, yangyingliang, peter.ujfalusi
The init/exit() of driver only calls platform_driver_register/unregister,
it can be simpilfied with module_platform_driver.
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
sound/soc/ti/davinci-evm.c | 13 +------------
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git a/sound/soc/ti/davinci-evm.c b/sound/soc/ti/davinci-evm.c
index 983d69b951b0..544cb3da50eb 100644
--- a/sound/soc/ti/davinci-evm.c
+++ b/sound/soc/ti/davinci-evm.c
@@ -257,18 +257,7 @@ static struct platform_driver davinci_evm_driver = {
},
};
-static int __init evm_init(void)
-{
- return platform_driver_register(&davinci_evm_driver);
-}
-
-static void __exit evm_exit(void)
-{
- platform_driver_unregister(&davinci_evm_driver);
-}
-
-module_init(evm_init);
-module_exit(evm_exit);
+module_platform_driver(davinci_evm_driver);
MODULE_AUTHOR("Vladimir Barinov");
MODULE_DESCRIPTION("TI DAVINCI EVM ASoC driver");
--
2.25.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver
2023-01-12 13:54 [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver Yang Yingliang
@ 2023-01-13 21:25 ` Péter Ujfalusi
2023-01-19 14:29 ` Mark Brown
1 sibling, 0 replies; 6+ messages in thread
From: Péter Ujfalusi @ 2023-01-13 21:25 UTC (permalink / raw)
To: Yang Yingliang, alsa-devel; +Cc: tiwai, broonie, lgirdwood
On 1/12/23 15:54, Yang Yingliang wrote:
> The init/exit() of driver only calls platform_driver_register/unregister,
> it can be simpilfied with module_platform_driver.
Acked-by: Peter Ujfalusi <peter.ujfalusi@gmail.com>
> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
> ---
> sound/soc/ti/davinci-evm.c | 13 +------------
> 1 file changed, 1 insertion(+), 12 deletions(-)
>
> diff --git a/sound/soc/ti/davinci-evm.c b/sound/soc/ti/davinci-evm.c
> index 983d69b951b0..544cb3da50eb 100644
> --- a/sound/soc/ti/davinci-evm.c
> +++ b/sound/soc/ti/davinci-evm.c
> @@ -257,18 +257,7 @@ static struct platform_driver davinci_evm_driver = {
> },
> };
>
> -static int __init evm_init(void)
> -{
> - return platform_driver_register(&davinci_evm_driver);
> -}
> -
> -static void __exit evm_exit(void)
> -{
> - platform_driver_unregister(&davinci_evm_driver);
> -}
> -
> -module_init(evm_init);
> -module_exit(evm_exit);
> +module_platform_driver(davinci_evm_driver);
>
> MODULE_AUTHOR("Vladimir Barinov");
> MODULE_DESCRIPTION("TI DAVINCI EVM ASoC driver");
--
Péter
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver
2023-01-12 13:54 [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver Yang Yingliang
2023-01-13 21:25 ` Péter Ujfalusi
@ 2023-01-19 14:29 ` Mark Brown
2023-01-30 2:22 ` Yang Yingliang
1 sibling, 1 reply; 6+ messages in thread
From: Mark Brown @ 2023-01-19 14:29 UTC (permalink / raw)
To: Yang Yingliang; +Cc: alsa-devel, tiwai, peter.ujfalusi, lgirdwood
[-- Attachment #1: Type: text/plain, Size: 259 bytes --]
On Thu, Jan 12, 2023 at 09:54:57PM +0800, Yang Yingliang wrote:
> The init/exit() of driver only calls platform_driver_register/unregister,
> it can be simpilfied with module_platform_driver.
This doesn't apply against current code, please check and resend.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver
2023-01-19 14:29 ` Mark Brown
@ 2023-01-30 2:22 ` Yang Yingliang
0 siblings, 0 replies; 6+ messages in thread
From: Yang Yingliang @ 2023-01-30 2:22 UTC (permalink / raw)
To: Mark Brown; +Cc: alsa-devel, tiwai, lgirdwood, yangyingliang, peter.ujfalusi
On 2023/1/19 22:29, Mark Brown wrote:
> On Thu, Jan 12, 2023 at 09:54:57PM +0800, Yang Yingliang wrote:
>> The init/exit() of driver only calls platform_driver_register/unregister,
>> it can be simpilfied with module_platform_driver.
> This doesn't apply against current code, please check and resend.
Because commit efe81e9a9273 ("ASoC: remove unused davinci support") is
not merged yet,
I will resend it after it's merged.
Thanks,
Yang
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver
@ 2023-08-04 8:54 Yang Yingliang
2023-08-04 16:57 ` Mark Brown
0 siblings, 1 reply; 6+ messages in thread
From: Yang Yingliang @ 2023-08-04 8:54 UTC (permalink / raw)
To: alsa-devel; +Cc: lgirdwood, broonie, perex, tiwai, yangyingliang
The init/exit() of driver only calls platform_driver_register/unregister,
it can be simpilfied with module_platform_driver.
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
sound/soc/ti/davinci-evm.c | 13 +------------
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git a/sound/soc/ti/davinci-evm.c b/sound/soc/ti/davinci-evm.c
index 983d69b951b0..544cb3da50eb 100644
--- a/sound/soc/ti/davinci-evm.c
+++ b/sound/soc/ti/davinci-evm.c
@@ -257,18 +257,7 @@ static struct platform_driver davinci_evm_driver = {
},
};
-static int __init evm_init(void)
-{
- return platform_driver_register(&davinci_evm_driver);
-}
-
-static void __exit evm_exit(void)
-{
- platform_driver_unregister(&davinci_evm_driver);
-}
-
-module_init(evm_init);
-module_exit(evm_exit);
+module_platform_driver(davinci_evm_driver);
MODULE_AUTHOR("Vladimir Barinov");
MODULE_DESCRIPTION("TI DAVINCI EVM ASoC driver");
--
2.25.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver
2023-08-04 8:54 Yang Yingliang
@ 2023-08-04 16:57 ` Mark Brown
0 siblings, 0 replies; 6+ messages in thread
From: Mark Brown @ 2023-08-04 16:57 UTC (permalink / raw)
To: alsa-devel, Yang Yingliang; +Cc: lgirdwood, perex, tiwai
On Fri, 04 Aug 2023 16:54:02 +0800, Yang Yingliang wrote:
> The init/exit() of driver only calls platform_driver_register/unregister,
> it can be simpilfied with module_platform_driver.
>
>
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[1/1] ASoC: ti: davinci-evm: simplify the code with module_platform_driver
commit: 9606cda3501ae5d1a865d839ee5dbae9552a7b37
All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying
to this mail.
Thanks,
Mark
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2023-08-04 16:59 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-01-12 13:54 [PATCH -next] ASoC: ti: davinci-evm: simplify the code with module_platform_driver Yang Yingliang
2023-01-13 21:25 ` Péter Ujfalusi
2023-01-19 14:29 ` Mark Brown
2023-01-30 2:22 ` Yang Yingliang
-- strict thread matches above, loose matches on Subject: below --
2023-08-04 8:54 Yang Yingliang
2023-08-04 16:57 ` Mark Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox