On Tue, 12 Feb 2008, Paul Jackson wrote:The enum has already been removed, as I've said a few times. The 'flags' field would be wrong because you're ignoring that these flags are both passed by the user to the kernel and by the kernel to the user as part of the 'int *' parameter in either set_mempolicy() or mbind(). So they must have predefined shift in linux/mempolicy.h to separate that 'int *' parameter into the policy mode and the optional mode flags. If you introduced a separate flags member to struct mempolicy, you'd be wasting the lower MPOL_FLAG_SHIFT bits for no apparent purpose so your flag bits still work: #define MPOL_F_STATIC_NODES (1 << MPOL_FLAG_SHIFT) There's no way around that without shifting before storing and each time you read pol->flags. So since those bits would have to be unused and can perfectly accomodate the mode bits (with the current definition of MPOL_FLAG_SHIFT at 8, we can accomodate up to 256 distinct modes), there is no reason why they cannot be combined. That is why I implemented it that way. David --
| Michal Piotrowski | Re: 2.6.23-rc3-mm1 |
| Tarkan Erimer | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Fred Tyler | Slow, persistent memory leak in 2.6.20 |
| Roland Dreier | Re: Integration of SCST in the mainstream Linux kernel |
git: | |
| David Miller | [GIT]: Networking |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| Antonio Almeida | HTB accuracy for high speed |
