lists.openwall.net   lists  /  announce  john-users  owl-users  popa3d-users  /  xvendor  oss-security  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4 
Open Source and information security mailing list archives
 
This website is powered by Openwall GNU/*/Linux security-enhanced OS
[<prev] [next>] [<thread-prev] [thread-next>] [month] [year] [list]
Date:	Sun, 1 Jun 2008 09:49:36 +0200
From:	Tobias Diedrich <ranma+kernel@...edrich.de>
To:	Alan Stern <stern@...land.harvard.edu>
Subject: Re: [linux-pm] [PATCH 0/4] Fix forcedeth hibernate/wake-on-lan
	problems

Alan Stern wrote:
> On Sun, 1 Jun 2008, Tobias Diedrich wrote:
> 
> > Ok, after another long debugging session I finally found out the
> > reason for the immediate reboot (after finding the place that
> > suspends the serial console (drivers/pnp) and disabling that suspend
> > path):
> > The system is woken up by USB activity! (Optical mouse, anyone?)
> > 
> > Lo and behold:
> > drivers/usb/core/hcd-pci.c tries it's best to activate 'wake on
> > usb', which I didn't know since it apparently also never worked.
> > However, after applying the 'use platform_enable_wakeup'-patch,
> > not only forcedeth wake starts working, also usb wake.
> > If I prevent usb wake:
> > |echo disabled > /sys/devices/pci0000\:00/0000\:00\:02.0/power/wakeup'
> > |echo disabled > /sys/devices/pci0000\:00/0000\:00\:02.1/power/wakeup'
> > And then hibernate in platform mode, the immediate reboot is gone
> > and waking up using magic packets works fine even without setting up
> > /proc/acpi/wakeup first.
> > 
> > Maybe I should try hooking mouse and keyboard onto different usb
> > host controllers, so I can disable wakeup for the mouse host
> > controller and enable wakeup for the keyboard host controller,
> > then it should be possible to wake the system by pressing a key. :)
> 
> You don't need to do that.  Wakeup can be set specifically for each 
> individual USB device, provided CONFIG_USB_SUSPEND is enabled.

Cool, I didn't know that. :)

> On Sun, 1 Jun 2008, Tobias Diedrich wrote:
> 
> > (BTW I first thought the 'immediate reboot because of usb wake' effect is
> > caused by the optical mouse generating a wake event, but it rather
> > seems to be a problem with a flaky secondary usb host controller,
> > which sees a connected device where nothing is attached)
> 
> Can you provide debugging information (i.e., CONFIG_USB_DEBUG) with the 
> details on this bogus wakeup?

Sure.
Here is the complete log of one boot and two s2disk_platform cycles
captured using the serial console (in the first s2disk I forgot to
remove the 'turn off /sys/bus/usb/device/usb?/power/wakeup' part).

Interestingly even with power/wakeup disabled for usb1 and usb2,
which I assume to be the usb root ports, I could wake up the system
by pressing a key on my keyboard (which didn't work before turning
on CONFIG_USB_SUSPEND).

On the second suspend the system rebooted immediately as expected
(I power/wakeup for usb1 and usb2 back on and disabled the part in
the script).

I think this might be some general usb hw flakiness, since it seems
to detect (and has so for a long time) a non-existing device:

lsusb output:
Bus 002 Device 003: ID 045e:00db Microsoft Corp. Natural Ergonomic Keyboard 4000 V1.0
Bus 002 Device 002: ID 045e:0040 Microsoft Corp. Wheel Mouse Optical
Bus 002 Device 001: ID 1d6b:0001  
Bus 001 Device 001: ID 1d6b:0002  

bogus device?:
[14316046.469949] usb 2-4: new full speed USB device using ohci_hcd and address 12
[14316046.679951] usb 2-4: device descriptor read/64, error -62
[14316046.986619] usb 2-4: device descriptor read/64, error -62
[14316047.263284] usb 2-4: new full speed USB device using ohci_hcd and address 13
[14316047.476614] usb 2-4: device descriptor read/64, error -62
[14316047.786618] usb 2-4: device descriptor read/64, error -62
[14316048.063282] usb 2-4: new full speed USB device using ohci_hcd and address 14
[14316048.499945] usb 2-4: device not accepting address 14, error -62
[14316048.669950] usb 2-4: new full speed USB device using ohci_hcd and address 15
[14316049.106612] usb 2-4: device not accepting address 15, error -62
[14316049.112960] hub 2-0:1.0: unable to enumerate USB device on port 4


complete log:
[    0.000000] Linux version 2.6.26-rc4 (ranma@...chior) (gcc version 4.2.3 (Debian 4.2.3-5)) #28 PREEMPT Sun Jun 1 09:06:24 CEST 2008
[    0.000000] Command line: root=/dev/sda5 resume=/dev/sda6 vga=6 apic=verbose console=ttyS0,115200 console=tty0 pci=nomsi no_console_suspend ro
[    0.000000] BIOS-provided physical RAM map:
[    0.000000]  BIOS-e820: 0000000000000000 - 000000000009f800 (usable)
[    0.000000]  BIOS-e820: 000000000009f800 - 00000000000a0000 (reserved)
[    0.000000]  BIOS-e820: 00000000000f0000 - 0000000000100000 (reserved)
[    0.000000]  BIOS-e820: 0000000000100000 - 000000007fee0000 (usable)
[    0.000000]  BIOS-e820: 000000007fee0000 - 000000007fee3000 (ACPI NVS)
[    0.000000]  BIOS-e820: 000000007fee3000 - 000000007fef0000 (ACPI data)
[    0.000000]  BIOS-e820: 000000007fef0000 - 000000007ff00000 (reserved)
[    0.000000]  BIOS-e820: 00000000f0000000 - 00000000f4000000 (reserved)
[    0.000000]  BIOS-e820: 00000000fec00000 - 0000000100000000 (reserved)
[    0.000000] max_pfn_mapped = 1048576
[    0.000000] x86 PAT enabled: cpu 0, old 0x7040600070406, new 0x7010600070106
[    0.000000] init_memory_mapping
[    0.000000] DMI 2.4 present.
[    0.000000] ACPI: RSDP 000F7D20, 0024 (r2 Nvidia)
[    0.000000] ACPI: XSDT 7FEE3100, 004C (r1 Nvidia ASUSACPI 42302E31 AWRD        0)
[    0.000000] ACPI: FACP 7FEEADC0, 00F4 (r3 Nvidia ASUSACPI 42302E31 AWRD        0)
[    0.000000] ACPI: DSDT 7FEE3280, 7ACE (r1 NVIDIA AWRDACPI     1000 MSFT  3000000)
[    0.000000] ACPI: FACS 7FEE0000, 0040
[    0.000000] ACPI: SSDT 7FEEB000, 0136 (r1 PTLTD  POWERNOW        1  LTP        1)
[    0.000000] ACPI: HPET 7FEEB180, 0038 (r1 Nvidia ASUSACPI 42302E31 AWRD       98)
[    0.000000] ACPI: MCFG 7FEEB200, 003C (r1 Nvidia ASUSACPI 42302E31 AWRD        0)
[    0.000000] ACPI: APIC 7FEEAF00, 0098 (r1 Nvidia ASUSACPI 42302E31 AWRD        0)
[    0.000000]   early res: 0 [0-fff] BIOS data page
[    0.000000]   early res: 1 [6000-7fff] TRAMPOLINE
[    0.000000]   early res: 2 [200000-d3638f] TEXT DATA BSS
[    0.000000]   early res: 3 [9f800-fffff] BIOS reserved
[    0.000000]   early res: 4 [8000-bfff] PGTABLE
[    0.000000] Zone PFN ranges:
[    0.000000]   DMA             0 ->     4096
[    0.000000]   DMA32        4096 ->  1048576
[    0.000000]   Normal    1048576 ->  1048576
[    0.000000] Movable zone start PFN for each node
[    0.000000] early_node_map[2] active PFN ranges
[    0.000000]     0:        0 ->      159
[    0.000000]     0:      256 ->   524000
[    0.000000] Detected use of extended apic ids on hypertransport bus
[    0.000000] ACPI: PM-Timer IO Port: 0x1008
[    0.000000] ACPI: LAPIC (acpi_id[0x00] lapic_id[0x00] enabled)
[    0.000000] ACPI: LAPIC (acpi_id[0x01] lapic_id[0x01] disabled)
[    0.000000] ACPI: LAPIC (acpi_id[0x02] lapic_id[0x02] disabled)
[    0.000000] ACPI: LAPIC (acpi_id[0x03] lapic_id[0x03] disabled)
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x00] high edge lint[0x1])
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x01] high edge lint[0x1])
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x02] high edge lint[0x1])
[    0.000000] ACPI: LAPIC_NMI (acpi_id[0x03] high edge lint[0x1])
[    0.000000] ACPI: IOAPIC (id[0x04] address[0xfec00000] gsi_base[0])
[    0.000000] IOAPIC[0]: apic_id 4, version 0, address 0xfec00000, GSI 0-23
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 0 global_irq 2 dfl dfl)
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 high level)
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 14 global_irq 14 high edge)
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 15 global_irq 15 high edge)
[    0.000000] Setting APIC routing to flat
[    0.000000] ACPI: HPET id: 0x10de8201 base: 0xfefff000
[    0.000000] Using ACPI (MADT) for SMP configuration information
[    0.000000] mapped APIC to ffffffffff5fb000 (        fee00000)
[    0.000000] mapped IOAPIC to ffffffffff5fa000 (00000000fec00000)
[    0.000000] PM: Registered nosave memory: 000000000009f000 - 00000000000a0000
[    0.000000] PM: Registered nosave memory: 00000000000a0000 - 00000000000f0000
[    0.000000] PM: Registered nosave memory: 00000000000f0000 - 0000000000100000
[    0.000000] Allocating PCI resources starting at 80000000 (gap: 7ff00000:70100000)
[14315324.233334] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 513763
[14315324.233334] Kernel command line: root=/dev/sda5 resume=/dev/sda6 vga=6 apic=verbose console=ttyS0,115200 console=tty0 pci=nomsi no_console_suspend ro
[14315324.233334] Initializing CPU#0
[14315324.233334] PID hash table entries: 4096 (order: 12, 32768 bytes)
[14315324.233334] Extended CMOS year: 2000
[14315324.233334] TSC calibrated against PM_TIMER
[14315324.233334] time.c: Detected 2411.107 MHz processor.
[14315324.233334] Console: colour VGA+ 80x60
[14315324.233334] console [tty0] enabled
[14315324.233334] console [ttyS0] enabled
[14315324.233334] Lock dependency validator: Copyright (c) 2006 Red Hat, Inc., Ingo Molnar
[14315324.233334] ... MAX_LOCKDEP_SUBCLASSES:    8
[14315324.233334] ... MAX_LOCK_DEPTH:          48
[14315324.233334] ... MAX_LOCKDEP_KEYS:        2048
[14315324.233334] ... CLASSHASH_SIZE:           1024
[14315324.233334] ... MAX_LOCKDEP_ENTRIES:     8192
[14315324.233334] ... MAX_LOCKDEP_CHAINS:      16384
[14315324.233334] ... CHAINHASH_SIZE:          8192
[14315324.233334]  memory used by lock dependency info: 1648 kB
[14315324.233334]  per task-struct memory footprint: 2688 bytes
[14315324.233334] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes)
[14315324.233334] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes)
[14315324.233334] Checking aperture...
[14315324.233334] Node 0: aperture @ ab94000000 size 32 MB
[14315324.233334] Aperture beyond 4GB. Ignoring.
[14315324.233334] No AGP bridge found
[14315324.233334] Memory: 2051692k/2096000k available (4624k kernel code, 43544k reserved, 2268k data, 260k init)
[14315324.316528] Calibrating delay using timer specific routine.. 4827.00 BogoMIPS (lpj=8043211)
[14315324.322857] Mount-cache hash table entries: 256
[14315324.327217] CPU: L1 I Cache: 64K (64 bytes/line), D cache 64K (64 bytes/line)
[14315324.333327] CPU: L2 Cache: 512K (64 bytes/line)
[14315324.336660] CPU: AMD Athlon(tm) 64 Processor 3800+ stepping 01
[14315324.342947] ACPI: Core revision 20080321
[14315324.359992] Parsing all Control Methods:
[14315324.364011] Table [DSDT](id 0001) - 1203 Objects with 101 Devices 380 Methods 44 Regions
[14315324.369992] Parsing all Control Methods:
[14315324.373967] Table [SSDT](id 0002) - 4 Objects with 0 Devices 0 Methods 0 Regions
[14315324.379991]  tbxface-0598 [02] tb_load_namespace     : ACPI Tables successfully acquired
[14315324.389990] evxfevnt-0091 [02] enable                : Transition to ACPI mode successful
[14315324.398904] enabled ExtINT on CPU#0
[14315324.402998] ENABLING IO-APIC IRQs
[14315324.406656] ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
[14315324.442963] Using local APIC timer interrupts.
[14315324.449986] Detected 12.557 MHz APIC timer.
[14315324.453320] net_namespace: 1272 bytes
[14315324.456653] NET: Registered protocol family 16
[14315324.460262] No dock devices found.
[14315324.464194] TOM: 0000000080000000 aka 2048M
[14315324.468795] ACPI: bus type pci registered
[14315324.473293] PCI: Using configuration type 1 for base access
[14315324.481636] evgpeblk-0956 [04] ev_create_gpe_block   : GPE 00 to 1F [_GPE] 4 regs on int 0x9
[14315324.490696] evgpeblk-0956 [04] ev_create_gpe_block   : GPE 20 to 5F [_GPE] 8 regs on int 0x9
[14315324.509805] Completing Region/Field/Buffer/Package initialization:...................................................................................................................................................................................
[14315324.545447] Initialized 39/44 Regions 11/11 Fields 40/40 Buffers 89/101 Packages (1216 nodes)
[14315324.549980] Initializing Device/Processor/Thermal objects by executing _INI methods:...
[14315324.556256] Executed 3 _INI methods requiring 1 _STA executions (examined 108 objects)
[14315324.559979] evgpeblk-1052 [03] ev_initialize_gpe_bloc: Found 9 Wake, Enabled 0 Runtime GPEs in this block
[14315324.569979] evgpeblk-1052 [03] ev_initialize_gpe_bloc: Found 0 Wake, Enabled 1 Runtime GPEs in this block
[14315324.579978] ACPI: Interpreter enabled
[14315324.583311] ACPI: (supports S0 S1 S3 S4 S5)
[14315324.587948] ACPI: Using IOAPIC for interrupt routing
[14315324.615454] ACPI: PCI Root Bridge [PCI0] (0000:00)
[14315324.619975] PCI: Transparent bridge - 0000:00:06.0
[14315324.713931] ACPI: PCI Interrupt Link [LNK1] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.722733] ACPI: PCI Interrupt Link [LNK2] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.728224] ACPI: PCI Interrupt Link [LNK3] (IRQs 5 7 9 *10 11 14 15)
[14315324.735722] ACPI: PCI Interrupt Link [LNK4] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.741551] ACPI: PCI Interrupt Link [LNK5] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.750168] ACPI: PCI Interrupt Link [LNK6] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.758958] ACPI: PCI Interrupt Link [LNK7] (IRQs 5 7 9 10 *11 14 15)
[14315324.763301] ACPI: PCI Interrupt Link [LNK8] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.768608] ACPI: PCI Interrupt Link [LP2P] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.777265] ACPI: PCI Interrupt Link [LUBA] (IRQs 5 7 9 10 *11 14 15)
[14315324.784758] ACPI: PCI Interrupt Link [LMAC] (IRQs 5 7 9 *10 11 14 15)
[14315324.792250] ACPI: PCI Interrupt Link [LMC1] (IRQs 5 7 9 *10 11 14 15)
[14315324.796634] ACPI: PCI Interrupt Link [LAZA] (IRQs *5 7 9 10 11 14 15)
[14315324.800688] ACPI: PCI Interrupt Link [LPMU] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.809482] ACPI: PCI Interrupt Link [LSMB] (IRQs 5 7 9 *10 11 14 15)
[14315324.813827] ACPI: PCI Interrupt Link [LUB2] (IRQs *5 7 9 10 11 14 15)
[14315324.821294] ACPI: PCI Interrupt Link [LIDE] (IRQs 5 7 9 10 11 14 15) *0, disabled.
[14315324.829954] ACPI: PCI Interrupt Link [LSID] (IRQs *5 7 9 10 11 14 15)
[14315324.834333] ACPI: PCI Interrupt Link [LFID] (IRQs 5 7 9 *10 11 14 15)
[14315324.841605] ACPI: PCI Interrupt Link [LSA2] (IRQs 5 7 9 10 *11 14 15)
[14315324.849225] ACPI: PCI Interrupt Link [APC1] (IRQs 16) *0, disabled.
[14315324.853301] ACPI: PCI Interrupt Link [APC2] (IRQs 17) *0, disabled.
[14315324.857246] ACPI: PCI Interrupt Link [APC3] (IRQs 18) *0
[14315324.863511] ACPI: PCI Interrupt Link [APC4] (IRQs 19) *0, disabled.
[14315324.870581] ACPI: PCI Interrupt Link [APC5] (IRQs 16) *0, disabled.
[14315324.877827] ACPI: PCI Interrupt Link [APC6] (IRQs 16) *0, disabled.
[14315324.885078] ACPI: PCI Interrupt Link [APC7] (IRQs 16) *0
[14315324.889968] ACPI: PCI Interrupt Link [APC8] (IRQs 16) *0, disabled.
[14315324.895427] ACPI: PCI Interrupt Link [APCF] (IRQs 20 21 22 23) *0
[14315324.899968] ACPI: PCI Interrupt Link [APCH] (IRQs 20 21 22 23) *0
[14315324.903301] ACPI: PCI Interrupt Link [AMC1] (IRQs 20 21 22 23) *0
[14315324.907248] ACPI: PCI Interrupt Link [APMU] (IRQs 20 21 22 23) *0, disabled.
[14315324.915379] ACPI: PCI Interrupt Link [AAZA] (IRQs 20 21 22 23) *0
[14315324.919968] ACPI: PCI Interrupt Link [APCS] (IRQs 20 21 22 23) *0
[14315324.923301] ACPI: PCI Interrupt Link [APCL] (IRQs 20 21 22 23) *0
[14315324.927247] ACPI: PCI Interrupt Link [APCM] (IRQs 20 21 22 23) *0, disabled.
[14315324.934990] ACPI: PCI Interrupt Link [APCZ] (IRQs 20 21 22 23) *0, disabled.
[14315324.943235] ACPI: PCI Interrupt Link [APSI] (IRQs 20 21 22 23) *0
[14315324.947245] ACPI: PCI Interrupt Link [APSJ] (IRQs 20 21 22 23) *0
[14315324.954299] ACPI: PCI Interrupt Link [ASA2] (IRQs 20 21 22 23) *0
[14315324.961445] Linux Plug and Play Support v0.97 (c) Adam Belay
[14315324.966635] pnp: PnP ACPI init
[14315324.969968] ACPI: bus type pnp registered
[14315324.982451] pnp: PnP ACPI: found 13 devices
[14315324.986635] ACPI: ACPI bus type pnp unregistered
[14315324.989968] SCSI subsystem initialized
[14315324.993377] usbcore: registered new interface driver usbfs
[14315324.999287] usbcore: registered new interface driver hub
[14315325.003301] usbcore: registered new device driver usb
[14315325.006635] PCI: Using ACPI for IRQ routing
[14315325.009968] testing the IO APIC.......................
[14315325.013301] 
[14315325.013301] .................................... done.
[14315325.027785] Bluetooth: Core ver 2.11
[14315325.031917] NET: Registered protocol family 31
[14315325.036635] Bluetooth: HCI device and connection manager initialized
[14315325.039968] Bluetooth: HCI socket layer initialized
[14315325.043301] DMAR:parse DMAR table failure.
[14315325.054043] system 00:01: ioport range 0x1000-0x107f has been reserved
[14315325.060940] system 00:01: ioport range 0x1080-0x10ff has been reserved
[14315325.067827] system 00:01: ioport range 0x1400-0x147f has been reserved
[14315325.074713] system 00:01: ioport range 0x1480-0x14ff has been reserved
[14315325.081599] system 00:01: ioport range 0x1800-0x187f has been reserved
[14315325.088485] system 00:01: ioport range 0x1880-0x18ff has been reserved
[14315325.095383] system 00:02: ioport range 0x4d0-0x4d1 has been reserved
[14315325.102096] system 00:02: ioport range 0x800-0x87f has been reserved
[14315325.108810] system 00:02: ioport range 0x290-0x297 has been reserved
[14315325.115545] system 00:0b: iomem range 0xf0000000-0xf3ffffff could not be reserved
[14315325.123493] system 00:0c: iomem range 0xcd000-0xcffff has been reserved
[14315325.130468] system 00:0c: iomem range 0xf0000-0xf7fff could not be reserved
[14315325.139923] system 00:0c: iomem range 0xf8000-0xfbfff could not be reserved
[14315325.147331] system 00:0c: iomem range 0xfc000-0xfffff could not be reserved
[14315325.154737
[ TRUNCATED ]

Hosted by DataForce ISP - Powered by Openwall GNU/*/Linux