lkml.org 
[lkml]   [2017]   [Oct]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: x86/mce: suspicious RCU usage in 4.13.4
Date
"Luck, Tony" <tony.luck@intel.com> writes:

>> for (;;) {
>> entry = mce_log_get_idx_check(mcelog.next);
>
> Can't this get even simpler? Do we need the loop? The mutex
> will now protect us while we check to see if there is a slot
> to stash this new entry. Also just say:

IMHO the warning is just bogus. There's nothing here that actually
uses RCU. I would just remove it.

>> if (entry >= MCE_LOG_LEN) {
>> - set_bit(MCE_OVERFLOW,
>> - (unsigned long *)&mcelog.flags);
>> + set_bit(MCE_OVERFLOW, (unsigned long *)&mcelog.flags);
>
> Need to mutex_unlock(&mce_chrdev_read_mutex); here.

And yes that too.

-Andi

\
 
 \ /
  Last update: 2017-10-10 22:15    [W:0.041 / U:0.236 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site