9838b7032e
This is strictly the application of the script 'x-indent-all.sh' from util/modular. Compared to the patch that Daniel posted in January, I've added a few indent flags: -bap -psl -T PrivatePtr -T pmWait -T _XFUNCPROTOBEGIN -T _XFUNCPROTOEND -T _X_EXPORT The typedefs were needed to make the output of sdksyms.sh match the previous output, otherwise, the code is formatted badly enough that sdksyms.sh generates incorrect output. The generated code was compared with the previous version and found to be essentially identical -- "assert" line numbers and BUILD_TIME were the only differences found. The comparison was done with this script: dir1=$1 dir2=$2 for dir in $dir1 $dir2; do (cd $dir && find . -name '*.o' | while read file; do dir=`dirname $file` base=`basename $file .o` dump=$dir/$base.dump objdump -d $file > $dump done) done find $dir1 -name '*.dump' | while read dump; do otherdump=`echo $dump | sed "s;$dir1;$dir2;"` diff -u $dump $otherdump done Signed-off-by: Keith Packard <keithp@keithp.com> Acked-by: Daniel Stone <daniel@fooishbar.org> Acked-by: Alan Coopersmith <alan.coopersmith@oracle.com>
45 lines
1.1 KiB
C
45 lines
1.1 KiB
C
#ifndef __TDA8425_H__
|
|
#define __TDA8425_H__
|
|
|
|
#include "xf86i2c.h"
|
|
|
|
typedef struct {
|
|
I2CDevRec d;
|
|
|
|
int mux;
|
|
int stereo;
|
|
int v_left;
|
|
int v_right;
|
|
int bass;
|
|
int treble;
|
|
int src_sel;
|
|
Bool mute;
|
|
} TDA8425Rec, *TDA8425Ptr;
|
|
|
|
#define TDA8425_ADDR_1 0x82
|
|
|
|
/* the third parameter is meant to force detection of tda8425.
|
|
This is because tda8425 is write-only and complete implementation
|
|
of I2C protocol is not always available. Besides address there is no good
|
|
way to autodetect it so we have to _know_ it is there anyway */
|
|
|
|
#define xf86_Detect_tda8425 Detect_tda8425
|
|
extern _X_EXPORT TDA8425Ptr Detect_tda8425(I2CBusPtr b, I2CSlaveAddr addr,
|
|
Bool force);
|
|
#define xf86_tda8425_init tda8425_init
|
|
extern _X_EXPORT Bool tda8425_init(TDA8425Ptr t);
|
|
|
|
#define xf86_tda8425_setaudio tda8425_setaudio
|
|
extern _X_EXPORT void tda8425_setaudio(TDA8425Ptr t);
|
|
|
|
#define xf86_tda8425_mute tda8425_mute
|
|
extern _X_EXPORT void tda8425_mute(TDA8425Ptr t, Bool mute);
|
|
|
|
#define TDA8425SymbolsList \
|
|
"Detect_tda8425", \
|
|
"tda8425_init", \
|
|
"tda8425_setaudio", \
|
|
"tda8425_mute"
|
|
|
|
#endif
|