1 From d2563faf053da31e1329e7313339669f31c989da Mon Sep 17 00:00:00 2001
2 From: Christian Marangi <ansuelsmth@gmail.com>
3 Date: Wed, 20 Mar 2024 19:48:33 +0100
4 Subject: [PATCH] dahdi_echocan_mg2: rename ABS define to PARA_ABS
6 Rename ABS define to PARA_ABS to fix compilation error with mips 24kc
9 This target define in his ASM header a similar define ABS that cause
10 conflicts and redefinition error for this driver.
12 Rename ABS to PARA_ABS to better suite the usage as it's abs usage with
13 value decremented by one if it's the max negative int.
15 Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
17 drivers/dahdi/dahdi_echocan_mg2.c | 6 +++---
18 1 file changed, 3 insertions(+), 3 deletions(-)
20 --- a/drivers/dahdi/dahdi_echocan_mg2.c
21 +++ b/drivers/dahdi/dahdi_echocan_mg2.c
24 static int aggressive;
26 -#define ABS(a) abs(a!=-32768?a:-32767)
27 +#define PARA_ABS(a) abs(a!=-32768?a:-32767)
29 #define RESTORE_COEFFS {\
31 @@ -464,9 +464,9 @@ static inline short sample_update(struct
35 - sign_error = ABS(rs) - ABS(isig);
36 + sign_error = PARA_ABS(rs) - PARA_ABS(isig);
38 - if (ABS(sign_error) > MAX_SIGN_ERROR)
39 + if (PARA_ABS(sign_error) > MAX_SIGN_ERROR)