On Sun, May 29, 2011 at 9:22 AM, Linus Torvalds wrote: > > Or, in fact, we could just do something like the attached (UNTESTED!) So I did warn you that it was untested. It still is, but I walked through it a bit more, and I realized that while I had gotten rid of the extra allocations of the cpu_vm_mask_var, I hadn't gotten rid of the freeing. So that patch would definitely not have worked very well with CONFIG_CPUMASK_OFFSTACK. And I noticed that I moved the cpu_vm_mask back in the wrong space, it should likely be as close as possible to the mm_context_t, since the main user is likely the task switching code that touches that anyway. So here's a slightly updated patch. STILL TOTALLY UNTESTED! The fixes were just from eyeballing it a bit more, not from any actual testing. Linus