From: Hugo Lefeuvre <hle@owl.eu.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: devel@driverdev.osuosl.org,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-kernel@vger.kernel.org, kernelnewbies@kernelnewbies.org
Subject: Re: [PATCH] staging: pi433: add mutex fixing race condition when accessing tx_cfg
Date: Tue, 12 Jun 2018 20:36:17 -0400 [thread overview]
Message-ID: <20180613003617.GA2265@hle-laptop.local> (raw)
In-Reply-To: <20180612110230.dvqmcyisdwaynixj@mwanda>
[-- Attachment #1: Type: text/plain, Size: 519 bytes --]
> We read the data from the user here and then we write it to the fifo
> in pi433_write(). We should be using the device->tx_fifo_lock so that
> we don't copy over the data at the same time we're writing it to the
> fifo.
Oh right, that makes the bug even worse.
In this case we don't even need to introduce a new lock, using
device->tx_fifo_lock should be fine. I'll update the patch.
--
Hugo Lefeuvre (hle) | www.owl.eu.com
4096/ 9C4F C8BF A4B0 8FC5 48EB 56B8 1962 765B B9A8 BACA
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
prev parent reply other threads:[~2018-06-13 0:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-12 1:12 Hugo Lefeuvre
2018-06-12 11:02 ` Dan Carpenter
2018-06-13 0:36 ` Hugo Lefeuvre [this message]
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=20180613003617.GA2265@hle-laptop.local \
--to=hle@owl.eu.com \
--cc=dan.carpenter@oracle.com \
--cc=devel@driverdev.osuosl.org \
--cc=gregkh@linuxfoundation.org \
--cc=kernelnewbies@kernelnewbies.org \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®