From patchwork Fri Feb 15 18:41:22 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Anderson X-Patchwork-Id: 220803 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 45E632C0082 for ; Sat, 16 Feb 2013 05:42:28 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750733Ab3BOSmG (ORCPT ); Fri, 15 Feb 2013 13:42:06 -0500 Received: from mail-qc0-f202.google.com ([209.85.216.202]:50937 "EHLO mail-qc0-f202.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750730Ab3BOSmF (ORCPT ); Fri, 15 Feb 2013 13:42:05 -0500 Received: by mail-qc0-f202.google.com with SMTP id k26so362897qcs.3 for ; Fri, 15 Feb 2013 10:42:03 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer :x-gm-message-state; bh=0qTMfRXyK5xW7T3lMSmxYrM4LLfDNp54OxtJHsnyLXs=; b=JruBEKVifb2oWANAIYu9gEhQiC9IGVnyzeoARENrCAZA9bjsVAe4h1fqvhgHRqY07k U0rHlhaOulJXx7tfmTgm9fbdXAgbCla6G+oO7kjteIsW9LvjFve3mCjkkqKeNs98KdMD EXY+U9HjM/LOPdOa1gDmf9tZyYUisDBLK7qDH5QTdRMAJkHMxUiHyMZ4sqVlGiDn8SFW Baxix6IraPpTON95qPk4e9tEGn8GfDRWtMaSwihkCbq7meBTCt4wcgKjBp70/uawe/7B 8B7E+OmXiR9sljypZ3ZvbwjpPu42JEH5HSTozgq1k/Mk56zW82TYP98/61Mt+dKP4xve LlLQ== X-Received: by 10.236.147.210 with SMTP id t58mr1507668yhj.29.1360953723459; Fri, 15 Feb 2013 10:42:03 -0800 (PST) Received: from corp2gmr1-2.hot.corp.google.com (corp2gmr1-2.hot.corp.google.com [172.24.189.93]) by gmr-mx.google.com with ESMTPS id e21si1283763anp.1.2013.02.15.10.42.03 (version=TLSv1.1 cipher=AES128-SHA bits=128/128); Fri, 15 Feb 2013 10:42:03 -0800 (PST) Received: from tictac.mtv.corp.google.com (tictac.mtv.corp.google.com [172.22.73.80]) by corp2gmr1-2.hot.corp.google.com (Postfix) with ESMTP id 4CF8C5A4193; Fri, 15 Feb 2013 10:42:03 -0800 (PST) Received: by tictac.mtv.corp.google.com (Postfix, from userid 121310) id E51D581184; Fri, 15 Feb 2013 10:42:02 -0800 (PST) From: Doug Anderson To: Wolfram Sang Cc: Stephen Warren , Doug Anderson , Peter Korsgaard , "Ben Dooks (embedded platforms)" , linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] i2c: mux: Remove unneeded platform_set_drvdata to NULL in remove Date: Fri, 15 Feb 2013 10:41:22 -0800 Message-Id: <1360953682-25066-1-git-send-email-dianders@chromium.org> X-Mailer: git-send-email 1.8.1 X-Gm-Message-State: ALoCoQk9xPrl6L9w9BZ3fezIZNAoxLgA0T/ALvoqB3dLP4kuAJluDM8EYDucYvpPRbrdGGVMlMa9vHclalW0365MgJei2yB3vfe+FyB5cwAGka3Cl7clKepib9suxMus6JaWMUNL6K94t4TyebSEmdQQVbYsggogIEsu8SUrAGuFXWokPFMBW8fyYtOS4CuQa0GX8J7/p2luOIRmaUrYKs6jh7HULe9KXw== Sender: linux-i2c-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-i2c@vger.kernel.org Stephen Warren pointed out as part of a code review of another mux driver that there should be no need to have "platform_set_drvdata(pdev, NULL)" in the remove function. Get rid of it in the i2c-mux-gpio driver. See Stephen's comment at: http://www.gossamer-threads.com/lists/linux/kernel/1678627?do=post_view_threaded#1678627 Signed-off-by: Doug Anderson --- drivers/i2c/muxes/i2c-mux-gpio.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/i2c/muxes/i2c-mux-gpio.c b/drivers/i2c/muxes/i2c-mux-gpio.c index 9f50ef0..abc2e55a 100644 --- a/drivers/i2c/muxes/i2c-mux-gpio.c +++ b/drivers/i2c/muxes/i2c-mux-gpio.c @@ -250,7 +250,6 @@ static int i2c_mux_gpio_remove(struct platform_device *pdev) for (i = 0; i < mux->data.n_gpios; i++) gpio_free(mux->gpio_base + mux->data.gpios[i]); - platform_set_drvdata(pdev, NULL); i2c_put_adapter(mux->parent); return 0;