login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2008
»
August
»
18
Re: [PATCH] Fix i486 suspend to disk CR4 oops
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: Pavel Machek
Subject:
Re: [PATCH] Fix i486 suspend to disk CR4 oops
Date: Monday, August 18, 2008 - 2:15 am
>
quoted text
> * David Fries <david@fries.net> wrote: > > > arch/x86/power/cpu_32.c __save_processor_state calls read_cr4() only a > > i486 CPU doesn't have the CR4 register. Trying to read it produces an > > invalid opcode oops during suspend to disk. > > > > Added the check (boot_cpu_data.x86 >= 5) before reading the register. > > If the value to be written is zero the write is skipped. > > > > arch/x86/power/hibernate_asm_32.S > > done: swapped the use of %eax and %ecx to use jecxz for > > the zero test and jump over store to %cr4. > > restore_image: s/%ecx/%eax/ to be consistent with done: > > > > In addition to __save_processor_state, acpi_save_state_mem, > > efi_call_phys_prelog, and efi_call_phys_epilog had checks added (acpi > > restore was in assembly and already had a check for non-zero). There > > were other reads and writes of CR4, but MCE and virtualization > > shouldn't be executed on a i486 anyway. > > > > Signed-off-by: David Fries <david@fries.net> > > applied to tip/x86/urgent, thanks David. I've changed the conditions to > read_cr4_safe() instead - that's cleaner. Could you please check whether > the patch below works fine too on your box? > > Rafael, Pavel - does the commit below look good to you too? > > Ingo > > ----------------------> > >From e437fa5586f2e3b2aaeba649fae52be1f9a6eabb Mon Sep 17 00:00:00 2001 > From: David Fries <david@fries.net> > Date: Sun, 17 Aug 2008 23:03:40 -0500 > Subject: [PATCH] x86: fix i486 suspend to disk CR4 oops > > arch/x86/power/cpu_32.c __save_processor_state calls read_cr4() > only a i486 CPU doesn't have the CR4 register. Trying to read it > produces an invalid opcode oops during suspend to disk. > > Use the safe rc4 reading op instead. If the value to be written is > zero the write is skipped. > > arch/x86/power/hibernate_asm_32.S > done: swapped the use of %eax and %ecx to use jecxz for > the zero test and jump over store to %cr4. > restore_image: s/%ecx/%eax/ to be consistent with done: > > In addition to __save_processor_state, acpi_save_state_mem, > efi_call_phys_prelog, and efi_call_phys_epilog had checks added > (acpi restore was in assembly and already had a check for > non-zero). There were other reads and writes of CR4, but MCE and > virtualization shouldn't be executed on a i486 anyway. > > Signed-off-by: David Fries <david@fries.net> > Signed-off-by: Ingo Molnar <mingo@elte.hu>
Acked-by: Pavel Machek <pavel@suse.cz> -- (english)
http://www.livejournal.com/~pavelmachek
(cesky, pictures)
http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[PATCH] Fix i486 suspend to disk CR4 oops
, David Fries
, (Sun Aug 17, 9:03 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Maciej W. Rozycki
, (Sun Aug 17, 9:14 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, H. Peter Anvin
, (Sun Aug 17, 9:35 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Andi Kleen
, (Sun Aug 17, 11:04 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, H. Peter Anvin
, (Sun Aug 17, 11:34 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Ingo Molnar
, (Sun Aug 17, 11:41 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Andi Kleen
, (Sun Aug 17, 11:42 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, H. Peter Anvin
, (Sun Aug 17, 11:45 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Pavel Machek
, (Mon Aug 18, 2:15 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Rafael J. Wysocki
, (Mon Aug 18, 3:16 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, David Fries
, (Mon Aug 18, 5:58 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Ingo Molnar
, (Mon Aug 18, 6:25 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Maciej W. Rozycki
, (Mon Aug 18, 7:38 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Maciej W. Rozycki
, (Mon Aug 18, 7:41 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Dave Jones
, (Mon Aug 18, 8:24 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Lennart Sorensen
, (Mon Aug 18, 9:04 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Dave Jones
, (Mon Aug 18, 10:17 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, H. Peter Anvin
, (Mon Aug 18, 10:32 am)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Pavel Machek
, (Mon Aug 18, 3:02 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, Pavel Machek
, (Mon Aug 18, 3:04 pm)
Re: [PATCH] Fix i486 suspend to disk CR4 oops
, H. Peter Anvin
, (Mon Aug 18, 3:10 pm)
Re: [PATCH] i486 CR4 oops, no_console_suspend
, David Fries
, (Mon Aug 18, 8:37 pm)
Re: [PATCH] i486 CR4 oops, no_console_suspend
, Ingo Molnar
, (Tue Aug 19, 2:34 am)
Re: [PATCH] i486 CR4 oops, no_console_suspend
, H. Peter Anvin
, (Tue Aug 19, 9:07 am)
Re: [PATCH] i486 CR4 oops, no_console_suspend
, David Fries
, (Wed Aug 20, 9:17 pm)
Re: [PATCH] i486 CR4 oops, no_console_suspend
, H. Peter Anvin
, (Wed Aug 20, 10:37 pm)
Navigation
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Ken Chen
[patch] sched: fix inconsistency when redistribute per-cpu tg->cfs_rq shares.
Ingo Molnar
Re: [PATCH v3] x86: merge the simple bitops and move them to bitops.h
Jan Engelhardt
Re: [PATCH] Allow Kconfig to set default mmap_min_addr protection
Dmitry Torokhov
Re: [2.6 patch] input/serio/hp_sdc.c section fix
Rafael J. Wysocki
[Bug #16380] Loop devices act strangely in 2.6.35
git
:
Steven Grimm
Using git as a general backup mechanism (was Re: Using GIT to store /etc)
Jeff King
Re: [PATCH] git-reset: allow --soft in a bare repo
Johannes Sixt
Re: [PATCH 01/14] msvc: Fix compilation errors in compat/win32/sys/poll.c
Johannes Schindelin
Re: [PATCH] Uninstall rule for top level Makefile
Shawn O. Pearce
Re: [PATCH v2] Speed up bash completion loading
git-commits-head
:
Linux Kernel Mailing List
cgroups: clean up cgroup_pidlist_find() a bit
Linux Kernel Mailing List
sony-laptop: Add support for extended hotkeys
Linux Kernel Mailing List
IB/core: Add support for masked atomic operations
Linux Kernel Mailing List
V4L/DVB (8939): cx18: fix sparse warnings
Linux Kernel Mailing List
ipv6 mcast: Check address family of gf_group in getsockopt(MS_FILTER).
linux-netdev
:
Inaky Perez-Gonzalez
[PATCH 40/40] wimax/i2400m: add CREDITS and MAINTAINERS entries
Karsten Keil
[mISDN PATCH v2 05/19] Reduce stack size in dsp_cmx_send()
linux
Re: 2.6.23-rc8 network problem. Mem leak? ip1000a?
David Miller
Re: tun: Use netif_receive_skb instead of netif_rx
David Miller
Re: [net-next PATCH v2] llc enhancements
freebsd-current
:
Matthew Fleming
Re: [RFC] Outline of USB process integration in the kernel taskqueue system
illoai@gmail.com
Re: OT: 2d password
Hartmut Brandt
Re: problem with nss_ldap
Andrew Reilly
Re: FreeBSD's problems as seen by the BSDForen.de community
Max Laier
Re: Upcoming ABI Breakage in RELENG_7
Colocation donated by:
Syndicate