Re: [patch] slub: fix a code merge error

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

 



On Mon, 2011-11-14 at 09:56 +0800, alex shi wrote:
> >
> > Indeed. Please resend with proper subject and changelog with
> > Christoph's and David's ACKs included.
> 
> Pekka:
> 
> SLUB stat attribute was designed for stat accounting only. I checked
> the total 24 attributes that used now. All of them used in stat() only
> except the DEACTIVATE_TO_HEAD/TAIL.
it's an enum, it can be used in any case if proper used.

> And in fact, in the most of using scenarios the DEACTIVATE_TO_TAIL
> make reader confuse, TO_TAIL is correct but not for DEACTIVATE.
please look at the comments where DEACTIVATE_TO_TAIL is defined.

> Further more, CL also regretted this after he acked the original
> patches for this attribute mis-usages. He said "don't think we want
> this patch any more."
> http://permalink.gmane.org/gmane.linux.kernel.mm/67653 and want to use
> a comment instead of this confusing usage.
> https://lkml.org/lkml/2011/8/29/187
> 
> So, as to this regression, from my viewpoint, reverting the
> DEACTIVATE_TO_TAIL incorrect usage(commit 136333d104) is a better way.
>  :)
using 0/1 is insane and can easily cause problems. Using a name can help
avoid such insane. This is exactly what commit 136333d104 tries to do.
This is a general C programming skill everybody should already know.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]