From: Marc Zyngier <marc.zyngier@arm.com>
To: Thomas Gleixner <tglx@linutronix.de>,
kernel test robot <fengguang.wu@intel.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Tomasz Nowicki <tn@semihalf.com>,
Christoffer Dall <christoffer.dall@linaro.org>,
Sasha Levin <alexander.levin@verizon.com>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>,
Johannes Berg <johannes.berg@intel.com>
Subject: Re: [linux-stable] 4fc2942b6e kernel BUG at kernel/time/hrtimer.c:109!
Date: Fri, 17 Feb 2017 10:09:06 +0000 [thread overview]
Message-ID: <0f58a1d0-a2e6-9430-7883-68e986ccb4c0@arm.com> (raw)
In-Reply-To: <alpine.DEB.2.20.1702171014430.3536@nanos>
On 17/02/17 09:28, Thomas Gleixner wrote:
> On Fri, 17 Feb 2017, kernel test robot wrote:
>
>> Hi Marc,
>>
>> We find this oops in linux-4.4.y. The gcc-6 compiled mainline kernel is fine.
The last bit is worrying, as mainline has the exact same bug. Has it
been tested the same way?
>>
>> commit 4fc2942b6e2de2efc8a9d3784d4b0d3543149613
>> hrtimer: Catch illegal clockids
>
> And that commit is doing what the subject line says. Catch illegal usage.
>
>> [ 38.101342] Call Trace:
>> [ 38.101342] Call Trace:
>> [ 38.102045] [<ffffffff8109aee1>] tasklet_hrtimer_init+0x16/0x52
>> [ 38.102045] [<ffffffff8109aee1>] tasklet_hrtimer_init+0x16/0x52
>> [ 38.103698] [<ffffffff81c767c7>] mac80211_hwsim_new_radio+0x766/0x84d
>
> The real bug is in this code:
>
> drivers/net/wireless/mac80211_hwsim.c
>
> mac80211_hwsim_new_radio()
>
> tasklet_hrtimer_init(&data->beacon_timer,
> mac80211_hwsim_beacon,
> CLOCK_MONOTONIC_RAW, HRTIMER_MODE_ABS);
>
> CLOCK_MONOTONIC_RAW is not a supported clockid for hrtimers. Sigh.
>
> Fix below.
>
> Thanks,
>
> tglx
>
> 8<------------------
>
> diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
> index 0cd95120bc78..da363ec91a1c 100644
> --- a/drivers/net/wireless/mac80211_hwsim.c
> +++ b/drivers/net/wireless/mac80211_hwsim.c
> @@ -2535,9 +2535,8 @@ static int mac80211_hwsim_new_radio(struct genl_info *info,
> data->debugfs,
> data, &hwsim_simulate_radar);
>
> - tasklet_hrtimer_init(&data->beacon_timer,
> - mac80211_hwsim_beacon,
> - CLOCK_MONOTONIC_RAW, HRTIMER_MODE_ABS);
> + tasklet_hrtimer_init(&data->beacon_timer, mac80211_hwsim_beacon,
> + CLOCK_MONOTONIC, HRTIMER_MODE_ABS);
>
> spin_lock_bh(&hwsim_radio_lock);
> list_add_tail(&data->list, &hwsim_radios);
>
Acked-by: Marc Zyngier <marc.zyngier@arm.com>
M.
--
Jazz is not dead. It just smells funny...
next prev parent reply other threads:[~2017-02-17 10:09 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-17 5:26 [linux-stable] 4fc2942b6e kernel BUG at kernel/time/hrtimer.c:109! kernel test robot
2017-02-17 9:28 ` Thomas Gleixner
2017-02-17 10:09 ` Marc Zyngier [this message]
2017-02-17 10:16 ` Thomas Gleixner
2017-02-17 10:31 ` Marc Zyngier
2017-02-17 12:49 ` Fengguang Wu
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=0f58a1d0-a2e6-9430-7883-68e986ccb4c0@arm.com \
--to=marc.zyngier@arm.com \
--cc=alexander.levin@verizon.com \
--cc=christoffer.dall@linaro.org \
--cc=fengguang.wu@intel.com \
--cc=gregkh@linuxfoundation.org \
--cc=johannes.berg@intel.com \
--cc=linux-wireless@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=tn@semihalf.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).