[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CANpmjNNaBqV2jPcM9p_dB4KEUJDTcRd+V_LyD=tejSRG4DBAeg@mail.gmail.com>
Date: Wed, 18 Mar 2020 13:03:48 +0100
From: Marco Elver <elver@...gle.com>
To: Daniel Vetter <daniel@...ll.ch>
Cc: Qiujun Huang <hqjagain@...il.com>,
Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>,
Maxime Ripard <mripard@...nel.org>,
Dave Airlie <airlied@...ux.ie>,
dri-devel <dri-devel@...ts.freedesktop.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH RESEND] drm/lease: fix potential race in fill_object_idr
On Wed, 18 Mar 2020 at 08:34, Daniel Vetter <daniel@...ll.ch> wrote:
>
> On Tue, Mar 17, 2020 at 11:33 PM Qiujun Huang <hqjagain@...il.com> wrote:
> >
> > On Wed, Mar 18, 2020 at 1:02 AM Daniel Vetter <daniel@...ll.ch> wrote:
> > >
> > > On Mon, Mar 16, 2020 at 03:18:23PM +0800, Qiujun Huang wrote:
> > > > We should hold idr_mutex for idr_alloc.
> > > >
> > > > Signed-off-by: Qiujun Huang <hqjagain@...il.com>
> > >
> > > I've not seen the first version of this anywhere in my inbox, not sure
> > > where that got lost.
> > >
> > > Anyway, this seems like a false positive - I'm assuming this was caught
> > > with KCSAN. The commit message really should mention that.
> > >
> > > fill_object_idr creates the idr, which yes is only access later on under
> > > the idr_mutex. But here it's not yet visible to any other thread, and
> > > hence lockless access is safe and correct.
> >
> > Agree that.
>
> Do you know what the recommended annotation for kcsan false positives
> like this should be? Adding kcsan author Marco.
AFAIK KCSAN has not reported this, so I think there is nothing to do here.
Thanks,
-- Marco
Powered by blists - more mailing lists