media:phytium:update phytium media function update to 6.6.0.4#1681
media:phytium:update phytium media function update to 6.6.0.4#1681wangchenlu2236 wants to merge 3 commits into
Conversation
…are present maillist inclusion category: bugfix The DATA-packet handler in rxrpc_input_call_event() and the RESPONSE handler in rxrpc_verify_response() copy the skb to a linear one before calling into the security ops only when skb_cloned() is true. An skb that is not cloned but still carries externally-owned paged fragments (e.g. SKBFL_SHARED_FRAG set by splice() into a UDP socket via __ip_append_data, or a chained skb_has_frag_list()) falls through to the in-place decryption path, which binds the frag pages directly into the AEAD/skcipher SGL via skb_to_sgvec(). Extend the gate to also unshare when skb_has_frag_list() or skb_has_shared_frag() is true. This catches the splice-loopback vector and other externally-shared frag sources while preserving the zero-copy fast path for skbs whose frags are kernel-private (e.g. NIC page_pool RX, GRO). The OOM/trace handling already in place is reused. Fixes: d0d5c0c ("rxrpc: Use skb_unshare() rather than skb_cow_data()") Cc: stable@vger.kernel.org Signed-off-by: Wang Chenlu <wangchenlu2236@phytium.com.cn> Signed-off-by: Hyunwoo Kim <imv4bel@gmail.com> Signed-off-by: Wentao Guan <guanwentao@uniontech.com>
Signed-off-by:Wang Chenlu <wangchenlu2236@phytium.com.cn>
Signed-off-by:Wang Chenlu <wangchenlu2236@phytium.com.cn>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hi @wangchenlu2236. Thanks for your PR. 😃 |
Reviewer's GuideUpdates the Phytium JPEG media controller driver to refine KVM "No Signal" handling and host power state detection via a reserved buffer index register, reduces resolution-change latency, tracks host power-off transitions, and tightens rxrpc skb sharing checks for in-place decryption, along with minor cleanup and initialization changes. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
|
Hi @wangchenlu2236. Thanks for your PR. I'm waiting for a deepin-community member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
There was a problem hiding this comment.
Hey - I've left some high level feedback:
- The host power/signal markers (HAVE_SIGNAL, HOST_POWER_ON, HOST_POWER_OFF) and use of VB_BUF_LAST as a status slot are fairly implicit; consider wrapping access to BUF_LIST_INDEX_ADDR(VB_BUF_LAST) in small helper functions and/or an enum to make the state machine easier to understand and harder to misuse.
- The
once_poweroffflag is written in several paths but its lifetime and concurrency model are not obvious; consider adding a short comment near the field definition or centralizing its reset/transition logic so it’s clear under which conditions it toggles and how it interacts with resolution changes. - It looks like
build.logandtatuswere added accidentally to the tree; these should be removed from the commit to avoid tracking build artifacts or temporary files.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- The host power/signal markers (HAVE_SIGNAL, HOST_POWER_ON, HOST_POWER_OFF) and use of VB_BUF_LAST as a status slot are fairly implicit; consider wrapping access to BUF_LIST_INDEX_ADDR(VB_BUF_LAST) in small helper functions and/or an enum to make the state machine easier to understand and harder to misuse.
- The `once_poweroff` flag is written in several paths but its lifetime and concurrency model are not obvious; consider adding a short comment near the field definition or centralizing its reset/transition logic so it’s clear under which conditions it toggles and how it interacts with resolution changes.
- It looks like `build.log` and `tatus` were added accidentally to the tree; these should be removed from the commit to avoid tracking build artifacts or temporary files.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
| *** | ||
| /home/user/deepin-kernel/Makefile:775: include/config/auto.conf.cmd: 没有那个文件或目录 | ||
| make[1]: *** [/home/user/deepin-kernel/Makefile:784:.config] 错误 1 | ||
| make: *** [Makefile:234:__sub-make] 错误 2 |
| Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | ||
|
|
||
| net/rxrpc/call_event.c | 4 [32m+++[m[31m-[m | ||
| 1 file changed, 3 insertions(+), 1 deletion(-) |
There was a problem hiding this comment.
Pull request overview
This PR updates the Phytium JPEG media driver’s signal/power handling and resolution-switch timing, and adjusts RxRPC packet handling to avoid in-place crypto operations on skbs that may share fragment storage.
Changes:
- RxRPC: unshare/copy DATA and RESPONSE packets not only when
skb_cloned(), but also whenskb_has_frag_list()orskb_has_shared_frag(). - Phytium JPEG: reduce resolution-change delay, expand destination buffer bookkeeping, and add host-power/signal tracking via a reserved buffer-list index.
- Add a platform dependency in the Phytium media Kconfig (currently referencing a missing symbol in this tree).
Reviewed changes
Copilot reviewed 6 out of 7 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
net/rxrpc/call_event.c |
Extends the conditions that trigger copying/unsharing before in-place decryption of DATA packets. |
net/rxrpc/conn_event.c |
Extends the conditions that trigger copying/unsharing before verifying/decrypting RESPONSE packets. |
drivers/media/platform/phytium/phytium_jpeg_core.h |
Adjusts timing constants and introduces new signal/power markers and buffer index constants. |
drivers/media/platform/phytium/phytium_jpeg_core.c |
Implements revised no-signal/host-power logic and reduces resolution-switch latency. |
drivers/media/platform/phytium/Kconfig |
Adds an architecture dependency for the driver (currently uses an undefined symbol here). |
tatus |
Adds a repository artifact (appears to be pasted VCS output; should not be in-tree). |
build.log |
Adds a local build artifact (should not be in-tree). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| tristate "Phytium JPEG Encoder Engine driver" | ||
| depends on V4L_PLATFORM_DRIVERS | ||
| depends on VIDEO_DEV | ||
| depends on ARCH_PHYTIUM |
| [33mcommit 02ced38ea255f262806c92e557bddc5e17a71410[m[33m ([m[1;36mHEAD[m[33m -> [m[1;32mmedia-6.6.y[m[33m, [m[1;31morigin/linux-6.6.y[m[33m, [m[1;31morigin/HEAD[m[33m, [m[1;32mlinux-6.6.y[m[33m)[m | ||
| Author: Hyunwoo Kim <imv4bel@gmail.com> | ||
| Date: Fri May 8 17:53:09 2026 +0900 | ||
|
|
||
| FROMLIST: rxrpc: Also unshare DATA/RESPONSE packets when paged frags are present | ||
|
|
||
| maillist inclusion | ||
| category: bugfix | ||
|
|
||
| The DATA-packet handler in rxrpc_input_call_event() and the RESPONSE | ||
| handler in rxrpc_verify_response() copy the skb to a linear one before | ||
| calling into the security ops only when skb_cloned() is true. An skb | ||
| that is not cloned but still carries externally-owned paged fragments | ||
| (e.g. SKBFL_SHARED_FRAG set by splice() into a UDP socket via | ||
| __ip_append_data, or a chained skb_has_frag_list()) falls through to | ||
| the in-place decryption path, which binds the frag pages directly into | ||
| the AEAD/skcipher SGL via skb_to_sgvec(). | ||
|
|
||
| Extend the gate to also unshare when skb_has_frag_list() or | ||
| skb_has_shared_frag() is true. This catches the splice-loopback vector | ||
| and other externally-shared frag sources while preserving the | ||
| zero-copy fast path for skbs whose frags are kernel-private (e.g. NIC | ||
| page_pool RX, GRO). The OOM/trace handling already in place is reused. | ||
|
|
||
| Fixes: d0d5c0cd1e71 ("rxrpc: Use skb_unshare() rather than skb_cow_data()") | ||
| Cc: stable@vger.kernel.org | ||
| Signed-off-by: Hyunwoo Kim <imv4bel@gmail.com> | ||
| Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | ||
|
|
||
| net/rxrpc/call_event.c | 4 [32m+++[m[31m-[m | ||
| net/rxrpc/conn_event.c | 3 [32m++[m[31m-[m | ||
| 2 files changed, 5 insertions(+), 2 deletions(-) | ||
|
|
||
| [33mcommit 79d762c30c5a37252749488c83d258a5410a70fa[m | ||
| Author: David Howells <dhowells@redhat.com> | ||
| Date: Thu Apr 23 21:09:06 2026 +0100 | ||
|
|
||
| BACKPORT: rxrpc: Fix rxrpc_input_call_event() to only unshare DATA packets | ||
|
|
||
| mainline inclusion | ||
| from mainline-v7.1-rc1 | ||
| category: bugfix | ||
|
|
||
| commit 55b2984c96c37f909bbfe8851f13152693951382 upstream. | ||
|
|
||
| Fix rxrpc_input_call_event() to only unshare DATA packets and not ACK, | ||
| ABORT, etc.. | ||
|
|
||
| And with that, rxrpc_input_packet() doesn't need to take a pointer to the | ||
| pointer to the packet, so change that to just a pointer. | ||
|
|
||
| Fixes: 1f2740150f90 ("rxrpc: Fix potential UAF after skb_unshare() failure") | ||
| Closes: https://sashiko.dev/#/patchset/20260422161438.2593376-4-dhowells@redhat.com | ||
| Signed-off-by: David Howells <dhowells@redhat.com> | ||
| cc: Marc Dionne <marc.dionne@auristor.com> | ||
| cc: Jeffrey Altman <jaltman@auristor.com> | ||
| cc: Simon Horman <horms@kernel.org> | ||
| cc: linux-afs@lists.infradead.org | ||
| cc: stable@kernel.org | ||
| Link: https://patch.msgid.link/20260423200909.3049438-2-dhowells@redhat.com | ||
| Signed-off-by: Jakub Kicinski <kuba@kernel.org> | ||
| Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> | ||
| Signed-off-by: Wentao Guan <guanwentao@uniontech.com> | ||
|
|
||
| net/rxrpc/call_event.c | 4 [32m+++[m[31m-[m | ||
| 1 file changed, 3 insertions(+), 1 deletion(-) |
This patches updates the support for phytium media controller driver.
1.Redesign the "No Signal" prompt display feature on KVM
2.Add platform dependencies in Kconfig file
3.Reduce resolution switching latency
Summary by Sourcery
Update Phytium media JPEG driver signal/power handling and timing, and harden rxrpc packet handling for fragmented/skb-shared buffers.
New Features:
Bug Fixes:
Enhancements:
Chores: