Re: [PATCH] staging: wlags49_h2: Replace kmalloc+memset by kzalloc and add error handling.

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

 



On Fri, Mar 23, 2012 at 09:00:19PM +0530, santosh prasad nayak wrote:
> Can you please explain whats the disadvantage of having 'unlikely()' here ?
> I have seen it at several places in driver side.

And I bet they are used wrong there.  Again, unless you are in some very
performance critical section of code, don't use unlikely().

The big thing is that it just is not needed at all.  Don't try to be
smarter than the compiler if you don't need it, _AND_ you haven't
actually measured it.

greg k-h
_______________________________________________
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