Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp2091452ybh; Fri, 17 Jul 2020 09:06:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyLUOSzM7IXtGIE7jrZIC8fS5gJd02pEZwQM03P4zWnzju4rK6SnNtkbUIbMGXL9Pqi3OGo X-Received: by 2002:a17:906:57da:: with SMTP id u26mr9436434ejr.157.1595001965457; Fri, 17 Jul 2020 09:06:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595001965; cv=none; d=google.com; s=arc-20160816; b=PIa0+K8Ii1Eh+XZUP6/4b16il+Qn9oXOnOK6Bmm+p4JBB6nKTqX78zS8lULkVhuTaZ ltnQtPic2mQ4pLY2gmAvgShPkDmgCmAEX8riF3rxpaaq7wqq2JVSd3Y5G3dKhEqAtj/R i4VdKaZgLI8JVyZjWHxsQmWEa2ww2ysb0/NMUzVvv3/LmVl973gMQFrr5sUihJdnZYgs 2XIE0HlimksvXi6f8FPTtF184AlMOdskeh5+ZpmdBJv5paArOOsCiD3ZRYZhatdIcTAz 0SWctBCYmKo5hJ5hrLzbC06lRzJAm0T+KEJubNBzcRVqUYduux/F1MM6MNN/QvdHcUMu lhrA== 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:mime-version:user-agent:date:message-id:autocrypt :from:subject:cc:to:dkim-signature; bh=+CyasyHX6+85/NnAkWQkouWlVyO/a+IVPfoIFnurDYQ=; b=Lc6Psj8EVSZdSTnlU1jVTyoa4dMKNczXtSGJ8dl6XkqrJYAExytPxREtuBEPcqmKRq vPZf7dy+ijwrk7ClGsopF5fiTA3UViNcXmOa4rCVGlaQCZK83D3FJzxKgaxhUkco7/J7 /THlVqNUeC+HLJqTpsX1HmGuE1G8FEMm9+aVtZKbgQ854GNKrEK3HdjAVRt+2/nMXG4Z 9s2EvVtx8uIu+Rgps3m4zzL8yuDxxAsJCs8oL5Wt0ohDYlwZqyUcGjlPi2QHLIdFKMPc VSFazUsZc2FtjM86fHS/OYPY8/SO+ew01A37OBWHWIuA1HbgNeI1PAAeU1aHFFp/YOJC Y/Og== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@web.de header.s=dbaedf251592 header.b=i4IFI01y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v12si5290840ejc.292.2020.07.17.09.05.32; Fri, 17 Jul 2020 09:06:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@web.de header.s=dbaedf251592 header.b=i4IFI01y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726648AbgGQQFY (ORCPT + 99 others); Fri, 17 Jul 2020 12:05:24 -0400 Received: from mout.web.de ([212.227.15.14]:32801 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726233AbgGQQFX (ORCPT ); Fri, 17 Jul 2020 12:05:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1595001915; bh=IXSBqWZE7pE8IG9SsTMiiZ0y4wKidBcIctGlOhcTNuw=; h=X-UI-Sender-Class:To:Cc:Subject:From:Date; b=i4IFI01yWPkDINO6OoW+03rO9waaBUv18duTjejHxD5Q1z+Sf2hSd3r7sEeZkpOLm 09J/ZOcaC2gTEpFDsqCtKjKo+9KUJmAwD1CIwrCrdAiYgyOZJ3h+X186FymMeXmXy5 5FJ+j9VYEU5mjsTelC4tkus6lwR/2I6p0GrqqIco= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from [192.168.1.2] ([93.131.15.38]) by smtp.web.de (mrweb006 [213.165.67.108]) with ESMTPSA (Nemesis) id 1MP3CC-1kCtoF0i2m-00PJmV; Fri, 17 Jul 2020 18:05:15 +0200 To: Denis Efremov , Coccinelle , Gilles Muller , Julia Lawall , Masahiro Yamada , Michal Marek , Nicolas Palix Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4] coccinelle: api: add kzfree script From: Markus Elfring Autocrypt: addr=Markus.Elfring@web.de; prefer-encrypt=mutual; keydata= mQINBFg2+xABEADBJW2hoUoFXVFWTeKbqqif8VjszdMkriilx90WB5c0ddWQX14h6w5bT/A8 +v43YoGpDNyhgA0w9CEhuwfZrE91GocMtjLO67TAc2i2nxMc/FJRDI0OemO4VJ9RwID6ltwt mpVJgXGKkNJ1ey+QOXouzlErVvE2fRh+KXXN1Q7fSmTJlAW9XJYHS3BDHb0uRpymRSX3O+E2 lA87C7R8qAigPDZi6Z7UmwIA83ZMKXQ5stA0lhPyYgQcM7fh7V4ZYhnR0I5/qkUoxKpqaYLp YHBczVP+Zx/zHOM0KQphOMbU7X3c1pmMruoe6ti9uZzqZSLsF+NKXFEPBS665tQr66HJvZvY GMDlntZFAZ6xQvCC1r3MGoxEC1tuEa24vPCC9RZ9wk2sY5Csbva0WwYv3WKRZZBv8eIhGMxs rcpeGShRFyZ/0BYO53wZAPV1pEhGLLxd8eLN/nEWjJE0ejakPC1H/mt5F+yQBJAzz9JzbToU 5jKLu0SugNI18MspJut8AiA1M44CIWrNHXvWsQ+nnBKHDHHYZu7MoXlOmB32ndsfPthR3GSv jN7YD4Ad724H8fhRijmC1+RpuSce7w2JLj5cYj4MlccmNb8YUxsE8brY2WkXQYS8Ivse39MX BE66MQN0r5DQ6oqgoJ4gHIVBUv/ZwgcmUNS5gQkNCFA0dWXznQARAQABtCZNYXJrdXMgRWxm cmluZyA8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djSGGN/5IBDfUqSANC8cWzHpWaHmSuU3JSAMB/N+yQjIad2ztTckZY pwT6oxng29LzZspTYUEzMz3wK2jQHw+U66qBFk8whA7B2uAU1QdGyPgahLYSOa4XAEGb6wbI FEE= Message-ID: Date: Fri, 17 Jul 2020 18:05:13 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:pKIFLkCMfXOR3B7TE46iyvM/kz/6zP9oIH2IWKSNZ4WBJo2kqd+ jGPkIGX2lqp2B9NeaRoAkDrHz2SVrclEXESX7lap4wQ5H5PXUZMoDTTfjOIn2xP0nG0+a3H eiCse1vMx+/IdKEUNEX3oa2xjIy8wEyfBsH2JOGbyGU0NOfdEzA/A8uyqcY6zckrnfM3orC 7p6wgUeBM+WTbVgKVHg1g== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:DF7btZ07Dac=:O2dZaojWPdey47X0drF8Ae Nd1Ga62Bx6VSHLQAak+1iUT1sVj/eWoOAry29J1VA07k569X9wWPlFAs8sOK+AbKzPOYQ+2gA ILDS4FXYpi4/UkabmPobSeEg3TNtUbweO5GKaDBC6ULDLq6jNIl0cozFjCdsnRa6f5MJtsIZr CxJJWCcRQcuQmicrd9XhcKYvf8/TQl5xMUdC0A8gw5PX+jUu+G2cDprYA9TNhMLqMAOmsaRBC rBrndjbqmmbY/2lbSxh0IeAcnn3thQdYylgHFwcr0u6Tjgk2kjzWI1tLiB44ncQuxT2UbXozS YQgJ9RL8/wLFsTmvfMjdVS5VhiE1JPZuefg6OtUoQK56Xs4t1RI2fLrfkWygTMlqX+6NWghFK EvZcXzeKVHPwS3SYPDcePHq8jfQo5iZUFooI36B06zPnkwq8gcDVUA9ld90F1whFY1JOEXq3j qfAteP9Au0D+ms/pcZZ1gdI/JCw7WBJ3P4fB47/itH8t4iWg4vkJMa/zL8pwyR015Lgetz1oM oY6rTmHcp8cO567i35GvKb2D1MLjZ6mNC/TPQkOUj2iSZToHc/TwVkehnd4dE1GPC092XlTFp JWzqp5UclpMngiWqwxTef20U9y6UE0Eyt0+QlpOfe0iJl3qrA4C/JNgQMXwflGuDwNnVHxsS3 MLzYdaU5MgDq6z8pTyHoujO1MqTA8j7NDMhno+Tb0mWDLRH1od1y+QOCxalGPzgalvBhENn/j LT1v+1ENQiIKYhnDhnekcxniO0zweyrrdibvM78iK/qhgmAUUDqrTfrut8cMyCA6+yAhhYgJn v0AdSUIYdSENI5QBxhgtahMy9YEAnmy4TtvNB/cUwPvzJRtauVFPvB811Eq9VKD94YJhVTvAD CmyRB/t7JV8g1Y5f8jKiCI9GXEqXxgfZOaRgGZPSKds0e72Sk0iUkSRr5+IV5BzMoFre9yTXM rFkdOOQzZZOSQqP0GHlP9nOnpIcQyPubxnq/e4SxA7A3VsMjpVKobqdsoYp63yX5AOH/toH/C t3NVM2rArUWp/LD9Xplk/xeQCPqhPu68PCR1jtnkrKyBvhORRCM/2vaFNneDCkuuXSwt0/Umu THJr20ae3dGPnePbBpqQeuSRKZ/2PDzdkb09vp0HxPmfPrLmxiHAXo0IfPf+z1P4Jl9bh6CYD zkQZ1nWotvh6j7U3csMJtuQ3PlH4lHvGZ27zqY1XLPFR5Q9x22TOpneu5AI6yKi4ddu5jmSLz KVvp0jCgqQaVMFu7UyHOYQGh3O13d77au1kNLtA== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org I dare to repeat previous patch review aspects once more. https://lore.kernel.org/cocci/a316f076-1686-25d8-18fe-1bbc0cf9a701@web.de/ =E2=80=A6 > +virtual context > +virtual patch > +virtual org > +virtual report +virtual context, patch, org, report Is such a SmPL code variant more succinct? =E2=80=A6 > +if (...) > + \(memset@ok\|memzero_explicit@ok\)(...); Would you like to tolerate any extra source code around such a function ca= ll in an if branch? =E2=80=A6 > +( > +* memset@m((T)E, 0, ...); > +| > +* memzero_explicit@m((T)E, ...); > +) =E2=80=A6 I suggest to move a semicolon. +( +*memset@m((T)E, 0, ...) +| +*memzero_explicit@m((T)E, ...) +); =E2=80=A6 > +- \(kfree\|vfree\|kvfree\)(E); > ++ kvfree_sensitive(E, size); =E2=80=A6 Would you like to increase the precision a bit for the change specificatio= n? +-\(kfree\|vfree\|kvfree\) ++kvfree_sensitive + (E ++ , size + ); =E2=80=A6 > +( > +- kfree(E); > ++ kzfree(E); > +| > +- \(vfree\|kvfree\)(E); > ++ kvfree_sensitive(E, size); > +) =E2=80=A6 +( +-kfree ++kzfree + (E) +| +-\(vfree\|kvfree\) ++kvfree_sensitive + (E ++ , size + ) +); =E2=80=A6 > +// TODO: uncomment when kfree_sensitive will be merged. > +// Only this case is commented out because developers > +// may not like patches like this since kzfree uses memset > +// internally (not memzero_explicit). Will this information trigger any further clarification? =E2=80=A6 > +coccilib.org.print_todo(p[0], > + "WARNING: opportunity for kzfree/kvfree_sensitive") I propose to align the second function parameter. +coccilib.org.print_todo(p[0], + "WARNING: opportunity for kzfree/kvfree_sensitive= ") Regards, Markus