Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp519692imm; Wed, 20 Jun 2018 02:08:07 -0700 (PDT) X-Google-Smtp-Source: ADUXVKLaR9V9v/lB7bKSBBLGmxBEtZ4vLCEH1FY6HZENATwCPf3AinrxGw54YEe2GWEJk0z6kciJ X-Received: by 2002:a62:d09:: with SMTP id v9-v6mr21531271pfi.163.1529485687348; Wed, 20 Jun 2018 02:08:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529485687; cv=none; d=google.com; s=arc-20160816; b=vlgLHsz+7c1+Kbzu09z3ribwx43aMDeflsaNZc7JbGt6WFAU+j2VQr2ya8IvPXZCGm QKdiue3I/kMORUVVV3fo0n1CeqVMud7fnTBr6dV+6q6ZOFMNc5FLGpN+H6wO1beIfUEN vRgo4bjUQ11dP0zoaRw+hX2bjrn+HAjmmjte6ahkECYPzQU54eCd/Wb0ca/VoEt6En9b sFGLWKC8a2+9VhtoO/SVMg94acTTXQ3vx/479QpepOWTmdatBf9p6mKS16+ELFV9DoOF QQXMWGmY8XFSUH4defAIoRLq+zG2enT0dRmueQP+iN0boxxUQWfQc+WgRcPJrmOBVvyu pc1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=O0vJUcT4Mc+H9wUe3QEqBqdbXIDak+uMs4CoMKKvHTA=; b=JIsbVXu0z3XhCOSNq+ZJkl/5GUU7nkZAe2rp9UM8lHJCf4aHS/TUP8Eu9uW4Krk8iN H4naEJfaRh66D4cHE0oTXxrQ+Faztjux1IDv1cQ7Xpn64PvHBgBsWMC4qZkafZKPFKSh /2aWN2VzfjAZ87RphRrrV352k4t6Beoy7BKS8ABTsdWSjnSdiqSFBDahOrjFG/1ZjrEA m4ukWSyIw9yynkUtsOA4vcN6XXdMXV5wGjFrz6WIqNSFxiETbN78R7cXiiZon+gRV56B CbOcugxsZcnmRMdH5wFt4Tg9rSUAWIJg54PXeIA+ixj3PT7Kk/oOo8shSQOGsV30vr5t Adig== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=JOEfEQBI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q11-v6si1598574pgp.95.2018.06.20.02.07.53; Wed, 20 Jun 2018 02:08:07 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=JOEfEQBI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754757AbeFTIhH (ORCPT + 99 others); Wed, 20 Jun 2018 04:37:07 -0400 Received: from mail-lf0-f67.google.com ([209.85.215.67]:32891 "EHLO mail-lf0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750793AbeFTIhD (ORCPT ); Wed, 20 Jun 2018 04:37:03 -0400 Received: by mail-lf0-f67.google.com with SMTP id y20-v6so3694746lfy.0; Wed, 20 Jun 2018 01:37:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=O0vJUcT4Mc+H9wUe3QEqBqdbXIDak+uMs4CoMKKvHTA=; b=JOEfEQBIjXYzn/vuXqmXtseykNqihRjle8cAO6+y8a2RNR5NEsZdgwNZYZXe5W8DlU FxQ9e5qB4Q/49uhwJ31J6D46pxmYHv/wKFp/hnloFjPEmA5n5R1NgCWDAVMXHWPpMKPT JMWi6osjOak7enZbxoD1FowlsMq/xM2wBC9WA/lcrW9apzA4T92/UlsQLa8ohWtFhRhs 3rJLsJLTUP2oQaJqvHIF/ASMY9ArvlpgHy+57NSux9eGMErDagKDMEtk1nmj85VoaN4O HXlIxaRKzXkXdPPAb9nBAE56TD5wESt6zsNLYsb3OhYUdwrD375PclvtUPg56OnrYXlU junA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=O0vJUcT4Mc+H9wUe3QEqBqdbXIDak+uMs4CoMKKvHTA=; b=gt1rLL8F9nbYa1fjFktk89IPFdTlgSbHo+qjFPREQv3sg1LMHMjjgcF1F1N0mzTikV l2umoIbjRLTH60Gu41xxNRsG/46Crr2CSO7SZ/p1VJTwN3eivurmtjQyLxb3Bw9wsMg8 YB3fQUGluhYWMb9vAIpU5l+1VFsOZUEODqjfF/dEAJQWEF+vWkmjnLzMxvcjuQ+12bBp Az5fLN8+XypZOTSqH6AT9DGQ6Y2eBLYcu7I1lQzu2D5yffE7tOW+R95Ckj2NcbSq6Zvy /i1ZR8HqwRiBiNJeEd+eMWjXt3+BPkh0CMqf1Mn1Xi8iv9i0vLNvWNQ6iHo91K0rq91k ZTQA== X-Gm-Message-State: APt69E2aXMpSzVxdOzVfPMjoBlh35rNuU0kSGrSIXfXj/RAuutYigwxF ySiPOJNKOk0N38hEGmsCFuv59W92 X-Received: by 2002:a19:ccc6:: with SMTP id c189-v6mr3044347lfg.88.1529480087204; Wed, 20 Jun 2018 00:34:47 -0700 (PDT) Received: from localhost (87-57-30-174-static.dk.customer.tdc.net. [87.57.30.174]) by smtp.gmail.com with ESMTPSA id z3-v6sm284167lfg.47.2018.06.20.00.34.46 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 20 Jun 2018 00:34:46 -0700 (PDT) From: Esben Haabendal To: Mark Brown , linux-spi@vger.kernel.org Cc: Kurt Kanzenbach , Angelo Dureghello , Nikita Yushchenko , Sanchayan Maity , Yuan Yao , linux-kernel@vger.kernel.org, Esben Haabendal , =?UTF-8?q?Martin=20Hundeb=C3=B8ll?= Subject: [PATCH 01/12] spi: spi-fsl-dspi: Drop unreachable else if statement Date: Wed, 20 Jun 2018 09:34:31 +0200 Message-Id: <20180620073442.20913-2-esben.haabendal@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180620073442.20913-1-esben.haabendal@gmail.com> References: <20180620073442.20913-1-esben.haabendal@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Esben Haabendal The if statement just above this if/else statement triggers on the same condition, and then invalidates it. Signed-off-by: Esben Haabendal Cc: Martin Hundebøll --- drivers/spi/spi-fsl-dspi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/spi/spi-fsl-dspi.c b/drivers/spi/spi-fsl-dspi.c index 0630962ce442..3ca9b9608801 100644 --- a/drivers/spi/spi-fsl-dspi.c +++ b/drivers/spi/spi-fsl-dspi.c @@ -593,8 +593,7 @@ static int dspi_eoq_write(struct fsl_dspi *dspi) dspi_pushr |= SPI_PUSHR_EOQ; if ((dspi->cs_change) && (!dspi->len)) dspi_pushr &= ~SPI_PUSHR_CONT; - } else if (tx_word && (dspi->len == 1)) - dspi_pushr |= SPI_PUSHR_EOQ; + } regmap_write(dspi->regmap, SPI_PUSHR, dspi_pushr); -- 2.17.1