#!/bin/sh
# Force eth0 up before suspend, else we'll fail to suspend (LP: #771588)

case "${1}" in
    suspend)
        if [ "`cat /sys/class/net/eth*/address`x" != "00:11:22:33:44:55x" ] ; then
            nic=`ifconfig -a | grep eth | cut -f1 -d\ `;
            ifconfig $nic up
        fi
        ;;
esac
