[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200723.151158.2190104866687627036.davem@davemloft.net>
Date: Thu, 23 Jul 2020 15:11:58 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: madhuparnabhowmik10@...il.com
Cc: isdn@...ux-pingi.de, arnd@...db.de, gregkh@...uxfoundation.org,
edumazet@...gle.com, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, andrianov@...ras.ru,
ldv-project@...uxtesting.org
Subject: Re: [PATCH] drivers: isdn: capi: Fix data-race bug
From: madhuparnabhowmik10@...il.com
Date: Wed, 22 Jul 2020 22:53:29 +0530
> From: Madhuparna Bhowmik <madhuparnabhowmik10@...il.com>
>
> In capi_init(), after register_chrdev() the file operation callbacks
> can be called. However capinc_tty_init() is called later.
> Since capiminors and capinc_tty_driver are initialized in
> capinc_tty_init(), their initialization can race with their usage
> in various callbacks like in capi_release().
>
> Therefore, call capinc_tty_init() before register_chrdev to avoid
> such race conditions.
>
> Found by Linux Driver Verification project (linuxtesting.org).
>
> Signed-off-by: Madhuparna Bhowmik <madhuparnabhowmik10@...il.com>
I agree with Arnd that this just exchanges one set of problems for
another.
Powered by blists - more mailing lists