summaryrefslogtreecommitdiff
path: root/drivers/net/tun.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2019-10-19 22:51:25 -0700
committerDavid S. Miller <davem@davemloft.net>2019-10-20 10:43:00 -0700
commit2f184393e0c2d409c62262f57f2a57efdf9370b8 (patch)
tree25b96db2550014d7f888605abfabb67a7f40a5d3 /drivers/net/tun.c
parentebcd670d05d54ff8d17a1a51bba1ec1e4069d949 (diff)
parent531e93d11470aa2e14e6a3febef50d9bc7bab7a1 (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Several cases of overlapping changes which were for the most part trivially resolvable. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tun.c')
-rw-r--r--drivers/net/tun.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index 0413d182d782..dab6cccfeb52 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -526,8 +526,8 @@ static void tun_flow_update(struct tun_struct *tun, u32 rxhash,
e = tun_flow_find(head, rxhash);
if (likely(e)) {
/* TODO: keep queueing to old queue until it's empty? */
- if (e->queue_index != queue_index)
- e->queue_index = queue_index;
+ if (READ_ONCE(e->queue_index) != queue_index)
+ WRITE_ONCE(e->queue_index, queue_index);
if (e->updated != jiffies)
e->updated = jiffies;
sock_rps_record_flow_hash(e->rps_rxhash);