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)     cx24110 - Single Chip Satellite Channel Receiver driver module
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5)     Copyright (C) 2002 Peter Hettkamp <peter.hettkamp@htp-tel.de> based on
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6)     work
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7)     Copyright (C) 1999 Convergence Integrated Media GmbH <ralph@convergence.de>
^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) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) #ifndef CX24110_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) #define CX24110_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) #include <linux/dvb/frontend.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) struct cx24110_config
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) 	/* the demodulator's i2c address */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) 	u8 demod_address;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) };
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) static inline int cx24110_pll_write(struct dvb_frontend *fe, u32 val)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) 	u8 buf[] = {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 		(u8)((val >> 24) & 0xff),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) 		(u8)((val >> 16) & 0xff),
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 		(u8)((val >> 8) & 0xff)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) 	};
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) 	if (fe->ops.write)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) 		return fe->ops.write(fe, buf, 3);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) #if IS_REACHABLE(CONFIG_DVB_CX24110)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) extern struct dvb_frontend* cx24110_attach(const struct cx24110_config* config,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 					   struct i2c_adapter* i2c);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) #else
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) static inline struct dvb_frontend* cx24110_attach(const struct cx24110_config* config,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) 						  struct i2c_adapter* i2c)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) 	printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) 	return NULL;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) #endif // CONFIG_DVB_CX24110
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) #endif // CX24110_H