Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp1332902imm; Wed, 13 Jun 2018 18:11:21 -0700 (PDT) X-Google-Smtp-Source: ADUXVKLgn2glbKdXcLFoNFU5CpmOAKvdE3nl9Ams1Obqwpu0IuinPt9f10FRBuqwlwYqNTrgFLJz X-Received: by 2002:a63:7b07:: with SMTP id w7-v6mr394181pgc.199.1528938681772; Wed, 13 Jun 2018 18:11:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1528938681; cv=none; d=google.com; s=arc-20160816; b=ovu4LafAZsZZbhVaP4k3p7TdhdtWfhynVQ1cVJm1ERAb3PLLdMILjyxnOGwz6vUlp0 kpQii6ZQPtB074FT7a4aoQKKuCcsTyeSKRYRVNwmd6W9xPsr4Li+gAi++rZuI0i9uVR6 ZIVPnT0R00+w8kY0pEL6qopJXjIWWrhhG5GGj/1A2n19ajkMzUfh87XCjfTTpO4ny9WY QWu4k8nvyw/4nS+iPDFzfI4c/+bXE5CMBDXP+JOjDAMdUH+r1BqGQofBJsTgGUbm51F6 Jl3sAsY0xrBtPv/jNaiL44ENGqRRitFDdKTLSnZuMrnVIUflfAxwhrdTmq2XVZd4dW/4 EQlQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=ymx1dgSnv75k3HaLOHi+hzygJRnmAdpxDoGHy48bbn8=; b=odXHpJhrIp0M6BMirVC1kfVHmW6OowavQAsBdR47LzCSikNkk7UZ656hfP+rYcnqJb uLry1+iT2i0v7mx97uXLi96N16IAuPR8nIxoy8flwwpJQX47SvXh+Ujc+3n4aKMymJMP i1bbDTBNt0/kxlUYKFp2n4SUhR8AUAVGUFulmN5TcpkKQKqPgirNfwJGwQPeYL6RlHyt VNwggeNEMoNxuIs/s8PEfnc5NNbwjmy/uN5WnLK2I3OmBn8tE2Jy6llu/FzOD0KR3cQy urkNxWBMNCgmrv6TFsK+cdFPDmQkNM1Q0y/2puxdQTjvM0sWSOogTCn22Pm8iCFTg5HY XwzA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y20-v6si3785801pfm.186.2018.06.13.18.11.07; Wed, 13 Jun 2018 18:11:21 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935885AbeFNBKn (ORCPT + 99 others); Wed, 13 Jun 2018 21:10:43 -0400 Received: from relay8-d.mail.gandi.net ([217.70.183.201]:40579 "EHLO relay8-d.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S935513AbeFNBKm (ORCPT ); Wed, 13 Jun 2018 21:10:42 -0400 X-Originating-IP: 70.80.172.8 Received: from localhost (modemcable008.172-80-70.mc.videotron.ca [70.80.172.8]) (Authenticated sender: hle@owl.eu.com) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id 1D0D51BF206; Thu, 14 Jun 2018 01:10:47 +0000 (UTC) Date: Wed, 13 Jun 2018 21:10:37 -0400 From: Hugo Lefeuvre To: Dan Carpenter Cc: devel@driverdev.osuosl.org, Greg Kroah-Hartman , Marcus Wolf , linux-kernel@vger.kernel.org, kernelnewbies@kernelnewbies.org Subject: Re: [PATCH v2] staging: pi433: fix race condition in pi433_ioctl Message-ID: <20180614011037.GA21075@hle-laptop.local> References: <20180613014741.GC2265@hle-laptop.local> <20180613091649.r3bck3wjma6tmjet@mwanda> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="Nq2Wo0NMKNjxTN9z" Content-Disposition: inline In-Reply-To: <20180613091649.r3bck3wjma6tmjet@mwanda> User-Agent: Mutt/1.10.0 (2018-05-17) X-Spam-Level: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --Nq2Wo0NMKNjxTN9z Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Dan, > There is no need for this comment, since it's obvious. Also if you use > simpler names then the copy fits on one line: >=20 > if (copy_from_user(&tx_cfg, argp, sizeof(tx_cfg)) { >=20 >=20 > > + mutex_lock(&device->tx_fifo_lock); > > + if (copy_from_user(&tx_cfg_buffer, argp, > > + sizeof(struct pi433_tx_cfg))) { >=20 > Sorry for the duplicate review, but it got sent to both my inboxes... :P Thanks for your review ! Patch updated. Please tell me if you don't to be CC-ed anymore. :) regards, Hugo --=20 Hugo Lefeuvre (hle) | www.owl.eu.com 4096/ 9C4F C8BF A4B0 8FC5 48EB 56B8 1962 765B B9A8 BACA --Nq2Wo0NMKNjxTN9z Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEE5LpPtQuYJzvmooL3LVy48vb3khkFAlshwIIACgkQLVy48vb3 khmLBAf9FO3lTSjPwyO1Uy1ACTowKWK67DW6xhm+UVRe2mDRTG83CsW0WfF72bzH G+FpIbglu8qanddDQepLuVEi6NCJlm4uqArhcq4EeMb2Ju+aqmsiODrlYNZkWlfi BzD2Jv1csWl0tnoo0jFnUVoInR6rfRlfn7FqVxCXXf63z8pN+ueqoQXAJAIyFoWE JFl0O82MiEUwsuRFwc81Tx/ijuvJSFgjUCOcn9+PodojlVJYqtV7fU7gRCFnMeb3 GYFB7MeDMDodjYM4oEQ1BOXDxm3CeSXGCkV4oDgxn9xEBZlX4QvHzEjUhixOaEvf NvtUwwzx+2+NllE1yLJrgF8b3Ky0rQ== =WUYq -----END PGP SIGNATURE----- --Nq2Wo0NMKNjxTN9z--