]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
staging: speakup: Replace BUG_ON() with WARN_ON().
authorVarsha Rao <rvarsha016@gmail.com>
Sat, 25 Feb 2017 12:23:58 +0000 (17:53 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 22 Mar 2018 08:23:19 +0000 (09:23 +0100)
commitc2e4c685b3c97bbf6210602cbe5791c468a31fdd
treed6e2fbca86d866915d5d9b5ecc317f11e776d8ca
parent3389b386139d79b5eb8bb023e9ca603d6245a8fa
staging: speakup: Replace BUG_ON() with WARN_ON().

[ Upstream commit d351c2db5420bb17dcd2d9aac7ddb5f64c6d04b3 ]

BUG_ON() is replaced with WARN_ON() and EINVAL is returned, when
WARN_ON() is true. This fixes the following checkpatch issue:

Avoid crashing the kernel - try using WARN_ON & recovery code rather
than BUG() or BUG_ON().

Signed-off-by: Varsha Rao <rvarsha016@gmail.com>
Reviewed-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/speakup/kobjects.c