From patchwork Fri Sep 20 06:38:53 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 2915431 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 9E6469F1E2 for ; Fri, 20 Sep 2013 06:38:48 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9C26520335 for ; Fri, 20 Sep 2013 06:38:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D46DB20319 for ; Fri, 20 Sep 2013 06:38:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753916Ab3ITGiq (ORCPT ); Fri, 20 Sep 2013 02:38:46 -0400 Received: from mail-pd0-f170.google.com ([209.85.192.170]:40344 "EHLO mail-pd0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753522Ab3ITGiq (ORCPT ); Fri, 20 Sep 2013 02:38:46 -0400 Received: by mail-pd0-f170.google.com with SMTP id x10so21166pdj.29 for ; Thu, 19 Sep 2013 23:38:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=X56yEuZLkl/6L4E4eb3TDLqIOtWthKwUDqHFUVSYpdw=; b=i9k7Zgxsu0VL8nDPzTpVx403dL0Lys2e8Tugo1RxrumI5wUSEEVoREqVmKh3wy278u tYMR5EmJOXS+FQuHGd+ed0+3EGboohMqbl9TYEYFO/DiLlDHaBYOxnXKWXh14OP1RUF3 DiSZGTLBOmr1+O7KaEmG9xhxDdWGh1TrTwg2lb9Iboi8aTClq1uPSdSwaXCwwCfJXP5O 8w2MBHGXmkcYEPm87yPhLTxORyORhVgyKWV5HRGoZZ0fo0ow9v0/beNKgB1wS+4XiJ94 0XUICp8flfyDvsjmVpa7aKyEYy0dSRzoRz61caBmYfl5gL/D5aMKbjck/nIOBKUBNxnr oFJA== X-Gm-Message-State: ALoCoQm67AlvUUVXOAtLRinaRvuPVY3pPHpopHqiTxz4NIwq1eLwkr0M2m4fvO4SSfShCdtYbpzf X-Received: by 10.68.252.33 with SMTP id zp1mr6165207pbc.95.1379659125596; Thu, 19 Sep 2013 23:38:45 -0700 (PDT) Received: from linaro.sisodomain.com ([115.113.119.130]) by mx.google.com with ESMTPSA id ry4sm16801290pab.4.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 19 Sep 2013 23:38:45 -0700 (PDT) From: Sachin Kamat To: linux-fbdev@vger.kernel.org Cc: tomi.valkeinen@ti.com, jg1.han@samsung.com, rpurdie@rpsys.net, akpm@linux-foundation.org, sachin.kamat@linaro.org Subject: [PATCH 2/2] backlight: tosa: Remove redundant spi_set_drvdata Date: Fri, 20 Sep 2013 12:08:53 +0530 Message-Id: <1379659133-18799-2-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1379659133-18799-1-git-send-email-sachin.kamat@linaro.org> References: <1379659133-18799-1-git-send-email-sachin.kamat@linaro.org> Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Driver core sets driver data to NULL upon failure or remove. Signed-off-by: Sachin Kamat Acked-by: Jingoo Han --- drivers/video/backlight/tosa_lcd.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/video/backlight/tosa_lcd.c b/drivers/video/backlight/tosa_lcd.c index bf08157..be5d636 100644 --- a/drivers/video/backlight/tosa_lcd.c +++ b/drivers/video/backlight/tosa_lcd.c @@ -198,7 +198,7 @@ static int tosa_lcd_probe(struct spi_device *spi) ret = devm_gpio_request_one(&spi->dev, TOSA_GPIO_TG_ON, GPIOF_OUT_INIT_LOW, "tg #pwr"); if (ret < 0) - goto err_gpio_tg; + return ret; mdelay(60); @@ -219,8 +219,6 @@ static int tosa_lcd_probe(struct spi_device *spi) err_register: tosa_lcd_tg_off(data); -err_gpio_tg: - spi_set_drvdata(spi, NULL); return ret; } @@ -235,8 +233,6 @@ static int tosa_lcd_remove(struct spi_device *spi) tosa_lcd_tg_off(data); - spi_set_drvdata(spi, NULL); - return 0; }