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-or-later */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3)  * Linux driver for TerraTec DMX 6Fire USB
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5)  * Author:	Torsten Schenk <torsten.schenk@zoho.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6)  * Created:	Jan 01, 2011
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7)  * Copyright:	(C) Torsten Schenk
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8)  */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) #ifndef USB6FIRE_CONTROL_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) #define USB6FIRE_CONTROL_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) #include "common.h"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) enum {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) 	CONTROL_MAX_ELEMENTS = 32
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) enum {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) 	CONTROL_RATE_44KHZ,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) 	CONTROL_RATE_48KHZ,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 	CONTROL_RATE_88KHZ,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 	CONTROL_RATE_96KHZ,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) 	CONTROL_RATE_176KHZ,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) 	CONTROL_RATE_192KHZ,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 	CONTROL_N_RATES
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) struct control_runtime {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 	int (*update_streaming)(struct control_runtime *rt);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) 	int (*set_rate)(struct control_runtime *rt, int rate);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) 	int (*set_channels)(struct control_runtime *rt, int n_analog_out,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 		int n_analog_in, bool spdif_out, bool spdif_in);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) 	struct sfire_chip *chip;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) 	struct snd_kcontrol *element[CONTROL_MAX_ELEMENTS];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 	bool opt_coax_switch;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) 	bool line_phono_switch;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) 	bool digital_thru_switch;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) 	bool usb_streaming;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) 	u8 output_vol[6];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) 	u8 ovol_updated;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) 	u8 output_mute;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) 	s8 input_vol[2];
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) 	u8 ivol_updated;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) int usb6fire_control_init(struct sfire_chip *chip);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) void usb6fire_control_abort(struct sfire_chip *chip);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51) void usb6fire_control_destroy(struct sfire_chip *chip);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) #endif /* USB6FIRE_CONTROL_H */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53)