Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2149287pxj; Thu, 20 May 2021 00:59:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwgujHgF2KFlpkdMwNupaSDs25bb8BcnnZXexFii0ejkMXZux7G+vgvct86DV6I1+CY33fB X-Received: by 2002:a50:9990:: with SMTP id m16mr3576165edb.292.1621497544173; Thu, 20 May 2021 00:59:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621497544; cv=none; d=google.com; s=arc-20160816; b=GbwFnH1t9r7borqX6yku1uGLG/757pmelPSAJQnG5PqV4xmTbf9BpPdqxUXsR/bfJl GzAYhZG7so70szw9gWICvmGafBxg3OvC6Cdif4XKjIhqBJHFsgbUK7euOLHNCkTDEnxB j3ijeiEjxciyKMVwyePAZpGd8pcQOXfj/KcETcH8f25TylMRAkrcqe8jDT2ayxciO9X4 qzySKiDLnHqpawVD8ZJMreK0KFEOCecnaJ9z0jVmGZOva+yRrBp7CkFOnpUVL07vNzYe EnwbJL/BmirWm7j9ZZ5o44ZAQ6Dm4j3sGJoiaWrNNybn4F5Hj8Y2T84MW7TphVbVwrQa HJOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=QRVLntSheXKXlr8GdTEFOhZ3Zvd4Coyp1lOO0dy4YdU=; b=MNf66RbbbnXpNl9WMj7LI/QGhzbsdtTy4lR342IJlSz829K+MTtSHn2CziiUMSVs1e MTrB5u9HMhHlnjBQUTahb3z22DgC4aug1GpD77SWpn0R8PinXswUpRpTpc5Hm5MPzhgB kJquO0EtXOyfdcUXBr50NbSxkCMw42gqyBrlzNF9KnSAi4RE3EPJ6CMT8SwFovh8vvno sUBNZFBuTwIrhQ/zEI3flHc3rIB1W/gAuQ/KvTf5nRlvAsbMSLLAbKjWNZZsXwY68CO+ JvWRl2Mwm+ekBD4bV6ZMYx6b3qsmkOzdpBbSejSBe4OBpqe6Ie8AdDfeGAJsAjF8RjBO FF4g== 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=hisilicon.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u9si1874306ejh.586.2021.05.20.00.58.30; Thu, 20 May 2021 00:59:04 -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=hisilicon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229534AbhETH5h (ORCPT + 99 others); Thu, 20 May 2021 03:57:37 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:4765 "EHLO szxga04-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229978AbhETH5h (ORCPT ); Thu, 20 May 2021 03:57:37 -0400 Received: from dggems706-chm.china.huawei.com (unknown [172.30.72.58]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4Fm25m3JYszqV8p for ; Thu, 20 May 2021 15:52:44 +0800 (CST) Received: from dggpeml500023.china.huawei.com (7.185.36.114) by dggems706-chm.china.huawei.com (10.3.19.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Thu, 20 May 2021 15:56:15 +0800 Received: from localhost.localdomain (10.69.192.56) by dggpeml500023.china.huawei.com (7.185.36.114) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Thu, 20 May 2021 15:56:14 +0800 From: Shaokun Zhang To: CC: Shaokun Zhang , PrasannaKumar Muralidharan , Herbert Xu Subject: [PATCH] hwrng: core - remove redundant initialization of variable err Date: Thu, 20 May 2021 15:56:11 +0800 Message-ID: <1621497371-14746-1-git-send-email-zhangshaokun@hisilicon.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.69.192.56] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpeml500023.china.huawei.com (7.185.36.114) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org 'err' will be assigned later and cleanup the redundant initialization. Cc: PrasannaKumar Muralidharan Cc: Herbert Xu Signed-off-by: Shaokun Zhang --- drivers/char/hw_random/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/char/hw_random/core.c b/drivers/char/hw_random/core.c index adb3c2bd7783..322e3d0ea98c 100644 --- a/drivers/char/hw_random/core.c +++ b/drivers/char/hw_random/core.c @@ -323,7 +323,7 @@ static ssize_t hwrng_attr_current_store(struct device *dev, struct device_attribute *attr, const char *buf, size_t len) { - int err = -ENODEV; + int err; struct hwrng *rng, *old_rng, *new_rng; err = mutex_lock_interruptible(&rng_mutex); -- 2.7.4