From patchwork Thu Apr 30 23:48:30 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anton Vorontsov X-Patchwork-Id: 26726 X-Patchwork-Delegate: galak@kernel.crashing.org Return-Path: X-Original-To: patchwork-incoming@bilbo.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from ozlabs.org (ozlabs.org [203.10.76.45]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mx.ozlabs.org", Issuer "CA Cert Signing Authority" (verified OK)) by bilbo.ozlabs.org (Postfix) with ESMTPS id 5F0C6B707E for ; Fri, 1 May 2009 10:12:57 +1000 (EST) Received: by ozlabs.org (Postfix) id B70B551756; Fri, 1 May 2009 09:54:36 +1000 (EST) Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [127.0.0.1]) by ozlabs.org (Postfix) with ESMTP id B48F451755 for ; Fri, 1 May 2009 09:54:36 +1000 (EST) X-Original-To: linuxppc-dev@ozlabs.org Delivered-To: linuxppc-dev@ozlabs.org Received: from buildserver.ru.mvista.com (unknown [213.79.90.228]) by ozlabs.org (Postfix) with ESMTP id 16301DE77E for ; Fri, 1 May 2009 09:48:32 +1000 (EST) Received: from localhost (unknown [10.150.0.9]) by buildserver.ru.mvista.com (Postfix) with ESMTP id D064D8829; Fri, 1 May 2009 05:48:52 +0500 (SAMST) Date: Fri, 1 May 2009 03:48:30 +0400 From: Anton Vorontsov To: Kumar Gala Subject: [PATCH 7/9] spi_mpc83xx: Remove dead code Message-ID: <20090430234830.GG7901@oksana.dev.rtsoft.ru> References: <20090430234739.GA27709@oksana.dev.rtsoft.ru> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20090430234739.GA27709@oksana.dev.rtsoft.ru> User-Agent: Mutt/1.5.18 (2008-05-17) Cc: linuxppc-dev@ozlabs.org, Andrew Morton , David Brownell , linux-kernel@vger.kernel.org, spi-devel-general@lists.sourceforge.net X-BeenThere: linuxppc-dev@ozlabs.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@ozlabs.org This patch removes #if 0'ed code, and spi_mpc83xx->busy variable that is used by that dead snippet only. Signed-off-by: Anton Vorontsov --- drivers/spi/spi_mpc83xx.c | 16 ---------------- 1 files changed, 0 insertions(+), 16 deletions(-) diff --git a/drivers/spi/spi_mpc83xx.c b/drivers/spi/spi_mpc83xx.c index 50112a5..4192ce4 100644 --- a/drivers/spi/spi_mpc83xx.c +++ b/drivers/spi/spi_mpc83xx.c @@ -98,8 +98,6 @@ struct mpc83xx_spi { bool qe_mode; - u8 busy; - struct workqueue_struct *workqueue; struct work_struct work; @@ -411,7 +409,6 @@ static void mpc83xx_spi_work(struct work_struct *work) work); spin_lock_irq(&mpc83xx_spi->lock); - mpc83xx_spi->busy = 1; while (!list_empty(&mpc83xx_spi->queue)) { struct spi_message *m = container_of(mpc83xx_spi->queue.next, struct spi_message, queue); @@ -423,7 +420,6 @@ static void mpc83xx_spi_work(struct work_struct *work) spin_lock_irq(&mpc83xx_spi->lock); } - mpc83xx_spi->busy = 0; spin_unlock_irq(&mpc83xx_spi->lock); } @@ -482,18 +478,6 @@ static int mpc83xx_spi_setup(struct spi_device *spi) dev_dbg(&spi->dev, "%s, mode %d, %u bits/w, %u Hz\n", __func__, spi->mode & (SPI_CPOL | SPI_CPHA), spi->bits_per_word, spi->max_speed_hz); -#if 0 /* Don't think this is needed */ - /* NOTE we _need_ to call chipselect() early, ideally with adapter - * setup, unless the hardware defaults cooperate to avoid confusion - * between normal (active low) and inverted chipselects. - */ - - /* deselect chip (low or high) */ - spin_lock(&mpc83xx_spi->lock); - if (!mpc83xx_spi->busy) - mpc83xx_spi_chipselect(spi, BITBANG_CS_INACTIVE); - spin_unlock(&mpc83xx_spi->lock); -#endif return 0; }