From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mout.web.de ([212.227.17.12]:48123 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726754AbfKGO3C (ORCPT ); Thu, 7 Nov 2019 09:29:02 -0500 Subject: Re: s390/pkey: Use memdup_user() rather than duplicating its implementation References: <08422b7e-2071-ee52-049e-c3ac55bc67a9@web.de> <6137855bb4170c438c7436cbdb7dfd21639a8855.camel@perches.com> <833d7d5e-6ede-6bdd-a2cc-2da7f0b03908@de.ibm.com> <1b65bc81-f47a-eefa-f1f4-d5af6a1809c0@web.de> <733b29df-207e-a165-ee80-46be8720c0c4@de.ibm.com> From: Markus Elfring Message-ID: <8f98f9fc-57df-5993-44b5-5ea4c0de7ef9@web.de> Date: Thu, 7 Nov 2019 15:27:33 +0100 MIME-Version: 1.0 In-Reply-To: <733b29df-207e-a165-ee80-46be8720c0c4@de.ibm.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable Sender: linux-s390-owner@vger.kernel.org List-ID: To: =?UTF-8?Q?Christian_Borntr=c3=a4ger?= , linux-s390@vger.kernel.org, Joe Perches , Harald Freudenberger , Heiko Carstens , Ingo Franzki , Vasily Gorbik Cc: LKML , kernel-janitors@vger.kernel.org, Kangjie Lu , Navid Emamdoost , Stephen McCamant >>>> Reuse existing functionality from memdup_user() instead of keeping >>>> duplicate source code. >>>> >>>> Generated by: scripts/coccinelle/api/memdup_user.cocci >>>> >>>> Delete local variables which became unnecessary with this refactoring >>>> in two function implementations. >>>> >>>> Fixes: f2bbc96e7cfad3891b7bf9bd3e566b9b7ab4553d ("s390/pkey: add CCA = AES cipher key support") >>> >>> With that patch description, the Fixes tag is wrong...but (see below) >> >> I wonder about such a conclusion together with your subsequent feedback= . > > Please try to read and understand what other people write. I am also trying as usual. > My point was that your patch description only talks about refactoring > and avoiding code duplication. These implementation details are mentioned. > So you do not claim to have fixed anything. We have got a different understanding for the provided wording. > You claim to have refactored things to avoid code duplication. The reused code can reduce the probability for programming mistakes, can't it? > And no, refactoring is NOT a fix. Software development opinions vary around such a view, don't they? > That fact that you fix a bug was obviously just by accident. I can follow this view to some degree. > So you have not even noticed that your change was actually chaning > the logical flow of the code. I suggested to improve two function implementations. > Now: When you change the patch description explaining what you fix, > a Fixes tag is appropriate. Can such a disagreement be resolved by adding the information to the change description that an incomplete exception handling (which can trigger a memory leak) should be replaced by hopefully better functionality? Regards, Markus