/linux/drivers/input/keyboard/ |
H A D | sun4i-lradc-keys.c | 111 struct sun4i_lradc_data *lradc = dev_id; in sun4i_lradc_irq() local 114 ints = readl(lradc->base + LRADC_INTS); in sun4i_lradc_irq() 122 input_report_key(lradc->input, lradc->chan0_keycode, 0); in sun4i_lradc_irq() 123 lradc->chan0_keycode = 0; in sun4i_lradc_irq() 126 if ((ints & CHAN0_KEYDOWN_IRQ) && lradc->chan0_keycode == 0) { in sun4i_lradc_irq() 127 val = readl(lradc->base + LRADC_DATA0) & 0x3f; in sun4i_lradc_irq() 128 voltage = val * lradc->vref / 63; in sun4i_lradc_irq() 130 for (i = 0; i < lradc->chan0_map_count; i++) { in sun4i_lradc_irq() 131 diff = abs(lradc->chan0_map[i].voltage - voltage); in sun4i_lradc_irq() 134 keycode = lradc->chan0_map[i].keycode; in sun4i_lradc_irq() [all …]
|
H A D | Makefile | 66 obj-$(CONFIG_KEYBOARD_SUN4I_LRADC) += sun4i-lradc-keys.o
|
/linux/drivers/mfd/ |
H A D | mxs-lradc.c | 130 struct mxs_lradc *lradc; in mxs_lradc_probe() local 136 lradc = devm_kzalloc(&pdev->dev, sizeof(*lradc), GFP_KERNEL); in mxs_lradc_probe() 137 if (!lradc) in mxs_lradc_probe() 140 lradc->soc = (kernel_ulong_t)device_get_match_data(&pdev->dev); in mxs_lradc_probe() 142 lradc->clk = devm_clk_get(&pdev->dev, NULL); in mxs_lradc_probe() 143 if (IS_ERR(lradc->clk)) { in mxs_lradc_probe() 145 return PTR_ERR(lradc->clk); in mxs_lradc_probe() 148 ret = clk_prepare_enable(lradc->clk); in mxs_lradc_probe() 158 lradc->buffer_vchans = BUFFER_VCHANS_LIMITED; in mxs_lradc_probe() 162 lradc->touchscreen_wire = MXS_LRADC_TOUCHSCREEN_4WIRE; in mxs_lradc_probe() [all …]
|
/linux/drivers/input/touchscreen/ |
H A D | mxs-lradc-ts.c | 42 struct mxs_lradc *lradc; member 274 struct mxs_lradc *lradc = ts->lradc; in mxs_lradc_setup_touch_detection() local 282 writel(info[lradc->soc].mask, in mxs_lradc_setup_touch_detection() 284 writel(info[lradc->soc].bit, in mxs_lradc_setup_touch_detection() 302 struct mxs_lradc *lradc = ts->lradc; in mxs_lradc_prepare_x_pos() local 304 writel(info[lradc->soc].mask, in mxs_lradc_prepare_x_pos() 306 writel(info[lradc->soc].x_plate, in mxs_lradc_prepare_x_pos() 328 struct mxs_lradc *lradc = ts->lradc; in mxs_lradc_prepare_y_pos() local 330 writel(info[lradc->soc].mask, in mxs_lradc_prepare_y_pos() 332 writel(info[lradc->soc].y_plate, in mxs_lradc_prepare_y_pos() [all …]
|
/linux/Documentation/devicetree/bindings/mfd/ |
H A D | mxs-lradc.txt | 4 - compatible: Should be "fsl,imx23-lradc" for i.MX23 SoC and "fsl,imx28-lradc" 10 - fsl,lradc-touchscreen-wires: Number of wires used to connect the touchscreen 25 lradc@80050000 { 26 compatible = "fsl,imx23-lradc"; 29 fsl,lradc-touchscreen-wires = <4>; 37 lradc@80050000 { 38 compatible = "fsl,imx28-lradc"; 41 fsl,lradc-touchscreen-wires = <5>;
|
/linux/arch/riscv/boot/dts/allwinner/ |
H A D | sun20i-d1.dtsi | 9 lradc: keys@2009800 { label 10 compatible = "allwinner,sun20i-d1-lradc", 11 "allwinner,sun50i-r329-lradc";
|
/linux/include/linux/mfd/ |
H A D | mxs-lradc.h | 166 static inline u32 mxs_lradc_irq_mask(struct mxs_lradc *lradc) in mxs_lradc_irq_mask() argument 168 switch (lradc->soc) { in mxs_lradc_irq_mask()
|
/linux/arch/arm/boot/dts/nxp/mxs/ |
H A D | imx28-cfa10058.dts | 67 &lradc { 68 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx23-evk.dts | 103 lradc@80050000 { 105 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx28-cfa10057.dts | 67 &lradc { 68 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx28-cfa10055.dts | 81 &lradc { 82 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx28-apf28dev.dts | 111 &lradc { 112 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx23.dtsi | 525 lradc: lradc@80050000 { label 526 compatible = "fsl,imx23-lradc"; 633 io-channels = <&lradc 8>;
|
H A D | imx28-m28evk.dts | 127 &lradc { 129 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx28-eukrea-mbmx28lc.dtsi | 176 &lradc { 177 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx28-evk.dts | 179 &lradc { 180 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx28-cfa10049.dts | 230 &lradc { 231 fsl,lradc-touchscreen-wires = <4>;
|
H A D | imx23-olinuxino.dts | 68 lradc@80050000 {
|
H A D | imx28-duckbill.dts | 59 &lradc {
|
H A D | imx28-duckbill-2.dts | 66 &lradc {
|
/linux/arch/arm/boot/dts/allwinner/ |
H A D | suniv-f1c100s.dtsi | 289 lradc: lradc@1c23400 { label 290 compatible = "allwinner,suniv-f1c100s-lradc", 291 "allwinner,sun8i-a83t-r-lradc";
|
H A D | sun8i-v3-sl631.dtsi | 42 &lradc {
|
H A D | sun5i-a13-pocketbook-614-plus.dts | 94 &lradc {
|
H A D | sun6i-a31s-colorfly-e708-q1.dts | 52 &lradc {
|
/linux/drivers/clk/mxs/ |
H A D | clk-imx28.c | 139 clk32k_div, rtc, lradc, spdif_div, clk32k, pwm, uart, ssp0, enumerator 208 clks[lradc] = mxs_clk_fixed_factor("lradc", "clk32k", 1, 16); in mx28_clocks_init()
|