mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Yu Liao <liaoyu15@huawei.com>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"liwei (GF)" <liwei391@huawei.com>
Subject: Re: [PATCH] tick/broadcast-hrtimer: Prevent the timer device on broadcast duty CPU from being disabled
Date: Thu, 11 Jul 2024 21:10:28 +0800	[thread overview]
Message-ID: <d4edde3f-0047-2ade-0b65-d59dbeb6fca6@huawei.com> (raw)
In-Reply-To: <87y1cek0av.ffs@tglx>

Hi Thomas,

Sorry it took so long to reply.

On 2024/1/25 3:18, Thomas Gleixner wrote:
>> +	if (tick_check_broadcast_expired() && expires >= next_event)
>> +		tick_program_event(next_event, 1);
> 
> I'm not really enthused about another conditional here and that
> condition is more than obscure.
> 
> The problem is that the local clockevent might be shut down, right?
> 
> So checking for that state is the right thing to do and the proper place
> is in hotplug_cpu__broadcast_tick_pull(), no?

We can't check the clockevent state, because when exiting broadcast mode the
state is switched to oneshot, but the clockevent is still shutdown, due to
some device (e.g. arm arch timers) do not implement set_state_oneshot handler,
the switch operation only change the state value.

Yeah, hotplug_cpu__broadcast_tick_pull() is the proper place to do the check.
Thank you for your advice, I have modified it and sent you the v2 patch.

Best regards,
Yu


      reply	other threads:[~2024-07-11 13:10 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-18  2:58 Yu Liao
2024-01-12  7:40 ` Yu Liao
2024-01-12 15:34   ` Thomas Gleixner
2024-01-24 19:18 ` Thomas Gleixner
2024-07-11 13:10   ` Yu Liao [this message]

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=d4edde3f-0047-2ade-0b65-d59dbeb6fca6@huawei.com \
    --to=liaoyu15@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=liwei391@huawei.com \
    --cc=tglx@linutronix.de \
    /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

all inboxes | Powered by JetHome®