From patchwork Thu Nov 9 11:49:59 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Baruch Siach X-Patchwork-Id: 836313 X-Patchwork-Delegate: jagannadh.teki@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 3yXhMZ2s4cz9t4c for ; Thu, 9 Nov 2017 22:51:22 +1100 (AEDT) Received: by lists.denx.de (Postfix, from userid 105) id 0F2EFC21FE9; Thu, 9 Nov 2017 11:50:44 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id EBD11C21F51; Thu, 9 Nov 2017 11:50:41 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 93366C21FA1; Thu, 9 Nov 2017 11:50:23 +0000 (UTC) Received: from mx.tkos.co.il (guitar.tcltek.co.il [192.115.133.116]) by lists.denx.de (Postfix) with ESMTPS id B3567C21F95 for ; Thu, 9 Nov 2017 11:50:18 +0000 (UTC) Received: from tarshish.tkos.co.il (unknown [10.0.8.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx.tkos.co.il (Postfix) with ESMTPSA id D44DE44059D; Thu, 9 Nov 2017 13:50:17 +0200 (IST) From: Baruch Siach To: u-boot@lists.denx.de Date: Thu, 9 Nov 2017 13:49:59 +0200 Message-Id: <46edc78f8fbd21ab1a4f2313d634f4dd1b5bf2bd.1510228199.git.baruch@tkos.co.il> X-Mailer: git-send-email 2.14.2 Cc: Baruch Siach Subject: [U-Boot] [PATCH] cmd: sf: remove useless pointer assignment X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" The 'flash' pointer is assigned unconditionally a few lines below, and is not used before that. Signed-off-by: Baruch Siach Reviewed-by: Lukasz Majewski --- cmd/sf.c | 1 - 1 file changed, 1 deletion(-) diff --git a/cmd/sf.c b/cmd/sf.c index f971eec781cc..9be8a89bc84c 100644 --- a/cmd/sf.c +++ b/cmd/sf.c @@ -126,7 +126,6 @@ static int do_spi_flash_probe(int argc, char * const argv[]) if (!ret) { device_remove(new, DM_REMOVE_NORMAL); } - flash = NULL; ret = spi_flash_probe_bus_cs(bus, cs, speed, mode, &new); if (ret) { printf("Failed to initialize SPI flash at %u:%u (error %d)\n",