diff options
author | Jacob Keller <jacob.e.keller@intel.com> | 2018-05-17 01:08:36 -0700 |
---|---|---|
committer | Jeff Kirsher <jeffrey.t.kirsher@intel.com> | 2018-05-22 08:37:06 -0700 |
commit | 9b10df596bd4d38f2a58cf87e0780510acc53d8d (patch) | |
tree | 1eebcef2e05db43a08a513cb065b2298d56eaa95 /scripts/gdb/linux/utils.py | |
parent | 019b9cd44d5aa457d9e45c85847f86ced40c852d (diff) |
i40e: use WARN_ONCE to replace the commented BUG_ON size check
We don't really want to use BUG_ON here since that would completely
crash the kernel, thus the reason we commented it out. We *can't* use
BUILD_BUG_ON because at least now (a) the sizes aren't constant (we are
fixing this) and (b) not all compilers are smart enough to understand
that "p - data" is a constant.
Instead, just use a WARN_ONCE so that the first time we end up with an
incorrect size we will dump a stack trace and a message, hopefully
highlighting the issues early in testing.
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions