Re: [PATCH RT 4/5] allow preemption in mem_cgroup_move_account_page_stat

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

 



* Nicholas Mc Guire | 2014-02-10 16:39:33 [+0100]:

>index a67e630f..e7cc35a 100644
>--- a/mm/memcontrol.c
>+++ b/mm/memcontrol.c
>@@ -3784,10 +3784,10 @@ void mem_cgroup_move_account_page_stat(struct mem_cgroup *from,
> 					enum mem_cgroup_stat_index idx)
> {
> 	/* Update stat data for mem_cgroup */
>-	preempt_disable();
>+	migrate_disable();
> 	__this_cpu_sub(from->stat->count[idx], nr_pages);
> 	__this_cpu_add(to->stat->count[idx], nr_pages);
>-	preempt_enable();
>+	migrate_enable();
> }

Now, that I look at it again. Isn't it more efficient to keep preemption
disabled for this very short time instead instead of invoking
migrate_disable() which includes preempt_disable()/enable() and a few
more opcodes…
Therefore, I drop it again.

Sebastian
--
To unsubscribe from this list: send the line "unsubscribe linux-rt-users" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [RT Stable]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux