From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from poutre.nerim.net (poutre.nerim.net [62.4.16.124]) by ozlabs.org (Postfix) with ESMTP id 3294AB7D1C for ; Tue, 1 Jun 2010 23:53:15 +1000 (EST) Date: Tue, 1 Jun 2010 15:53:10 +0200 From: Jean Delvare To: Wolfram Sang Subject: Re: [PATCH] drivers: remove all i2c_set_clientdata(client, NULL) Message-ID: <20100601155310.3781fce6@hyperion.delvare> In-Reply-To: <1275310552-14685-1-git-send-email-w.sang@pengutronix.de> References: <1275310552-14685-1-git-send-email-w.sang@pengutronix.de> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Cc: Dmitry Torokhov , linuxppc-dev@ozlabs.org, linux-mtd@lists.infradead.org, linux-i2c@vger.kernel.org, devel@driverdev.osuosl.org, Samuel Ortiz , lm-sensors@lm-sensors.org, linux-input@vger.kernel.org, linux-media@vger.kernel.org, Paul Gortmaker , Riku Voipio , rtc-linux@googlegroups.com, Alessandro Rubini , Mauro Carvalho Chehab , "Ben Dooks \(embedded platforms\)" , Greg Kroah-Hartman , Liam Girdwood , Alessandro Zummo , Guillaume Ligneul , George Joseph , Mark Brown , linux-kernel@vger.kernel.org, Richard Purdie , Colin Leroy , David Woodhouse List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On Mon, 31 May 2010 14:55:48 +0200, Wolfram Sang wrote: > I2C-drivers can use the clientdata-pointer to point to private data. As I2C > devices are not really unregistered, but merely detached from their driver, it > used to be the drivers obligation to clear this pointer during remove() or a > failed probe(). As a couple of drivers forgot to do this, it was agreed that it > was cleaner if the i2c-core does this clearance when appropriate, as there is > no guarantee for the lifetime of the clientdata-pointer after remove() anyhow. > This feature was added to the core with commit > e4a7b9b04de15f6b63da5ccdd373ffa3057a3681 to fix the faulty drivers. > > As there is no need anymore to clear the clientdata-pointer, remove all current > occurrences in the drivers to simplify the code and prevent confusion. > > Signed-off-by: Wolfram Sang > Cc: Jean Delvare > (...) Applied, thanks. Will go to Linus in the next few days. -- Jean Delvare