Home
last modified time | relevance | path

Searched refs:lradc (Results 1 – 25 of 79) sorted by relevance

1234

/Linux-v6.1/drivers/input/keyboard/
Dsun4i-lradc-keys.c110 struct sun4i_lradc_data *lradc = dev_id; in sun4i_lradc_irq() local
113 ints = readl(lradc->base + LRADC_INTS); in sun4i_lradc_irq()
121 input_report_key(lradc->input, lradc->chan0_keycode, 0); in sun4i_lradc_irq()
122 lradc->chan0_keycode = 0; in sun4i_lradc_irq()
125 if ((ints & CHAN0_KEYDOWN_IRQ) && lradc->chan0_keycode == 0) { in sun4i_lradc_irq()
126 val = readl(lradc->base + LRADC_DATA0) & 0x3f; in sun4i_lradc_irq()
127 voltage = val * lradc->vref / 63; in sun4i_lradc_irq()
129 for (i = 0; i < lradc->chan0_map_count; i++) { in sun4i_lradc_irq()
130 diff = abs(lradc->chan0_map[i].voltage - voltage); in sun4i_lradc_irq()
133 keycode = lradc->chan0_map[i].keycode; in sun4i_lradc_irq()
[all …]
DMakefile69 obj-$(CONFIG_KEYBOARD_SUN4I_LRADC) += sun4i-lradc-keys.o
/Linux-v6.1/drivers/mfd/
Dmxs-lradc.c131 struct mxs_lradc *lradc; in mxs_lradc_probe() local
137 lradc = devm_kzalloc(&pdev->dev, sizeof(*lradc), GFP_KERNEL); in mxs_lradc_probe()
138 if (!lradc) in mxs_lradc_probe()
145 lradc->soc = (enum mxs_lradc_id)of_id->data; in mxs_lradc_probe()
147 lradc->clk = devm_clk_get(&pdev->dev, NULL); in mxs_lradc_probe()
148 if (IS_ERR(lradc->clk)) { in mxs_lradc_probe()
150 return PTR_ERR(lradc->clk); in mxs_lradc_probe()
153 ret = clk_prepare_enable(lradc->clk); in mxs_lradc_probe()
163 lradc->buffer_vchans = BUFFER_VCHANS_LIMITED; in mxs_lradc_probe()
167 lradc->touchscreen_wire = MXS_LRADC_TOUCHSCREEN_4WIRE; in mxs_lradc_probe()
[all …]
/Linux-v6.1/drivers/input/touchscreen/
Dmxs-lradc-ts.c42 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-v6.1/drivers/iio/adc/
Dmxs-lradc-adc.c114 struct mxs_lradc *lradc; member
135 struct mxs_lradc *lradc = adc->lradc; in mxs_lradc_adc_read_single() local
155 if (lradc->soc == IMX28_LRADC) in mxs_lradc_adc_read_single()
388 struct mxs_lradc *lradc = adc->lradc; in mxs_lradc_adc_handle_irq() local
392 if (!(reg & mxs_lradc_irq_mask(lradc))) in mxs_lradc_adc_handle_irq()
396 if (reg & lradc->buffer_vchans) { in mxs_lradc_adc_handle_irq()
405 writel(reg & mxs_lradc_irq_mask(lradc), in mxs_lradc_adc_handle_irq()
486 struct mxs_lradc *lradc = adc->lradc; in mxs_lradc_adc_buffer_preenable() local
495 if (lradc->soc == IMX28_LRADC) in mxs_lradc_adc_buffer_preenable()
496 writel(lradc->buffer_vchans << LRADC_CTRL1_LRADC_IRQ_EN_OFFSET, in mxs_lradc_adc_buffer_preenable()
[all …]
/Linux-v6.1/Documentation/devicetree/bindings/mfd/
Dmxs-lradc.txt4 - 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-v6.1/include/linux/mfd/
Dmxs-lradc.h166 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-v6.1/arch/arm/boot/dts/
Dimx23-evk.dts103 lradc@80050000 {
105 fsl,lradc-touchscreen-wires = <4>;
Dimx28-cfa10058.dts78 lradc@80050000 {
79 fsl,lradc-touchscreen-wires = <4>;
Dimx28-cfa10055.dts119 lradc@80050000 {
120 fsl,lradc-touchscreen-wires = <4>;
Dimx28-cfa10057.dts105 lradc@80050000 {
106 fsl,lradc-touchscreen-wires = <4>;
Dimx28-apf28dev.dts117 lradc@80050000 {
118 fsl,lradc-touchscreen-wires = <4>;
Dimx23.dtsi527 lradc: lradc@80050000 { label
528 compatible = "fsl,imx23-lradc";
634 io-channels = <&lradc 8>;
Dimx28-m28evk.dts151 lradc@80050000 {
153 fsl,lradc-touchscreen-wires = <4>;
Dimx28-eukrea-mbmx28lc.dtsi186 &lradc {
187 fsl,lradc-touchscreen-wires = <4>;
Dimx28-evk.dts239 lradc@80050000 {
241 fsl,lradc-touchscreen-wires = <4>;
Dsun8i-v3-sl631.dtsi42 &lradc {
Dimx23-olinuxino.dts68 lradc@80050000 {
Dimx28-cfa10049.dts285 lradc@80050000 {
287 fsl,lradc-touchscreen-wires = <4>;
Dimx28-duckbill.dts77 lradc@80050000 {
Dimx28-duckbill-2.dts92 lradc@80050000 {
Dimx28-duckbill-2-485.dts94 lradc@80050000 {
Dimx28-duckbill-2-spi.dts120 lradc@80050000 {
Dsun4i-a10-topwise-a721.dts126 &lradc {
/Linux-v6.1/drivers/clk/mxs/
Dclk-imx28.c139 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()

1234