ALSA: aoa: Remove obsolete cleanup for clientdata
Subsystems (2)
PATCH 1/2 ALSA: aoa: Remove obsolete cleanup for clientdata
The i2c core will clear the clientdata pointer automatically. We don't have to set the `data' field to NULL in remove() or if probe() failed anymore.
--- sound/aoa/codecs/onyx.c | 1 - 1 files changed, 0 insertions(+), 1 deletions(-)
sound/aoa/codecs/onyx.c +0 -1
@@ -1067,7 +1067,6 @@ static int onyx_i2c_probe(struct i2c_client *client, printk(KERN_DEBUG PFX "created and attached onyx instance\n");return 0 ; fail: -i2c_set_clientdata (client,NULL );kfree (onyx);return -ENODEV ; }
Signature · 1 line
1.7.4.1
PATCH 2/2 ALSA: keywest: Remove obsolete cleanup for clientdata
The i2c core will clear the clientdata pointer automatically. We don't have to set the `data' field to NULL in remove() or if probe() failed anymore.
--- sound/ppc/keywest.c | 1 - 1 files changed, 0 insertions(+), 1 deletions(-)
sound/ppc/keywest.c +0 -1
@@ -82,7 +82,6 @@ static int keywest_attach_adapter(struct i2c_adapter *adapter)static int keywest_remove (struct i2c_client *client) { -i2c_set_clientdata (client,NULL );if (! keywest_ctx)return 0 ;if (client == keywest_ctx->client)
Signature · 1 line
1.7.4.1
Re: [PATCH 2/2] ALSA: keywest: Remove obsolete cleanup for clientdata
Quoted 5 lines · Axel Lin
The i2c core will clear the clientdata pointer automatically. We don't have to set the `data' field to NULL in
remove()or ifprobe()failed anymore.Signed-off-by Axel Lin <[email protected]>
There is (at least) one
if (ptr)
kfree(ptr);
in this driver. Maybe you could fix this, too, while you are here.
And there is soc/codecs/tpa6130a2.c waiting to be fixed as well :)
Quoted 21 lines
--- sound/ppc/keywest.c | 1 - 1 files changed, 0 insertions(+), 1 deletions(-)sound/ppc/keywest.c +0
-1@@ -82,7 +82,6 @@ static int keywest_attach_adapter(struct i2c_adapter *adapter)static int keywest_remove (struct i2c_client *client) { -i2c_set_clientdata (client,NULL );if (! keywest_ctx)return 0 ;if (client == keywest_ctx->client)Signature · 1 line
1.7.4.1
Signature · 2 lines
Pengutronix e.K. | Wolfram Sang | Industrial Linux Solutions | http://www.pengutronix.de/ |
Re: [PATCH 2/2] ALSA: keywest: Remove obsolete cleanup for clientdata
In reply to Axel LinAt Fri, 09 Sep 2011 17:50:52 +0800,
Quoted 6 lines · Axel Lin
The i2c core will clear the clientdata pointer automatically. We don't have to set the `data' field to NULL in
remove()or ifprobe()failed anymore.Signed-off-by Axel Lin <[email protected]>
Applied now. Thanks.
Takashi
Quoted 21 lines
--- sound/ppc/keywest.c | 1 - 1 files changed, 0 insertions(+), 1 deletions(-)sound/ppc/keywest.c +0
-1@@ -82,7 +82,6 @@ static int keywest_attach_adapter(struct i2c_adapter *adapter)static int keywest_remove (struct i2c_client *client) { -i2c_set_clientdata (client,NULL );if (! keywest_ctx)return 0 ;if (client == keywest_ctx->client)Signature · 1 line
1.7.4.1
Quoted 5 lines · Axel Lin
The i2c core will clear the clientdata pointer automatically. We don't have to set the `data' field to NULL in
remove()or ifprobe()failed anymore.Signed-off-by Axel Lin <[email protected]>
Signature · 2 lines
Pengutronix e.K. | Wolfram Sang | Industrial Linux Solutions | http://www.pengutronix.de/ |