[mythtv-users] want to disable /proc/acpi/alarm wakeup

David Watkins watkinshome at gmail.com
Fri Jun 29 08:11:07 UTC 2007


> ==========================================================
> *** Archive/halt        2006-08-17 09:14:07.000000000 -0500
> --- new/halt    2007-03-25 18:47:18.000000000 -0500
> ***************
> *** 126,133 ****
> --- 126,151 ----
>        ;;
>  esac
>
> + ####MYTHtv Fix Start Part 1
> + ACPITIME=`cat /proc/acpi/alarm`
> + ####MYTHtv Fix End Part 1
> +
>  [ -x /sbin/hwclock ] && action $"Syncing hardware clock to system time" /sbin/hwclock $CLOCKFLAGS
>
> + ####MYTHtv Fix Start Part 2
> + if [[ "$ACPITIME" =~ "....-00-00 00:00:00" ]]; then
> + # Should not be setting alarm for *exactly* midnight GMT on a MythTV system --
> + #equivalent to 7pm CDT or 6pm CST.  Should be waking up some minutes before
> + #the hour to allow MythTV to get up and running before show starts.
> + #Therefore, this must be intended to turn off the alarm and NOT wake up the
> + #system automatically until manual intervention occurs. Hence, ...
> +   echo "Not setting alarm time."
> + else
> +   echo -n "Setting alarm time: "
> +   echo "$ACPITIME" | tee /proc/acpi/alarm
> + fi
> + ####MYTHtv Fix Start Part 2
> +
>  # Try to unmount tmpfs filesystems to avoid swapping them in.  Ignore failures.
>  tmpfs=$(awk '$2 ~ /^\/($|proc|dev)/ { next; }
>             $3 == "tmpfs" { print $2; }' /proc/mounts | sort -r)
> ==========================================================
>

Craig,

Thanks for sharing that.  It looks like you've done exactly what I
did, and now I understand a bit more about how patch files work.

But it looks to me that your 'if' statement simply avoids the error
message that I got when I echoed "00-00 00:00:00" into
/proc/acpi/alarm.

I think the mod will either set a valid wakeup time (which the OP
doesn't want) or do nothing (which it what isn't working now)?

Mark,
One thing has occured to me.  Mythdora uses mythwelcome and, the last
time I looked mythwelcome used nvram-wakeup (rather than acpi/alarm).
Are you sure that nvram-wakup isn't setting wake-up times for you?

If you're sure that nothing is actively setting wake up times then, to
clear any existing value you could try resetting your motherboard
BIOS, to see if that clears it.  Seems much too drastic though to be a
reasonable solution.


More information about the mythtv-users mailing list