linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Daniel Lezcano <daniel.lezcano@linaro.org>
To: Freddy Hsin <freddy.hsin@mediatek.com>,
	linux-mediatek@lists.infradead.or,
	linux-arm-kernel@lists.infradead.org,
	"Ahmed S. Darwish" <a.darwish@linutronix.de>,
	Paul Cercueil <paul@crapouillou.net>,
	"Ben Dooks (Codethink)" <ben.dooks@codethink.co.uk>,
	Matthias Brugger <matthias.bgg@gmail.com>,
	Thomas Gleixner <tglx@linutronix.de>
Cc: Saravana Kannan <saravanak@google.com>,
	linux-kernel@vger.kernel.org, chang-an.chen@mediatek.com,
	Baolin Wang <baolin.wang7@gmail.com>,
	wsd_upstream@mediatek.com, kuohong.wang@mediatek.com,
	stanley.chu@mediatek.com
Subject: Re: [PATCH v1 1/2] kernel: time: export sched_clock_register function
Date: Wed, 29 Jul 2020 16:09:44 +0200	[thread overview]
Message-ID: <6535cd1b-327c-db4b-e6d8-9a29a5847e17@linaro.org> (raw)
In-Reply-To: <1595931377-21627-2-git-send-email-freddy.hsin@mediatek.com>


Hi Freddy,

On 28/07/2020 12:16, Freddy Hsin wrote:
> export sched_clock_register function, because the Mediatek timer
> loadable module depends on this function

That is not a sufficient reason to ask for exporting a symbol from the
core framework.

It is the second patch asking for exporting the symbols because of GKI.

If we want to do this move, it is important to understand what that will
imply by doing the changes as a whole:

 - Identify the routines which will need EXPORT_SYMBOL_GPL

 - Show it is safe to use them with what that implies as module. eg.
What about cpuidle drivers using the broadcast timers?

 - As pointed by Thomas, TIMER_OF_DECLARE must be adapted to handle the
module cases

The conversion to all modules is not as straightforward as just
exporting a symbol and the changes must be provided with the proof the
impact has been studied and anticipated.


> Signed-off-by: Freddy Hsin <freddy.hsin@mediatek.com>
> ---
>  kernel/time/sched_clock.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/kernel/time/sched_clock.c b/kernel/time/sched_clock.c
> index fa3f800..e1d5afe 100644
> --- a/kernel/time/sched_clock.c
> +++ b/kernel/time/sched_clock.c
> @@ -239,6 +239,7 @@ static enum hrtimer_restart sched_clock_poll(struct hrtimer *hrt)
>  
>  	pr_debug("Registered %pS as sched_clock source\n", read);
>  }
> +EXPORT_SYMBOL(sched_clock_register);



-- 
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs

Follow Linaro:  <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog

  parent reply	other threads:[~2020-07-29 14:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-28 10:16 [PATCH v1] Porting Mediatek timer driver to kernel module Freddy Hsin
2020-07-28 10:16 ` [PATCH v1 1/2] kernel: time: export sched_clock_register function Freddy Hsin
2020-07-29 12:47   ` Thomas Gleixner
2020-07-29 14:09   ` Daniel Lezcano [this message]
2020-07-28 10:16 ` [PATCH v1 2/2] timer: mt6873: porting Mediatek timer driver to loadable module Freddy Hsin
2020-07-29 13:02   ` Thomas Gleixner
2020-07-29 18:42     ` Saravana Kannan

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=6535cd1b-327c-db4b-e6d8-9a29a5847e17@linaro.org \
    --to=daniel.lezcano@linaro.org \
    --cc=a.darwish@linutronix.de \
    --cc=baolin.wang7@gmail.com \
    --cc=ben.dooks@codethink.co.uk \
    --cc=chang-an.chen@mediatek.com \
    --cc=freddy.hsin@mediatek.com \
    --cc=kuohong.wang@mediatek.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.or \
    --cc=matthias.bgg@gmail.com \
    --cc=paul@crapouillou.net \
    --cc=saravanak@google.com \
    --cc=stanley.chu@mediatek.com \
    --cc=tglx@linutronix.de \
    --cc=wsd_upstream@mediatek.com \
    /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).