From patchwork Wed Sep 28 15:43:22 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: SF Markus Elfring X-Patchwork-Id: 9355829 X-Patchwork-Delegate: snitzer@redhat.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C2F58600C8 for ; Thu, 29 Sep 2016 07:57:01 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B48AB29894 for ; Thu, 29 Sep 2016 07:57:01 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A8D242989A; Thu, 29 Sep 2016 07:57:01 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from mx3-phx2.redhat.com (mx3-phx2.redhat.com [209.132.183.24]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8070A29894 for ; Thu, 29 Sep 2016 07:57:00 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by mx3-phx2.redhat.com (8.13.8/8.13.8) with ESMTP id u8T7swTs002803; Thu, 29 Sep 2016 03:54:58 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id u8SFhP5T024267 for ; Wed, 28 Sep 2016 11:43:25 -0400 Received: from mx1.redhat.com (ext-mx08.extmail.prod.ext.phx2.redhat.com [10.5.110.32]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u8SFhPMC027197 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 28 Sep 2016 11:43:25 -0400 Received: from mout.web.de (mout.web.de [212.227.17.12]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B4C48C05AA63; Wed, 28 Sep 2016 15:43:24 +0000 (UTC) Received: from [192.168.1.2] ([78.48.47.99]) by smtp.web.de (mrweb102) with ESMTPSA (Nemesis) id 0LtFUV-1amQG80RZ5-012ns8; Wed, 28 Sep 2016 17:43:23 +0200 To: dm-devel@redhat.com, linux-raid@vger.kernel.org, Alasdair Kergon , Mike Snitzer , Shaohua Li References: <566ABCD9.1060404@users.sourceforge.net> <7c232017-e291-fd2d-5516-26e5150d90df@users.sourceforge.net> From: SF Markus Elfring Message-ID: <1a9b8a2d-8ae6-52f6-99b7-7e6172b6b6d1@users.sourceforge.net> Date: Wed, 28 Sep 2016 17:43:22 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 In-Reply-To: <7c232017-e291-fd2d-5516-26e5150d90df@users.sourceforge.net> X-Provags-ID: V03:K0:8dkeYF2AjYZ/PjScZqfSx2lC+BiXgRiYxINND4XsSvZNaXxmQQw VttYBRESHo0IjRGJeIhEwMbLq1mkIxGs19FJlFh6I9lqg2yT7uyWeHC+kHTWKFGMJrrXCZj NIsBC8kbyLUidZUpY42Pw9kohADSgNZaEff7NEY7fCH1wPFiaQ0a50/kHcEMz4zG0Yw36ok 8P+eG9s5JKcbLWoNhgZNQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:rRIuErEbzs8=:pbiPfI4BiK6EFgIKOra1E8 JwNkDSCLsd+CLlt3q5Vw2V6oYtjV7AZ8NsAwjvbARGFJ85nFkhOyw7v/k0Zia0VkyLhUJW2wq x1naIMK3xRmP5f+D+ajpfka4lOUjLvGk100HrIcQiMRws0oivKi1IYBk5nX4lMPI2kbvZLa36 Dqte9trGkBgxPHo0vLQkoECnLddTX9UpB+TZIUkiFjg/oJ2RCcxDm5asq511cC0R7mpiWJ6WM j5IHcmQX41fqxkhuFFRVRVnJKUQZSEx59OVkRlbLZq5sJs0KQ822oHc7zm1mDOX3TkUGKsMh4 padZ/d/H9TlMkNUnKEcqF5TtwBviO7XxRmUfzsC3M+5Rju4xPhtvoOaaB/VSgoL3Z8z7qB36o jf7Lj9EK7lkFY8d78fXzv30+cb6VKIUqqUsADmg2GOF9Nyop3iUaIauIbTW1PykBW1HEFALIr WoGvlqLhiNulItJMwyoeYhIBlb5DKBnNP7944m6yazyoPTMUBHl1IUNAMIKlxVttAe4BidGH0 tQ4pe3FKy13izPErEbPJZ1tr3u1xiqlKuZ4VU02mHoIVoqlLQmGyp/y6b1Ewi36x+C0ifZjtX aQpwltDcyAqf7BuzJZJju1oL/IqZkS6eXRlJuJJuVw/wZlC/U+XTQBKqldk16daHskjYHiQs0 2EL8LNeCoDbgGeU0pyB2cTJDz9peQ1E4QY1w+wmjPdTW73C0UMc5I+Et8s8QEX2IdVReabhWa PxYetD611oUWQHur/pBJPeZ7krU2xNySVlayENE5TioW9vjsltdjikbdt0ASXp3+4yoZLqPg9 jmCZMSe X-Greylist: Sender IP whitelisted by DNSRBL, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Wed, 28 Sep 2016 15:43:25 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.32]); Wed, 28 Sep 2016 15:43:25 +0000 (UTC) for IP:'212.227.17.12' DOMAIN:'mout.web.de' HELO:'mout.web.de' FROM:'elfring@users.sourceforge.net' RCPT:'' X-RedHat-Spam-Score: 0.079 (BAYES_50, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_PASS) 212.227.17.12 mout.web.de 212.227.17.12 mout.web.de X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Scanned-By: MIMEDefang 2.78 on 10.5.110.32 X-loop: dm-devel@redhat.com X-Mailman-Approved-At: Thu, 29 Sep 2016 03:54:16 -0400 Cc: Julia Lawall , kernel-janitors@vger.kernel.org, LKML Subject: [dm-devel] [PATCH 06/10] md/dm-crypt: Delete an unnecessary variable initialisation in crypt_set_key() X-BeenThere: dm-devel@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: device-mapper development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dm-devel-bounces@redhat.com Errors-To: dm-devel-bounces@redhat.com X-Virus-Scanned: ClamAV using ClamSMTP From: Markus Elfring Date: Wed, 28 Sep 2016 15:24:13 +0200 The local variable "r" will be set to an appropriate value a bit later. Thus omit the explicit initialisation at the beginning. Signed-off-by: Markus Elfring --- drivers/md/dm-crypt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/md/dm-crypt.c b/drivers/md/dm-crypt.c index 7e0fd82..3bc54c1 100644 --- a/drivers/md/dm-crypt.c +++ b/drivers/md/dm-crypt.c @@ -1491,7 +1491,7 @@ static int crypt_setkey_allcpus(struct crypt_config *cc) static int crypt_set_key(struct crypt_config *cc, char *key) { - int r = -EINVAL; + int r; int key_string_len = strlen(key); /* The key size may not be changed. */