[v2,3/3] x86: Add the test case of __get_cpu_features support for Zhaoxin processors

Message ID 1585546430-6167-4-git-send-email-MayShao@zhaoxin.com
State Committed
Headers
Series x86: Add support for Zhaoxin processors |

Commit Message

May Shao(BJ-RD) March 30, 2020, 5:33 a.m. UTC
  For the test case of the __get_cpu_features interface, add an item in
cpu_kinds and a switch case for Zhaoxin support.

---
 sysdeps/x86/tst-get-cpu-features.c | 2 ++
 1 file changed, 2 insertions(+)

--
2.7.4



保密声明:
本邮件含有保密或专有信息,仅供指定收件人使用。严禁对本邮件或其内容做任何未经授权的查阅、使用、复制或转发。
CONFIDENTIAL NOTE:
This email contains confidential or legally privileged information and is for the sole use of its intended recipient. Any unauthorized review, use, copying or forwarding of this email or the content of this email is strictly prohibited.
  

Comments

H.J. Lu April 7, 2020, 12:39 p.m. UTC | #1
On Sun, Mar 29, 2020 at 10:35 PM MayShao <MayShao@zhaoxin.com> wrote:
>
> For the test case of the __get_cpu_features interface, add an item in
> cpu_kinds and a switch case for Zhaoxin support.
>
> ---
>  sysdeps/x86/tst-get-cpu-features.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/sysdeps/x86/tst-get-cpu-features.c b/sysdeps/x86/tst-get-cpu-features.c
> index 0f55987..0dcb906 100644
> --- a/sysdeps/x86/tst-get-cpu-features.c
> +++ b/sysdeps/x86/tst-get-cpu-features.c
> @@ -38,6 +38,7 @@ static const char * const cpu_kinds[] =
>    "Unknown",
>    "Intel",
>    "AMD",
> +  "ZHAOXIN",
>    "Other",
>  };
>
> @@ -50,6 +51,7 @@ do_test (void)
>      {
>      case arch_kind_intel:
>      case arch_kind_amd:
> +    case arch_kind_zhaoxin:
>      case arch_kind_other:
>        printf ("Vendor: %s\n", cpu_kinds[cpu_features->basic.kind]);
>        printf ("Family: 0x%x\n", cpu_features->basic.family);
> --
> 2.7.4

LGTM.

BTW, have you finished your paperwork with FSF?
  
May Shao(BJ-RD) April 8, 2020, 2:36 a.m. UTC | #2
On Tue, April 7, 2020 at 8:38 PM H.J. Lu <hjl.tools@gmail.com> wrote:
>
> On Sun, Mar 29, 2020 at 10:35 PM MayShao <MayShao@zhaoxin.com> wrote:
> >
> > For the test case of the __get_cpu_features interface, add an item in
> > cpu_kinds and a switch case for Zhaoxin support.
> >
> > ---
> >  sysdeps/x86/tst-get-cpu-features.c | 2 ++
> >  1 file changed, 2 insertions(+)
> >
> > diff --git a/sysdeps/x86/tst-get-cpu-features.c
> b/sysdeps/x86/tst-get-cpu-features.c
> > index 0f55987..0dcb906 100644
> > --- a/sysdeps/x86/tst-get-cpu-features.c
> > +++ b/sysdeps/x86/tst-get-cpu-features.c
> > @@ -38,6 +38,7 @@ static const char * const cpu_kinds[] =
> >    "Unknown",
> >    "Intel",
> >    "AMD",
> > +  "ZHAOXIN",
> >    "Other",
> >  };
> >
> > @@ -50,6 +51,7 @@ do_test (void)
> >      {
> >      case arch_kind_intel:
> >      case arch_kind_amd:
> > +    case arch_kind_zhaoxin:
> >      case arch_kind_other:
> >        printf ("Vendor: %s\n", cpu_kinds[cpu_features->basic.kind]);
> >        printf ("Family: 0x%x\n", cpu_features->basic.family);
> > --
> > 2.7.4
>
> LGTM.
>
> BTW, have you finished your paperwork with FSF?

Yes, I have finished the paperwork with FSF.  If there is any problem,
please let me know.

Thanks for the review.

Best Regards,
May Shao

> --
> H.J.


保密声明:
本邮件含有保密或专有信息,仅供指定收件人使用。严禁对本邮件或其内容做任何未经授权的查阅、使用、复制或转发。
CONFIDENTIAL NOTE:
This email contains confidential or legally privileged information and is for the sole use of its intended recipient. Any unauthorized review, use, copying or forwarding of this email or the content of this email is strictly prohibited.
  
Carlos O'Donell April 8, 2020, 12:52 p.m. UTC | #3
On 4/7/20 10:36 PM, May Shao(BJ-RD) wrote:
> 
> 
> On Tue, April 7, 2020 at 8:38 PM H.J. Lu <hjl.tools@gmail.com> wrote:
>>
>> On Sun, Mar 29, 2020 at 10:35 PM MayShao <MayShao@zhaoxin.com> wrote:
>>>
>>> For the test case of the __get_cpu_features interface, add an item in
>>> cpu_kinds and a switch case for Zhaoxin support.
>>>
>>> ---
>>>  sysdeps/x86/tst-get-cpu-features.c | 2 ++
>>>  1 file changed, 2 insertions(+)
>>>
>>> diff --git a/sysdeps/x86/tst-get-cpu-features.c
>> b/sysdeps/x86/tst-get-cpu-features.c
>>> index 0f55987..0dcb906 100644
>>> --- a/sysdeps/x86/tst-get-cpu-features.c
>>> +++ b/sysdeps/x86/tst-get-cpu-features.c
>>> @@ -38,6 +38,7 @@ static const char * const cpu_kinds[] =
>>>    "Unknown",
>>>    "Intel",
>>>    "AMD",
>>> +  "ZHAOXIN",
>>>    "Other",
>>>  };
>>>
>>> @@ -50,6 +51,7 @@ do_test (void)
>>>      {
>>>      case arch_kind_intel:
>>>      case arch_kind_amd:
>>> +    case arch_kind_zhaoxin:
>>>      case arch_kind_other:
>>>        printf ("Vendor: %s\n", cpu_kinds[cpu_features->basic.kind]);
>>>        printf ("Family: 0x%x\n", cpu_features->basic.family);
>>> --
>>> 2.7.4
>>
>> LGTM.
>>
>> BTW, have you finished your paperwork with FSF?
> 
> Yes, I have finished the paperwork with FSF.  If there is any problem,
> please let me know.

I confirm that we can accept patches only from May Shao from Zhaoxin.
  

Patch

diff --git a/sysdeps/x86/tst-get-cpu-features.c b/sysdeps/x86/tst-get-cpu-features.c
index 0f55987..0dcb906 100644
--- a/sysdeps/x86/tst-get-cpu-features.c
+++ b/sysdeps/x86/tst-get-cpu-features.c
@@ -38,6 +38,7 @@  static const char * const cpu_kinds[] =
   "Unknown",
   "Intel",
   "AMD",
+  "ZHAOXIN",
   "Other",
 };

@@ -50,6 +51,7 @@  do_test (void)
     {
     case arch_kind_intel:
     case arch_kind_amd:
+    case arch_kind_zhaoxin:
     case arch_kind_other:
       printf ("Vendor: %s\n", cpu_kinds[cpu_features->basic.kind]);
       printf ("Family: 0x%x\n", cpu_features->basic.family);