[PATCH 1/2 V4] move some common functions from kdumpctl to kdump-lib.sh