Patchwork [4/8] cputime: Generic on-demand virtual cputime accounting

login
register
mail settings
Submitter Stephen Rothwell
Date Feb. 8, 2013, 3:14 a.m.
Message ID <20130208141447.03914013db9a5f7308fc1675@canb.auug.org.au>
Download mbox | patch
Permalink /patch/219032/
State Not Applicable
Headers show

Comments

Stephen Rothwell - Feb. 8, 2013, 3:14 a.m.
Hi Frederic,

On Fri, 8 Feb 2013 14:07:49 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> This patch has the side effect of changing the default configurations:
> (This is PowerPC pseries_defconfig before/after this patch)
> 
> @@ -119,8 +120,8 @@
>  #
>  # CPU/Task time and stats accounting
>  #
> -# CONFIG_TICK_CPU_ACCOUNTING is not set
> -CONFIG_VIRT_CPU_ACCOUNTING=y
> +CONFIG_TICK_CPU_ACCOUNTING=y
> +# CONFIG_VIRT_CPU_ACCOUNTING_NATIVE is not set
>  # CONFIG_BSD_PROCESS_ACCT is not set
>  CONFIG_TASKSTATS=y
>  CONFIG_TASK_DELAY_ACCT=y
> 
> I don't know if that was deliberate, but it was suprising.  I noticed
> when this patch entered next-20130207.

I suspect that this is caused by the changes to init/Kconfig:


The next line of context is:

        default VIRT_CPU_ACCOUNTING if PPC64

Which may have needed changing as well?  Indeed, changing that to
VIRT_CPU_ACCOUNTING_NATIVE restores the old defaults.
Frédéric Weisbecker - Feb. 8, 2013, 2:31 p.m.
2013/2/8 Stephen Rothwell <sfr@canb.auug.org.au>:
> Hi Frederic,
>
> On Fri, 8 Feb 2013 14:07:49 +1100 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>>
>> This patch has the side effect of changing the default configurations:
>> (This is PowerPC pseries_defconfig before/after this patch)
>>
>> @@ -119,8 +120,8 @@
>>  #
>>  # CPU/Task time and stats accounting
>>  #
>> -# CONFIG_TICK_CPU_ACCOUNTING is not set
>> -CONFIG_VIRT_CPU_ACCOUNTING=y
>> +CONFIG_TICK_CPU_ACCOUNTING=y
>> +# CONFIG_VIRT_CPU_ACCOUNTING_NATIVE is not set
>>  # CONFIG_BSD_PROCESS_ACCT is not set
>>  CONFIG_TASKSTATS=y
>>  CONFIG_TASK_DELAY_ACCT=y
>>
>> I don't know if that was deliberate, but it was suprising.  I noticed
>> when this patch entered next-20130207.
>
> I suspect that this is caused by the changes to init/Kconfig:
>
> diff --git a/init/Kconfig b/init/Kconfig
> index be8b7f5..a05f843 100644
> --- a/init/Kconfig
> +++ b/init/Kconfig
> @@ -326,6 +326,9 @@ source "kernel/time/Kconfig"
>
>  menu "CPU/Task time and stats accounting"
>
> +config VIRT_CPU_ACCOUNTING
> +       bool
> +
>  choice
>         prompt "Cputime accounting"
>         default TICK_CPU_ACCOUNTING if !PPC64
>
> The next line of context is:
>
>         default VIRT_CPU_ACCOUNTING if PPC64
>
> Which may have needed changing as well?  Indeed, changing that to
> VIRT_CPU_ACCOUNTING_NATIVE restores the old defaults.

Indeed, thanks for your fix!

Patch

diff --git a/init/Kconfig b/init/Kconfig
index be8b7f5..a05f843 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -326,6 +326,9 @@  source "kernel/time/Kconfig"
 
 menu "CPU/Task time and stats accounting"
 
+config VIRT_CPU_ACCOUNTING
+	bool
+
 choice
 	prompt "Cputime accounting"
 	default TICK_CPU_ACCOUNTING if !PPC64