Repository navigation
xiongmai-opensdk-xm510: open_mmz and open_h264 in place of the vendor mmz.ko and xm510_h264.ko - #2716
Conversation
… mmz.ko and xm510_h264.ko xiongmai-opensdk-xm510 now also builds two kernel modules from OpenIPC/openxiongmai (0e82ee2), and load_xiongmai loads them by modprobe, falling back to the vendor modules: - open_mmz: the XM510 mmz.ko's allocator, ioctls and /proc layout; - open_h264: the Hantro encoder driver, in place of xm510_h264.ko. Neither needs a vendor module's symbols. libwrapper is built from the package's own source as before. load_xiongmai -r now unloads mmz too. Tested on an XM510 + JX-H62, flashed with sysupgrade: both open modules load at boot, the vendor VI, ISP and RGN modules sit on open_mmz, and majestic streams H.264; load_xiongmai -r then -i unloads and reloads everything, and video comes back.
PR Summary by QodoAdd open MMZ and H.264 modules for XM510
AI Description
Diagram
High-Level Assessment
Files changed (3)
|
Code Review by Qodo
1.
|
…xm510 help points to openxiongmai depmod indexes the vendor modules under xiongmai/ on XM510, so the fallbacks for mmz and xm510_h264 use modprobe as the open modules do. Tested on the XM510 with the open module names hidden: modprobe loads the vendor mmz and xm510_h264, and video streams.
|
Also in 14a2040, for the help-text finding: the |
The XM510 gets the open drivers the XM530 already has.
xiongmai-opensdk-xm510now builds two kernel modules from OpenIPC/openxiongmai (pinned at 0e82ee2, OpenIPC/openxiongmai#40), andload_xiongmailoads them bymodprobe, falling back to the vendor modules:open_mmz: the XM510mmz.ko's allocator (blocks on the next page, no marker), ioctls 0–3 on 40-byte records, and/proc/umap/mmzlayout.open_h264: the Hantro encoder driver (openxiongmaidrivers/hx280enc), in place of the vendorxm510_h264.ko.Neither module needs a vendor module's symbols, so
modprobedoesn't pull in a vendormmz.ko, and the vendor modules stay where they are as the fallback.libwrapper.sois still built from the package's own source.load_xiongmai -rnow also unloads mmz, which it used to leave loaded. VI, ISP and RGN stay vendor.Tested
XM510 + JX-H62 (32 MB,
mem=18M), xm510_lite image from this branch flashed with sysupgrade:load_xiongmailoadsopen_mmzandopen_h264, and the vendorxm510_vi,xm510_ispandxm510_rgnrun onopen_mmz, with the same 12 MMZ blocks at the same addresses as with the vendormmz.ko;/video.mp4in 5 s, and an earlier capture decoded cleanly with ffmpeg);load_xiongmai -r, then-i, unloads every module, the open ones included, and loads them back; video returns.JPEG snapshots return 503 on this board with the vendor modules as well, so that is unrelated to this change.