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: <201002110156.54617.rjw@sisk.pl>
Date:	Thu, 11 Feb 2010 01:56:54 +0100
From:	"Rafael J. Wysocki" <rjw@...k.pl>
To:	Gary Hade <garyhade@...ibm.com>
Cc:	linux-pm@...ts.linux-foundation.org,
	Linux PCI <linux-pci@...r.kernel.org>,
	LKML <linux-kernel@...r.kernel.org>,
	Jesse Barnes <jbarnes@...tuousgeek.org>,
	"Moore, Robert" <robert.moore@...el.com>,
	Matthew Garrett <mjg@...hat.com>,
	Bjorn Helgaas <bjorn.helgaas@...com>
Subject: Re: [PATCH 8/9] PCI / ACPI / PM: Platform support for PCI PME wake-up (rev. 7)

On Thursday 11 February 2010, Rafael J. Wysocki wrote:
> On Thursday 11 February 2010, Gary Hade wrote:
> > On Wed, Feb 10, 2010 at 11:58:00PM +0100, Rafael J. Wysocki wrote:
> > > On Wednesday 10 February 2010, Gary Hade wrote:
> ...
> > > > Yes, 6/9 also appeared to be the most likely suspect to me and
> > > > I was already doing what you asked except in the opposite order.
> > > > With 1/9 through 6/9 both the hot-add and hot-remove issues still
> > > > reproduced.  After removing 6/9 both issues disappeared.
> > > 
> > > Thanks for verifying, I've already started to look for bugs in it.
> > 
> > Thanks!
> > 
> > > 
> > > What's your kernel command line, BTW?
> > 
> > root=/dev/disk/by-id/scsi-35000c5000036ffcb-part7 ip=9.47.66.9:9.47.67.50:9.47.66.1:255.255.254.0 resume=/dev/disk/by-id/scsi-35000c50000370247-part3 crashkernel=256M-:128M console=tty0 console=ttyS0,115200 pci=use_crs pci=norom
> 
> Thanks.  We found a bug in the patch, but it would require you to use a
> specific command line switch to trigger, which you don't use.
> 
> I'll let you know if I have anything to test.

OK, please try the patch below on top of [1-6/9].

Rafael

---
 drivers/acpi/acpica/evgpeblk.c |    4 ++++
 drivers/acpi/acpica/evxface.c  |   14 ++++++++++++++
 2 files changed, 18 insertions(+)

Index: linux-2.6/drivers/acpi/acpica/evxface.c
===================================================================
--- linux-2.6.orig/drivers/acpi/acpica/evxface.c
+++ linux-2.6/drivers/acpi/acpica/evxface.c
@@ -617,6 +617,13 @@ acpi_install_gpe_handler(acpi_handle gpe
 	handler->context = context;
 	handler->method_node = gpe_event_info->dispatch.method_node;
 
+	/* Disable the GPE before installing the handler */
+
+	status = acpi_ev_disable_gpe(gpe_event_info);
+	if (ACPI_FAILURE(status)) {
+		goto unlock_and_exit;
+	}
+
 	/* Install the handler */
 
 	flags = acpi_os_acquire_lock(acpi_gbl_gpe_lock);
@@ -709,6 +716,13 @@ acpi_remove_gpe_handler(acpi_handle gpe_
 		return_ACPI_STATUS(status);
 	}
 
+	/* Disable the GPE before removing the handler */
+
+	status = acpi_ev_disable_gpe(gpe_event_info);
+	if (ACPI_FAILURE(status)) {
+		goto unlock_and_exit;
+	}
+
 	/* Remove the handler */
 
 	flags = acpi_os_acquire_lock(acpi_gbl_gpe_lock);
Index: linux-2.6/drivers/acpi/acpica/evgpeblk.c
===================================================================
--- linux-2.6.orig/drivers/acpi/acpica/evgpeblk.c
+++ linux-2.6/drivers/acpi/acpica/evgpeblk.c
@@ -335,6 +335,10 @@ acpi_ev_save_method_info(acpi_handle obj
 	gpe_event_info->dispatch.method_node =
 	    (struct acpi_namespace_node *)obj_handle;
 
+	/* Update enable mask, but don't enable the HW GPE as of yet */
+
+	status = acpi_ev_enable_gpe(gpe_event_info, FALSE);
+
 	ACPI_DEBUG_PRINT((ACPI_DB_LOAD,
 			  "Registered GPE method %s as GPE number 0x%.2X\n",
 			  name, gpe_number));
--
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