pipewire: add dmaheap sysusers.d entry for OTA safety - #414
Conversation
| @@ -0,0 +1,8 @@ | |||
| # Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries. | |||
| # SPDX-License-Identifier: BSD-3-Clause-Clear | |||
There was a problem hiding this comment.
MIT or BSD-3-Clause (not Clear)
| # Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries. | ||
| # SPDX-License-Identifier: BSD-3-Clause-Clear | ||
|
|
||
| # Create the dmaheap group so PipeWire can access /dev/dma_heap/system. |
There was a problem hiding this comment.
It's not PipeWire-centric, there can be other users. Please move to systemd or any other generic recipe.
|
This is a workaround for the fact that the user and group id list in meta-qcom-distro is not static, and because of that the relevant files under /etc are not managed by OStree, and an update ends up not really reflecting the new users and groups associated with the new build. For our ostree flavor we should really use useradd-staticids with nss-alt support, similar to what we did in lmp via meta-lmp, as with that we get a static and ostree-managed user and group list. As a workaround, we could have this under a more generic recipe, which would take care of adding any other user that might be reflected in 2.0. |
245dd0b to
adc444f
Compare
|
Updated the PR based on review feedback. |
|
Missing DCO tag |
Dmitry Baryshkov (lumag)
left a comment
There was a problem hiding this comment.
Missing DCO. Also, does this work together with the existing groups created via GROUPADD?
adc444f to
0cd0461
Compare
Regarding GROUPADD_PARAM compatibility: Both works together without conflict. GROUPADD_PARAM runs only once at image build time and does not run during OTA updates. systemd-sysusers is safe to run multiple times, it checks if dmaheap group already exists before creating it, so no duplicates or conflicts. On fresh flash it skips (group already exists), post-OTA it creates the group on first boot. |
| @@ -0,0 +1,12 @@ | |||
| # SPDX-License-Identifier: BSD-3-Clause | |||
There was a problem hiding this comment.
Remove this SPDX line, no need, this is a bbappend.
| @@ -0,0 +1,7 @@ | |||
| # Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries. | |||
| # SPDX-License-Identifier: BSD-3-Clause | |||
|
|
|||
There was a problem hiding this comment.
I would also say that we don't really need copyright / license for this single file (one liner), but ok to keep.
The dmaheap group is required by pipewire.service.d/dmaheap.conf (SupplementaryGroups=dmaheap). Previously it was only created via GROUPADD_PARAM at image build time which does not survive OSTree OTA updates. Add a sysusers.d entry so systemd-sysusers creates the group declaratively on every boot, making it OTA-safe. The dmaheap group is not PipeWire-specific (other components like weston also use it), so it belongs in a generic recipe rather than a component-specific one. CR-Id: 4591795 Signed-off-by: Tejas Vijay Kanfade <tkanfade@qti.qualcomm.com>
0cd0461 to
96a4bcd
Compare
ae115f9
into
qualcomm-linux:main
|
Successfully created backport PR for |
The dmaheap group is required by pipewire.service.d/dmaheap.conf (SupplementaryGroups=dmaheap). Previously it was only created via GROUPADD_PARAM at image build time which does not survive OSTree OTA updates. Add a sysusers.d entry alongside the existing dmaheap drop-in so systemd-sysusers creates the group declaratively on every boot from /usr, making it OTA-safe.
Fixes: wpctl status returning Could not connect to PipeWire post OTA (1.9 to 2.0) on QCS9075 RB3 Config-2.
CR-Id: 4591795