lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1f104cd576b71f53f01e0cd4ae5c57143231dd58.1598518912.git.brookxu@tencent.com>
Date:   Thu, 27 Aug 2020 18:14:28 +0800
From:   Chunguang Xu <brookxu.cn@...il.com>
To:     arnd@...db.de
Cc:     rppt@...nel.org, linux-arch@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: [PATCH 23/23] ALSA: asihpi: use ASSERT_FAIL()/ASSERT_WARN() to cleanup some code

Since ASSERT_FAIL() and ASSERT_WARN() have been provided, ASSERT()
may be realized through them, thus reducing code redundancy and
facilitating problem analysis.

Signed-off-by: Chunguang Xu <brookxu@...cent.com>
---
 sound/pci/asihpi/hpidebug.h | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/sound/pci/asihpi/hpidebug.h b/sound/pci/asihpi/hpidebug.h
index c24ed69..b65c8dc 100644
--- a/sound/pci/asihpi/hpidebug.h
+++ b/sound/pci/asihpi/hpidebug.h
@@ -34,13 +34,7 @@ enum { HPI_DEBUG_LEVEL_ERROR = 0,	/* always log errors */
 #define FILE_LINE  __FILE__ ":" __stringify(__LINE__) " "
 #endif
 
-#define HPI_DEBUG_ASSERT(expression) \
-	do { \
-		if (!(expression)) { \
-			printk(KERN_ERR  FILE_LINE \
-				"ASSERT " __stringify(expression)); \
-		} \
-	} while (0)
+#define HPI_DEBUG_ASSERT(expression) ASSERT_WARN(expression)
 
 #define HPI_DEBUG_LOG(level, ...) \
 	do { \
-- 
1.8.3.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ