blktests: Add _have_kernel_config_file() and _check_kernel_option()
The helper function _have_kernel_option() sets SKIP_REASON when the
specified kernel config option is not set. Sometimes this SKIP_REASON
update is not desired and it is unset after _have_kernel_option() calls.
This unset is not straight-forward and confusing.
To avoid the unset operation, introduce two new helper functions:
1) _have_kernel_config_file() which sets SKIP_REASON when neither
/boot/config* nor /proc/config.gz is available.
2) _check_kernel_option() which doesn't set SKIP_RESAON when
the specified kernel option is not defined.
Also re-implement _have_kernel_option() with the new helper functions.
When SKIP_REASON update is not desired, call _check_kernel_option() in
place of _have_kernel_option().
Signed-off-by: Xiao Yang <yangx.jy@fujitsu.com>
[Shin'ichiro: added change purpose in the commit message] Signed-off-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>