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]
Date:   Sun, 9 Oct 2022 11:40:09 +0800
From:   Yang Yingliang <yangyingliang@...wei.com>
To:     <linux-kernel@...r.kernel.org>
CC:     <chenhuacai@...nel.org>, <lvjianmin@...ngson.cn>,
        <chenhuacai@...ngson.cn>
Subject: [PATCH -next 3/3] platform/loongarch: laptop: remove unnecessary BUG_ON in generic_subdriver_init()

The 'sub_driver' has already be check, remove BUG_ON() to handle the fault
more gracefully.

Signed-off-by: Yang Yingliang <yangyingliang@...wei.com>
---
 drivers/platform/loongarch/loongson-laptop.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/platform/loongarch/loongson-laptop.c b/drivers/platform/loongarch/loongson-laptop.c
index a9fdfac50f35..8299195a7116 100644
--- a/drivers/platform/loongarch/loongson-laptop.c
+++ b/drivers/platform/loongarch/loongson-laptop.c
@@ -498,8 +498,6 @@ static int __init generic_subdriver_init(struct generic_sub_driver *sub_driver)
 {
 	int ret;
 
-	BUG_ON(!sub_driver);
-
 	if (!sub_driver || !sub_driver->driver)
 		return -EINVAL;
 
-- 
2.25.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ