Allwinner A64/H6 IR support
Subsystems (4)
v3 cover Allwinner A64/H6 IR support
Hi,
A64 IR support series[1] pointed out that an A31 bindings should be introduced.
This series introduce the A31 compatible bindings, then switch it on the already existing board.
Finally introduce A64 and H6 support.
I didn't enable the IR on other H6 boards as Ondrej reported an issue on his board[2].
Regards,
Clément
[1] https://lore.kernel.org/patchwork/patch/1031390/#1221464
[2] https://lkml.org/lkml/2019/5/27/321
Changes since v2:
- Disable IR for other H6 boards
- Split DTS patch for H3/H5
- Introduce IR quirks
Changes since v1:
- Document reset lines as required since A31
- Explain the memory mapping difference in commit log
- Fix misspelling "Allwiner" to "Allwinner"
Clément Péron (10):
dt-bindings: media: sunxi-ir: add A31 compatible
media: rc: Introduce sunxi_ir_quirks
media: rc: sunxi: Add A31 compatible
ARM: dts: sunxi: Prefer A31 bindings for IR
ARM: dts: sunxi: Prefer A31 bindings for IR
dt-bindings: media: sunxi-ir: Add A64 compatible
dt-bindings: media: sunxi-ir: Add H6 compatible
arm64: dts: allwinner: h6: Add IR receiver node
arm64: dts: allwinner: h6: Enable IR on Beelink GS1
arm64: defconfig: enable IR SUNXI option
Igors Makejevs (1):
arm64: dts: allwinner: a64: Add IR node
Jernej Skrabec (1):
arm64: dts: allwinner: a64: Enable IR on Orange Pi Win
.../devicetree/bindings/media/sunxi-ir.txt | 11 ++- arch/arm/boot/dts/sun6i-a31.dtsi | 2 +- arch/arm/boot/dts/sun8i-a83t.dtsi | 2 +- arch/arm/boot/dts/sun9i-a80.dtsi | 2 +- arch/arm/boot/dts/sunxi-h3-h5.dtsi | 2 +- .../dts/allwinner/sun50i-a64-orangepi-win.dts | 4 ++ arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 18 +++++ .../dts/allwinner/sun50i-h6-beelink-gs1.dts | 4 ++ arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++ arch/arm64/configs/defconfig | 1 + drivers/media/rc/sunxi-cir.c | 70 +++++++++++++++---- 11 files changed, 115 insertions(+), 20 deletions(-)
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-1-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 1/12 dt-bindings: media: sunxi-ir: add A31 compatible
Allwinner A31 has introduced a new memory mapping and a reset line.
The difference in memory mapping are :
- In the configure register there is a new sample bit and Allwinner has introduced the active threshold feature.
- In the status register a new STAT bit is present.
Note: CGPO and DRQ_EN bits are removed on A31 but present on A13 and on new SoCs like A64/H6.
This is actually not an issue as these bits are togglable and new SoCs have a dedicated bindings.
Introduce this bindings to make a difference since this generation. And declare the reset line required since A31.
--- Documentation/devicetree/bindings/media/sunxi-ir.txt | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-)
Documentation/devicetree/bindings/media/sunxi-ir.txt +7 -2
@@ -1,16 +1,21 @@ Device-Tree bindings for SUNXI IR controller found in sunXi SoC family Required properties: -- compatible : "allwinner,sun4i-a10-ir" or "allwinner,sun5i-a13-ir" +- compatible : + "allwinner,sun4i-a10-ir" + "allwinner,sun5i-a13-ir" + "allwinner,sun6i-a31-ir" - clocks : list of clock specifiers, corresponding to entries in clock-names property; - clock-names : should contain "apb" and "ir" entries; - interrupts : should contain IR IRQ number; - reg : should contain IO map address for IR. +Required properties since A31: +- resets : phandle + reset specifier pair + Optional properties: - linux,rc-map-name: see rc.txt file in the same directory. -- resets : phandle + reset specifier pair - clock-frequency : IR Receiver clock frequency, in Hertz. Defaults to 8 MHz if missing.
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-2-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [PATCH v3 01/12] dt-bindings: media: sunxi-ir: add A31 compatible
Quoted 15 lines · On Tue, 28 May 2019 18:14:29 +0200, =?UTF-8?q?Cl=C3=A9ment=20P=C3=A9ron?= wrote:
Allwinner A31 has introduced a new memory mapping and a reset line.
The difference in memory mapping are :
- In the configure register there is a new sample bit and Allwinner has introduced the active threshold feature.
- In the status register a new STAT bit is present.
Note: CGPO and
DRQ_ENbits are removed on A31 but present on A13 and on new SoCs like A64/H6.
This is actually not an issue as these bits are togglable and new SoCs have a dedicated bindings.
Quoted 8 lines
Introduce this bindings to make a difference since this generation. And declare the reset line required since A31.
Signed-off-by Clément Péron <[email protected]>--- Documentation/devicetree/bindings/media/sunxi-ir.txt | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-)
PATCH v3 2/12 media: rc: Introduce sunxi_ir_quirks
In reply to Clément PéronThis driver is used in various Allwinner SoC with different configuration.
Introduce a quirks struct to know the fifo size and if a reset is required.
--- drivers/media/rc/sunxi-cir.c | 61 +++++++++++++++++++++++++++--------- 1 file changed, 47 insertions(+), 14 deletions(-)
drivers/media/rc/sunxi-cir.c +47 -14
@@ -81,6 +81,17 @@/* Time after which device stops sending data in ms */ #define SUNXI_IR_TIMEOUT 120 +/** +* struct sunxi_ir_quirks - Differences between SoC variants. +* +* @has_reset: SoC needs reset deasserted. +* @fifo_size: size of the fifo. +*/ +struct sunxi_ir_quirks { +bool has_reset; +int fifo_size; +}; +struct sunxi_ir {spinlock_t ir_lock;struct rc_dev *rc;
@@ -143,6 +154,7 @@ static int sunxi_ir_probe(struct platform_device *pdev)struct device *dev = &pdev->dev;struct device_node *dn = dev->of_node; +const struct sunxi_ir_quirks *quirks;struct resource *res;struct sunxi_ir *ir;u32 b_clk_freq =SUNXI_IR_BASE_CLK ;
@@ -151,12 +163,15 @@ static int sunxi_ir_probe(struct platform_device *pdev)if (!ir)return -ENOMEM ; + quirks =of_device_get_match_data (&pdev->dev); +if (quirks ==NULL ) { +dev_err (&pdev->dev,"Failed to determine the quirks to use\n" ); +return -ENODEV ; + } +spin_lock_init (&ir->ir_lock); -if (of_device_is_compatible (dn,"allwinner,sun5i-a13-ir" )) - ir->fifo_size =64 ; -else - ir->fifo_size =16 ; + ir->fifo_size = quirks->fifo_size;/* Clock */ ir->apb_clk =devm_clk_get (dev,"apb" );
@@ -173,13 +188,15 @@ static int sunxi_ir_probe(struct platform_device *pdev)/* Base clock frequency (optional) */ of_property_read_u32 (dn,"clock-frequency" , &b_clk_freq); -/* Reset (optional) */ - ir->rst =devm_reset_control_get_optional_exclusive (dev,NULL ); -if (IS_ERR (ir->rst)) -return PTR_ERR (ir->rst); - ret =reset_control_deassert (ir->rst); -if (ret) -return ret; +/* Reset */ +if (quirks->has_reset) { + ir->rst =devm_reset_control_get_exclusive (dev,NULL ); +if (IS_ERR (ir->rst)) +return PTR_ERR (ir->rst); + ret =reset_control_deassert (ir->rst); +if (ret) +return ret; + } ret =clk_set_rate (ir->clk, b_clk_freq);if (ret) {
@@ -316,10 +333,26 @@ static int sunxi_ir_remove(struct platform_device *pdev)return 0 ; } +static const struct sunxi_ir_quirks sun4i_a10_ir_quirks = { + .has_reset = false, + .fifo_size =16 , +}; + +static const struct sunxi_ir_quirks sun5i_a13_ir_quirks = { + .has_reset = false, + .fifo_size =64 , +}; +static const struct of_device_id sunxi_ir_match[] = { - { .compatible ="allwinner,sun4i-a10-ir" , }, - { .compatible ="allwinner,sun5i-a13-ir" , }, - {}, + { + .compatible ="allwinner,sun4i-a10-ir" , + .data = &sun4i_a10_ir_quirks, + }, + { + .compatible ="allwinner,sun5i-a13-ir" , + .data = &sun5i_a13_ir_quirks, + }, + {} };MODULE_DEVICE_TABLE (of, sunxi_ir_match);
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-3-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 3/12 media: rc: sunxi: Add A31 compatible
In reply to Clément PéronAllwiner A31 has a different memory mapping so add the compatible we will need it later.
--- drivers/media/rc/sunxi-cir.c | 9 +++++++++ 1 file changed, 9 insertions(+)
drivers/media/rc/sunxi-cir.c +9 -0
@@ -343,6 +343,11 @@ static const struct sunxi_ir_quirks sun5i_a13_ir_quirks = { .fifo_size = 64, }; +static const struct sunxi_ir_quirks sun6i_a31_ir_quirks = { + .has_reset = true, + .fifo_size =64 , +}; +static const struct of_device_id sunxi_ir_match[] = { { .compatible ="allwinner,sun4i-a10-ir" ,
@@ -352,6 +357,10 @@ static const struct of_device_id sunxi_ir_match[] = { .compatible = "allwinner,sun5i-a13-ir", .data = &sun5i_a13_ir_quirks, }, + { + .compatible = "allwinner,sun6i-a31-ir", + .data = &sun6i_a31_ir_quirks, + }, {} };MODULE_DEVICE_TABLE (of, sunxi_ir_match);
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-4-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [PATCH v3 03/12] media: rc: sunxi: Add A31 compatible
Quoted 13 lines · Clément Péron
Allwiner A31 has a different memory mapping so add the compatible we will need it later.
Signed-off-by Clément Péron <[email protected]>--- drivers/media/rc/sunxi-cir.c | 9 +++++++++ 1 file changed, 9 insertions(+)drivers/media/rc/sunxi-cir.c +0
-0
drivers/media/rc/sunxi-cir.c static const struct sunxi_ir_quirks sun5i_a13_ir_quirks = { · line 350
Quoted 8 lines
drivers/media/rc/sunxi-cir.c +5
-0@@ -343,6 +343,11 @@ static const struct sunxi_ir_quirks sun5i_a13_ir_quirks = { .fifo_size = 64, }; +static const struct sunxi_ir_quirks sun6i_a31_ir_quirks = { + .has_reset = true, + .fifo_size =64 , +}; +
BTW, H6 BSP uses FIFO size 40:
Have you tried filling the fifo with over 40 words on H6, to see if it works?
I know it's docummented as having 64 words in the manual, so maybe Allwiner just didn't care enough to make the driver configurable, and the H6 FIFO really has that depth.
regards,
o.
Quoted 22 lines
drivers/media/rc/sunxi-cir.c +4
-0static const struct of_device_id sunxi_ir_match[] = { { .compatible ="allwinner,sun4i-a10-ir" ,@@ -352,6 +357,10 @@ static const struct of_device_id sunxi_ir_match[] = { .compatible = "allwinner,sun5i-a13-ir", .data = &sun5i_a13_ir_quirks, }, + { + .compatible = "allwinner,sun6i-a31-ir", + .data = &sun6i_a31_ir_quirks, + }, {} };MODULE_DEVICE_TABLE (of, sunxi_ir_match);Signature · 7 lines
2.20.1 _______________________________________________ linux-arm-kernel mailing list [email protected] http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Re: [PATCH v3 03/12] media: rc: sunxi: Add A31 compatible
Hi,
Quoted 26 lines · Ondřej Jirman
Quoted 13 lines · Clément Péron
Allwiner A31 has a different memory mapping so add the compatible we will need it later.
Signed-off-by Clément Péron <[email protected]>--- drivers/media/rc/sunxi-cir.c | 9 +++++++++ 1 file changed, 9 insertions(+)drivers/media/rc/sunxi-cir.c +0
-0drivers/media/rc/sunxi-cir.c static const struct sunxi_ir_quirks sun5i_a13_ir_quirks = { · line 350
Quoted 8 lines
drivers/media/rc/sunxi-cir.c +5
-0@@ -343,6 +343,11 @@ static const struct sunxi_ir_quirks sun5i_a13_ir_quirks = { .fifo_size = 64, }; +static const struct sunxi_ir_quirks sun6i_a31_ir_quirks = { + .has_reset = true, + .fifo_size =64 , +}; +BTW, H6 BSP uses FIFO size 40:
Quoted 3 lines
Have you tried filling the fifo with over 40 words on H6, to see if it works?
No I didn't try this, but I trust more the user manual than the driver. And I don't see why they would have reduce the fifo size in the new generation. Anyway, I will be able to test that at the end of the week.
Regards,
Clément
Quoted 29 lines
I know it's docummented as having 64 words in the manual, so maybe Allwiner just didn't care enough to make the driver configurable, and the H6 FIFO really has that depth.
regards,
o.Quoted 22 lines
drivers/media/rc/sunxi-cir.c +4
-1static const struct of_device_id sunxi_ir_match[] = { { .compatible ="allwinner,sun4i-a10-ir" ,@@ -352,6 +357,10 @@ static const struct of_device_id sunxi_ir_match[] = { .compatible = "allwinner,sun5i-a13-ir", .data = &sun5i_a13_ir_quirks, }, + { + .compatible = "allwinner,sun6i-a31-ir", + .data = &sun6i_a31_ir_quirks, + }, {} };MODULE_DEVICE_TABLE (of, sunxi_ir_match); --2.20.1
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
PATCH v3 4/12 ARM: dts: sunxi: Prefer A31 bindings for IR
In reply to Clément PéronSince A31, memory mapping of the IR driver has changed.
Prefer the A31 bindings instead of A13.
--- arch/arm/boot/dts/sun6i-a31.dtsi | 2 +- arch/arm/boot/dts/sun8i-a83t.dtsi | 2 +- arch/arm/boot/dts/sun9i-a80.dtsi | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
arch/arm/boot/dts/sun6i-a31.dtsi +1 -1
@@ -1351,7 +1351,7 @@ }; ir: ir@1f02000 { - compatible = "allwinner,sun5i-a13-ir"; + compatible = "allwinner,sun6i-a31-ir"; clocks = <&apb0_gates 1>, <&ir_clk>; clock-names = "apb", "ir"; resets = <&apb0_rst 1>;
arch/arm/boot/dts/sun8i-a83t.dtsi +1 -1
@@ -1067,7 +1067,7 @@ r_cir: ir@1f02000 { compatible = "allwinner,sun8i-a83t-ir", - "allwinner,sun5i-a13-ir"; + "allwinner,sun6i-a31-ir"; clocks = <&r_ccu CLK_APB0_IR>, <&r_ccu CLK_IR>; clock-names = "apb", "ir"; resets = <&r_ccu RST_APB0_IR>;
arch/arm/boot/dts/sun9i-a80.dtsi +1 -1
@@ -1167,7 +1167,7 @@ }; r_ir: ir@8002000 { - compatible = "allwinner,sun5i-a13-ir"; + compatible = "allwinner,sun6i-a31-ir"; interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>; pinctrl-names = "default"; pinctrl-0 = <&r_ir_pins>;
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-5-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 5/12 ARM: dts: sunxi: Prefer A31 bindings for IR
In reply to Clément PéronSince A31, memory mapping of the IR driver has changed.
Prefer the A31 bindings instead of A13.
--- arch/arm/boot/dts/sunxi-h3-h5.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/sunxi-h3-h5.dtsi +1 -1
@@ -822,7 +822,7 @@ }; ir: ir@1f02000 { - compatible = "allwinner,sun5i-a13-ir"; + compatible = "allwinner,sun6i-a31-ir"; clocks = <&r_ccu CLK_APB0_IR>, <&r_ccu CLK_IR>; clock-names = "apb", "ir"; resets = <&r_ccu RST_APB0_IR>;
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-6-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 6/12 dt-bindings: media: sunxi-ir: Add A64 compatible
In reply to Clément PéronThere are some minor differences between A31 and A64 driver.
But A31 IR driver is compatible with A64.
--- Documentation/devicetree/bindings/media/sunxi-ir.txt | 1 + 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/media/sunxi-ir.txt +1 -0
@@ -5,6 +5,7 @@ Required properties: "allwinner,sun4i-a10-ir" "allwinner,sun5i-a13-ir" "allwinner,sun6i-a31-ir" + "allwinner,sun50i-a64-ir", "allwinner,sun6i-a31-ir" - clocks : list of clock specifiers, corresponding to entries in clock-names property; - clock-names : should contain "apb" and "ir" entries;
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-7-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 7/12 arm64: dts: allwinner: a64: Add IR node
In reply to Clément PéronFrom: Igors Makejevs <git_bb-v/FNU3S1YP/[email protected]>
IR peripheral is completely compatible with A31 one.
--- arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+)
arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi +18 -0
@@ -1072,6 +1072,19 @@ #size-cells = <0>; }; + r_ir: ir@1f02000 { + compatible = "allwinner,sun50i-a64-ir", + "allwinner,sun6i-a31-ir"; + reg = <0x01f02000 0x400>; + clocks = <&r_ccu CLK_APB0_IR>, <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_APB0_IR>; + interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; + }; + r_pwm: pwm@1f03800 { compatible = "allwinner,sun50i-a64-pwm", "allwinner,sun5i-a13-pwm";
@@ -1099,6 +1112,11 @@ function = "s_i2c"; }; + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL11"; + function = "s_cir_rx"; + }; + r_pwm_pin: r-pwm-pin { pins = "PL10"; function = "s_pwm";
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-8-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 8/12 arm64: dts: allwinner: a64: Enable IR on Orange Pi Win
In reply to Clément PéronFrom: Jernej Skrabec <[email protected]>
OrangePi Win board contains IR receiver. Enable it.
--- arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts | 4 ++++ 1 file changed, 4 insertions(+)
arch/arm64/boot/dts/allwinner/sun50i-a64-orangepi-win.dts +4 -0
@@ -180,6 +180,10 @@ status = "okay"; }; +&r_ir { + status = "okay"; +}; + &r_rsb { status = "okay";
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-9-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 9/12 dt-bindings: media: sunxi-ir: Add H6 compatible
In reply to Clément PéronThere are some minor differences between A31 or A64 with H6 IR peripheral.
But A31 IR driver is compatible with H6.
--- Documentation/devicetree/bindings/media/sunxi-ir.txt | 1 + 1 file changed, 1 insertion(+)
Documentation/devicetree/bindings/media/sunxi-ir.txt +1 -0
@@ -6,6 +6,7 @@ Required properties: "allwinner,sun5i-a13-ir" "allwinner,sun6i-a31-ir" "allwinner,sun50i-a64-ir", "allwinner,sun6i-a31-ir" + "allwinner,sun50i-h6-ir", "allwinner,sun6i-a31-ir" - clocks : list of clock specifiers, corresponding to entries in clock-names property; - clock-names : should contain "apb" and "ir" entries;
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-10-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 10/12 arm64: dts: allwinner: h6: Add IR receiver node
In reply to Clément PéronAllwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +19 -0
@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir"; + reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; }; r_i2c: i2c@7081400 {
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-11-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hello Clément,
Quoted 27 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +10
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir";
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 10 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +9
-0+ reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };
Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
thanks,
o.
Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-0r_i2c: i2c@7081400 {Signature · 7 lines
2.20.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Signature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190530145550.amalnxmx7kpokykv%40core.my.home. For more options, visit https://groups.google.com/d/optout.
Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hi Ondrej,
Quoted 36 lines · Ondřej Jirman
Hello Clément,
Quoted 32 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +15
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir"; + reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir";
Quoted 8 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 5 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +4
-0+ resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
I'm planning to send a v4 next week with the IRQ_NONE return as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4
But maybe we could also use the bit 5 of the IRQ status.
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Re: [linux-sunxi] Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hello Clément,
Quoted 48 lines · Clément Péron
Hi Ondrej,
Quoted 36 lines · Ondřej Jirman
Hello Clément,
Quoted 32 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +15
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir"; + reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir";Quoted 8 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 5 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +4
-0+ resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
Quoted 5 lines
I'm planning to send a v4 next week with the
IRQ_NONEreturn as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4But maybe we could also use the bit 5 of the IRQ status.
Thanks, that's nice, but that will not make the HW work. That will just disable it. The comment is still necessary.
thank you,
o.
Quoted 21 lines
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernelSignature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCce7nHSktVsDKcR8GLRpD3WrN5yP3Nb_Hbu_Q9NjUQbSMw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
Signature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190531124630.q2guo54kjfzr7rkn%40core.my.home. For more options, visit https://groups.google.com/d/optout.
Re: [linux-sunxi] Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hi Ondrej,
Quoted 52 lines · Ondřej Jirman
Hello Clément,
Quoted 48 lines · Clément Péron
Hi Ondrej,
Quoted 44 lines · Ondřej Jirman
Hello Clément,
Quoted 27 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +10
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir";arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 10 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +9
-0+ reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
Quoted 8 lines
Quoted 5 lines
I'm planning to send a v4 next week with the
IRQ_NONEreturn as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4But maybe we could also use the bit 5 of the IRQ status.
Thanks, that's nice, but that will not make the HW work. That will just disable it. The comment is still necessary.
I have pushed a new version on my github.
https://github.com/clementperon/linux/commits/h6_ir_v4
I will submit it, if you are ok with it.
Thanks,
Clément
Quoted 25 lines
thank you,
o.Quoted 21 lines
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCce7nHSktVsDKcR8GLRpD3WrN5yP3Nb_Hbu_Q9NjUQbSMw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Signature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCcdMftAjCwk2_naE9VBGGqS%3DOY9xcqv6%2B5pDX2Z8O%3DL28w%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [linux-sunxi] Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hi Clément,
Quoted 59 lines · Clément Péron
Hi Ondrej,
Quoted 56 lines · Ondřej Jirman
Hello Clément,
Quoted 52 lines · Clément Péron
Hi Ondrej,
Quoted 36 lines · Ondřej Jirman
Hello Clément,
Quoted 32 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +15
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir"; + reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir";Quoted 8 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 5 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +4
-0+ resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
I'm planning to send a v4 next week with the
IRQ_NONEreturn as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4
Quoted 8 lines
Quoted 4 lines
Quoted 1 line
But maybe we could also use the bit 5 of the IRQ status.
Thanks, that's nice, but that will not make the HW work. That will just disable it. The comment is still necessary.
I have pushed a new version on my github.
https://github.com/clementperon/linux/commits/h6_ir_v4I will submit it, if you are ok with it.
the changes make it worse. Console is flooded with "Temporarily disable IRQ" and other symptoms are the same as I described before. Interrupts are not disabled in a any reasonable time. (I've waited for more > 5mins already.)
You probably need to disable interrupts right away, not wait for 100k failures.
thank you and regards,
o.
Quoted 33 lines
Thanks,
ClémentQuoted 25 lines
thank you,
o.Quoted 21 lines
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCce7nHSktVsDKcR8GLRpD3WrN5yP3Nb_Hbu_Q9NjUQbSMw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout._______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Signature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190604123355.m47ufmhtzuzfvmp7%40core.my.home. For more options, visit https://groups.google.com/d/optout.
Re: [linux-sunxi] Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hi Clément,
Quoted 69 lines · verejna
Hi Clément,
Quoted 66 lines · Clément Péron
Hi Ondrej,
Quoted 52 lines · Ondřej Jirman
Hello Clément,
Quoted 48 lines · Clément Péron
Hi Ondrej,
Quoted 44 lines · Ondřej Jirman
Hello Clément,
Quoted 27 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +10
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir";arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 10 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +9
-0+ reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
Quoted 8 lines
Quoted 5 lines
I'm planning to send a v4 next week with the
IRQ_NONEreturn as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4But maybe we could also use the bit 5 of the IRQ status.
Thanks, that's nice, but that will not make the HW work. That will just disable it. The comment is still necessary.
I have pushed a new version on my github.
https://github.com/clementperon/linux/commits/h6_ir_v4
Quoted 7 lines
Quoted 1 line
I will submit it, if you are ok with it.
the changes make it worse. Console is flooded with "Temporarily disable IRQ" and other symptoms are the same as I described before. Interrupts are not disabled in a any reasonable time. (I've waited for more > 5mins already.)
You probably need to disable interrupts right away, not wait for 100k failures.
Hmm, this is what the registers look like post-probe:
R_CIR:0x07040000 : 000000300x07040004 : 000000300x07040008 : 000000300x0704000c : 000000300x07040010 : 000000300x07040014 : 000000300x07040018 : 000000300x0704001c : 000000300x07040020 : 000000300x07040024 : 000000300x07040028 : 000000300x0704002c : 000000300x07040030 : 000000300x07040034 : 000000300x07040038 : 000000300x0704003c : 000000300x07040040 : 000000300x07040044 : 000000300x07040048 : 000000300x0704004c : 000000300x07040050 : 000000300x07040054 : 000000300x07040058 : 000000300x0704005c : 000000300x07040060 : 000000300x07040064 : 000000300x07040068 : 000000300x0704006c : 000000300x07040070 : 000000300x07040074 : 000000300x07040078 : 000000300x0704007c : 000000300x07040080 : 000000300x07040084 : 000000300x07040088 : 000000300x0704008c : 000000300x07040090 : 000000300x07040094 : 000000300x07040098 : 000000300x0704009c : 000000300x070400a0 : 000000300x070400a4 : 000000300x070400a8 : 000000300x070400ac : 000000300x070400b0 : 000000300x070400b4 : 000000300x070400b8 : 000000300x070400bc : 000000300x070400c0 : 000000300x070400c4 : 000000300x070400c8 : 000000300x070400cc : 000000300x070400d0 : 000000300x070400d4 : 000000300x070400d8 : 000000300x070400dc : 000000300x070400e0 : 000000300x070400e4 : 000000300x070400e8 : 000000300x070400ec : 000000300x070400f0 : 000000300x070400f4 : 000000300x070400f8 : 000000300x070400fc : 00000030
Clearly not right. It's just the R_CIR module, other modules have normal values.
I've checked:0x070101c0 : 81000002
(IR clock config register)0x070101cc : 00010000
(IR reset/bus clk gate reg)
static const char * const r_mod0_default_parents[] = { "osc32k", "osc24M" }; static SUNXI_CCU_MP_WITH_MUX_GATE(ir_clk, "ir",
r_mod0_default_parents, 0x1c0,
0, 5, /* M */
8, 2, /* P */
24, 1, /* mux */
BIT(31), /* gate */
0);static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0);
[RST_R_APB1_IR] = { 0x1cc, BIT(16) },So parent clock seems to be OK. But gate clock is not enabled, so the bus is not working.
And look at this!!:
static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0);
static SUNXI_CCU_GATE(r_apb1_w1_clk, "r-apb1-w1", "r-apb1",
0x1cc, BIT(0), 0);So, it's wrong w1 gate config!
You can drop your changes, because I've probbably found the root cause.
regards,
o.
Quoted 41 lines
thank you and regards,
o.Quoted 29 lines
Thanks,
ClémentQuoted 25 lines
thank you,
o.Quoted 21 lines
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCce7nHSktVsDKcR8GLRpD3WrN5yP3Nb_Hbu_Q9NjUQbSMw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.Quoted 4 lines
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Signature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190604144757.xvggmj6asyf44vuc%40core.my.home. For more options, visit https://groups.google.com/d/optout.
Re: [linux-sunxi] Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hi Ondrej,
Quoted 176 lines · Ondřej Jirman
Hi Clément,
Quoted 69 lines · verejna
Hi Clément,
Quoted 66 lines · Clément Péron
Hi Ondrej,
Quoted 52 lines · Ondřej Jirman
Hello Clément,
Quoted 48 lines · Clément Péron
Hi Ondrej,
Quoted 44 lines · Ondřej Jirman
Hello Clément,
Quoted 27 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +10
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir";arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 10 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +9
-0+ reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
Quoted 8 lines
Quoted 5 lines
I'm planning to send a v4 next week with the
IRQ_NONEreturn as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4But maybe we could also use the bit 5 of the IRQ status.
Thanks, that's nice, but that will not make the HW work. That will just disable it. The comment is still necessary.
I have pushed a new version on my github.
https://github.com/clementperon/linux/commits/h6_ir_v4Quoted 7 lines
Quoted 1 line
I will submit it, if you are ok with it.
the changes make it worse. Console is flooded with "Temporarily disable IRQ" and other symptoms are the same as I described before. Interrupts are not disabled in a any reasonable time. (I've waited for more > 5mins already.)
You probably need to disable interrupts right away, not wait for 100k failures.
Hmm, this is what the registers look like post-probe:
R_CIR:0x07040000: 000000300x07040004: 000000300x07040008: 000000300x0704000c: 000000300x07040010: 000000300x07040014: 000000300x07040018: 000000300x0704001c: 000000300x07040020: 000000300x07040024: 000000300x07040028: 000000300x0704002c: 000000300x07040030: 000000300x07040034: 000000300x07040038: 000000300x0704003c: 000000300x07040040: 000000300x07040044: 000000300x07040048: 000000300x0704004c: 000000300x07040050: 000000300x07040054: 000000300x07040058: 000000300x0704005c: 000000300x07040060: 000000300x07040064: 000000300x07040068: 000000300x0704006c: 000000300x07040070: 000000300x07040074: 000000300x07040078: 000000300x0704007c: 000000300x07040080: 000000300x07040084: 000000300x07040088: 000000300x0704008c: 000000300x07040090: 000000300x07040094: 000000300x07040098: 000000300x0704009c: 000000300x070400a0: 000000300x070400a4: 000000300x070400a8: 000000300x070400ac: 000000300x070400b0: 000000300x070400b4: 000000300x070400b8: 000000300x070400bc: 000000300x070400c0: 000000300x070400c4: 000000300x070400c8: 000000300x070400cc: 000000300x070400d0: 000000300x070400d4: 000000300x070400d8: 000000300x070400dc: 000000300x070400e0: 000000300x070400e4: 000000300x070400e8: 000000300x070400ec: 000000300x070400f0: 000000300x070400f4: 000000300x070400f8: 000000300x070400fc: 00000030Clearly not right. It's just the
R_CIRmodule, other modules have normal values.I've checked:
0x070101c0: 81000002
(IR clock config register)0x070101cc: 00010000
(IR reset/bus clk gate reg)static const char * const r_mod0_default_parents[] = { "osc32k", "osc24M" }; static SUNXI_CCU_MP_WITH_MUX_GATE(ir_clk, "ir",
r_mod0_default_parents, 0x1c0, 0, 5, /* M */ 8, 2, /* P */ 24, 1, /* mux */ BIT(31), /* gate */ 0);static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0); [RST_R_APB1_IR] = { 0x1cc, BIT(16) },So parent clock seems to be OK. But gate clock is not enabled, so the bus is not working.
And look at this!!:
Quoted 8 lines
static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0); static SUNXI_CCU_GATE(r_apb1_w1_clk, "r-apb1-w1", "r-apb1", 0x1cc, BIT(0), 0);So, it's wrong w1 gate config!
You can drop your changes, because I've probbably found the root cause.
Nice to see that you have found the issue, but I don't understand why It's working on my board on not on yours.
Regards,
Clément
Quoted 45 lines
regards,
o.Quoted 41 lines
thank you and regards,
o.Quoted 29 lines
Thanks,
ClémentQuoted 25 lines
thank you,
o.Quoted 21 lines
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCce7nHSktVsDKcR8GLRpD3WrN5yP3Nb_Hbu_Q9NjUQbSMw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.Quoted 4 lines
_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Re: [linux-sunxi] Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hi Clément,
Quoted 184 lines · Clément Péron
Hi Ondrej,
Quoted 181 lines · Ondřej Jirman
Hi Clément,
Quoted 69 lines · verejna
Hi Clément,
Quoted 66 lines · Clément Péron
Hi Ondrej,
Quoted 52 lines · Ondřej Jirman
Hello Clément,
Quoted 48 lines · Clément Péron
Hi Ondrej,
Quoted 44 lines · Ondřej Jirman
Hello Clément,
Quoted 27 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +10
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir";arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 10 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +9
-0+ reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
Quoted 8 lines
Quoted 5 lines
I'm planning to send a v4 next week with the
IRQ_NONEreturn as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4But maybe we could also use the bit 5 of the IRQ status.
Thanks, that's nice, but that will not make the HW work. That will just disable it. The comment is still necessary.
I have pushed a new version on my github.
https://github.com/clementperon/linux/commits/h6_ir_v4Quoted 7 lines
Quoted 1 line
I will submit it, if you are ok with it.
the changes make it worse. Console is flooded with "Temporarily disable IRQ" and other symptoms are the same as I described before. Interrupts are not disabled in a any reasonable time. (I've waited for more > 5mins already.)
You probably need to disable interrupts right away, not wait for 100k failures.
Hmm, this is what the registers look like post-probe:
R_CIR:0x07040000: 000000300x07040004: 000000300x07040008: 000000300x0704000c: 000000300x07040010: 000000300x07040014: 000000300x07040018: 000000300x0704001c: 000000300x07040020: 000000300x07040024: 000000300x07040028: 000000300x0704002c: 000000300x07040030: 000000300x07040034: 000000300x07040038: 000000300x0704003c: 000000300x07040040: 000000300x07040044: 000000300x07040048: 000000300x0704004c: 000000300x07040050: 000000300x07040054: 000000300x07040058: 000000300x0704005c: 000000300x07040060: 000000300x07040064: 000000300x07040068: 000000300x0704006c: 000000300x07040070: 000000300x07040074: 000000300x07040078: 000000300x0704007c: 000000300x07040080: 000000300x07040084: 000000300x07040088: 000000300x0704008c: 000000300x07040090: 000000300x07040094: 000000300x07040098: 000000300x0704009c: 000000300x070400a0: 000000300x070400a4: 000000300x070400a8: 000000300x070400ac: 000000300x070400b0: 000000300x070400b4: 000000300x070400b8: 000000300x070400bc: 000000300x070400c0: 000000300x070400c4: 000000300x070400c8: 000000300x070400cc: 000000300x070400d0: 000000300x070400d4: 000000300x070400d8: 000000300x070400dc: 000000300x070400e0: 000000300x070400e4: 000000300x070400e8: 000000300x070400ec: 000000300x070400f0: 000000300x070400f4: 000000300x070400f8: 000000300x070400fc: 00000030Clearly not right. It's just the
R_CIRmodule, other modules have normal values.I've checked:
0x070101c0: 81000002
(IR clock config register)0x070101cc: 00010000
(IR reset/bus clk gate reg)static const char * const r_mod0_default_parents[] = { "osc32k", "osc24M" }; static SUNXI_CCU_MP_WITH_MUX_GATE(ir_clk, "ir",
r_mod0_default_parents, 0x1c0, 0, 5, /* M */ 8, 2, /* P */ 24, 1, /* mux */ BIT(31), /* gate */ 0);static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0); [RST_R_APB1_IR] = { 0x1cc, BIT(16) },So parent clock seems to be OK. But gate clock is not enabled, so the bus is not working.
And look at this!!:
static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0); static SUNXI_CCU_GATE(r_apb1_w1_clk, "r-apb1-w1", "r-apb1", 0x1cc, BIT(0), 0);
Quoted 6 lines
Quoted 3 lines
So, it's wrong w1 gate config!
You can drop your changes, because I've probbably found the root cause.
Nice to see that you have found the issue, but I don't understand why It's working on my board on not on yours.
Maybe you use modules? I have a builtin driver.
That may change initialization order. It would disable unused gates first, and when you load the module later from userpsace then it would enable the gate.
If builtin, then it would enable IR gate first, and then disable the unused gates (W1 in this case), later on when entering userspace.
Anyway, I can confirm that now, when I turn on the light in the room, I get around 10 interrupts with empty FIFO and than it stops.
It doesn't cause the flood anymore.
regards,
o.
Quoted 53 lines
Regards,
ClémentQuoted 45 lines
regards,
o.Quoted 41 lines
thank you and regards,
o.Quoted 29 lines
Thanks,
ClémentQuoted 25 lines
thank you,
o.Quoted 21 lines
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCce7nHSktVsDKcR8GLRpD3WrN5yP3Nb_Hbu_Q9NjUQbSMw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.Quoted 4 lines
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Signature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190604153006.g53kzhnx3hzpg5qh%40core.my.home. For more options, visit https://groups.google.com/d/optout.
Re: [linux-sunxi] Re: [PATCH v3 10/12] arm64: dts: allwinner: h6: Add IR receiver node
Hi Ondrej,
Quoted 188 lines · Ondřej Jirman
Hi Clément,
Quoted 184 lines · Clément Péron
Hi Ondrej,
Quoted 181 lines · Ondřej Jirman
Hi Clément,
Quoted 69 lines · verejna
Hi Clément,
Quoted 66 lines · Clément Péron
Hi Ondrej,
Quoted 52 lines · Ondřej Jirman
Hello Clément,
Quoted 48 lines · Clément Péron
Hi Ondrej,
Quoted 44 lines · Ondřej Jirman
Hello Clément,
Quoted 27 lines · Clément Péron
Allwinner H6 IR is similar to A31 and can use same driver.
Add support for it.
Signed-off-by Clément Péron <[email protected]>--- arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+)arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +10
-0@@ -647,6 +647,25 @@ pins = "PL0", "PL1"; function = "s_i2c"; }; + + r_ir_rx_pin: r-ir-rx-pin { + pins = "PL9"; + function = "s_cir_rx"; + }; + }; + + r_ir: ir@7040000 { + compatible = "allwinner,sun50i-h6-ir", + "allwinner,sun6i-a31-ir";arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi line 669
Quoted 10 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +9
-0+ reg = <0x07040000 0x400>; + interrupts = <GIC_SPI 109 IRQ_TYPE_LEVEL_HIGH>; + clocks = <&r_ccu CLK_R_APB1_IR>, + <&r_ccu CLK_IR>; + clock-names = "apb", "ir"; + resets = <&r_ccu RST_R_APB1_IR>; + pinctrl-names = "default"; + pinctrl-0 = <&r_ir_rx_pin>; + status = "disabled"; };Please make a comment here, that this is known broken on some boards and may result IRQ flood if enabled. Otherwise noone will know.
Quoted 8 lines
Quoted 5 lines
I'm planning to send a v4 next week with the
IRQ_NONEreturn as Maxime suggested it.
https://github.com/clementperon/linux/tree/h6_ir_v4But maybe we could also use the bit 5 of the IRQ status.
Thanks, that's nice, but that will not make the HW work. That will just disable it. The comment is still necessary.
I have pushed a new version on my github.
https://github.com/clementperon/linux/commits/h6_ir_v4Quoted 7 lines
Quoted 1 line
I will submit it, if you are ok with it.
the changes make it worse. Console is flooded with "Temporarily disable IRQ" and other symptoms are the same as I described before. Interrupts are not disabled in a any reasonable time. (I've waited for more > 5mins already.)
You probably need to disable interrupts right away, not wait for 100k failures.
Hmm, this is what the registers look like post-probe:
R_CIR:0x07040000: 000000300x07040004: 000000300x07040008: 000000300x0704000c: 000000300x07040010: 000000300x07040014: 000000300x07040018: 000000300x0704001c: 000000300x07040020: 000000300x07040024: 000000300x07040028: 000000300x0704002c: 000000300x07040030: 000000300x07040034: 000000300x07040038: 000000300x0704003c: 000000300x07040040: 000000300x07040044: 000000300x07040048: 000000300x0704004c: 000000300x07040050: 000000300x07040054: 000000300x07040058: 000000300x0704005c: 000000300x07040060: 000000300x07040064: 000000300x07040068: 000000300x0704006c: 000000300x07040070: 000000300x07040074: 000000300x07040078: 000000300x0704007c: 000000300x07040080: 000000300x07040084: 000000300x07040088: 000000300x0704008c: 000000300x07040090: 000000300x07040094: 000000300x07040098: 000000300x0704009c: 000000300x070400a0: 000000300x070400a4: 000000300x070400a8: 000000300x070400ac: 000000300x070400b0: 000000300x070400b4: 000000300x070400b8: 000000300x070400bc: 000000300x070400c0: 000000300x070400c4: 000000300x070400c8: 000000300x070400cc: 000000300x070400d0: 000000300x070400d4: 000000300x070400d8: 000000300x070400dc: 000000300x070400e0: 000000300x070400e4: 000000300x070400e8: 000000300x070400ec: 000000300x070400f0: 000000300x070400f4: 000000300x070400f8: 000000300x070400fc: 00000030Clearly not right. It's just the
R_CIRmodule, other modules have normal values.I've checked:
0x070101c0: 81000002
(IR clock config register)0x070101cc: 00010000
(IR reset/bus clk gate reg)static const char * const r_mod0_default_parents[] = { "osc32k", "osc24M" }; static SUNXI_CCU_MP_WITH_MUX_GATE(ir_clk, "ir",
r_mod0_default_parents, 0x1c0, 0, 5, /* M */ 8, 2, /* P */ 24, 1, /* mux */ BIT(31), /* gate */ 0);static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0); [RST_R_APB1_IR] = { 0x1cc, BIT(16) },So parent clock seems to be OK. But gate clock is not enabled, so the bus is not working.
And look at this!!:
static SUNXI_CCU_GATE(r_apb1_ir_clk, "r-apb1-ir", "r-apb1",
0x1cc, BIT(0), 0); static SUNXI_CCU_GATE(r_apb1_w1_clk, "r-apb1-w1", "r-apb1", 0x1cc, BIT(0), 0);
Quoted 8 lines
Quoted 6 lines
Quoted 3 lines
So, it's wrong w1 gate config!
You can drop your changes, because I've probbably found the root cause.
Nice to see that you have found the issue, but I don't understand why It's working on my board on not on yours.
Maybe you use modules? I have a builtin driver.
Correct,
Quoted 6 lines
That may change initialization order. It would disable unused gates first, and when you load the module later from userpsace then it would enable the gate.
If builtin, then it would enable IR gate first, and then disable the unused gates (W1 in this case), later on when entering userspace.
Thanks for the explanation it makes sense.
Quoted 3 lines
Anyway, I can confirm that now, when I turn on the light in the room, I get around 10 interrupts with empty FIFO and than it stops.
Ok I will push a V4 with just the introduction of the RXSTA.
Regards,
Clément
Quoted 59 lines
It doesn't cause the flood anymore.
regards,
o.Quoted 53 lines
Regards,
ClémentQuoted 45 lines
regards,
o.Quoted 41 lines
thank you and regards,
o.Quoted 29 lines
Thanks,
ClémentQuoted 25 lines
thank you,
o.Quoted 21 lines
Regards, Clement
Quoted 13 lines
thanks,
o.Quoted 9 lines
arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi +0
-1r_i2c: i2c@7081400 { --2.20.1
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCce7nHSktVsDKcR8GLRpD3WrN5yP3Nb_Hbu_Q9NjUQbSMw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.Quoted 4 lines
_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel_______________________________________________
linux-arm-kernel mailing list linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Signature · 4 lines
You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/CAJiuCcc1D1RVdpZG4bEeYWbCr8isWfP-2O9DAt-%2BavcrSp0f9Q%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 11/12 arm64: dts: allwinner: h6: Enable IR on Beelink GS1
In reply to Clément PéronBeelink GS1 has an IR receiver.
Enable it in the device-tree.
--- arch/arm64/boot/dts/allwinner/sun50i-h6-beelink-gs1.dts | 4 ++++ 1 file changed, 4 insertions(+)
arch/arm64/boot/dts/allwinner/sun50i-h6-beelink-gs1.dts +4 -0
@@ -232,6 +232,10 @@ }; }; +&r_ir { + status = "okay"; +}; + &r_pio { /* * PL0 and PL1 are used for PMIC I2C
Signature · 7 lines
2.20.1 -- You received this message because you are subscribed to the Google Groups "linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected] To view this discussion on the web, visit https://groups.google.com/d/msgid/linux-sunxi/20190528161440.27172-12-peron.clem%40gmail.com. For more options, visit https://groups.google.com/d/optout.
PATCH v3 12/12 arm64: defconfig: enable IR SUNXI option
In reply to Clément PéronEnable CONFIG_IR_SUNXI option for ARM64, so that Allwinner A64/H6 SoCs can use their IR receiver controller.
--- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+)
arch/arm64/configs/defconfig +1 -0
@@ -460,6 +460,7 @@ CONFIG_RC_CORE=m CONFIG_RC_DECODERS=y CONFIG_RC_DEVICES=y CONFIG_IR_MESON=m +CONFIG_IR_SUNXI=m CONFIG_MEDIA_SUPPORT=m CONFIG_MEDIA_CAMERA_SUPPORT=y CONFIG_MEDIA_ANALOG_TV_SUPPORT=y
Signature · 1 line
2.20.1
Quoted 5 lines · Clément Péron
Hi,
A64 IR support series[1] pointed out that an A31 bindings should be introduced.
Quoted 7 lines
This series introduce the A31 compatible bindings, then switch it on the already existing board.
Finally introduce A64 and H6 support.
I didn't enable the IR on other H6 boards as Ondrej reported an issue on his board[2].
For the whole series:
Quoted 50 lines
Regards,
Clément[1] https://lore.kernel.org/patchwork/patch/1031390/#1221464
[2] https://lkml.org/lkml/2019/5/27/321Changes since v2:
- Disable IR for other H6 boards
- Split DTS patch for H3/H5
- Introduce IR quirksChanges since v1:
- Document reset lines as required since A31
- Explain the memory mapping difference in commit log
- Fix misspelling "Allwiner" to "Allwinner"Clément Péron (10):
dt-bindings: media: sunxi-ir: add A31 compatible
media: rc: Introducesunxi_ir_quirks
media: rc: sunxi: Add A31 compatible
ARM: dts: sunxi: Prefer A31 bindings for IR
ARM: dts: sunxi: Prefer A31 bindings for IR
dt-bindings: media: sunxi-ir: Add A64 compatible
dt-bindings: media: sunxi-ir: Add H6 compatible
arm64: dts: allwinner: h6: Add IR receiver node
arm64: dts: allwinner: h6: Enable IR on Beelink GS1
arm64: defconfig: enable IR SUNXI optionIgors Makejevs (1):
arm64: dts: allwinner: a64: Add IR nodeJernej Skrabec (1):
arm64: dts: allwinner: a64: Enable IR on Orange Pi Win.../devicetree/bindings/media/sunxi-ir.txt | 11 ++- arch/arm/boot/dts/sun6i-a31.dtsi | 2 +- arch/arm/boot/dts/sun8i-a83t.dtsi | 2 +- arch/arm/boot/dts/sun9i-a80.dtsi | 2 +- arch/arm/boot/dts/sunxi-h3-h5.dtsi | 2 +- .../dts/allwinner/sun50i-a64-orangepi-win.dts | 4 ++ arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 18 +++++ .../dts/allwinner/sun50i-h6-beelink-gs1.dts | 4 ++ arch/arm64/boot/dts/allwinner/sun50i-h6.dtsi | 19 +++++ arch/arm64/configs/defconfig | 1 + drivers/media/rc/sunxi-cir.c | 70 +++++++++++++++---- 11 files changed, 115 insertions(+), 20 deletions(-)Signature · 1 line
2.20.1