- 10 10月, 2005 8 次提交
-
-
由 Rafael J. Wysocki 提交于
The following patch makes swsusp avoid the possible temporary corruption of page translation tables during resume on x86-64. This is achieved by creating a copy of the relevant page tables that will not be modified by swsusp and can be safely used by it on resume. The problem is that during resume on x86-64 swsusp may temporarily corrupt the page tables used for the direct mapping of RAM. If that happens, a page fault occurs and cannot be handled properly, which leads to the solid hang of the affected system. This leads to the loss of the system's state from before suspend and may result in the loss of data or the corruption of filesystems, so it is a serious issue. Also, it appears to happen quite often (for me, as often as 50% of the time). The problem is related to the fact that (at least) one of the PMD entries used in the direct memory mapping (starting at PAGE_OFFSET) points to a page table the physical address of which is much greater than the physical address of the PMD entry itself. Moreover, unfortunately, the physical address of the page table before suspend (i.e. the one stored in the suspend image) happens to be different to the physical address of the corresponding page table used during resume (i.e. the one that is valid right before swsusp_arch_resume() in arch/x86_64/kernel/suspend_asm.S is executed). Thus while the image is restored, the "offending" PMD entry gets overwritten, so it does not point to the right physical address any more (i.e. there's no page table at the address pointed to by it, because it points to the address the page table has been at during suspend). Consequently, if the PMD entry is used later on, and it _is_ used in the process of copying the image pages, a page fault occurs, but it cannot be handled in the normal way and the system hangs. In principle we can call create_resume_mapping() from swsusp_arch_resume() (ie. from suspend_asm.S), but then the memory allocations in create_resume_mapping(), resume_pud_mapping(), and resume_pmd_mapping() must be made carefully so that we use _only_ NosaveFree pages in them (the other pages are overwritten by the loop in swsusp_arch_resume()). Additionally, we are in atomic context at that time, so we cannot use GFP_KERNEL. Moreover, if one of the allocations fails, we should free all of the allocated pages, so we need to trace them somehow. All of this is done in the appended patch, except that the functions populating the page tables are located in arch/x86_64/kernel/suspend.c rather than in init.c. It may be done in a more elegan way in the future, with the help of some swsusp patches that are in the works now. [AK: move some externs into headers, renamed a function] Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl> Signed-off-by: NAndi Kleen <ak@suse.de> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
Fix whitespace - I split this off the previous patch for easier review. Signed-off-by: NPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
After restoring the existing code, make it work also when included in kernelspace code (which isn't currently the case, but at least this will prevent people from "fixing" it as just happened). Whitespace is fixed in next patch - it cluttered the diff too much. Signed-off-by: NPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
Commit 44456d37, between 2.6.13-rc3 and -rc4, was a "nice cleanup" which broke something. Revert the offending part. It broke because: a) because this part doesn't fall under the description b) the author didn't know what he was doing here c) the author didn't try to compile the existing code and see that it worked perfectly. d) the author didn't ask us what was happening e) you didn't either, and somebody there should have learned that UML is a bit different. In fact, UML is special in linking to host libc and using its includes. In particular, since host includes always define both __BIG_ENDIAN and __LITTLE_ENDIAN, ntohll() macros started thinking to be in a big-endian world; and on-disk compatibility was broken. Many thanks go to Nix for reporting the problem and correctly diagnosing an endianness problem. Btw, this patch restores the previous code, which worked; but the definitions would be uncorrect if used in kernelspace files. Next patch addresses that. Cc: Nix <nix@esperi.org.uk>, Olaf Hering <olh@suse.de> Signed-off-by: NPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
For files which need to include glibc headers (i.e. userspace files), we specified the correct flags only for .o, not for .s/.lst/.i. Fix this. Signed-off-by: NPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
Too many people were confused by skas0 and tried using "mode=skas0". And after all, they are right - accept this. Signed-off-by: NPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
Add a missing $(Q) to a "ln" invocation. Signed-off-by: NPaolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 Steven Rostedt 提交于
The pccardd thread has a race in it that it can shutdown in the TASK_INTERRUPTIBLE state. Make sure we mark ourselves runnable again as we remove ourselves from the wait queue. Signed-off-by: NSteven Rostedt <rostedt@goodmis.org> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
- 09 10月, 2005 13 次提交
-
-
由 Sven Hartge 提交于
irq.c is missing the inclusion of asm/io.h, which causes readb() and writeb() the be undefined. Signed-off-by: NSven Hartge <hartge@ds9.argh.org> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Al Viro 提交于
- added typedef unsigned int __nocast gfp_t; - replaced __nocast uses for gfp flags with gfp_t - it gives exactly the same warnings as far as sparse is concerned, doesn't change generated code (from gcc point of view we replaced unsigned int with typedef) and documents what's going on far better. Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 Jens Axboe 提交于
We should not be warning about commands that we allow, even if they are unknown. So move the if-root-allow check up a notch. Signed-off-by: NJens Axboe <axboe@suse.de> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 Linus Torvalds 提交于
-
由 Linus Torvalds 提交于
-
由 Linus Torvalds 提交于
-
由 Linus Torvalds 提交于
-
由 David Howells 提交于
This patch makes the possessor permissions on a key additive with user/group/other permissions on the same key. This permits extra rights to be granted to the possessor of a key without taking away any rights conferred by them owning the key or having common group membership. Signed-Off-By: NDavid Howells <dhowells@redhat.com> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 David Howells 提交于
The attached patch splits key permissions checking out of key-ui.h and moves it into a .c file. It's quite large and called quite a lot, and it's about to get bigger with the addition of LSM support for keys... key_any_permission() is also discarded as it's no longer used. Signed-Off-By: NDavid Howells <dhowells@redhat.com> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 David Howells 提交于
The attached patch adds documentation for the process by which request-key works, including how it permits helper processes to gain access to the requestor's keyrings. Signed-Off-By: NDavid Howells <dhowells@redhat.com> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 David Howells 提交于
Plug request_key_auth memleak. This can be triggered by unprivileged users, so is local DoS. Signed-off-by: NChris Wright <chrisw@osdl.org> Signed-Off-By: NDavid Howells <dhowells@redhat.com> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 David Vrabel 提交于
(struct pcmcia_socket).tune_bridge only exists if CONFIG_CARDBUS is set but building yenta_socket without CardBus is valid. Signed-off-by: NDavid Vrabel <dvrabel@arcom.com> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
由 Oleg Nesterov 提交于
Let's suppose we have 2 threads in thread group: A - does coredump B - has pending SIGSTOP thread A thread B do_coredump: get_signal_to_deliver: lock(->sighand) ->signal->flags = SIGNAL_GROUP_EXIT unlock(->sighand) lock(->sighand) signr = dequeue_signal() ->signal->flags |= SIGNAL_STOP_DEQUEUED return SIGSTOP; do_signal_stop: unlock(->sighand) coredump_wait: zap_threads: lock(tasklist_lock) send SIGKILL to B // signal_wake_up() does nothing unlock(tasklist_lock) lock(tasklist_lock) lock(->sighand) re-check sig->flags & SIGNAL_STOP_DEQUEUED, yes set_current_state(TASK_STOPPED); finish_stop: schedule(); // ->state == TASK_STOPPED wait_for_completion(&startup_done) // waits for complete() from B, // ->state == TASK_UNINTERRUPTIBLE We can't wake up 'B' in any way: SIGCONT will be ignored because handle_stop_signal() sees ->signal->flags & SIGNAL_GROUP_EXIT. sys_kill(SIGKILL)->__group_complete_signal() will choose uninterruptible 'A', so it can't help. sys_tkill(B, SIGKILL) will be ignored by specific_send_sig_info() because B already has pending SIGKILL. This scenario is not possbile if 'A' does do_group_exit(), because it sets sig->flags = SIGNAL_GROUP_EXIT and delivers SIGKILL to subthreads atomically, holding both tasklist_lock and sighand->lock. That means that do_signal_stop() will notice !SIGNAL_STOP_DEQUEUED after re-locking ->sighand. And it is not possible to any other thread to re-add SIGNAL_STOP_DEQUEUED later, because dequeue_signal() can only return SIGKILL. I think it is better to change do_coredump() to do sigaddset(SIGKILL) and signal_wake_up() under sighand->lock, but this patch is much simpler. Signed-off-by: NOleg Nesterov <oleg@tv-sign.ru> Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
-
- 08 10月, 2005 3 次提交
-
-
由 Jean-Denis Boyer 提交于
From: "Jean-Denis Boyer" <jdboyer@mediatrix.com> Signed-off-by: NChas Williams <chas@cmf.nrl.navy.mil> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 David S. Miller 提交于
We need to use stricter memory barriers around the block load and store instructions we use to save and restore the FPU register file. Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
由 Tom 'spot' Callaway 提交于
The attached patch fixes the p9100 framebuffer so that text is viewable (not black on black, like it was before the patch). The linux logo displays for a very short period of time, then is replaced by a grey box. This leads me to believe that this framebuffer would have problems in X, but since there hasn't been a weitek driver for X in several millennia, this isn't something that I can confirm or deny. But this patch does get color console working on my SPARCbook 3TX. Signed-off-by: NTom 'spot' Callaway <tcallawa@redhat.com> Signed-off-by: NDavid S. Miller <davem@davemloft.net>
-
- 07 10月, 2005 16 次提交
-
-
由 Clemens Ladisch 提交于
USB generic driver Add a quirk entry for the external MIDI ports of the Windows Edition of the Hercules DJ Console. Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
-
由 Clemens Ladisch 提交于
USB generic driver Add a mixer quirk entry for the Hercules DJ Console (Windows Edition) that uses a different USB product ID. Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
-
由 Takashi Iwai 提交于
ALI5451 driver Don't build the modem PCM if the corresponding codec isn't detected. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
EMU10K1/EMU10K2 driver Fixed the handling of ac97_chip=2 capability type. The error occurs in snd_ac97_mixer(), not in snd_ac97_bus(). Also, release the unnecessary ac97_bus object in the error path. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Clemens Ladisch 提交于
KORG1212 driver Add a missing comma that made the stateName array one entry too short. Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
-
由 Takashi Iwai 提交于
EMU10K1/EMU10K2 driver Fixed the error at loading SBLive Game board (and possible other models). The PCI SSIDs of this board conflicts with SB Live 5.1 Platinum, which has no AC97 chip. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
VIA82xx driver Addded a dxs_support entry for an ASUS mobo. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Takashi Iwai 提交于
HDA Codec driver Fixed the confliction of capture controls on ALC880 'test' model. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 John W. Linville 提交于
HDA Codec driver Mark the ALC882 'LFE Playback Switch' as an input, like the other playback switch settings. Signed-off-by: NJohn W. Linville <linville@tuxdriver.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 John W. Linville 提交于
HDA Codec driver Fix a typo (cut & paste) in the alc880_test_mixer structure. Signed-off-by: NJohn W. Linville <linville@tuxdriver.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 John W. Linville 提交于
HDA Codec driver The ALC260 'Mono Playback Switch' is marked as an output in patch_realtek.c. It actually does not work unless it is marked as an input. Go figure... This was tested and confirmed on an HP xw4300. Signed-off-by: NJohn W. Linville <linville@tuxdriver.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Clemens Ladisch 提交于
USB generic driver Increase the maximum PCM buffer size to 1 MB. The USB driver doesn't have any inherent buffer size limit, and big multichannel interfaces may benefit from this. Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
-
由 Clemens Ladisch 提交于
USB generic driver There is another revision of the PHASE26 with a different product ID; add a quirk entry for that, too. Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
-
由 Clemens Ladisch 提交于
USB generic driver Add quirk entries for four unknown Yamaha USB MIDI devices. Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
-
由 Takashi Iwai 提交于
PPC PMAC driver Added the support of iBook 1.33GHz. Signed-off-by: NTakashi Iwai <tiwai@suse.de>
-
由 Clemens Ladisch 提交于
USB generic driver Add a quirk entry for the Roland RD-700SX. This should work for the RD-300SX, too. Signed-off-by: NClemens Ladisch <clemens@ladisch.de>
-