Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-29 Thread Maxim Uvarov

On 09/26/15 17:16, Mike Holmes wrote:

Hongbo,

Try the exact CI docker environment which is  linked at the bottom of 
http://www.opendataplane.org/testing/

It has to pass clean there with the check-odp scripts to be acceptable.

Let me know if the docs are not good enough.



I do not see any warnings.  I use check-odp scripts which use one of the 
latest Linaros gcc.
Also we have them in CI scripts (with gcc, clang and etc) and do not see 
any warning.  So

yours warnings have to be fixed before merge.

Maxim.



On 26 September 2015 at 00:35, Hongbo Zhang <hongbo.zh...@linaro.org 
<mailto:hongbo.zh...@linaro.org>> wrote:


Yes, I see.

I don't like to introduce warnings/errors by my patch, But there are
already such errors even _without_ my patch, so I had to use
"-Wno-error" option to compile. Just curious if you have such errors
too and how can you compile it.


On 26 September 2015 at 02:07, Savolainen, Petri (Nokia - FI/Espoo)
<petri.savolai...@nokia.com <mailto:petri.savolai...@nokia.com>>
wrote:
> Hi,
>
> If a function does not use some parameter it must be marker with
ODP_UNUSED.
>
>
> For example,
>
> int odp_cpumask_def_control(odp_cpumask_t *mask, int num ODP_UNUSED)
> {
>
> ...
>
> }
>
>
> -Petri
>
>
>> -Original Message-
>> From: lng-odp [mailto:lng-odp-boun...@lists.linaro.org
<mailto:lng-odp-boun...@lists.linaro.org>] On Behalf Of
>> EXT Hongbo Zhang
>> Sent: Friday, September 25, 2015 2:40 AM
>> To: Maxim Uvarov
    >> Cc: LNG ODP Mailman List
>> Subject: Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU
>> frequency API clean up
>>
>> On 18 September 2015 at 18:20, Maxim Uvarov
<maxim.uva...@linaro.org <mailto:maxim.uva...@linaro.org>>
>> wrote:
>> > Hello Hongbo,
>> >
>> > can you please update patch series for top of api-next?
>> >
>> > Check arm compilation:
>> >
>> > odp_system_info.c:193:41: error: unused parameter 'id'
>> > [-Werror=unused-parameter]
>> >  static uint64_t arch_cpu_hz_current(int id)
>> >
>> >
>> > And x86 with all tests turned on:
>> > ./configure  --enable-test-vald --enable-test-perf
--enable-test-cpp
>> > --enable-debug CFLAGS="-O0 -g" --enable-debug
--enable-debug-print
>> >
>> > odp_scheduling.c:749:2: error: implicit declaration of function
>> > ‘odp_sys_cpu_hz’ [-Werror=implicit-function-declaration]
>> >
>> > Thanks,
>> > Maxim.
>> >
>> >
>> Maxim,
>> I have so many such errors in other codes even without my patches.
>> I know the errors show up due to that they are originally
warnings but
>> are now treated as errors for strict code checking, I had to use
>> "-Wno-error" parameter for configure to eliminate such errors
to pass
>> compiling.
>>
>> I'am curious, don't you have such compiling errors? if you
don't, how
>> can you achieve that? I am using a old Ubuntu 12.04, but it
seems not
>> a reason.
>>
>> >
>> > On 09/17/15 16:50, Savolainen, Petri (Nokia - FI/Espoo) wrote:
>> >>
>> >> Reviewed-by: Petri Savolainen <petri.savolai...@nokia.com
<mailto:petri.savolai...@nokia.com>>
>> >>
>> >>
>> >>> -Original Message-
>> >>> From: EXT hongbo.zh...@freescale.com
<mailto:hongbo.zh...@freescale.com>
>> >>> [mailto:hongbo.zh...@freescale.com
<mailto:hongbo.zh...@freescale.com>]
>> >>> Sent: Thursday, September 17, 2015 4:10 PM
>> >>> To: lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org>
>> >>> Cc: mike.hol...@linaro.org <mailto:mike.hol...@linaro.org>;
stuart.has...@arm.com <mailto:stuart.has...@arm.com>; Savolainen,
>> Petri
>> >>> (Nokia - FI/Espoo); petri.savolai...@linaro.org
<mailto:petri.savolai...@linaro.org>;
>> >>> ivan.khoronz...@linaro.org
<mailto:ivan.khoronz...@linaro.org>; Hongbo Zhang
>> >>> Subject: [API NEXT PATCH v6 00/14] api: sysinfo: CPU
frequency API
>> >>> clean up
>> >>>
>> >>> From: Hongbo Zhang <hongbo.zh...@linaro.org
<mailto:hongbo.zh

Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-26 Thread Mike Holmes
Hongbo,

Try the exact CI docker environment which is  linked at the bottom of
http://www.opendataplane.org/testing/
It has to pass clean there with the check-odp scripts to be acceptable.

Let me know if the docs are not good enough.

On 26 September 2015 at 00:35, Hongbo Zhang <hongbo.zh...@linaro.org> wrote:

> Yes, I see.
>
> I don't like to introduce warnings/errors by my patch, But there are
> already such errors even _without_ my patch, so I had to use
> "-Wno-error" option to compile. Just curious if you have such errors
> too and how can you compile it.
>
>
> On 26 September 2015 at 02:07, Savolainen, Petri (Nokia - FI/Espoo)
> <petri.savolai...@nokia.com> wrote:
> > Hi,
> >
> > If a function does not use some parameter it must be marker with
> ODP_UNUSED.
> >
> >
> > For example,
> >
> > int odp_cpumask_def_control(odp_cpumask_t *mask, int num ODP_UNUSED)
> > {
> >
> > ...
> >
> > }
> >
> >
> > -Petri
> >
> >
> >> -Original Message-
> >> From: lng-odp [mailto:lng-odp-boun...@lists.linaro.org] On Behalf Of
> >> EXT Hongbo Zhang
> >> Sent: Friday, September 25, 2015 2:40 AM
> >> To: Maxim Uvarov
> >> Cc: LNG ODP Mailman List
> >> Subject: Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU
> >> frequency API clean up
> >>
> >> On 18 September 2015 at 18:20, Maxim Uvarov <maxim.uva...@linaro.org>
> >> wrote:
> >> > Hello Hongbo,
> >> >
> >> > can you please update patch series for top of api-next?
> >> >
> >> > Check arm compilation:
> >> >
> >> > odp_system_info.c:193:41: error: unused parameter 'id'
> >> > [-Werror=unused-parameter]
> >> >  static uint64_t arch_cpu_hz_current(int id)
> >> >
> >> >
> >> > And x86 with all tests turned on:
> >> > ./configure  --enable-test-vald  --enable-test-perf --enable-test-cpp
> >> > --enable-debug CFLAGS="-O0 -g" --enable-debug --enable-debug-print
> >> >
> >> > odp_scheduling.c:749:2: error: implicit declaration of function
> >> > ‘odp_sys_cpu_hz’ [-Werror=implicit-function-declaration]
> >> >
> >> > Thanks,
> >> > Maxim.
> >> >
> >> >
> >> Maxim,
> >> I have so many such errors in other codes even without my patches.
> >> I know the errors show up due to that they are originally warnings but
> >> are now treated as errors for strict code checking, I had to use
> >> "-Wno-error" parameter for configure to eliminate such errors to pass
> >> compiling.
> >>
> >> I'am curious, don't you have such compiling errors? if you don't, how
> >> can you achieve that? I am using a old Ubuntu 12.04, but it seems not
> >> a reason.
> >>
> >> >
> >> > On 09/17/15 16:50, Savolainen, Petri (Nokia - FI/Espoo) wrote:
> >> >>
> >> >> Reviewed-by: Petri Savolainen <petri.savolai...@nokia.com>
> >> >>
> >> >>
> >> >>> -Original Message-
> >> >>> From: EXT hongbo.zh...@freescale.com
> >> >>> [mailto:hongbo.zh...@freescale.com]
> >> >>> Sent: Thursday, September 17, 2015 4:10 PM
> >> >>> To: lng-odp@lists.linaro.org
> >> >>> Cc: mike.hol...@linaro.org; stuart.has...@arm.com; Savolainen,
> >> Petri
> >> >>> (Nokia - FI/Espoo); petri.savolai...@linaro.org;
> >> >>> ivan.khoronz...@linaro.org; Hongbo Zhang
> >> >>> Subject: [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API
> >> >>> clean up
> >> >>>
> >> >>> From: Hongbo Zhang <hongbo.zh...@linaro.org>
> >> >>>
> >> >>> v5 -> v6 changes:
> >> >>> - update tag in title to be more accurate
> >> >>> - merge patches in case of compile error, eg changing apis and
> >> updating
> >> >>> calling function come in one patch
> >> >>>
> >> >>> v4 -> v5 changes:
> >> >>> - most obvious change is split some patches into even smaller
> >> patches
> >> >>> and re-arange the sequency for convenience of review
> >> >>> - change odp_cpu_id_*() to odp_cpu_*_id()
> >> >>>
> >> >>> v3 -> v4 changes:
> >> >>> - reb

Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-25 Thread Hongbo Zhang
Yes, I see.

I don't like to introduce warnings/errors by my patch, But there are
already such errors even _without_ my patch, so I had to use
"-Wno-error" option to compile. Just curious if you have such errors
too and how can you compile it.


On 26 September 2015 at 02:07, Savolainen, Petri (Nokia - FI/Espoo)
<petri.savolai...@nokia.com> wrote:
> Hi,
>
> If a function does not use some parameter it must be marker with ODP_UNUSED.
>
>
> For example,
>
> int odp_cpumask_def_control(odp_cpumask_t *mask, int num ODP_UNUSED)
> {
>
> ...
>
> }
>
>
> -Petri
>
>
>> -Original Message-
>> From: lng-odp [mailto:lng-odp-boun...@lists.linaro.org] On Behalf Of
>> EXT Hongbo Zhang
>> Sent: Friday, September 25, 2015 2:40 AM
>> To: Maxim Uvarov
>> Cc: LNG ODP Mailman List
>> Subject: Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU
>> frequency API clean up
>>
>> On 18 September 2015 at 18:20, Maxim Uvarov <maxim.uva...@linaro.org>
>> wrote:
>> > Hello Hongbo,
>> >
>> > can you please update patch series for top of api-next?
>> >
>> > Check arm compilation:
>> >
>> > odp_system_info.c:193:41: error: unused parameter 'id'
>> > [-Werror=unused-parameter]
>> >  static uint64_t arch_cpu_hz_current(int id)
>> >
>> >
>> > And x86 with all tests turned on:
>> > ./configure  --enable-test-vald  --enable-test-perf --enable-test-cpp
>> > --enable-debug CFLAGS="-O0 -g" --enable-debug --enable-debug-print
>> >
>> > odp_scheduling.c:749:2: error: implicit declaration of function
>> > ‘odp_sys_cpu_hz’ [-Werror=implicit-function-declaration]
>> >
>> > Thanks,
>> > Maxim.
>> >
>> >
>> Maxim,
>> I have so many such errors in other codes even without my patches.
>> I know the errors show up due to that they are originally warnings but
>> are now treated as errors for strict code checking, I had to use
>> "-Wno-error" parameter for configure to eliminate such errors to pass
>> compiling.
>>
>> I'am curious, don't you have such compiling errors? if you don't, how
>> can you achieve that? I am using a old Ubuntu 12.04, but it seems not
>> a reason.
>>
>> >
>> > On 09/17/15 16:50, Savolainen, Petri (Nokia - FI/Espoo) wrote:
>> >>
>> >> Reviewed-by: Petri Savolainen <petri.savolai...@nokia.com>
>> >>
>> >>
>> >>> -Original Message-
>> >>> From: EXT hongbo.zh...@freescale.com
>> >>> [mailto:hongbo.zh...@freescale.com]
>> >>> Sent: Thursday, September 17, 2015 4:10 PM
>> >>> To: lng-odp@lists.linaro.org
>> >>> Cc: mike.hol...@linaro.org; stuart.has...@arm.com; Savolainen,
>> Petri
>> >>> (Nokia - FI/Espoo); petri.savolai...@linaro.org;
>> >>> ivan.khoronz...@linaro.org; Hongbo Zhang
>> >>> Subject: [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API
>> >>> clean up
>> >>>
>> >>> From: Hongbo Zhang <hongbo.zh...@linaro.org>
>> >>>
>> >>> v5 -> v6 changes:
>> >>> - update tag in title to be more accurate
>> >>> - merge patches in case of compile error, eg changing apis and
>> updating
>> >>> calling function come in one patch
>> >>>
>> >>> v4 -> v5 changes:
>> >>> - most obvious change is split some patches into even smaller
>> patches
>> >>> and re-arange the sequency for convenience of review
>> >>> - change odp_cpu_id_*() to odp_cpu_*_id()
>> >>>
>> >>> v3 -> v4 changes:
>> >>> - rebase to latest odp version
>> >>> - add odp_cpumask_available() to iterate each cpu
>> >>>
>> >>> v2 -> v3 changes:
>> >>> - move all CPU related API declaration into cpu.h
>> >>> - refine tests for per-CPU APIs
>> >>> - revise API for getting current frequency
>> >>>
>> >>> v1 -> v2 changes:
>> >>> - separate original 1/3 patch to two
>> >>> - add validation patch to test new APIs
>> >>> - other minor updates upon review comments
>> >>>
>> >>> v1 notes:
>> >>> The current API of getting CPU frequency is really ambiguous.
>> >>> CPU has its max frequency, and if enabled, the current frequency
>> may be
>>

Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-25 Thread Savolainen, Petri (Nokia - FI/Espoo)
Hi,

If a function does not use some parameter it must be marker with ODP_UNUSED.


For example,

int odp_cpumask_def_control(odp_cpumask_t *mask, int num ODP_UNUSED)
{

...

}


-Petri


> -Original Message-
> From: lng-odp [mailto:lng-odp-boun...@lists.linaro.org] On Behalf Of
> EXT Hongbo Zhang
> Sent: Friday, September 25, 2015 2:40 AM
> To: Maxim Uvarov
> Cc: LNG ODP Mailman List
> Subject: Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU
> frequency API clean up
> 
> On 18 September 2015 at 18:20, Maxim Uvarov <maxim.uva...@linaro.org>
> wrote:
> > Hello Hongbo,
> >
> > can you please update patch series for top of api-next?
> >
> > Check arm compilation:
> >
> > odp_system_info.c:193:41: error: unused parameter 'id'
> > [-Werror=unused-parameter]
> >  static uint64_t arch_cpu_hz_current(int id)
> >
> >
> > And x86 with all tests turned on:
> > ./configure  --enable-test-vald  --enable-test-perf --enable-test-cpp
> > --enable-debug CFLAGS="-O0 -g" --enable-debug --enable-debug-print
> >
> > odp_scheduling.c:749:2: error: implicit declaration of function
> > ‘odp_sys_cpu_hz’ [-Werror=implicit-function-declaration]
> >
> > Thanks,
> > Maxim.
> >
> >
> Maxim,
> I have so many such errors in other codes even without my patches.
> I know the errors show up due to that they are originally warnings but
> are now treated as errors for strict code checking, I had to use
> "-Wno-error" parameter for configure to eliminate such errors to pass
> compiling.
> 
> I'am curious, don't you have such compiling errors? if you don't, how
> can you achieve that? I am using a old Ubuntu 12.04, but it seems not
> a reason.
> 
> >
> > On 09/17/15 16:50, Savolainen, Petri (Nokia - FI/Espoo) wrote:
> >>
> >> Reviewed-by: Petri Savolainen <petri.savolai...@nokia.com>
> >>
> >>
> >>> -Original Message-
> >>> From: EXT hongbo.zh...@freescale.com
> >>> [mailto:hongbo.zh...@freescale.com]
> >>> Sent: Thursday, September 17, 2015 4:10 PM
> >>> To: lng-odp@lists.linaro.org
> >>> Cc: mike.hol...@linaro.org; stuart.has...@arm.com; Savolainen,
> Petri
> >>> (Nokia - FI/Espoo); petri.savolai...@linaro.org;
> >>> ivan.khoronz...@linaro.org; Hongbo Zhang
> >>> Subject: [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API
> >>> clean up
> >>>
> >>> From: Hongbo Zhang <hongbo.zh...@linaro.org>
> >>>
> >>> v5 -> v6 changes:
> >>> - update tag in title to be more accurate
> >>> - merge patches in case of compile error, eg changing apis and
> updating
> >>> calling function come in one patch
> >>>
> >>> v4 -> v5 changes:
> >>> - most obvious change is split some patches into even smaller
> patches
> >>> and re-arange the sequency for convenience of review
> >>> - change odp_cpu_id_*() to odp_cpu_*_id()
> >>>
> >>> v3 -> v4 changes:
> >>> - rebase to latest odp version
> >>> - add odp_cpumask_available() to iterate each cpu
> >>>
> >>> v2 -> v3 changes:
> >>> - move all CPU related API declaration into cpu.h
> >>> - refine tests for per-CPU APIs
> >>> - revise API for getting current frequency
> >>>
> >>> v1 -> v2 changes:
> >>> - separate original 1/3 patch to two
> >>> - add validation patch to test new APIs
> >>> - other minor updates upon review comments
> >>>
> >>> v1 notes:
> >>> The current API of getting CPU frequency is really ambiguous.
> >>> CPU has its max frequency, and if enabled, the current frequency
> may be
> >>> scaled from time to time, what's more, on some AMP platforms, cores
> are
> >>> heterogenous, they have different max and current frequencies.
> >>>
> >>> This patch set cleans up these above issues.
> >>> Patch 1/3 makes cpu_hz and model_str to be per-CPU data, then on
> AMP
> >>> system, it is possible to acquire data for each different CPU.
> >>> Patch 2/3 makes it clear that the cpu_hz stands for max CPU
> frequency
> >>> Patch 3/3 adds new API to get the current CPU frequency if needed.
> >>>
> >>> Due to lack of test platform, only x86 platform is implemented
> right
> >>> now,
> >>> the others should follow up if this patch set is accepted.
> &g

Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-24 Thread Hongbo Zhang
On 18 September 2015 at 18:20, Maxim Uvarov  wrote:
> Hello Hongbo,
>
> can you please update patch series for top of api-next?
>
> Check arm compilation:
>
> odp_system_info.c:193:41: error: unused parameter 'id'
> [-Werror=unused-parameter]
>  static uint64_t arch_cpu_hz_current(int id)
>
>
> And x86 with all tests turned on:
> ./configure  --enable-test-vald  --enable-test-perf --enable-test-cpp
> --enable-debug CFLAGS="-O0 -g" --enable-debug --enable-debug-print
>
> odp_scheduling.c:749:2: error: implicit declaration of function
> ‘odp_sys_cpu_hz’ [-Werror=implicit-function-declaration]
>
> Thanks,
> Maxim.
>
>
Maxim,
I have so many such errors in other codes even without my patches.
I know the errors show up due to that they are originally warnings but
are now treated as errors for strict code checking, I had to use
"-Wno-error" parameter for configure to eliminate such errors to pass
compiling.

I'am curious, don't you have such compiling errors? if you don't, how
can you achieve that? I am using a old Ubuntu 12.04, but it seems not
a reason.

>
> On 09/17/15 16:50, Savolainen, Petri (Nokia - FI/Espoo) wrote:
>>
>> Reviewed-by: Petri Savolainen 
>>
>>
>>> -Original Message-
>>> From: EXT hongbo.zh...@freescale.com
>>> [mailto:hongbo.zh...@freescale.com]
>>> Sent: Thursday, September 17, 2015 4:10 PM
>>> To: lng-odp@lists.linaro.org
>>> Cc: mike.hol...@linaro.org; stuart.has...@arm.com; Savolainen, Petri
>>> (Nokia - FI/Espoo); petri.savolai...@linaro.org;
>>> ivan.khoronz...@linaro.org; Hongbo Zhang
>>> Subject: [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API
>>> clean up
>>>
>>> From: Hongbo Zhang 
>>>
>>> v5 -> v6 changes:
>>> - update tag in title to be more accurate
>>> - merge patches in case of compile error, eg changing apis and updating
>>> calling function come in one patch
>>>
>>> v4 -> v5 changes:
>>> - most obvious change is split some patches into even smaller patches
>>> and re-arange the sequency for convenience of review
>>> - change odp_cpu_id_*() to odp_cpu_*_id()
>>>
>>> v3 -> v4 changes:
>>> - rebase to latest odp version
>>> - add odp_cpumask_available() to iterate each cpu
>>>
>>> v2 -> v3 changes:
>>> - move all CPU related API declaration into cpu.h
>>> - refine tests for per-CPU APIs
>>> - revise API for getting current frequency
>>>
>>> v1 -> v2 changes:
>>> - separate original 1/3 patch to two
>>> - add validation patch to test new APIs
>>> - other minor updates upon review comments
>>>
>>> v1 notes:
>>> The current API of getting CPU frequency is really ambiguous.
>>> CPU has its max frequency, and if enabled, the current frequency may be
>>> scaled from time to time, what's more, on some AMP platforms, cores are
>>> heterogenous, they have different max and current frequencies.
>>>
>>> This patch set cleans up these above issues.
>>> Patch 1/3 makes cpu_hz and model_str to be per-CPU data, then on AMP
>>> system, it is possible to acquire data for each different CPU.
>>> Patch 2/3 makes it clear that the cpu_hz stands for max CPU frequency
>>> Patch 3/3 adds new API to get the current CPU frequency if needed.
>>>
>>> Due to lack of test platform, only x86 platform is implemented right
>>> now,
>>> the others should follow up if this patch set is accepted.
>>>
>>> Hongbo Zhang (14):
>>>linux-generic: sysinfo: make the model_str per-CPU data
>>>linux-generic: sysinfo: make the cpu_hz per-CPU data
>>>api: sysinfo: move CPU model API to cpu.h
>>>api: sysinfo: move CPU Hz API to cpu.h
>>>api: cpu: add new API to get per-CPU model string
>>>api: cpu: add new API to get CPU max frequency
>>>api: cpu: add new API to get per-CPU max frequency
>>>linux-generic: sysinfo: revise odp_cpu_hz() to return current
>>>  frequency
>>>api: cpu: add new API to get per-CPU current frequency
>>>api: cpumask: add new API odp_cpumask_all_available()
>>>validation: system: add validation for new CPU APIs
>>>example: update CPU Hz calling functions
>>>linux-generic: update CPU Hz calling functions
>>>test: update CPU Hz calling functions
>>>
>>>   example/classifier/odp_classifier.c|   4 +-
>>>   example/generator/odp_generator.c  |   2 +-
>>>   example/ipsec/odp_ipsec.c  |   2 +-
>>>   example/packet/odp_pktio.c |   2 +-
>>>   example/timer/odp_timer_test.c |   6 +-
>>>   include/odp/api/cpu.h  |  60 +
>>>   include/odp/api/cpumask.h  |  10 ++
>>>   include/odp/api/system_info.h  |  14 ---
>>>   .../linux-generic/arch/linux/odp_time_cycles.c |   2 +-
>>>   platform/linux-generic/include/odp_internal.h  |   6 +-
>>>   platform/linux-generic/odp_cpumask_task.c  |  11 ++
>>>   platform/linux-generic/odp_system_info.c   | 136
>>> 

Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-18 Thread Maxim Uvarov

Hello Hongbo,

can you please update patch series for top of api-next?

Check arm compilation:

odp_system_info.c:193:41: error: unused parameter 'id' 
[-Werror=unused-parameter]

 static uint64_t arch_cpu_hz_current(int id)


And x86 with all tests turned on:
./configure  --enable-test-vald  --enable-test-perf --enable-test-cpp  
--enable-debug CFLAGS="-O0 -g" --enable-debug --enable-debug-print


odp_scheduling.c:749:2: error: implicit declaration of function 
‘odp_sys_cpu_hz’ [-Werror=implicit-function-declaration]


Thanks,
Maxim.


On 09/17/15 16:50, Savolainen, Petri (Nokia - FI/Espoo) wrote:

Reviewed-by: Petri Savolainen 



-Original Message-
From: EXT hongbo.zh...@freescale.com
[mailto:hongbo.zh...@freescale.com]
Sent: Thursday, September 17, 2015 4:10 PM
To: lng-odp@lists.linaro.org
Cc: mike.hol...@linaro.org; stuart.has...@arm.com; Savolainen, Petri
(Nokia - FI/Espoo); petri.savolai...@linaro.org;
ivan.khoronz...@linaro.org; Hongbo Zhang
Subject: [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API
clean up

From: Hongbo Zhang 

v5 -> v6 changes:
- update tag in title to be more accurate
- merge patches in case of compile error, eg changing apis and updating
calling function come in one patch

v4 -> v5 changes:
- most obvious change is split some patches into even smaller patches
and re-arange the sequency for convenience of review
- change odp_cpu_id_*() to odp_cpu_*_id()

v3 -> v4 changes:
- rebase to latest odp version
- add odp_cpumask_available() to iterate each cpu

v2 -> v3 changes:
- move all CPU related API declaration into cpu.h
- refine tests for per-CPU APIs
- revise API for getting current frequency

v1 -> v2 changes:
- separate original 1/3 patch to two
- add validation patch to test new APIs
- other minor updates upon review comments

v1 notes:
The current API of getting CPU frequency is really ambiguous.
CPU has its max frequency, and if enabled, the current frequency may be
scaled from time to time, what's more, on some AMP platforms, cores are
heterogenous, they have different max and current frequencies.

This patch set cleans up these above issues.
Patch 1/3 makes cpu_hz and model_str to be per-CPU data, then on AMP
system, it is possible to acquire data for each different CPU.
Patch 2/3 makes it clear that the cpu_hz stands for max CPU frequency
Patch 3/3 adds new API to get the current CPU frequency if needed.

Due to lack of test platform, only x86 platform is implemented right
now,
the others should follow up if this patch set is accepted.

Hongbo Zhang (14):
   linux-generic: sysinfo: make the model_str per-CPU data
   linux-generic: sysinfo: make the cpu_hz per-CPU data
   api: sysinfo: move CPU model API to cpu.h
   api: sysinfo: move CPU Hz API to cpu.h
   api: cpu: add new API to get per-CPU model string
   api: cpu: add new API to get CPU max frequency
   api: cpu: add new API to get per-CPU max frequency
   linux-generic: sysinfo: revise odp_cpu_hz() to return current
 frequency
   api: cpu: add new API to get per-CPU current frequency
   api: cpumask: add new API odp_cpumask_all_available()
   validation: system: add validation for new CPU APIs
   example: update CPU Hz calling functions
   linux-generic: update CPU Hz calling functions
   test: update CPU Hz calling functions

  example/classifier/odp_classifier.c|   4 +-
  example/generator/odp_generator.c  |   2 +-
  example/ipsec/odp_ipsec.c  |   2 +-
  example/packet/odp_pktio.c |   2 +-
  example/timer/odp_timer_test.c |   6 +-
  include/odp/api/cpu.h  |  60 +
  include/odp/api/cpumask.h  |  10 ++
  include/odp/api/system_info.h  |  14 ---
  .../linux-generic/arch/linux/odp_time_cycles.c |   2 +-
  platform/linux-generic/include/odp_internal.h  |   6 +-
  platform/linux-generic/odp_cpumask_task.c  |  11 ++
  platform/linux-generic/odp_system_info.c   | 136
-
  platform/linux-generic/odp_time.c  |   4 +-
  test/api_test/odp_common.c |   4 +-
  test/performance/odp_atomic.c  |   4 +-
  test/performance/odp_l2fwd.c   |   2 +-
  test/performance/odp_scheduling.c  |   4 +-
  test/validation/system/system.c|  74 ++-
  test/validation/system/system.h|   8 +-
  19 files changed, 281 insertions(+), 74 deletions(-)

--
1.9.1

___
lng-odp mailing list
lng-odp@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/lng-odp


___
lng-odp mailing list
lng-odp@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/lng-odp


Re: [lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-17 Thread Savolainen, Petri (Nokia - FI/Espoo)
Reviewed-by: Petri Savolainen 


> -Original Message-
> From: EXT hongbo.zh...@freescale.com
> [mailto:hongbo.zh...@freescale.com]
> Sent: Thursday, September 17, 2015 4:10 PM
> To: lng-odp@lists.linaro.org
> Cc: mike.hol...@linaro.org; stuart.has...@arm.com; Savolainen, Petri
> (Nokia - FI/Espoo); petri.savolai...@linaro.org;
> ivan.khoronz...@linaro.org; Hongbo Zhang
> Subject: [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API
> clean up
> 
> From: Hongbo Zhang 
> 
> v5 -> v6 changes:
> - update tag in title to be more accurate
> - merge patches in case of compile error, eg changing apis and updating
> calling function come in one patch
> 
> v4 -> v5 changes:
> - most obvious change is split some patches into even smaller patches
> and re-arange the sequency for convenience of review
> - change odp_cpu_id_*() to odp_cpu_*_id()
> 
> v3 -> v4 changes:
> - rebase to latest odp version
> - add odp_cpumask_available() to iterate each cpu
> 
> v2 -> v3 changes:
> - move all CPU related API declaration into cpu.h
> - refine tests for per-CPU APIs
> - revise API for getting current frequency
> 
> v1 -> v2 changes:
> - separate original 1/3 patch to two
> - add validation patch to test new APIs
> - other minor updates upon review comments
> 
> v1 notes:
> The current API of getting CPU frequency is really ambiguous.
> CPU has its max frequency, and if enabled, the current frequency may be
> scaled from time to time, what's more, on some AMP platforms, cores are
> heterogenous, they have different max and current frequencies.
> 
> This patch set cleans up these above issues.
> Patch 1/3 makes cpu_hz and model_str to be per-CPU data, then on AMP
> system, it is possible to acquire data for each different CPU.
> Patch 2/3 makes it clear that the cpu_hz stands for max CPU frequency
> Patch 3/3 adds new API to get the current CPU frequency if needed.
> 
> Due to lack of test platform, only x86 platform is implemented right
> now,
> the others should follow up if this patch set is accepted.
> 
> Hongbo Zhang (14):
>   linux-generic: sysinfo: make the model_str per-CPU data
>   linux-generic: sysinfo: make the cpu_hz per-CPU data
>   api: sysinfo: move CPU model API to cpu.h
>   api: sysinfo: move CPU Hz API to cpu.h
>   api: cpu: add new API to get per-CPU model string
>   api: cpu: add new API to get CPU max frequency
>   api: cpu: add new API to get per-CPU max frequency
>   linux-generic: sysinfo: revise odp_cpu_hz() to return current
> frequency
>   api: cpu: add new API to get per-CPU current frequency
>   api: cpumask: add new API odp_cpumask_all_available()
>   validation: system: add validation for new CPU APIs
>   example: update CPU Hz calling functions
>   linux-generic: update CPU Hz calling functions
>   test: update CPU Hz calling functions
> 
>  example/classifier/odp_classifier.c|   4 +-
>  example/generator/odp_generator.c  |   2 +-
>  example/ipsec/odp_ipsec.c  |   2 +-
>  example/packet/odp_pktio.c |   2 +-
>  example/timer/odp_timer_test.c |   6 +-
>  include/odp/api/cpu.h  |  60 +
>  include/odp/api/cpumask.h  |  10 ++
>  include/odp/api/system_info.h  |  14 ---
>  .../linux-generic/arch/linux/odp_time_cycles.c |   2 +-
>  platform/linux-generic/include/odp_internal.h  |   6 +-
>  platform/linux-generic/odp_cpumask_task.c  |  11 ++
>  platform/linux-generic/odp_system_info.c   | 136
> -
>  platform/linux-generic/odp_time.c  |   4 +-
>  test/api_test/odp_common.c |   4 +-
>  test/performance/odp_atomic.c  |   4 +-
>  test/performance/odp_l2fwd.c   |   2 +-
>  test/performance/odp_scheduling.c  |   4 +-
>  test/validation/system/system.c|  74 ++-
>  test/validation/system/system.h|   8 +-
>  19 files changed, 281 insertions(+), 74 deletions(-)
> 
> --
> 1.9.1

___
lng-odp mailing list
lng-odp@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/lng-odp


[lng-odp] [API NEXT PATCH v6 00/14] api: sysinfo: CPU frequency API clean up

2015-09-17 Thread hongbo.zhang
From: Hongbo Zhang 

v5 -> v6 changes:
- update tag in title to be more accurate
- merge patches in case of compile error, eg changing apis and updating
calling function come in one patch

v4 -> v5 changes:
- most obvious change is split some patches into even smaller patches
and re-arange the sequency for convenience of review
- change odp_cpu_id_*() to odp_cpu_*_id()

v3 -> v4 changes:
- rebase to latest odp version
- add odp_cpumask_available() to iterate each cpu

v2 -> v3 changes:
- move all CPU related API declaration into cpu.h
- refine tests for per-CPU APIs
- revise API for getting current frequency

v1 -> v2 changes:
- separate original 1/3 patch to two
- add validation patch to test new APIs
- other minor updates upon review comments

v1 notes:
The current API of getting CPU frequency is really ambiguous.
CPU has its max frequency, and if enabled, the current frequency may be
scaled from time to time, what's more, on some AMP platforms, cores are
heterogenous, they have different max and current frequencies.

This patch set cleans up these above issues.
Patch 1/3 makes cpu_hz and model_str to be per-CPU data, then on AMP
system, it is possible to acquire data for each different CPU.
Patch 2/3 makes it clear that the cpu_hz stands for max CPU frequency
Patch 3/3 adds new API to get the current CPU frequency if needed.

Due to lack of test platform, only x86 platform is implemented right now,
the others should follow up if this patch set is accepted.

Hongbo Zhang (14):
  linux-generic: sysinfo: make the model_str per-CPU data
  linux-generic: sysinfo: make the cpu_hz per-CPU data
  api: sysinfo: move CPU model API to cpu.h
  api: sysinfo: move CPU Hz API to cpu.h
  api: cpu: add new API to get per-CPU model string
  api: cpu: add new API to get CPU max frequency
  api: cpu: add new API to get per-CPU max frequency
  linux-generic: sysinfo: revise odp_cpu_hz() to return current
frequency
  api: cpu: add new API to get per-CPU current frequency
  api: cpumask: add new API odp_cpumask_all_available()
  validation: system: add validation for new CPU APIs
  example: update CPU Hz calling functions
  linux-generic: update CPU Hz calling functions
  test: update CPU Hz calling functions

 example/classifier/odp_classifier.c|   4 +-
 example/generator/odp_generator.c  |   2 +-
 example/ipsec/odp_ipsec.c  |   2 +-
 example/packet/odp_pktio.c |   2 +-
 example/timer/odp_timer_test.c |   6 +-
 include/odp/api/cpu.h  |  60 +
 include/odp/api/cpumask.h  |  10 ++
 include/odp/api/system_info.h  |  14 ---
 .../linux-generic/arch/linux/odp_time_cycles.c |   2 +-
 platform/linux-generic/include/odp_internal.h  |   6 +-
 platform/linux-generic/odp_cpumask_task.c  |  11 ++
 platform/linux-generic/odp_system_info.c   | 136 -
 platform/linux-generic/odp_time.c  |   4 +-
 test/api_test/odp_common.c |   4 +-
 test/performance/odp_atomic.c  |   4 +-
 test/performance/odp_l2fwd.c   |   2 +-
 test/performance/odp_scheduling.c  |   4 +-
 test/validation/system/system.c|  74 ++-
 test/validation/system/system.h|   8 +-
 19 files changed, 281 insertions(+), 74 deletions(-)

-- 
1.9.1

___
lng-odp mailing list
lng-odp@lists.linaro.org
https://lists.linaro.org/mailman/listinfo/lng-odp