Re: [PATCH 4/4] drivers/staging/lirc: Remove obsolete cleanup for clientdata

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 24 Jan 2011 19:09:02 -0500, Andy Walls wrote:
> On Mon, 2011-01-24 at 11:44 +0100, Wolfram Sang wrote:
> > A few new i2c-drivers came into the kernel which clear the clientdata-pointer
> > on exit or error. This is obsolete meanwhile, the core will do it. Simplify the
> > kfree() calls after that, the pointers don't need to be checked.
> > 
> > Signed-off-by: Wolfram Sang <w.sang@xxxxxxxxxxxxxx>
> > Cc: Greg Kroah-Hartman <gregkh@xxxxxxx>
> > Cc: Mauro Carvalho Chehab <mchehab@xxxxxxxxxx>
> > Cc: Andy Walls <awalls@xxxxxxxxxxxxxxxx>
> 
> Nak.
> 
> In a module where I plan to do more cleanup and add reference counting
> to struct IR, IR_tx, and IR_rx objects, I'd like the explicit "NULL"s in
> pointer checks to stay in for now.
> 
> Removing the explicit constant "NULL" makes searching for checks against
> NULL pointers more difficult when auditing the code (No red syntax
> highlighting and a /NULL search misses).

I agree that Wolfram was too generous with his clean-ups this time.
Wolfram, you should only be removing the calls to i2c_set_clientdata(x,
NULL), not changing the logic of the code.

Furthermore, lirc_zilog is currently undergoing heavy changes, I'd
rather let Andy and Jarod work on that staging driver, and clean up
what needs to be later.

-- 
Jean Delvare
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux