lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <50242670.4020302@linaro.org>
Date:	Thu, 09 Aug 2012 14:06:56 -0700
From:	John Stultz <john.stultz@...aro.org>
To:	Todd Poynor <toddpoynor@...gle.com>
CC:	linux-kernel@...r.kernel.org, linux-pm@...r.kernel.org,
	arve@...roid.com
Subject: Re: [PATCH] alarmtimer: implement minimum alarm interval for allowing
 suspend

On 08/09/2012 12:37 AM, Todd Poynor wrote:
> @@ -288,9 +293,11 @@ static int alarmtimer_suspend(struct device *dev)
>   	now = rtc_tm_to_ktime(tm);
>   	now = ktime_add(now, min);
>
> -	rtc_timer_start(rtc, &rtctimer, now, ktime_set(0, 0));
> -
> -	return 0;
> +	/* Set alarm, if in the past reject suspend briefly to handle */
> +	ret = rtc_timer_start(rtc, &rtctimer, now, ktime_set(0, 0));
> +	if (ret < 0)
> +		__pm_wakeup_event(ws, 1 * MSEC_PER_SEC);
> +	return ret;

What if something other then -ETIME  is returned from rtc_timer_start?

thanks
-john


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ