From patchwork Sun Jan 30 23:05:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin Ian King X-Patchwork-Id: 12730198 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5189FC433F5 for ; Sun, 30 Jan 2022 23:06:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=+jaIYOlv0Xet3BERS+t03CsyyhFFEnSWde5a9+pM5Os=; b=GCB7/AxSITGlkO zNQS5sTIydw9GyHjIBrb8+xUBhYu8YQ4vyhQ43YGBbQwn/Hxx5jM0z5ypqUsmXyT5+9DuR/0vSERP bKjwV0eLv1wsG6x72UFDcwQffbAuNlD6+pDPB3XiA5eIBHZGsx668yC8Lur+6W0ScANPX+ZcFu8Y6 qeIjmorxDN5iXhnaV7WhSQjfpP2NiVaq49hZt7i2y1mSZ/n/1CnMOnjDbY+xAfyYNybq0OkpCeVgx NejtgYWiN85Ctot3cnPnC6pT4EXMsSDF0aql5aLAl+SNhqu7Bt3v7oEFQLxndhlpQQXyGff0PNjp0 90uTkRlm4zJWVNEgUXLw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nEJG5-007cHD-T1; Sun, 30 Jan 2022 23:05:22 +0000 Received: from mail-wr1-x433.google.com ([2a00:1450:4864:20::433]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nEJG2-007cGG-Ry for linux-arm-kernel@lists.infradead.org; Sun, 30 Jan 2022 23:05:20 +0000 Received: by mail-wr1-x433.google.com with SMTP id f17so21975572wrx.1 for ; Sun, 30 Jan 2022 15:05:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=KLIKePOeCome+/jrAOdUWZSwyKBM/SDtl/LP3yhDNYM=; b=e+clUAX4p9oBLGf9A96fySwmIAjAATRP3Dk8p8FHCvwn5kEVpadYL06GhUQQWY80aP 4aMUnP1kuLXcH+z2S9ADV51gj/e5k4LxtC2X7g1GZldbToIcPZ+CqPVtZyS3VK0rXZBM k5FR3elkLENDFbp/Y0maydNFfjQK2k+DjUXvYhbz7Js2WHoAHiid7WnEw02r+YgDYEPc aam8aJkHEo2+YuyOtVy6NAiZmXpmq3rAuSAmjdsdGVdu6zuQiL7l9SbBIa5aMdDIPIq+ HV2+wj6HCY58eaM27F6J9b13tGQ7Bn5Wyj64rFZH6f9Zo2VELoZS+ffV9QCC6iLqnCXN WOAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=KLIKePOeCome+/jrAOdUWZSwyKBM/SDtl/LP3yhDNYM=; b=fvGOpr+X0Lfz0goLSWwlxnsRlTKBKRHkmQNLMhP9YmHF2KxEs4IR3PVZDAjoCGKc/P P/31CrKGDCL1hJwGBmZSvf8Z6zwZ1WfdhKwOWeyH/JIhXek5wF6yBiJo1k+SjmLV+LqX W0C7vel6vu3XGsDntIK67FgMNu11d0yvO3Vt5e95+KCeiFa0phOV5FoSM6OKOQOfeo0v rMwJceOy8Lrk1fsBFj7aH2/3/Sjz47EEYDX0scFHATOe7RKrRNb2tOG3+UomG1tQPsGj Oj6BzRFditPUtcCgLJyNjYoIhlSVzd1mMDuk+ycyZQ6mdmr82AkgHoUs69rDP6hpY2w8 56oQ== X-Gm-Message-State: AOAM530Bq9UxJly9xwsplkrUWu3QZQCD5AT2mO+Lfqw+lq2tSlqAz2zL ET3A7uteY1NuGMDiInoMZfY= X-Google-Smtp-Source: ABdhPJzb62H0qxffVALn0pUgTOkkID2z8NicfA9VV7LoeIrQoDnLlzgP80EsDJmq7VA5ZU7+b3EBog== X-Received: by 2002:adf:e8ce:: with SMTP id k14mr6185249wrn.284.1643583916962; Sun, 30 Jan 2022 15:05:16 -0800 (PST) Received: from localhost (cpc154979-craw9-2-0-cust193.16-3.cable.virginm.net. [80.193.200.194]) by smtp.gmail.com with ESMTPSA id r2sm14226210wrz.99.2022.01.30.15.05.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 30 Jan 2022 15:05:16 -0800 (PST) From: Colin Ian King To: Corentin Labbe , Hans Ulli Kroll , Linus Walleij , Herbert Xu , "David S . Miller" , linux-crypto@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] crypto: sl3516: remove redundant initializations of pointers in_sg and out_sg Date: Sun, 30 Jan 2022 23:05:15 +0000 Message-Id: <20220130230515.8338-1-colin.i.king@gmail.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220130_150518_933720_542863F2 X-CRM114-Status: GOOD ( 13.93 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Pointers in_sg and out_sg are being initialized with values that are never read, they are being re-assigned the same values later on. The initializations are redundant, remove them in preference to the later assignments that are closer to when the pointers are being used. Signed-off-by: Colin Ian King --- drivers/crypto/gemini/sl3516-ce-cipher.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/crypto/gemini/sl3516-ce-cipher.c b/drivers/crypto/gemini/sl3516-ce-cipher.c index c1c2b1d86663..53e3fefb81de 100644 --- a/drivers/crypto/gemini/sl3516-ce-cipher.c +++ b/drivers/crypto/gemini/sl3516-ce-cipher.c @@ -23,8 +23,8 @@ static bool sl3516_ce_need_fallback(struct skcipher_request *areq) struct crypto_skcipher *tfm = crypto_skcipher_reqtfm(areq); struct sl3516_ce_cipher_tfm_ctx *op = crypto_skcipher_ctx(tfm); struct sl3516_ce_dev *ce = op->ce; - struct scatterlist *in_sg = areq->src; - struct scatterlist *out_sg = areq->dst; + struct scatterlist *in_sg; + struct scatterlist *out_sg; struct scatterlist *sg; if (areq->cryptlen == 0 || areq->cryptlen % 16) {