Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1487277

Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!)

From Michael Ellerman <mpe@ellerman.id.au>
Newsgroups linux.kernel
Subject Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!)
Date 2016-09-20 14:10 +0200
Message-ID <sjs26-2Lm-29@gated-at.bofh.it> (permalink)
References (1 earlier) <shXtn-2IP-1@gated-at.bofh.it> <shZlv-3Xl-21@gated-at.bofh.it> <si0Ui-4PI-1@gated-at.bofh.it> <sjhT3-4IM-9@gated-at.bofh.it> <sjhT3-4IM-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Andrew Morton <akpm@linux-foundation.org> writes:
> On Tue, 20 Sep 2016 11:10:35 +1000 Michael Ellerman <mpe@ellerman.id.au> wrote:
>> Jan Kara <jack@suse.cz> writes:
>> >
>> > Right, that was the problem. spin_is_locked() without CONFIG_SPINLOCK_DEBUG
>> > returns always 0.
>> 
>> Can we get this fixed soon please? It's breaking all my CI runs.
>
> It should be fixed in next -next.

Great thanks.

I did search LKML to see if Jan had sent a fix but I guess I missed it.

> diff -puN fs/notify/fanotify/fanotify_user.c~fsnotify-convert-notification_mutex-to-a-spinlock-fix fs/notify/fanotify/fanotify_user.c
> --- a/fs/notify/fanotify/fanotify_user.c~fsnotify-convert-notification_mutex-to-a-spinlock-fix
> +++ a/fs/notify/fanotify/fanotify_user.c
> @@ -54,7 +54,8 @@ struct kmem_cache *fanotify_perm_event_c
>  static struct fsnotify_event *get_one_event(struct fsnotify_group *group,
>  					    size_t count)
>  {
> -	BUG_ON(!spin_is_locked(&group->notification_lock));
> +	BUG_ON(IS_ENABLED(CONFIG_SMP) &&
> +	       !spin_is_locked(&group->notification_lock));
  
I thought lockdep_assert_held() was preferred for checks like this that
are purely sanity checking, ie. not part of the algorithm.

cheers

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Guenter Roeck <linux@roeck-us.net> - 2016-09-16 04:30 +0200
  Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Jan Kara <jack@suse.cz> - 2016-09-16 11:20 +0200
    Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Guenter Roeck <linux@roeck-us.net> - 2016-09-16 13:20 +0200
      Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Jan Kara <jack@suse.cz> - 2016-09-16 15:00 +0200
        Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Andrew Morton <akpm@linux-foundation.org> - 2016-09-20 03:20 +0200
          Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Michael Ellerman <mpe@ellerman.id.au> - 2016-09-20 14:10 +0200
            Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Jan Kara <jack@suse.cz> - 2016-09-21 11:20 +0200
        Re: Crashes in next-20160915 (BUG at fs/notify/notification.c:66!) Michael Ellerman <mpe@ellerman.id.au> - 2016-09-20 03:20 +0200

csiph-web