All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Stultz <john.stultz@linaro.org>
To: Borislav Petkov <bp@alien8.de>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Jiri Kosina <jkosina@suse.cz>, Borislav Petkov <bp@suse.de>,
	Thomas Gleixner <tglx@linutronix.de>,
	Rabin Vincent <rabin.vincent@stericsson.com>
Subject: Re: [PATCH -v2] RTC: Add an alarm disable quirk
Date: Mon, 22 Jul 2013 15:03:29 -0700	[thread overview]
Message-ID: <51EDAC31.8090306@linaro.org> (raw)
In-Reply-To: <20130722211927.GD4613@pd.tnic>

On 07/22/2013 02:19 PM, Borislav Petkov wrote:
> On Mon, Jul 22, 2013 at 02:00:42PM -0700, John Stultz wrote:
>> Also, just to clarify, on the affected machines, with this patch,
>> wake-up alarm's will in effect be disabled, right?
> See below.
>
>>> @@ -385,6 +418,9 @@ static int cmos_alarm_irq_enable(struct device *dev, unsigned int enabled)
>>>   	if (!is_valid_irq(cmos->irq))
>>>   		return -EINVAL;
>>> +	if (!disable_alarm)
>>> +		return 0;
>>> +
>> Did you want this in cmos_alarm_irq_enable? Or cmos_irq_disable?
> You're right - the first version did call it only in rtc_alarm_disable()
> so I should move it to cmos_alarm_disable(). Will fix.
>
> Btw, I did some more runs on the weekend. It seems, the setting of the
> alarm interrupt bit in RTC_CONTROL doesn't matter. I dumped its contents
> on shutdown and I had cases where it was 0x22 (bit 5 set) and 0x2.

It doesn't matter in what way?  I get you're saying you had cases where 
the alarm irq was set and non-set on shutdown, but I'm confused as to 
what the result was. Did it boot up immediately on shutdown in both cases?

> So my hunch currently is us *not* disabling the alarm, doesn't make it
> reboot the box.
Just to avoid the double negatives, you're saying:
* Disabling the alarm seems to cause it power on immediately on shutdown.
* Leaving the alarm alone (even if its set?) doesn't seem to cause the 
immediate power-on

Does leaving it alone, cause eventual power-on if the wakeup alarm was 
set for some time (say 5 mins) in the future?

thanks
-john


  reply	other threads:[~2013-07-22 22:03 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-18 15:44 [PATCH] RTC: Add an alarm disable quirk Borislav Petkov
2013-07-18 16:35 ` John Stultz
2013-07-18 22:53   ` Borislav Petkov
2013-07-19 14:26     ` Borislav Petkov
2013-07-19 15:13       ` Borislav Petkov
2013-07-19 21:34         ` Borislav Petkov
2013-07-20 17:00           ` [PATCH -v2] " Borislav Petkov
2013-07-22 21:00             ` John Stultz
2013-07-22 21:19               ` Borislav Petkov
2013-07-22 22:03                 ` John Stultz [this message]
2013-07-22 20:59         ` [PATCH] " John Stultz
2013-07-22 21:12           ` Borislav Petkov
2013-07-22 21:15             ` John Stultz
2013-07-22 21:27               ` Borislav Petkov
2013-07-22 22:17                 ` John Stultz
2013-07-23  5:03                   ` Borislav Petkov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51EDAC31.8090306@linaro.org \
    --to=john.stultz@linaro.org \
    --cc=bp@alien8.de \
    --cc=bp@suse.de \
    --cc=jkosina@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rabin.vincent@stericsson.com \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.