The patch titled Avoid unnecessary PURR reading has been added to the -mm tree. Its filename is powerpc-add-scaled-time-accounting-speedup.patch *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: Avoid unnecessary PURR reading From: Badari Pulavarty <pbadari@xxxxxxxxxx> Avoid reading PURR multiple times, by passing it in to read_spurr(). Signed-off-by: Badari Pulavarty <pbadari@xxxxxxxxxx> Cc: Michael Neuling <mikey@xxxxxxxxxxx> Cc: Balbir Singh <balbir@xxxxxxxxxx> Cc: Jay Lan <jlan@xxxxxxxxxxxx> Cc: Paul Mackerras <paulus@xxxxxxxxx> Cc: Benjamin Herrenschmidt <benh@xxxxxxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- diff -puN arch/powerpc/kernel/time.c~powerpc-add-scaled-time-accounting-speedup arch/powerpc/kernel/time.c --- a/arch/powerpc/kernel/time.c~powerpc-add-scaled-time-accounting-speedup +++ a/arch/powerpc/kernel/time.c @@ -169,11 +169,11 @@ static u64 read_purr(void) /* * Read the SPURR on systems that have it, otherwise the purr */ -static u64 read_spurr(void) +static u64 read_spurr(u64 purr) { if (cpu_has_feature(CPU_FTR_SPURR)) return mfspr(SPRN_SPURR); - return read_purr(); + return purr; } /* @@ -189,7 +189,7 @@ void account_system_vtime(struct task_st now = read_purr(); delta = now - get_paca()->startpurr; get_paca()->startpurr = now; - nowscaled = read_spurr(); + nowscaled = read_spurr(now); deltascaled = nowscaled - get_paca()->startspurr; get_paca()->startspurr = nowscaled; if (!in_interrupt()) { _ Patches currently in -mm which might be from pbadari@xxxxxxxxxx are x86_64-mm-vdso-text-offset.patch ppc64-sparsemem_vmemmap-support-vmemmap-ppc64-convert-vmm_-macros-to-a-real-function-fix.patch ext3-convert-to-new-aops.patch ext4-convert-to-new-aops.patch memory-unplug-v7-memory-hotplug-cleanup-fix.patch hugetlbfs-read-support.patch hugetlbfs-read-support-fix.patch ext2-statfs-improvement-for-block-and-inode-free-count.patch aio-account-i-o-wait-time-properly.patch fix-for-ext2-reservation.patch sysctl-remove-the-binary-interface-for-aio-nr-aio-max-nr-acpi_video_flags.patch mem-controller-gfp-mask-fix.patch powerpc-add-scaled-time-accounting-speedup.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html