. /usr/share/initramfs-tools/scripts/functions
# First check if a location is set and is a valid swap partition.
# If so, the config file will be copied in and there is nothing to do.
if [ -n "$RESUME" ] && [ "$RESUME" != auto ]; then
if [ "$RESUME" = none ]; then
if resume_dev_node="$(resolve_device "$RESUME")" && \
blkid -p -n swap "$resume_dev_node" >/dev/null 2>&1; then
echo >&2 "W: initramfs-tools configuration sets RESUME=$RESUME"
echo >&2 "W: but no matching swap device is available."
# If we were not explicitly requested to select a device, report that we
test "$RESUME" = auto || echo >&2 "I: $*"
# We need to be able to read the listed swap partitions
if ischroot || [ ! -r /proc/swaps ]; then