From: Kalle Valo <kvalo@codeaurora.org>
To: Brian Norris <briannorris@chromium.org>
Cc: Govind Singh <govinds@codeaurora.org>,
linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org,
ath10k@lists.infradead.org
Subject: Re: [PATCH] ath10k: snoc: use module_platform_driver() macro
Date: Tue, 12 Jun 2018 14:24:51 +0300 [thread overview]
Message-ID: <87sh5sckn0.fsf@kamboji.qca.qualcomm.com> (raw)
In-Reply-To: <20180611193540.190255-1-briannorris@chromium.org> (Brian Norris's message of "Mon, 11 Jun 2018 12:35:40 -0700")
Brian Norris <briannorris@chromium.org> writes:
> ath10k_snoc_init()/ath10k_snoc_exit() don't add much value;
> module_platform_driver() can remove the boilerplate.
>
> Signed-off-by: Brian Norris <briannorris@chromium.org>
> ---
> drivers/net/wireless/ath/ath10k/snoc.c | 20 +-------------------
> 1 file changed, 1 insertion(+), 19 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath10k/snoc.c b/drivers/net/wireless/ath/ath10k/snoc.c
> index a3a7042fe13a..ee74e0060504 100644
> --- a/drivers/net/wireless/ath/ath10k/snoc.c
> +++ b/drivers/net/wireless/ath/ath10k/snoc.c
> @@ -1388,25 +1388,7 @@ static struct platform_driver ath10k_snoc_driver = {
> .of_match_table = ath10k_snoc_dt_match,
> },
> };
> -
> -static int __init ath10k_snoc_init(void)
> -{
> - int ret;
> -
> - ret = platform_driver_register(&ath10k_snoc_driver);
> - if (ret)
> - pr_err("failed to register ath10k snoc driver: %d\n",
> - ret);
> -
> - return ret;
> -}
> -module_init(ath10k_snoc_init);
> -
> -static void __exit ath10k_snoc_exit(void)
> -{
> - platform_driver_unregister(&ath10k_snoc_driver);
> -}
> -module_exit(ath10k_snoc_exit);
> +module_platform_driver(ath10k_snoc_driver);
Yeah, makes sense. And I also checked that this shouldn't conflict with
Govind's qmi patch:
https://patchwork.kernel.org/patch/10448183/
--
Kalle Valo
next prev parent reply other threads:[~2018-06-12 11:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-11 19:35 [PATCH] ath10k: snoc: use module_platform_driver() macro Brian Norris
2018-06-12 11:24 ` Kalle Valo [this message]
2018-06-14 15:14 ` Kalle Valo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87sh5sckn0.fsf@kamboji.qca.qualcomm.com \
--to=kvalo@codeaurora.org \
--cc=ath10k@lists.infradead.org \
--cc=briannorris@chromium.org \
--cc=govinds@codeaurora.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).