Commit 3ec50be588d773b408e82643c87c5a681b0354ad
Committed by
Greg Kroah-Hartman
1 parent
c01ef023ec
Exists in
smarc-l5.0.0_1.0.0-ga
and in
5 other branches
Staging: echo: One variable per line
Our convention is one (statement and) variable per line. Enforce this in drivers/staging/echo/echo.[ch] . Signed-off-by: Jesper Juhl <jj@chaosbits.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Showing 2 changed files with 26 additions and 11 deletions Side-by-side Diff
drivers/staging/echo/echo.c
... | ... | @@ -118,7 +118,8 @@ |
118 | 118 | #ifdef __bfin__ |
119 | 119 | static inline void lms_adapt_bg(struct oslec_state *ec, int clean, int shift) |
120 | 120 | { |
121 | - int i, j; | |
121 | + int i; | |
122 | + int j; | |
122 | 123 | int offset1; |
123 | 124 | int offset2; |
124 | 125 | int factor; |
... | ... | @@ -335,7 +336,8 @@ |
335 | 336 | { |
336 | 337 | int32_t echo_value; |
337 | 338 | int clean_bg; |
338 | - int tmp, tmp1; | |
339 | + int tmp; | |
340 | + int tmp1; | |
339 | 341 | |
340 | 342 | /* |
341 | 343 | * Input scaling was found be required to prevent problems when tx |
... | ... | @@ -624,7 +626,8 @@ |
624 | 626 | |
625 | 627 | int16_t oslec_hpf_tx(struct oslec_state *ec, int16_t tx) |
626 | 628 | { |
627 | - int tmp, tmp1; | |
629 | + int tmp; | |
630 | + int tmp1; | |
628 | 631 | |
629 | 632 | if (ec->adaption_mode & ECHO_CAN_USE_TX_HPF) { |
630 | 633 | tmp = tx << 15; |
drivers/staging/echo/echo.h
... | ... | @@ -36,7 +36,6 @@ |
36 | 36 | This module aims to provide G.168-2002 compliant echo cancellation, to remove |
37 | 37 | electrical echoes (e.g. from 2-4 wire hybrids) from voice calls. |
38 | 38 | |
39 | - | |
40 | 39 | How does it work? |
41 | 40 | |
42 | 41 | The heart of the echo cancellor is FIR filter. This is adapted to match the |
... | ... | @@ -128,7 +127,8 @@ |
128 | 127 | echo canceller. |
129 | 128 | */ |
130 | 129 | struct oslec_state { |
131 | - int16_t tx, rx; | |
130 | + int16_t tx; | |
131 | + int16_t rx; | |
132 | 132 | int16_t clean; |
133 | 133 | int16_t clean_nlp; |
134 | 134 | |
135 | 135 | |
... | ... | @@ -145,11 +145,18 @@ |
145 | 145 | int16_t shift; |
146 | 146 | |
147 | 147 | /* Average levels and averaging filter states */ |
148 | - int Ltxacc, Lrxacc, Lcleanacc, Lclean_bgacc; | |
149 | - int Ltx, Lrx; | |
148 | + int Ltxacc; | |
149 | + int Lrxacc; | |
150 | + int Lcleanacc; | |
151 | + int Lclean_bgacc; | |
152 | + int Ltx; | |
153 | + int Lrx; | |
150 | 154 | int Lclean; |
151 | 155 | int Lclean_bg; |
152 | - int Lbgn, Lbgn_acc, Lbgn_upper, Lbgn_upper_acc; | |
156 | + int Lbgn; | |
157 | + int Lbgn_acc; | |
158 | + int Lbgn_upper; | |
159 | + int Lbgn_upper_acc; | |
153 | 160 | |
154 | 161 | /* foreground and background filter states */ |
155 | 162 | struct fir16_state_t fir_state; |
156 | 163 | |
... | ... | @@ -157,11 +164,16 @@ |
157 | 164 | int16_t *fir_taps16[2]; |
158 | 165 | |
159 | 166 | /* DC blocking filter states */ |
160 | - int tx_1, tx_2, rx_1, rx_2; | |
167 | + int tx_1; | |
168 | + int tx_2; | |
169 | + int rx_1; | |
170 | + int rx_2; | |
161 | 171 | |
162 | 172 | /* optional High Pass Filter states */ |
163 | - int32_t xvtx[5], yvtx[5]; | |
164 | - int32_t xvrx[5], yvrx[5]; | |
173 | + int32_t xvtx[5]; | |
174 | + int32_t yvtx[5]; | |
175 | + int32_t xvrx[5]; | |
176 | + int32_t yvrx[5]; | |
165 | 177 | |
166 | 178 | /* Parameters for the optional Hoth noise generator */ |
167 | 179 | int cng_level; |