Messages in this thread | | | Subject | Re: [Patch v2] mm/swap_slots.c: assign|reset cache slot by value directly | From | Tim Chen <> | Date | Wed, 11 Mar 2020 09:10:39 -0700 |
| |
On 3/10/20 10:53 PM, Wei Yang wrote: > Currently we use a tmp pointer, pentry, to transfer and reset swap cache > slot, which is a little redundant. Swap cache slot stores the entry > value directly, assign and reset it by value would be straight forward. > > Also this patch merges the else and if, since this is the only case we > refill and repeat swap cache. > > Signed-off-by: Wei Yang <richard.weiyang@linux.alibaba.com> > CC: Tim Chen <tim.c.chen@linux.intel.com>
Acked-by: Tim Chen <tim.c.chen@linux.intel.com>
> > --- > v2: keep the reset step after use, but remove the tmp pointer > ---
| |