Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp804864ybt; Wed, 17 Jun 2020 14:37:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyZYa3C/DUGRscfTFXdP2VVfLqFht3xuF/SEBVL0QtRnsqfXCkC1KzS4z57wz5kfoXFhfKF X-Received: by 2002:a17:906:73d5:: with SMTP id n21mr1207427ejl.24.1592429878281; Wed, 17 Jun 2020 14:37:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592429878; cv=none; d=google.com; s=arc-20160816; b=CciOOSyrZ39OtnlkUhSyS0+z85EN3oOgiYG4H75+YNW5PrKWDXpC5IiH2C6VPc3okr 9lptV7rzJjcq3SLGEKdRF8hwj5K8nreEDwmsu2L0FTCnW+eSLb4B4sUZ47opiKDhJdE6 wG9gwGMlFESN5EdjBi4r3b2nxsuu7uhJW/nUDNYnf1oUdE/Dbei7kJvuv1Kj9MbXuJ7b L0C/0EEWGoqRHS2ImVEDAw1CNPc+Xfi7nE1tVdNLW0pD+NoEiwN/BYtbcjuByd5aapc0 n6J/A+/jIf8HXiylyFcGQHYHuSk2pZA6DSoL/8/QlbQOviOHx+KVs2lFOFzNIgWJt5Yy g7wQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:subject:autocrypt:from:references:cc:to; bh=RKUGEk6zj8LHdC9L456BsyYSoKpcBueo5EnIYdDtm50=; b=c3/ti3RTpZ7OoOopNk6V5Wkcd0rhPQeHYHNGneWKQBvqfgfIEU2TXrfG5/vceMPpJN irdCLLR71/G0d00jsfC6v/I8hANVGjqbh4rVu7GbXvaN/BN5aD+CkplXdAMvd/ltCO2V Nka+eg1P6EgljvQowxDmwK4/6MCIulrKhljs1ZPgitqAaJEVKC/JdNGwlolUdTfDoVz+ lmuohZa2z/XfIP4S/Y4kHkWsQFjezImuQTIleiBR0ToAt2643mvSToTzJr+TbK4+28y6 geKBL9Sr19gDCM+0FdB3qURI1S5ODu+yVf44D6Yu0Sg3l5/sbXL3QX6zJ1vDTSaHc8+O dNFA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ispras.ru Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d3si848438edl.218.2020.06.17.14.37.25; Wed, 17 Jun 2020 14:37:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ispras.ru Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727059AbgFQVhJ (ORCPT + 99 others); Wed, 17 Jun 2020 17:37:09 -0400 Received: from mail.ispras.ru ([83.149.199.45]:42916 "EHLO mail.ispras.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726758AbgFQVhI (ORCPT ); Wed, 17 Jun 2020 17:37:08 -0400 X-Greylist: delayed 346 seconds by postgrey-1.27 at vger.kernel.org; Wed, 17 Jun 2020 17:37:02 EDT Received: from [192.168.1.8] (unknown [213.87.137.195]) by mail.ispras.ru (Postfix) with ESMTPSA id 54355BFD1E; Thu, 18 Jun 2020 00:31:03 +0300 (MSK) To: Joe Perches , Waiman Long , Andrew Morton , David Howells , Jarkko Sakkinen , James Morris , "Serge E. Hallyn" , Linus Torvalds , Matthew Wilcox , David Rientjes Cc: Michal Hocko , Johannes Weiner , Dan Carpenter , David Sterba , "Jason A . Donenfeld" , linux-mm@kvack.org, keyrings@vger.kernel.org, linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org, linux-pm@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-amlogic@lists.infradead.org, linux-mediatek@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, virtualization@lists.linux-foundation.org, netdev@vger.kernel.org, linux-ppp@vger.kernel.org, wireguard@lists.zx2c4.com, linux-wireless@vger.kernel.org, devel@driverdev.osuosl.org, linux-scsi@vger.kernel.org, target-devel@vger.kernel.org, linux-btrfs@vger.kernel.org, linux-cifs@vger.kernel.org, linux-fscrypt@vger.kernel.org, ecryptfs@vger.kernel.org, kasan-dev@googlegroups.com, linux-bluetooth@vger.kernel.org, linux-wpan@vger.kernel.org, linux-sctp@vger.kernel.org, linux-nfs@vger.kernel.org, tipc-discussion@lists.sourceforge.net, linux-security-module@vger.kernel.org, linux-integrity@vger.kernel.org References: <20200616015718.7812-1-longman@redhat.com> From: Denis Efremov Autocrypt: addr=efremov@ispras.ru; keydata= mQINBFsJUXwBEADDnzbOGE/X5ZdHqpK/kNmR7AY39b/rR+2Wm/VbQHV+jpGk8ZL07iOWnVe1 ZInSp3Ze+scB4ZK+y48z0YDvKUU3L85Nb31UASB2bgWIV+8tmW4kV8a2PosqIc4wp4/Qa2A/ Ip6q+bWurxOOjyJkfzt51p6Th4FTUsuoxINKRMjHrs/0y5oEc7Wt/1qk2ljmnSocg3fMxo8+ y6IxmXt5tYvt+FfBqx/1XwXuOSd0WOku+/jscYmBPwyrLdk/pMSnnld6a2Fp1zxWIKz+4VJm QEIlCTe5SO3h5sozpXeWS916VwwCuf8oov6706yC4MlmAqsQpBdoihQEA7zgh+pk10sCvviX FYM4gIcoMkKRex/NSqmeh3VmvQunEv6P+hNMKnIlZ2eJGQpz/ezwqNtV/przO95FSMOQxvQY 11TbyNxudW4FBx6K3fzKjw5dY2PrAUGfHbpI3wtVUNxSjcE6iaJHWUA+8R6FLnTXyEObRzTS fAjfiqcta+iLPdGGkYtmW1muy/v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FFI/ik69hF9hemK/BmAHpShI+z1JsYT9cSs8D7wbaF/j QVy4URensgAPkgXsRiboqOj/rTz9F5mpd/gPU/IOUPFEMoo4TInt/+dEVECHioU3RRrWEahr GMfRngbdp/mKs9aBR56ECMfFFUPyI3VJsNbgpcIJjV/0N+JdJKQpJ/4uQ2zNm0wH/RU8CRJv EwtKemX6fp/zLI36Gvz8zJIjSBIEqCb7vdgvWarksrhmi6/Jay5zRZ03+k6YwiqgX8t7ANwv Ya1h1dQ36OiTqm1cIxRCGl4wrypOVGx3OjCar7sBLD+NkwO4RaqFvdv0xuuy4x01VnOF Subject: Re: [PATCH v4 0/3] mm, treewide: Rename kzfree() to kfree_sensitive() Message-ID: <17e4fede-bab0-d93c-6964-69decc889d7d@ispras.ru> Date: Thu, 18 Jun 2020 00:31:01 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On 6/16/20 9:53 PM, Joe Perches wrote: > On Mon, 2020-06-15 at 21:57 -0400, Waiman Long wrote: >> v4: >> - Break out the memzero_explicit() change as suggested by Dan Carpenter >> so that it can be backported to stable. >> - Drop the "crypto: Remove unnecessary memzero_explicit()" patch for >> now as there can be a bit more discussion on what is best. It will be >> introduced as a separate patch later on after this one is merged. > > To this larger audience and last week without reply: > https://lore.kernel.org/lkml/573b3fbd5927c643920e1364230c296b23e7584d.camel@perches.com/ > > Are there _any_ fastpath uses of kfree or vfree? > > Many patches have been posted recently to fix mispairings > of specific types of alloc and free functions. I've prepared a coccinelle script to highlight these mispairings in a function a couple of days ago: https://lkml.org/lkml/2020/6/5/953 I've listed all the fixes in the commit message. Not so many mispairings actually, and most of them are harmless like: kmalloc(E) -> kvfree(E) However, coccinelle script can't detect cross-functions mispairings, i.e. allocation in one function, free in another funtion. Thanks, Denis