Current-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
ACPI S3 patch for testing
Hi all,
please give the attached patch some testing. It should fix interrupt
handling after suspend-to-RAM on some machines and certainly not break
all other systems. This patch is intended for pullup to netbsd-5. Please
report any regressions.
Joerg
Index: arch/x86/acpi/acpi_wakeup.c
===================================================================
RCS file: /home/joerg/repo/netbsd/src/sys/arch/x86/acpi/acpi_wakeup.c,v
retrieving revision 1.10
diff -u -p -r1.10 acpi_wakeup.c
--- arch/x86/acpi/acpi_wakeup.c 23 Sep 2008 14:54:23 -0000 1.10
+++ arch/x86/acpi/acpi_wakeup.c 15 Nov 2008 21:05:28 -0000
@@ -376,6 +376,8 @@ acpi_md_sleep(int state)
AcpiClearEvent(ACPI_EVENT_RTC);
AcpiHwDisableAllGpes ();
+ acpi_pci_link_resume();
+
out:
#ifdef MULTIPROCESSOR
Index: dev/acpi/acpi_pci_link.c
===================================================================
RCS file: /home/joerg/repo/netbsd/src/sys/dev/acpi/acpi_pci_link.c,v
retrieving revision 1.13
diff -u -p -r1.13 acpi_pci_link.c
--- dev/acpi/acpi_pci_link.c 4 Jun 2008 21:37:03 -0000 1.13
+++ dev/acpi/acpi_pci_link.c 15 Nov 2008 21:06:11 -0000
@@ -1156,6 +1156,20 @@ acpi_pci_link_devbyhandle(ACPI_HANDLE ha
return (void *)sc;
}
+void
+acpi_pci_link_resume(void)
+{
+ struct acpi_pci_link_softc *sc;
+ ACPI_BUFFER srsbuf;
+
+ TAILQ_FOREACH(sc, &acpi_pci_linkdevs, pl_list) {
+ ACPI_SERIAL_BEGIN(pci_link);
+ if (ACPI_SUCCESS(acpi_pci_link_srs(sc, &srsbuf)))
+ AcpiOsFree(srsbuf.Pointer);
+ ACPI_SERIAL_END(pci_link);
+ }
+}
+
ACPI_HANDLE
acpi_pci_link_handle(void *v)
{
Index: dev/acpi/acpivar.h
===================================================================
RCS file: /home/joerg/repo/netbsd/src/sys/dev/acpi/acpivar.h,v
retrieving revision 1.33
diff -u -p -r1.33 acpivar.h
--- dev/acpi/acpivar.h 15 Jul 2008 16:15:28 -0000 1.33
+++ dev/acpi/acpivar.h 15 Nov 2008 21:04:37 -0000
@@ -289,6 +289,7 @@ int acpi_pci_link_route_interrupt(void
char * acpi_pci_link_name(void *);
ACPI_HANDLE acpi_pci_link_handle(void *);
void acpi_pci_link_state(void);
+void acpi_pci_link_resume(void);
struct acpi_io *acpi_res_io(struct acpi_resources *, int);
struct acpi_iorange *acpi_res_iorange(struct acpi_resources *, int);
Home |
Main Index |
Thread Index |
Old Index