[PATCH 04/23] fore200e: use ASSERT_FAIL()/ASSERT_WARN() to cleanup some code

Chunguang Xu
2020-08-27T10:18:21Z

drivers/atm/fore200e.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/drivers/atm/fore200e.c b/drivers/atm/fore200e.c
index a81bc49..04f121b 100644
--- a/drivers/atm/fore200e.c
+++ b/drivers/atm/fore200e.c
@@ -83,11 +83,7 @@
#define FORE200E_NEXT_ENTRY(index, modulo) (index = ((index) + 1) % (modulo))

#if 1
-#define ASSERT(expr) if (!(expr)) { \
- printk(FORE200E "assertion failed! %s[%d]: %s\n", \
- __func__, __LINE__, #expr); \
- panic(FORE200E "%s", __func__); \
- }
+#define ASSERT(expr) ASSERT_FAIL(expr)
#else
#define ASSERT(expr) do {} while (0)
#endif
--
1.8.3.1