I'm trying to enable interrupts for the si476x driver on i.MX6Q, but I'm having trouble. First of all, it seems that the IRQF_ONESHOT flag needs to be set, otherwise the interrupt can't be initialised at all.
Next I can't seem to generate an interrupt when I have the IRQF_TRIGGER_FALLING flag set. However, when I have the IRQF_TRIGGER_LOW flag set, I am generating interrupts all the time, even when my scope says I should not be generating any.
si476x-i2c.c
Device Tree:
sound-fm {
compatible = "fsl,imx-audio-si476x",
"fsl,imx-tuner-si476x";
model = "imx-radio-si4763";
ssi-controller = <&ssi2>;
fm-controller = <&si476x_codec>;
mux-int-port = <2>;
mux-ext-port = <5>;
};si4763: si4763@63 {
compatible = "si4761";
reg = <0x63>;
va-supply = <®_si4763_va>;
vd-supply = <®_si4763_vd>;
vio1-supply = <®_si4763_vio1>;
vio2-supply = <®_si4763_vio2>;
revision-a10; /* set to default A10 compatible command set */interrupts-extended = <&gpio5 29 IRQ_TYPE_EDGE_FALLING>;
si476x_codec: si476x-codec {
compatible = "si476x-codec";
};};
I've read the documentation and looked at other examples of drivers and can't figure out why this isn't working for me.
Any help is appreciated, thanks,
Nathan
Hi Nathan
available device tree si476x options are described in
Documentation/devicetree/bindings/sound/imx-audio-si476x.txt
http://git.freescale.com/git/cgit.cgi/imx/linux-imx.git/tree/Documentation/devicetree/bindings/sound...
Seems interrupt configuration is not implemented in driver and if necessary, one can add such codes:
linux/sound/soc/fsl/imx-si476x.c
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Yes, I am modifying the source code.