From a25bcdfd09bb8d92f319c258002d4bb9c44cc40a Mon Sep 17 00:00:00 2001 From: panhengchang Date: Fri, 25 Apr 2025 19:17:25 +0800 Subject: [PATCH 1/3] add hisi traits: virtcca, kae --- 0001-add-hisi-traits-virtcca-kae.patch | 44 ++++++++++++++++++++++++++ python-os-traits.spec | 3 +- 2 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 0001-add-hisi-traits-virtcca-kae.patch diff --git a/0001-add-hisi-traits-virtcca-kae.patch b/0001-add-hisi-traits-virtcca-kae.patch new file mode 100644 index 0000000..ff5eef5 --- /dev/null +++ b/0001-add-hisi-traits-virtcca-kae.patch @@ -0,0 +1,44 @@ +From 0da6ebe5e61159b0581e1deb52d6c342f1c5e270 Mon Sep 17 00:00:00 2001 +From: panhengchang +Date: Fri, 25 Apr 2025 19:12:45 +0800 +Subject: [PATCH] add hisi traits: virtcca, kae + +--- + .../cpu/{aarch64.py => aarch64/__init__.py} | 0 + os_traits/hw/cpu/aarch64/hisi.py | 20 +++++++++++++++++++ + 2 files changed, 20 insertions(+) + rename os_traits/hw/cpu/{aarch64.py => aarch64/__init__.py} (100%) + create mode 100644 os_traits/hw/cpu/aarch64/hisi.py + +diff --git a/os_traits/hw/cpu/aarch64.py b/os_traits/hw/cpu/aarch64/__init__.py +similarity index 100% +rename from os_traits/hw/cpu/aarch64.py +rename to os_traits/hw/cpu/aarch64/__init__.py +diff --git a/os_traits/hw/cpu/aarch64/hisi.py b/os_traits/hw/cpu/aarch64/hisi.py +new file mode 100644 +index 0000000..ca46252 +--- /dev/null ++++ b/os_traits/hw/cpu/aarch64/hisi.py +@@ -0,0 +1,20 @@ ++# -*- coding: utf-8 -*- ++# Copyright 2017 Arm Limited. ++# ++# Licensed under the Apache License, Version 2.0 (the "License"); you may ++# not use this file except in compliance with the License. You may obtain ++# a copy of the License at ++# ++# http://www.apache.org/licenses/LICENSE-2.0 ++# ++# Unless required by applicable law or agreed to in writing, software ++# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT ++# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the ++# License for the specific language governing permissions and limitations ++# under the License. ++ ++ ++TRAITS = [ ++ 'VIRTCCA', ++ 'KAE', ++] +-- + diff --git a/python-os-traits.spec b/python-os-traits.spec index e2b89b0..6f1c9ad 100644 --- a/python-os-traits.spec +++ b/python-os-traits.spec @@ -6,6 +6,7 @@ Summary: A library containing standardized trait strings License: Apache-2.0 URL: https://docs.openstack.org/os-traits/latest/ Source0: https://files.pythonhosted.org/packages/12/fa/383924bdd34cf2c1ae25197cbafc0013de15789542df6f8dd9254bcc9cec/os-traits-2.5.0.tar.gz +Patch0: 0001-add-hisi-traits-virtcca-kae.patch BuildArch: noarch %description os-traits is an OpenStack library containing standardized trait strings @@ -46,7 +47,7 @@ Provides: python3-os-traits-doc os-traits is an OpenStack library containing standardized trait strings %prep -%autosetup -n os-traits-2.5.0 +%autosetup -n os-traits-2.5.0 -p1 %build %py3_build -- Gitee From 459e6d8cf95ee358d23e4b8ea19d31e64e1493fe Mon Sep 17 00:00:00 2001 From: panhengchang Date: Sun, 27 Apr 2025 10:59:29 +0800 Subject: [PATCH 2/3] add description and change log for virtcca and kae --- 0001-add-hisi-traits-virtcca-kae.patch | 6 ++++++ python-os-traits.spec | 4 +++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/0001-add-hisi-traits-virtcca-kae.patch b/0001-add-hisi-traits-virtcca-kae.patch index ff5eef5..4139687 100644 --- a/0001-add-hisi-traits-virtcca-kae.patch +++ b/0001-add-hisi-traits-virtcca-kae.patch @@ -3,6 +3,12 @@ From: panhengchang Date: Fri, 25 Apr 2025 19:12:45 +0800 Subject: [PATCH] add hisi traits: virtcca, kae +Add new cpu traits to support virtcca in openstack: +VIRTCCA: virtcca on hisi +KAE: Kunpeng Accelerator Engine on hisi + +Signed-off-by: panhengchang + --- .../cpu/{aarch64.py => aarch64/__init__.py} | 0 os_traits/hw/cpu/aarch64/hisi.py | 20 +++++++++++++++++++ diff --git a/python-os-traits.spec b/python-os-traits.spec index 6f1c9ad..2164182 100644 --- a/python-os-traits.spec +++ b/python-os-traits.spec @@ -1,7 +1,7 @@ %global _empty_manifest_terminate_build 0 Name: python-os-traits Version: 2.5.0 -Release: 1 +Release: 2 Summary: A library containing standardized trait strings License: Apache-2.0 URL: https://docs.openstack.org/os-traits/latest/ @@ -95,3 +95,5 @@ mv %{buildroot}/doclist.lst . - Add buildrequires * Wed Jan 06 2021 Python_Bot - Package Spec generated +* Sun Apr 27 2025 panhengchang +- Add hisi traits: virtcca, kae \ No newline at end of file -- Gitee From 77cfea8dee0fd89794bfa970c3c1eea0cb0b947b Mon Sep 17 00:00:00 2001 From: panhengchang Date: Mon, 28 Apr 2025 09:13:03 +0800 Subject: [PATCH 3/3] fix change log --- python-os-traits.spec | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/python-os-traits.spec b/python-os-traits.spec index 2164182..c200cb7 100644 --- a/python-os-traits.spec +++ b/python-os-traits.spec @@ -89,11 +89,11 @@ mv %{buildroot}/doclist.lst . %{_docdir}/* %changelog +* Sun Apr 27 2025 panhengchang +- Add hisi traits: virtcca, kae * Wed Jul 21 2021 OpenStack_SIG - 2.5.0-1 - Update to 2.5.0 * Fri Jan 29 2021 zhangy - Add buildrequires * Wed Jan 06 2021 Python_Bot -- Package Spec generated -* Sun Apr 27 2025 panhengchang -- Add hisi traits: virtcca, kae \ No newline at end of file +- Package Spec generated \ No newline at end of file -- Gitee