-
Notifications
You must be signed in to change notification settings - Fork 27
packagegroup-qcom-test-pkg: Add minkipc into image #119
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
c9b313e to
d704df5
Compare
|
|
||
| RDEPENDS:${PN}:append:aarch64 = " \ | ||
| fastrpc-tests \ | ||
| minkipc \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need this package? Just pull the qteesupplicant. Also, it should not be a part of the tests, it is not a test binary.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently, there are four .bb files in packagegroups dir. Can I install minkipc in the packagegroup-qcom-utilities.bb file?
Please note that minkipc currently only supports compilation for the aarch64 version
Okey, I will remove the minkipc package and only install the minkipc-qteesupplicant package.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
However, the qcom-multimedia-image only installs the packagegroup-qcom-utilities-gpu-utils target.
We're unable to include the minkipc related binaries in the image when running kas build meta-qcom/ci/qcs6490-rb3gen2-core-kit.yml:meta-qcom/ci/qcom-distro.yml.
Could you please share any suggestions? Thank you.
eb7e888 to
b859d08
Compare
|
Add minkipc-qteesupplicant in packagegroup-qcom-utilities.bb. |
| " | ||
|
|
||
| RDEPENDS:${PN}:append:aarch64 = " \ | ||
| minkipc-qteesupplicant \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is no need to append the var that was just defined. Just fix that vat instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okey, add the minkipc-qteesupplicant into the packagegroup-qcom-test-pkgs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this correct?
diff --git a/recipes-products/packagegroups/packagegroup-qcom-utilities.bb b/recipes-products/packagegroups/packagegroup-qcom-utilities.bb
index c9c781c..08bf7b9 100644
--- a/recipes-products/packagegroups/packagegroup-qcom-utilities.bb
+++ b/recipes-products/packagegroups/packagegroup-qcom-utilities.bb
@@ -77,3 +77,7 @@ RDEPENDS:${PN}-support-utils = " \
trace-cmd \
usbutils \
"
+
+RDEPENDS:${PN}:aarch64 = " \
+ minkipc-qteesupplicant \
+ "There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am sorry, your previous version (RDEPENDS:${PN}:append:aarch64 in the utils packagegroup) was correct. Add a comment that the package is arm64-only.
b859d08 to
845cbef
Compare
|
Add the |
It's not a test. Why did you move it back? |
Sorry, I cannot get your point. How can we fix the var? Is this correct? diff --git a/recipes-products/packagegroups/packagegroup-qcom-utilities.bb b/recipes-products/packagegroups/packagegroup-qcom-utilities.bb
index c9c781c..08bf7b9 100644
--- a/recipes-products/packagegroups/packagegroup-qcom-utilities.bb
+++ b/recipes-products/packagegroups/packagegroup-qcom-utilities.bb
@@ -77,3 +77,7 @@ RDEPENDS:${PN}-support-utils = " \
trace-cmd \
usbutils \
"
+
+RDEPENDS:${PN}:aarch64 = " \
+ minkipc-qteesupplicant \
+ " |
|
Hello @lumag , thank you for you time here. I agree that On QLI 1.x, when we were shipping prebuilt binaries we had a |
|
I'm fine with |
Alright @lumag, I am thinking we can introduce a new |
You don't need to add
Yes |
845cbef to
5aec8a6
Compare
I think we need to include |
|
The Error Log: |
Then qteesupplicant must depend on the minkipc package. BTW: what is the reason for dynamically opening those libraries? Are they used for anything else than QTEE supplicant? |
Yes, the MinkIPC libraries are currently used only by qtee_supplicant. The minkipc libraries cannot be installed into the RDEPENDS:${PN}:aarch64 = " \
+ minkipc \
minkipc-qteesupplicant \
" |
Hi @lumag , no the libraries aren't used by any other daemon apart from QTEE supplicant. However, we have historically had a workflow where each team owns their own listener library (say RPMB) and delivers updates/bug-fixes to the customer independently by recompiling it separately from the QTEE supplicant. We want to continue with that workflow. This enables OTA updates to be provided by the tech owning team without our own involvement. There is a minor performance penalty that we pay for that via Also, regarding your request for |
|
|
||
| RDEPENDS:${PN}:append:aarch64 = " \ | ||
| fastrpc-tests \ | ||
| minkipc-qteesupplicant \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't minkipc package also be listed here? Or just listing the subpackage is fine?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is now outdated.
| packagegroup-container \ | ||
| packagegroup-qcom-test-pkgs \ | ||
| packagegroup-qcom-utilities-gpu-utils \ | ||
| packagegroup-qcom-security \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we really need to add it here? I can see we add qcom-console-image.bb on line 1 which already adds packagegroup-qcom-security.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is required to enable minkipc on meta-qcom, as the qcom-multimedia-image is currently only included in meta-qcom/ci/qcom-distro.yml.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes but I thought the qcom-multimedia-image is a superset of qcom-console-image, with all images in console-image + additional for multimedia. Both are appending the CORE_IMAGE_BASE_INSTALL list. So I was under the assumption that just adding to console image should add it here as well. Is this not the case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that's right. The qcom-multimedia-image is a superset of qcom-console-image, and the qcom-console-image target is included on line 1 of the qcom-multimedia-image.bb file.
require qcom-console-image.bb
SUMMARY = "Basic Wayland image with Weston"
IMAGE_FEATURES += "weston"I will update it in the next version.
How does that differ if qteesupplicant is dynamically linked to the libraries instead of using dlopen?
As usual, RDEPENDS. |
I am not sure if I have a real answer to this one. It seems this choice was made with our downstream implementation long before I was around, (probably a decade ago or so) and since the same code has now been open-sourced, it continues to exist. I will try to ask around if someone has a concrete reason, but I am not aware of any at least.
Thanks my query was, where should this RDEPENDS go? In packagegroup-qcom-security? |
Hi @lumag , do you recommend adding the diff --git a/dynamic-layers/openembedded-layer/recipes-security/minkipc/minkipc_git.bb b/dynamic-layers/openembedded-layer/recipes-security/minkipc/minkipc_git.bb
index 8b29c87..8c7e222 100644
--- a/dynamic-layers/openembedded-layer/recipes-security/minkipc/minkipc_git.bb
+++ b/dynamic-layers/openembedded-layer/recipes-security/minkipc/minkipc_git.bb
@@ -33,6 +33,7 @@ FILES:${PN}-qteesupplicant = "${bindir}/qtee_supplicant \
${nonarch_libdir}/udev/rules.d/99-qcomtee-udev.rules \
"
+RDEPENDS:${PN}-qteesupplicant += " ${PN}"
# Currently, this recipe only builds and installs for ARMv8 (aarch64) machine.
COMPATIBLE_MACHINE = "^$"
COMPATIBLE_MACHINE:aarch64 = "(.*)" |
5aec8a6 to
a1c7a96
Compare
+1 I also think this is probably the right approach. |
Yes. Another possibility is, if the libraries are exclusively to be used by the qteesupplicant, move them to the qteesupplicant package. |
| packagegroup-qcom-utilities-profile-utils \ | ||
| packagegroup-qcom-utilities-support-utils \ | ||
| ${@bb.utils.contains('DISTRO_FEATURES', 'virtualization', 'packagegroup-qcom-virtualization', '', d)} \ | ||
| packagegroup-qcom-security \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Separate commit, also keep the list sorted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated, separate into two commits.
Define packagegroup-qcom-security to include MinkIPC libraries and binaries, enabling communication between QTEE (QCOM Trusted Execution Environment) and REE (Rich Execution Environment). Signed-off-by: Jiaxing Li <jiaxing.li@oss.qualcomm.com>
Add packagegroup-qcom-security to qcom-console-image to provide MinkIPC libraries and service, enabling communication between QTEE and REE. Signed-off-by: Jiaxing Li <jiaxing.li@oss.qualcomm.com>
a1c7a96 to
ff2a553
Compare
Okay, we'll make updates to the meta-qcom repo later based on the comments. |
|
Hi Maintainer, it's very strange that I have already packaged all the minkipc libraries and binaries into the For example, the jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$ find build/ -name "libtimeservice.so.1"
build/tmp/sysroots-components/armv8-2a/minkipc/usr/lib/libtimeservice.so.1
build/tmp/work/rb3gen2_core_kit-qcom-linux/qcom-multimedia-image/1.0/rootfs/usr/lib/libtimeservice.so.1
build/tmp/work/armv8-2a-qcom-linux/minkipc/0.0+git/package/usr/lib/libtimeservice.so.1
build/tmp/work/armv8-2a-qcom-linux/minkipc/0.0+git/image/usr/lib/libtimeservice.so.1
build/tmp/work/armv8-2a-qcom-linux/minkipc/0.0+git/build/listeners/libtimeservice/libtimeservice.so.1
build/tmp/work/armv8-2a-qcom-linux/minkipc/0.0+git/sysroot-destdir/usr/lib/libtimeservice.so.1
build/tmp/work/armv8-2a-qcom-linux/minkipc/0.0+git/packages-split/minkipc/usr/lib/libtimeservice.so.1
jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$
jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$ ls -al build/tmp/work/rb3gen2_core_kit-qcom-linux/qcom-multimedia-image/1.0/rootfs/usr/lib/libtimeservice.so.1
lrwxrwxrwx 1 jiaxli users 23 Mar 9 2018 build/tmp/work/rb3gen2_core_kit-qcom-linux/qcom-multimedia-image/1.0/rootfs/usr/lib/libtimeservice.so.1 -> libtimeservice.so.1.0.0*
jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$
jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$ ls -al build/tmp/work/rb3gen2_core_kit-qcom-linux/qcom-multimedia-image/1.0/rootfs/usr/lib/libtimeservice.so.1.0.0
-rwxr-xr-x 1 jiaxli users 67416 Mar 9 2018 build/tmp/work/rb3gen2_core_kit-qcom-linux/qcom-multimedia-image/1.0/rootfs/usr/lib/libtimeservice.so.1.0.0*
jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$
jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$ md5sum build/tmp/work/rb3gen2_core_kit-qcom-linux/qcom-multimedia-image/1.0/rootfs/usr/lib/libtimeservice.so.1
9a42239efe27d00689a3976ddadaeb7a build/tmp/work/rb3gen2_core_kit-qcom-linux/qcom-multimedia-image/1.0/rootfs/usr/lib/libtimeservice.so.1
jiaxli@cse-cd01-lnx:/local/mnt2/workspace/jiaxli/upstream$ md5sum build/tmp/work/armv8-2a-qcom-linux/minkipc/0.0+git/package/usr/lib/libtimeservice.so.1.0.0
9a42239efe27d00689a3976ddadaeb7a build/tmp/work/armv8-2a-qcom-linux/minkipc/0.0+git/package/usr/lib/libtimeservice.so.1.0.0But when I flashed the device, I was able to find the PS C:\Users\jiaxli> adb wait-for-device shell
root@rb3gen2-core-kit:/# qtee_supplicant
qtee_supplicant: process entry PPID = 877
Total listener services to start = 4
dlopen(libtimeservice.so.1, RLTD_NOW) failed: libtimeservice.so.1: cannot open shared object file: No such file or directory
init_listener_svc failed: 0xffffffff
Total listener services to be stopped = 4
ERROR: listeners registration failed
root@rb3gen2-core-kit:/#
root@rb3gen2-core-kit:/# find / -name "libtimeservice.so.1" |
Which package will pull in the minkipc libraries into the image? And how? |
|
With the |
| PACKAGES = "${PN}" | ||
|
|
||
| RDEPENDS:${PN}:append:aarch64 = " \ | ||
| minkipc-qteesupplicant \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Packagegroup for a single package may be an over kill. Can't minkipc-qteesupplicant be added directly to image?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vkraleti , we are planning to use this packagegroup for adding more security packages such as optee_client which supports libckteec library immediately after this PR. We would need this anyways since more packages from our team will keep arriving, hence I think it's better if we do it upfront.
Add MinkIPC libraries and binaries to the test image to facilitate communication between QTEE (Qualified Trusted Execution Environment) and REE (Rich Execution Environment).
Included components:
Reference: qualcomm-linux/meta-qcom#1094