ARM: dts: sun8i: v3s: Enable video decoder
Subsystems (5)
v2 cover ARM: dts: sun8i: v3s: Enable video decoder
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWM
There is low memory on V3s (64MB) and maximum must be available to CMA:
- CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)
Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
best regards,
Martin
Changes since v1:
- patch 0005 rename
- added testing description
Martin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node
.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)
Signature · 1 line
2.17.1
PATCH v2 1/6 media: cedrus: Register all codecs as capability
All codecs should have capabilities.
For example "Allwinner V3s" does not support "MPEG2".
--- drivers/staging/media/sunxi/cedrus/cedrus.c | 18 +++++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 3 files changed, 21 insertions(+), 1 deletion(-)
drivers/staging/media/sunxi/cedrus/cedrus.c +17 -1
@@ -479,42 +479,58 @@ static int cedrus_remove(struct platform_device *pdev) }static const struct cedrus_variant sun4i_a10_cedrus_variant = { + .capabilities =CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC , .mod_rate =320000000 , };static const struct cedrus_variant sun5i_a13_cedrus_variant = { + .capabilities =CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC , .mod_rate =320000000 , };static const struct cedrus_variant sun7i_a20_cedrus_variant = { + .capabilities =CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC , .mod_rate =320000000 , };static const struct cedrus_variant sun8i_a33_cedrus_variant = { - .capabilities =CEDRUS_CAPABILITY_UNTILED , + .capabilities =CEDRUS_CAPABILITY_UNTILED | +CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC , .mod_rate =320000000 , };static const struct cedrus_variant sun8i_h3_cedrus_variant = { .capabilities =CEDRUS_CAPABILITY_UNTILED | +CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC |CEDRUS_CAPABILITY_H265_DEC , .mod_rate =402000000 , };static const struct cedrus_variant sun50i_a64_cedrus_variant = { .capabilities =CEDRUS_CAPABILITY_UNTILED | +CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC |CEDRUS_CAPABILITY_H265_DEC , .mod_rate =402000000 , };static const struct cedrus_variant sun50i_h5_cedrus_variant = { .capabilities =CEDRUS_CAPABILITY_UNTILED | +CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC |CEDRUS_CAPABILITY_H265_DEC , .mod_rate =402000000 , };static const struct cedrus_variant sun50i_h6_cedrus_variant = { .capabilities =CEDRUS_CAPABILITY_UNTILED | +CEDRUS_CAPABILITY_MPEG2_DEC | +CEDRUS_CAPABILITY_H264_DEC |CEDRUS_CAPABILITY_H265_DEC , .quirks =CEDRUS_QUIRK_NO_DMA_OFFSET , .mod_rate =600000000 ,
drivers/staging/media/sunxi/cedrus/cedrus.h +2 -0
@@ -28,6 +28,8 @@#define CEDRUS_CAPABILITY_UNTILED BIT(0)#define CEDRUS_CAPABILITY_H265_DEC BIT(1) +#define CEDRUS_CAPABILITY_H264_DEC BIT(2) +#define CEDRUS_CAPABILITY_MPEG2_DEC BIT(3)#define CEDRUS_QUIRK_NO_DMA_OFFSET BIT(0)
drivers/staging/media/sunxi/cedrus/cedrus_video.c +2 -0
@@ -38,10 +38,12 @@ static struct cedrus_format cedrus_formats[] = { { .pixelformat = V4L2_PIX_FMT_MPEG2_SLICE, .directions = CEDRUS_DECODE_SRC, + .capabilities = CEDRUS_CAPABILITY_MPEG2_DEC, }, { .pixelformat = V4L2_PIX_FMT_H264_SLICE, .directions = CEDRUS_DECODE_SRC, + .capabilities = CEDRUS_CAPABILITY_H264_DEC, }, { .pixelformat = V4L2_PIX_FMT_HEVC_SLICE,
Signature · 1 line
2.17.1
PATCH v2 2/6 dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s compatibles
In reply to Martin CervenyAllwinner V3s has system control similar to that in H3. Add compatibles for system control with SRAM C1 region.
--- .../bindings/sram/allwinner,sun4i-a10-system-control.yaml | 6 ++++++ 1 file changed, 6 insertions(+)
Documentation/devicetree/bindings/sram/allwinner,sun4i-a10-system-control.yaml +6 -0
@@ -33,6 +33,9 @@ properties: - const: allwinner,sun4i-a10-system-control - const: allwinner,sun8i-a23-system-control - const: allwinner,sun8i-h3-system-control + - items: + - const: allwinner,sun8i-v3s-system-control + - const: allwinner,sun8i-h3-system-control - const: allwinner,sun50i-a64-sram-controller deprecated: true - const: allwinner,sun50i-a64-system-control
@@ -86,6 +89,9 @@ patternProperties: - items: - const: allwinner,sun8i-h3-sram-c1 - const: allwinner,sun4i-a10-sram-c1 + - items: + - const: allwinner,sun8i-v3s-sram-c1 + - const: allwinner,sun4i-a10-sram-c1 - items: - const: allwinner,sun50i-a64-sram-c1 - const: allwinner,sun4i-a10-sram-c1
Signature · 1 line
2.17.1
Re: [PATCH v2 2/6] dt-bindings: sram: allwinner, sun4i-a10-system-control: Add V3s compatibles
Quoted 8 lines · Martin Cerveny
Allwinner V3s has system control similar to that in H3. Add compatibles for system control with SRAM C1 region.
Signed-off-by Martin Cerveny <[email protected]>--- .../bindings/sram/allwinner,sun4i-a10-system-control.yaml | 6 ++++++ 1 file changed, 6 insertions(+)
PATCH v2 3/6 ARM: dts: sun8i: v3s: Add node for system control
In reply to Martin CervenyAllwinner V3s has system control and SRAM C1 region similar to H3.
--- arch/arm/boot/dts/sun8i-v3s.dtsi | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+)
arch/arm/boot/dts/sun8i-v3s.dtsi +23 -0
@@ -138,6 +138,29 @@ }; }; + syscon: system-control@1c00000 { + compatible = "allwinner,sun8i-v3s-system-control", + "allwinner,sun8i-h3-system-control"; + reg = <0x01c00000 0x1000>; + #address-cells = <1>; + #size-cells = <1>; + ranges; + + sram_c: sram@1d00000 { + compatible = "mmio-sram"; + reg = <0x01d00000 0x80000>; + #address-cells = <1>; + #size-cells = <1>; + ranges = <0 0x01d00000 0x80000>; + + ve_sram: sram-section@0 { + compatible = "allwinner,sun8i-v3s-sram-c1", + "allwinner,sun4i-a10-sram-c1"; + reg = <0x000000 0x80000>; + }; + }; + }; + tcon0: lcd-controller@1c0c000 { compatible = "allwinner,sun8i-v3s-tcon"; reg = <0x01c0c000 0x1000>;
Signature · 1 line
2.17.1
PATCH v2 4/6 media: cedrus: Add support for V3s
In reply to Martin CervenyV3s video engine runs at lower speed and support video decoder for H.264 and JPEG/MJPEG only.
--- drivers/staging/media/sunxi/cedrus/cedrus.c | 10 ++++++++++ 1 file changed, 10 insertions(+)
drivers/staging/media/sunxi/cedrus/cedrus.c +10 -0
@@ -511,6 +511,12 @@ static const struct cedrus_variant sun8i_h3_cedrus_variant = { .mod_rate = 402000000, }; +static const struct cedrus_variant sun8i_v3s_cedrus_variant = { + .capabilities =CEDRUS_CAPABILITY_UNTILED | +CEDRUS_CAPABILITY_H264_DEC , + .mod_rate =297000000 , +}; +static const struct cedrus_variant sun50i_a64_cedrus_variant = { .capabilities =CEDRUS_CAPABILITY_UNTILED | CEDRUS_CAPABILITY_MPEG2_DEC |
@@ -557,6 +563,10 @@ static const struct of_device_id cedrus_dt_match[] = { .compatible = "allwinner,sun8i-h3-video-engine", .data = &sun8i_h3_cedrus_variant, }, + { + .compatible = "allwinner,sun8i-v3s-video-engine", + .data = &sun8i_v3s_cedrus_variant, + }, { .compatible = "allwinner,sun50i-a64-video-engine", .data = &sun50i_a64_cedrus_variant,
Signature · 7 lines
2.17.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
PATCH v2 5/6 dt-bindings: media: cedrus: Add V3s compatible
In reply to Martin CervenyAllwinner V3s SoC contains video engine. Add compatible for it.
--- .../bindings/media/allwinner,sun4i-a10-video-engine.yaml | 1 + 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/media/allwinner,sun4i-a10-video-engine.yaml +1 -0
@@ -18,6 +18,7 @@ properties: - allwinner,sun7i-a20-video-engine - allwinner,sun8i-a33-video-engine - allwinner,sun8i-h3-video-engine + - allwinner,sun8i-v3s-video-engine - allwinner,sun50i-a64-video-engine - allwinner,sun50i-h5-video-engine - allwinner,sun50i-h6-video-engine
Signature · 1 line
2.17.1
Re: [PATCH v2 5/6] dt-bindings: media: cedrus: Add V3s compatible
Quoted 7 lines · Martin Cerveny
Allwinner V3s SoC contains video engine. Add compatible for it.
Signed-off-by Martin Cerveny <[email protected]>--- .../bindings/media/allwinner,sun4i-a10-video-engine.yaml | 1 + 1 file changed, 1 insertion(+)
PATCH v2 6/6 ARM: dts: sun8i: v3s: Add video engine node
In reply to Martin CervenyAllwinner V3S SoC has a video engine.
Add a node for it.
--- arch/arm/boot/dts/sun8i-v3s.dtsi | 10 ++++++++++ 1 file changed, 10 insertions(+)
arch/arm/boot/dts/sun8i-v3s.dtsi +10 -0
@@ -195,6 +195,16 @@ }; }; + video-codec@1c0e000 { + compatible = "allwinner,sun8i-v3s-video-engine"; + reg = <0x01c0e000 0x1000>; + clocks = <&ccu CLK_BUS_VE>, <&ccu CLK_VE>, + <&ccu CLK_DRAM_VE>; + clock-names = "ahb", "mod", "ram"; + resets = <&ccu RST_BUS_VE>; + interrupts = <GIC_SPI 58 IRQ_TYPE_LEVEL_HIGH>; + allwinner,sram = <&ve_sram 1>; + }; mmc0: mmc@1c0f000 { compatible = "allwinner,sun7i-a20-mmc";
Signature · 1 line
2.17.1
Maxime,
Are you OK with this series? It looks good to me.
Regards,
Hans
Quoted 46 lines · Martin Cerveny
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWMThere is low memory on V3s (64MB) and maximum must be available to CMA:
-CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
best regards,
MartinChanges since v1:
- patch 0005 rename
- added testing descriptionMartin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)
Hi!
Quoted 3 lines · Hans Verkuil
Maxime,
Are you OK with this series? It looks good to me.
I am, you can take it. I'll merge the dt patches through arm-soc
Thanks!
Maxime
Hi Martin,
Quoted 14 lines · Martin Cerveny
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWM
Quoted 7 lines
There is low memory on V3s (64MB) and maximum must be available to CMA:
-CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
When I tried to merged these patches I got merge conflicts.
Possibly due to other 5.10 changes, but certainly because of conflicts with patches from Jernej:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
I've merged Jerne's patches and posted a PR for that:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
Can you rebase your patches on top of my branch that contains Jernej's patches?
https://git.linuxtv.org/hverkuil/media_tree.git/log/?h=for-v5.11e
Once my PR is merged into the media_tree master I can take your rebased patches.
Regards,
Hans
Quoted 25 lines
best regards,
MartinChanges since v1:
- patch 0005 rename
- added testing descriptionMartin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)
Hello.
Quoted 36 lines · Hans Verkuil
Hi Martin,
Quoted 14 lines · Martin Cerveny
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWMQuoted 7 lines
There is low memory on V3s (64MB) and maximum must be available to CMA:
-CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
When I tried to merged these patches I got merge conflicts.
Possibly due to other 5.10 changes, but certainly because of conflicts with patches from Jernej:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/I've merged Jerne's patches and posted a PR for that:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
Quoted 6 lines
Can you rebase your patches on top of my branch that contains Jernej's patches?
https://git.linuxtv.org/hverkuil/media_tree.git/log/?h=for-v5.11e
Once my PR is merged into the
media_treemaster I can take your rebased patches.
I updated patches:
https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e
BUT, commit (555 commits) for v5.10-1
https://github.com/torvalds/linux/commit/fd5c32d80884268a381ed0e67cccef0b3d37750b
disrupts usability of Cedrus H.264 (at least for my Allwinner V3s):
1) colors are disrupted
There are missing some initialization now.
If I use "5.9" compatible code
(last bisect good point https://github.com/torvalds/linux/commit/647412daeb454b6dad12a6c6961ab90aac9e5d29 ) then reboot (not power-off!) and use new code ( https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e ) and colors are OK.
2) decoding of complex streams fails
( https://github.com/mcerveny/v4l2-request-test/tree/v5.10 )
- bbb-h264-all-i-32 - OK
- bbb-h264-32 - bad from frame 5
- bbb-h264-high-32 - bad from frame 6
best regards,
Martin
Quoted 13 lines
Quoted 13 lines
Changes since v1:
- patch 0005 rename
- added testing descriptionMartin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node
Quoted 9 lines
Quoted 8 lines
.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 56 lines · Martin Cerveny
Hello.
Quoted 36 lines · Hans Verkuil
Hi Martin,
Quoted 14 lines · Martin Cerveny
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWMQuoted 7 lines
There is low memory on V3s (64MB) and maximum must be available to CMA:
-CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
When I tried to merged these patches I got merge conflicts.
Possibly due to other 5.10 changes, but certainly because of conflicts with patches from Jernej:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/I've merged Jerne's patches and posted a PR for that:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/Quoted 6 lines
Can you rebase your patches on top of my branch that contains Jernej's patches?
https://git.linuxtv.org/hverkuil/media_tree.git/log/?h=for-v5.11e
Once my PR is merged into the
media_treemaster I can take your rebased patches.I updated patches:
https://github.com/mcerveny/linux/tree/media_tree_for-v5.11eBUT, commit (555 commits) for v5.10-1
https://github.com/torvalds/linux/commit/fd5c32d80884268a381ed0e67cccef0b3d37750b
disrupts usability of Cedrus H.264 (at least for my Allwinner V3s):1) colors are disrupted
Quoted 7 lines
There are missing some initialization now.
If I use "5.9" compatible code
(last bisect good point https://github.com/torvalds/linux/commit/647412daeb454b6dad12a6c6961ab90aac9e5d29 ) then reboot (not power-off!) and use new code
( https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e )
and colors are OK.
Could this or the next issue be related to this bug fix?
https://git.linuxtv.org/media_tree.git/commit/?h=fixes&id=9ac924b98728c3733c91c6c59fc410827d0da49f
That fix isn't yet in our master tree.
Quoted 7 lines
2) decoding of complex streams fails
( https://github.com/mcerveny/v4l2-request-test/tree/v5.10 )
- bbb-h264-all-i-32 - OK
- bbb-h264-32 - bad from frame 5
- bbb-h264-high-32 - bad from frame 6
I think cedrus devs need to take a look at these issues.
Regards,
Hans
Quoted 26 lines
best regards,
MartinQuoted 22 lines
Quoted 21 lines
Changes since v1:
- patch 0005 rename
- added testing descriptionMartin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 65 lines · Hans Verkuil
Quoted 56 lines · Martin Cerveny
Hello.
Quoted 36 lines · Hans Verkuil
Hi Martin,
Quoted 14 lines · Martin Cerveny
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWMQuoted 7 lines
There is low memory on V3s (64MB) and maximum must be available to CMA:
-CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
When I tried to merged these patches I got merge conflicts.
Possibly due to other 5.10 changes, but certainly because of conflicts with patches from Jernej:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/I've merged Jerne's patches and posted a PR for that:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/Quoted 6 lines
Can you rebase your patches on top of my branch that contains Jernej's patches?
https://git.linuxtv.org/hverkuil/media_tree.git/log/?h=for-v5.11e
Once my PR is merged into the
media_treemaster I can take your rebased patches.I updated patches:
https://github.com/mcerveny/linux/tree/media_tree_for-v5.11eBUT, commit (555 commits) for v5.10-1
https://github.com/torvalds/linux/commit/fd5c32d80884268a381ed0e67cccef0b3d37750b
disrupts usability of Cedrus H.264 (at least for my Allwinner V3s):1) colors are disrupted
Quoted 7 lines
There are missing some initialization now.
If I use "5.9" compatible code
(last bisect good point https://github.com/torvalds/linux/commit/647412daeb454b6dad12a6c6961ab90aac9e5d29 ) then reboot (not power-off!) and use new code
( https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e )
and colors are OK.
Quoted 5 lines
Could this or the next issue be related to this bug fix?
https://git.linuxtv.org/media_tree.git/commit/?h=fixes&id=9ac924b98728c3733c91c6c59fc410827d0da49f
That fix isn't yet in our master tree.
Confirmed. It recovers colors !
Quoted 9 lines
Quoted 7 lines
2) decoding of complex streams fails
( https://github.com/mcerveny/v4l2-request-test/tree/v5.10 )
- bbb-h264-all-i-32 - OK
- bbb-h264-32 - bad from frame 5
- bbb-h264-high-32 - bad from frame 6I think cedrus devs need to take a look at these issues.
Maybe something wrong in my testing code,
problematic commit swapped some variables between structures :-(
I try to investigate more, regards Martin
Quoted 31 lines
Regards,
Hans
Quoted 26 lines
best regards,
MartinQuoted 22 lines
Quoted 21 lines
Changes since v1:
- patch 0005 rename
- added testing descriptionMartin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Hello.
Quoted 77 lines · Martin Cerveny
Quoted 60 lines · Hans Verkuil
Quoted 51 lines · Martin Cerveny
Quoted 34 lines · Hans Verkuil
Quoted 14 lines · Martin Cerveny
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWMQuoted 7 lines
There is low memory on V3s (64MB) and maximum must be available to CMA:
-CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
When I tried to merged these patches I got merge conflicts.
Possibly due to other 5.10 changes, but certainly because of conflicts with patches from Jernej:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/I've merged Jerne's patches and posted a PR for that:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/Quoted 6 lines
Can you rebase your patches on top of my branch that contains Jernej's patches?
https://git.linuxtv.org/hverkuil/media_tree.git/log/?h=for-v5.11e
Once my PR is merged into the
media_treemaster I can take your rebased patches.I updated patches:
https://github.com/mcerveny/linux/tree/media_tree_for-v5.11eBUT, commit (555 commits) for v5.10-1
https://github.com/torvalds/linux/commit/fd5c32d80884268a381ed0e67cccef0b3d37750b
disrupts usability of Cedrus H.264 (at least for my Allwinner V3s):1) colors are disrupted
Quoted 7 lines
There are missing some initialization now.
If I use "5.9" compatible code
(last bisect good point https://github.com/torvalds/linux/commit/647412daeb454b6dad12a6c6961ab90aac9e5d29 ) then reboot (not power-off!) and use new code
( https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e )
and colors are OK.Quoted 5 lines
Could this or the next issue be related to this bug fix?
https://git.linuxtv.org/media_tree.git/commit/?h=fixes&id=9ac924b98728c3733c91c6c59fc410827d0da49f
That fix isn't yet in our master tree.
Confirmed. It recovers colors !
Quoted 8 lines
Quoted 7 lines
2) decoding of complex streams fails
( https://github.com/mcerveny/v4l2-request-test/tree/v5.10 )
- bbb-h264-all-i-32 - OK
- bbb-h264-32 - bad from frame 5
- bbb-h264-high-32 - bad from frame 6
Quoted 6 lines
Quoted 1 line
I think cedrus devs need to take a look at these issues.
Maybe something wrong in my testing code,
problematic commit swapped some variables between structures :-(I try to investigate more, regards Martin
Yes. I found new format in ref_pic_list.
I updated test application. All H.264 tests are working now.
https://github.com/mcerveny/v4l2-request-test
Is it necessary to release new "Patch V3" (rebased) series from https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e or not ?
Regards, Martin
Quoted 21 lines
Quoted 21 lines
Regards,
Hans
Quoted 17 lines
best regards,
MartinQuoted 13 lines
Quoted 13 lines
Changes since v1:
- patch 0005 rename
- added testing descriptionMartin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node
Quoted 11 lines
Quoted 10 lines
Quoted 9 lines
Quoted 9 lines
Quoted 8 lines
.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Quoted 90 lines · Martin Cerveny
Hello.
Quoted 80 lines · Martin Cerveny
Quoted 63 lines · Hans Verkuil
Quoted 54 lines · Martin Cerveny
Quoted 34 lines · Hans Verkuil
Quoted 14 lines · Martin Cerveny
First patch extends cedrus capability to all decoders because V3s missing MPEG2 decoder.
Next two patches add system control node (SRAM C1) and next three patches add support for Cedrus VPU.
Tested on "Lichee Zero" V3s platform with testing LCD patch ( https://github.com/mcerveny/linux/tree/v3s_videocodec_v4 ) and V4L2 raw API testing utility
( https://github.com/mcerveny/v4l2-request-test ):
- enabled LCD (DRM dual VI and sigle UI planes)
- added RGB panel
- enabled PWMQuoted 7 lines
There is low memory on V3s (64MB) and maximum must be available to CMA:
-CONFIG_CMA_SIZE_MBYTES=28
- add swap to swapout other processes
- decrease buffers in v4l2-request-test (.buffers_count from 16 to 6)Only H.264 decoder working - MPEG and H.265 unsupported by V3s, JPEG/MJPEG still unimplemented, encoder unimplemented
When I tried to merged these patches I got merge conflicts.
Possibly due to other 5.10 changes, but certainly because of conflicts with patches from Jernej:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/I've merged Jerne's patches and posted a PR for that:
https://patchwork.linuxtv.org/project/linux-media/patch/[email protected]/Quoted 7 lines
Can you rebase your patches on top of my branch that contains Jernej's patches?
https://git.linuxtv.org/hverkuil/media_tree.git/log/?h=for-v5.11e
Once my PR is merged into the
media_treemaster I can take your rebased patches.I updated patches:
https://github.com/mcerveny/linux/tree/media_tree_for-v5.11eBUT, commit (555 commits) for v5.10-1
https://github.com/torvalds/linux/commit/fd5c32d80884268a381ed0e67cccef0b3d37750b
disrupts usability of Cedrus H.264 (at least for my Allwinner V3s):1) colors are disrupted
There are missing some initialization now.
Quoted 7 lines
If I use "5.9" compatible code
(last bisect good point
https://github.com/torvalds/linux/commit/647412daeb454b6dad12a6c6961ab90aac9e5d29
)
then reboot (not power-off!) and use new code
( https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e ) and colors are OK.Quoted 5 lines
Could this or the next issue be related to this bug fix?
https://git.linuxtv.org/media_tree.git/commit/?h=fixes&id=9ac924b98728c3733c91c6c59fc410827d0da49f
That fix isn't yet in our master tree.
Confirmed. It recovers colors !
Quoted 8 lines
Quoted 7 lines
2) decoding of complex streams fails
( https://github.com/mcerveny/v4l2-request-test/tree/v5.10 )
- bbb-h264-all-i-32 - OK
- bbb-h264-32 - bad from frame 5
- bbb-h264-high-32 - bad from frame 6Quoted 6 lines
Quoted 1 line
I think cedrus devs need to take a look at these issues.
Maybe something wrong in my testing code,
problematic commit swapped some variables between structures :-(I try to investigate more, regards Martin
Quoted 7 lines
Yes. I found new format in
ref_pic_list.
I updated test application. All H.264 tests are working now.https://github.com/mcerveny/v4l2-request-test
Is it necessary to release new "Patch V3" (rebased) series from
https://github.com/mcerveny/linux/tree/media_tree_for-v5.11e or not ?
Yes, please! That would be much appreciated.
Regards,
Hans
Quoted 35 lines
Regards, Martin
Quoted 32 lines
Quoted 31 lines
Regards,
Hans
Quoted 26 lines
best regards,
MartinQuoted 22 lines
Quoted 21 lines
Changes since v1:
- patch 0005 rename
- added testing descriptionMartin Cerveny (6):
media: cedrus: Register all codecs as capability
dt-bindings: sram: allwinner,sun4i-a10-system-control: Add V3s
compatibles
ARM: dts: sun8i: v3s: Add node for system control
media: cedrus: Add support for V3s
dt-bindings: media: cedrus: Add V3s compatible
ARM: dts: sun8i: v3s: Add video engine node.../allwinner,sun4i-a10-video-engine.yaml | 1 + .../allwinner,sun4i-a10-system-control.yaml | 6 ++++ arch/arm/boot/dts/sun8i-v3s.dtsi | 33 +++++++++++++++++++ drivers/staging/media/sunxi/cedrus/cedrus.c | 28 +++++++++++++++- drivers/staging/media/sunxi/cedrus/cedrus.h | 2 ++ .../staging/media/sunxi/cedrus/cedrus_video.c | 2 ++ 6 files changed, 71 insertions(+), 1 deletion(-)