All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jiri Slaby <jirislaby@gmail.com>
To: Greg KH <greg@kroah.com>
Cc: Linux-pm mailing list <linux-pm@lists.linux-foundation.org>,
	Alan Cox <alan@lxorguk.ukuu.org.uk>
Subject: Re: Suspend problems in 2.6.31-rc6
Date: Mon, 17 Aug 2009 23:31:48 +0200	[thread overview]
Message-ID: <4A89CC44.2000506@gmail.com> (raw)
In-Reply-To: <20090817211514.GA30538@kroah.com>

On 08/17/2009 11:15 PM, Greg KH wrote:
> Oh wait, I think this is only needed on top of the rest of the tty tree,
> Linus's tree should not need this.
> 
> But I think Jiri is tracking down something in this area, Jiri?

Yes, but I think it's unrelated. My problem lies probably somewhere in
kernel/cpu.c.

Anyway I use the following. The function is called with interrupts
disabled during resume. Won't it help you by a chance?

commit e5a02f5ee04b20aa84295c4912259d4fa5b7642b
Author: Jiri Slaby <jirislaby@gmail.com>
Date:   Thu Aug 13 21:53:18 2009 +0200

    fix load_debug_register locking

diff --git a/kernel/hw_breakpoint.c b/kernel/hw_breakpoint.c
index c1f64e6..bc5368d 100644
--- a/kernel/hw_breakpoint.c
+++ b/kernel/hw_breakpoint.c
@@ -80,17 +80,15 @@ void load_debug_registers(void)
        unsigned long flags;
        struct task_struct *tsk = current;

-       spin_lock_bh(&hw_breakpoint_lock);
+       spin_lock_irqsave(&hw_breakpoint_lock, flags);

        /* Prevent IPIs for new kernel breakpoint updates */
-       local_irq_save(flags);
        arch_update_kernel_hw_breakpoint(NULL);
-       local_irq_restore(flags);

        if (test_tsk_thread_flag(tsk, TIF_DEBUG))
                arch_install_thread_hw_breakpoint(tsk);

-       spin_unlock_bh(&hw_breakpoint_lock);
+       spin_unlock_irqrestore(&hw_breakpoint_lock, flags);
 }

 /*

  reply	other threads:[~2009-08-17 21:31 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-17 15:11 Suspend problems in 2.6.31-rc6 Alan Stern
2009-08-17 18:28 ` Rafael J. Wysocki
2009-08-17 20:53   ` Alan Stern
2009-08-17 21:14     ` Greg KH
2009-08-17 21:15       ` Greg KH
2009-08-17 21:31         ` Jiri Slaby [this message]
2009-08-17 21:33           ` Jiri Slaby
2009-08-17 21:21     ` Rafael J. Wysocki
2009-08-17 21:50       ` Alan Stern
2009-08-18 16:07     ` Alan Stern
2009-08-18 23:22       ` Rafael J. Wysocki
2009-08-19  2:01         ` Zhenyu Wang
2009-08-19 14:42           ` Alan Stern
2009-08-20  1:05             ` Zhenyu Wang
2009-08-20 14:03               ` Alan Stern
2009-08-21  1:17                 ` Zhenyu Wang
2009-08-20 15:34               ` Rafael J. Wysocki
2009-08-19 14:26         ` Alan Stern
2009-08-19 21:22           ` Rafael J. Wysocki
2009-08-20 15:17             ` Alan Stern
2009-08-20 16:17               ` Rafael J. Wysocki
2009-08-21  1:21               ` Zhenyu Wang
2009-08-21  3:13                 ` Zhenyu Wang
2009-08-21 14:32                   ` Alan Stern
2009-08-21 17:01                     ` Rafael J. Wysocki
2009-08-24  2:34                       ` Zhenyu Wang
2009-08-24 18:55                         ` Rafael J. Wysocki
2009-08-25  0:59                         ` Alan Stern
2009-08-27 14:51                         ` Alan Stern
2009-08-27 16:18                           ` Jesse Barnes
2009-08-24  1:30                     ` Zhenyu Wang
2009-08-20 15:41             ` Rafael J. Wysocki
2009-08-20 16:05               ` Jesse Barnes

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=4A89CC44.2000506@gmail.com \
    --to=jirislaby@gmail.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=greg@kroah.com \
    --cc=linux-pm@lists.linux-foundation.org \
    /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.