Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) /* SPDX-License-Identifier: GPL-2.0 */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) #ifndef RK_HEADSET_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3) #define RK_HEADSET_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5) #define HEADSET_IN_HIGH 0x00000001
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6) #define HEADSET_IN_LOW  0x00000000
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8) #define HOOK_DOWN_HIGH 0x00000001
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9) #define HOOK_DOWN_LOW  0x00000000
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) struct rk_headset_pdata {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) 	/* heaset about */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) 	unsigned int headset_gpio;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) 	/* Headphones into the state level */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) 	unsigned int headset_insert_type;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) 	/* hook about */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) 	unsigned int hook_gpio;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) 	/* Hook key down status */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) 	unsigned int hook_down_type;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) #ifdef CONFIG_MODEM_MIC_SWITCH
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) 	/* mic about */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 	unsigned int mic_switch_gpio;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 	unsigned int hp_mic_io_value;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) 	unsigned int main_mic_io_value;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) #endif
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 	struct iio_channel *chan;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) 	int headset_wakeup;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) #define HOOK_KEY_CODE KEY_MEDIA
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) int rk_headset_probe(struct platform_device *pdev,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 		     struct rk_headset_pdata *pdata);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) int rk_headset_adc_probe(struct platform_device *pdev,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) 			 struct rk_headset_pdata *pdata);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) int rk_headset_adc_suspend(struct platform_device *pdev, pm_message_t state);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) int rk_headset_adc_resume(struct platform_device *pdev);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) #endif