Replace calls to XE_BUG_ON() with calls XE_WARN_ON() which in turn calls WARN() instead of BUG(). BUG() crashes the kernel and should only be used when it is absolutely unavoidable in case of catastrophic and unrecoverable failures, which is not the case here. Signed-off-by: Francois Dugast <francois.dugast@intel.com> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
18 lines
347 B
C
18 lines
347 B
C
/* SPDX-License-Identifier: MIT */
|
|
/*
|
|
* Copyright © 2021 Intel Corporation
|
|
*/
|
|
|
|
#ifndef _XE_MACROS_H_
|
|
#define _XE_MACROS_H_
|
|
|
|
#include <linux/bug.h>
|
|
|
|
#define XE_WARN_ON WARN_ON
|
|
|
|
#define XE_IOCTL_DBG(xe, cond) \
|
|
((cond) && (drm_dbg(&(xe)->drm, \
|
|
"Ioctl argument check failed at %s:%d: %s", \
|
|
__FILE__, __LINE__, #cond), 1))
|
|
|
|
#endif
|