summaryrefslogtreecommitdiffstats
path: root/drivers/char
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'audit.b50' of ↵Linus Torvalds2008-04-292-61/+7
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/viro/audit-current * 'audit.b50' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/audit-current: [PATCH] new predicate - AUDIT_FILETYPE [patch 2/2] Use find_task_by_vpid in audit code [patch 1/2] audit: let userspace fully control TTY input auditing [PATCH 2/2] audit: fix sparse shadowed variable warnings [PATCH 1/2] audit: move extern declarations to audit.h Audit: MAINTAINERS update Audit: increase the maximum length of the key field Audit: standardize string audit interfaces Audit: stop deadlock from signals under load Audit: save audit_backlog_limit audit messages in case auditd comes back Audit: collect sessionid in netlink messages Audit: end printk with newline
| * [patch 1/2] audit: let userspace fully control TTY input auditingMiloslav Trmac2008-04-282-54/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove the code that automatically disables TTY input auditing in processes that open TTYs when they have no other TTY open; this heuristic was intended to automatically handle daemons, but it has false positives (e.g. with sshd) that make it impossible to control TTY input auditing from a PAM module. With this patch, TTY input auditing is controlled from user-space only. On the other hand, not even for daemons does it make sense to audit "input" from PTY masters; this data was produced by a program writing to the PTY slave, and does not represent data entered by the user. Signed-off-by: Miloslav Trmac <mitr@redhat.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Cc: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * Audit: standardize string audit interfacesEric Paris2008-04-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch standardized the string auditing interfaces. No userspace changes will be visible and this is all just cleanup and consistancy work. We have the following string audit interfaces to use: void audit_log_n_hex(struct audit_buffer *ab, const unsigned char *buf, size_t len); void audit_log_n_string(struct audit_buffer *ab, const char *buf, size_t n); void audit_log_string(struct audit_buffer *ab, const char *buf); void audit_log_n_untrustedstring(struct audit_buffer *ab, const char *string, size_t n); void audit_log_untrustedstring(struct audit_buffer *ab, const char *string); This may be the first step to possibly fixing some of the issues that people have with the string output from the kernel audit system. But we still don't have an agreed upon solution to that problem. Signed-off-by: Eric Paris <eparis@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
| * Audit: collect sessionid in netlink messagesEric Paris2008-04-281-6/+1
| | | | | | | | | | | | | | | | | | | | Previously I added sessionid output to all audit messages where it was available but we still didn't know the sessionid of the sender of netlink messages. This patch adds that information to netlink messages so we can audit who sent netlink messages. Signed-off-by: Eric Paris <eparis@redhat.com> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
* | char: use get_unaligned_* helpersHarvey Harrison2008-04-292-8/+4
| | | | | | | | | | | | | | | | | | | | Remove unnecessary temp variable from_buf in snsc_event.c Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Cc: Jiri Slaby <jirislaby@gmail.com> Cc: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | tpm: change Kconfig dependencies from PNPACPI to PNPBjorn Helgaas2008-04-291-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no "PNPACPI" driver interface as such. PNPACPI is an internal backend of PNP, and drivers just use the generic PNP interface. The drivers should depend on CONFIG_PNP, not CONFIG_PNPACPI. tpm_nsc.c doesn't use PNP at all, so we can just remove the dependency completely. It probably *should* use PNP to discover the device, but until it does, there's no point in depending on PNP. Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Kylene Jo Hall <kjhall@us.ibm.com> Cc: Marcel Selhorst <tpm@selhorst.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | tpm: fix section mismatch warningSam Ravnborg2008-04-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix following warning: WARNING: vmlinux.o(.init.text+0x32804): Section mismatch in reference from the function init_nsc() to the function .devexit.text:tpm_nsc_remove() The function tpm_nsc_remove() are used outside __exit, so remove the __exit annotation to make sure the function is always avilable. Note: Trying to compare this module with other users of platform_device gve me the impression that this driver needs some work to match other users. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Kylene Hall <kjhall@us.ibm.com> Cc: Marcel Selhorst <tpm@selhorst.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: add async notification support to /dev/randomJeff Dike2008-04-291-2/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add async notification support to /dev/random. A little test case is below. Without this patch, you get: $ ./async-random Drained the pool Found more randomness With it, you get: $ ./async-random Drained the pool SIGIO Found more randomness #include <stdio.h> #include <stdlib.h> #include <signal.h> #include <errno.h> #include <fcntl.h> static void handler(int sig) { printf("SIGIO\n"); } int main(int argc, char **argv) { int fd, n, err, flags; if(signal(SIGIO, handler) < 0){ perror("setting SIGIO handler"); exit(1); } fd = open("/dev/random", O_RDONLY); if(fd < 0){ perror("open"); exit(1); } flags = fcntl(fd, F_GETFL); if (flags < 0){ perror("getting flags"); exit(1); } flags |= O_NONBLOCK; if (fcntl(fd, F_SETFL, flags) < 0){ perror("setting flags"); exit(1); } while((err = read(fd, &n, sizeof(n))) > 0) ; if(err == 0){ printf("random returned 0\n"); exit(1); } else if(errno != EAGAIN){ perror("read"); exit(1); } flags |= O_ASYNC; if (fcntl(fd, F_SETFL, flags) < 0){ perror("setting flags"); exit(1); } if (fcntl(fd, F_SETOWN, getpid()) < 0) { perror("Setting SIGIO"); exit(1); } printf("Drained the pool\n"); read(fd, &n, sizeof(n)); printf("Found more randomness\n"); return(0); } Signed-off-by: Jeff Dike <jdike@linux.intel.com> Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: simplify and rename credit_entropy_storeMatt Mackall2008-04-291-17/+15
| | | | | | | | | | | | | | | | | | | | | | - emphasize bits in the name - make zero bits lock-free - simplify logic Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: make mixing interface byte-orientedMatt Mackall2008-04-291-18/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Switch add_entropy_words to a byte-oriented interface, eliminating numerous casts and byte/word size rounding issues. This also reduces the overall bit/byte/word confusion in this code. We now mix a byte at a time into the word-based pool. This takes four times as many iterations, but should be negligible compared to hashing overhead. This also increases our pool churn, which adds some depth against some theoretical failure modes. The function name is changed to emphasize pool mixing and deemphasize entropy (the samples mixed in may not contain any). extract is added to the core function to make it clear that it extracts from the pool. Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: simplify add_ptr logicMatt Mackall2008-04-291-11/+10
| | | | | | | | | | | | | | | | | | | | | | | | The add_ptr variable wasn't used in a sensible way, use only i instead. i got reused later for a different purpose, use j instead. While we're here, put tap0 first in the tap list and add a comment. Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: remove some prefetch logicMatt Mackall2008-04-291-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The urandom output pool (ie the fast path) fits in one cacheline, so this is pretty unnecessary. Further, the output path has already fetched the entire pool to hash it before calling in here. (This was the only user of prefetch_range in the kernel, and it passed in words rather than bytes!) Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: eliminate redundant new_rotate variableMatt Mackall2008-04-291-12/+10
| | | | | | | | | | | | | | | | | | | | | | | | - eliminate new_rotate - move input_rotate masking - simplify input_rotate update - move input_rotate update to end of inner loop for readability Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: remove cacheline alignment for locksMatt Mackall2008-04-291-2/+2
| | | | | | | | | | | | | | | | | | | | Earlier changes greatly reduce the number of times we grab the lock per output byte, so we shouldn't need this particular hack any more. Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: make backtracking attacks harderMatt Mackall2008-04-291-19/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At each extraction, we change (poolbits / 16) + 32 bits in the pool, or 96 bits in the case of the secondary pools. Thus, a brute-force backtracking attack on the pool state is less difficult than breaking the hash. In certain cases, this difficulty may be is reduced to 2^64 iterations. Instead, hash the entire pool in one go, then feedback the whole hash (160 bits) in one go. This will make backtracking at least as hard as inverting the hash. Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: improve variable naming, clear extract bufferMatt Mackall2008-04-291-11/+13
| | | | | | | | | | | | | | | | | | | | | | - split the SHA variables apart into hash and workspace - rename data to extract - wipe extract and workspace after hashing Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: reuse rand_initializeMatt Mackall2008-04-291-4/+2
| | | | | | | | | | | | | | Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: use unlocked_ioctlMatt Mackall2008-04-291-6/+5
| | | | | | | | | | | | | | | | | | No locking actually needed. Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: consolidate wakeup logicMatt Mackall2008-04-291-16/+4
| | | | | | | | | | | | | | Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | random: clean up checkpatch complaintsMatt Mackall2008-04-291-45/+35
| | | | | | | | | | | | | | Signed-off-by: Matt Mackall <mpm@selenic.com> Cc: Theodore Ts'o <tytso@mit.edu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | drivers: use non-racy method for proc entries creationDenis V. Lunev2008-04-295-28/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | Use proc_create()/proc_create_data() to make sure that ->proc_fops and ->data be setup before gluing PDE to main tree. Signed-off-by: Denis V. Lunev <den@openvz.org> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Cc: Alexey Dobriyan <adobriyan@gmail.com> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Acked-by: Dmitry Torokhov <dtor@mail.ru> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | proc: switch /proc/ip2mem to seq_file interfaceAlexey Dobriyan2008-04-291-28/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | /******************************************/ /* Remove useless comment, while I am it. */ /******************************************/ Signed-off-by: Alexey Dobriyan <adobriyan@sw.ru> Cc: Greg Kroah-Hartman <gregkh@suse.de> Cc: Jeff Garzik <jeff@garzik.org> Cc: Jeff Dike <jdike@addtoit.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | proc: switch /proc/apm to seq_file interfaceAlexey Dobriyan2008-04-291-5/+18
| | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Alexey Dobriyan <adobriyan@sw.ru> Cc: Rafael J. Wysocki <rjw@sisk.pl> Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Len Brown <len.brown@intel.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | proc: remove proc_root from driversAlexey Dobriyan2008-04-291-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | Remove proc_root export. Creation and removal works well if parent PDE is supplied as NULL -- it worked always that way. So, one useless export removed and consistency added, some drivers created PDEs with &proc_root as parent but removed them as NULL and so on. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: fix return from atca_oem_poweroff_hookAdrian Bunk2008-04-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | A void returning function returned the return value of another void returning function... Spotted by sparse. Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: make alloc_recv_msg staticAdrian Bunk2008-04-291-1/+1
| | | | | | | | | | | | | | | | | | Make the needlessly global ipmi_alloc_recv_msg() static. Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: remove ->write_proc codeAlexey Dobriyan2008-04-292-8/+7
| | | | | | | | | | | | | | | | | | | | IPMI code theoretically allows ->write_proc users, but nobody uses this thus far. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Acked-by: Corey Minyard <minyard@acm.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: remove unused target and action in MakefileDenis Cheng2008-04-291-4/+0
| | | | | | | | | | | | | | | | | | | | Kbuild system handles this automatically. Signed-off-by: Denis Cheng <crquan@gmail.com> Cc: Corey Minyard <minyard@acm.org> Cc: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | IPMI: Style fixes in the misc codeCorey Minyard2008-04-292-201/+227
| | | | | | | | | | | | | | | | | | | | Lots of style fixes for the miscellaneous IPMI files. No functional changes. Basically fixes everything reported by checkpatch and fixes the comment style. Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | IPMI: Style fixes in the system interface codeCorey Minyard2008-04-295-436/+574
| | | | | | | | | | | | | | | | | | | | | | | | | | Lots of style fixes for the IPMI system interface driver. No functional changes. Basically fixes everything reported by checkpatch and fixes the comment style. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Corey Minyard <cminyard@mvista.com> Cc: Rocky Craig <rocky.craig@hp.com> Cc: Hannes Schulz <schulz@schwaar.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: style fixes in the base codeCorey Minyard2008-04-291-414/+581
| | | | | | | | | | | | | | | | | | | | Lots of style fixes for the base IPMI driver. No functional changes. Basically fixes everything reported by checkpatch and fixes the comment style. Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | IPMI: Convert system interface defines to an enumCorey Minyard2008-04-291-17/+43
| | | | | | | | | | | | | | | | | | | | | | Convert the #defines for statistics into an enum in the IPMI system interface and remove the unused timeout_restart statistic. And comment what these statistics mean. Signed-off-by: Corey Minyard <cminyard@mvista.com> Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: convert locked counters to atomics in the system interfaceCorey Minyard2008-04-291-74/+66
| | | | | | | | | | | | | | | | Atomics are faster and neater than locked counters. Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | IPMI: convert message handler defines to an enumCorey Minyard2008-04-291-58/+67
| | | | | | | | | | | | | | | | | | | | Convert the #defines for statistics into an enum in the IPMI message handler. Signed-off-by: Corey Minyard <cminyard@mvista.com> Cc: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: convert locked counters to atomicsKonstantin Baydarov2008-04-291-248/+194
| | | | | | | | | | | | | | | | | | Atomics are a lot more efficient and neat than using a lock. Signed-off-by: Konstantin Baydarov <kbaidarov@ru.mvista.com> Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: update driver versionCorey Minyard2008-04-291-1/+1
| | | | | | | | | | | | | | | | Enough bug fixes and changes that we need a new driver version. Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: don't print event queue full on every eventCorey Minyard2008-04-291-4/+11
| | | | | | | | | | | | | | | | | | Don't print out that the event queue is full on every event, only print something out when it becomes full or becomes not full. Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: don't grab locks in run-to-completion modeKonstantin Baydarov2008-04-292-8/+28
| | | | | | | | | | | | | | | | | | | | | | This patch prevents deadlocks in IPMI panic handler caused by msg_lock in smi_info structure and waiting_msgs_lock in ipmi_smi structure. [cminyard@mvista.com: remove unnecessary memory barriers] Signed-off-by: Konstantin Baydarov <kbaidarov@ru.mvista.com> Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: run to completion fixesCorey Minyard2008-04-293-36/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "run_to_completion" mode was somewhat broken. Locks need to be avoided in run_to_completion mode, and it shouldn't be used by normal users, just internally for panic situations. This patch removes locks in run_to_completion mode and removes the user call for setting the mode. The only user was the poweroff code, but it was easily converted to use the polling interface. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Corey Minyard <cminyard@mvista.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipmi: hold ATTN until upper layer readyCorey Minyard2008-04-291-2/+5
| | | | | | | | | | | | | | | | | | | | Hold handling of ATTN until the upper layer has reported that it is ready. Signed-off-by: Corey Minyard <cminyard@mvista.com> Cc: Patrick Schoeller <Patrick.Schoeller@hp.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | vt: fix background color on line feedJan Engelhardt2008-04-291-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A command that causes a line feed while a background color is active, such as perl -e 'print "x" x 60, "\e[44m", "x" x 40, "\e[0m\n"' and perl -e 'print "x" x 40, "\e[44m\n", "x" x 40, "\e[0m\n"' causes the line that was started as a result of the line feed to be completely filled with the currently active background color instead of the default color. When scrolling, part of the current screen is memcpy'd/memmove'd to the new region, and the new line(s) that will appear as a result are cleared using memset. However, the lines are cleared with vc->vc_video_erase_char, causing them to be colored with the currently active background color. This is different from X11 terminal emulators which always paint the new lines with the default background color (e.g. `xterm -bg black`). The clear operation (\e[1J and \e[2J) also use vc_video_erase_char, so a new vc->vc_scrl_erase_char is introduced with contains the erase character used for scrolling, which is built from vc->vc_def_color instead of vc->vc_color. Signed-off-by: Jan Engelhardt <jengelh@computergmbh.de> Cc: "Antonino A. Daplas" <adaplas@pol.net> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Alan Cox <alan@lxorguk.ukuu.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | sysrq: add show-backtrace-on-all-cpus functionRik van Riel2008-04-291-0/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SysRQ-P is not always useful on SMP systems, since it usually ends up showing the backtrace of a CPU that is doing just fine, instead of the backtrace of the CPU that is having problems. This patch adds SysRQ show-all-cpus(L), which shows the backtrace of every active CPU in the system. It skips idle CPUs because some SMP systems are just too large and we already know what the backtrace of the idle task looks like. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Rik van Riel <riel@redhat.com> Randy Dunlap <randy.dunlap@oracle.com> Cc: <lwoodman@redhat.com> Cc: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | ipwireless: remove dead codeJiri Kosina2008-04-294-46/+0
| | | | | | | | | | | | | | | | | | Remove unused leftovers of debugging functions. 2.6.25 material. Reported-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | make /dev/kmem a config optionArjan van de Ven2008-04-292-0/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make /dev/kmem a config option; /dev/kmem is VERY rarely used, and when used, it's generally for no good (rootkits tend to be the most common users). With this config option, users have the choice to disable /dev/kmem, saving some size as well. A patch to disable /dev/kmem has been in the Fedora and RHEL kernels for 4+ years now without any known problems or legit users of /dev/kmem. [akpm@linux-foundation.org: make CONFIG_DEVKMEM default to y] Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | drivers: fix integer as NULL pointer warningsHarvey Harrison2008-04-283-3/+3
| | | | | | | | | | Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | drivers: atm, char fix integer as NULL pointer warningsHarvey Harrison2008-04-282-2/+2
| | | | | | | | | | | | | | | | | | drivers/atm/nicstar.c:418:25: warning: Using plain integer as NULL pointer drivers/char/drm/r128_cce.c:820:25: warning: Using plain integer as NULL pointer drivers/char/tty_io.c:1183:10: warning: Using plain integer as NULL pointer Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | VT notifier extension for accessibilityKarl Dahlke2008-04-281-0/+8
| | | | | | | | | | | | | | | | | | | | Some accessibility modules need to be able to catch the output on the console before the VT interpretation, and possibly swallow it. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | char: make functions static in synclinkmp.cHarvey Harrison2008-04-281-60/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All were forward declared with static. Fixes sparse warnings: drivers/char/synclinkmp.c:1476:5: warning: symbol 'read_proc' was not declared. Should it be static? drivers/char/synclinkmp.c:2027:5: warning: symbol 'bh_action' was not declared. Should it be static? drivers/char/synclinkmp.c:2058:6: warning: symbol 'bh_handler' was not declared. Should it be static? drivers/char/synclinkmp.c:2103:6: warning: symbol 'bh_receive' was not declared. Should it be static? drivers/char/synclinkmp.c:2112:6: warning: symbol 'bh_transmit' was not declared. Should it be static? drivers/char/synclinkmp.c:2124:6: warning: symbol 'bh_status' was not declared. Should it be static? drivers/char/synclinkmp.c:2136:6: warning: symbol 'isr_timer' was not declared. Should it be static? drivers/char/synclinkmp.c:2162:6: warning: symbol 'isr_rxint' was not declared. Should it be static? drivers/char/synclinkmp.c:2221:6: warning: symbol 'isr_rxrdy' was not declared. Should it be static? drivers/char/synclinkmp.c:2351:6: warning: symbol 'isr_txint' was not declared. Should it be static? drivers/char/synclinkmp.c:2379:6: warning: symbol 'isr_txrdy' was not declared. Should it be static? drivers/char/synclinkmp.c:2410:6: warning: symbol 'isr_rxdmaok' was not declared. Should it be static? drivers/char/synclinkmp.c:2427:6: warning: symbol 'isr_rxdmaerror' was not declared. Should it be static? drivers/char/synclinkmp.c:2445:6: warning: symbol 'isr_txdmaok' was not declared. Should it be static? drivers/char/synclinkmp.c:2463:6: warning: symbol 'isr_txdmaerror' was not declared. Should it be static? drivers/char/synclinkmp.c:2480:6: warning: symbol 'isr_io_pin' was not declared. Should it be static? drivers/char/synclinkmp.c:3420:5: warning: symbol 'alloc_dma_bufs' was not declared. Should it be static? drivers/char/synclinkmp.c:3494:5: warning: symbol 'alloc_buf_list' was not declared. Should it be static? drivers/char/synclinkmp.c:3553:5: warning: symbol 'alloc_frame_bufs' was not declared. Should it be static? drivers/char/synclinkmp.c:3570:6: warning: symbol 'free_dma_bufs' was not declared. Should it be static? drivers/char/synclinkmp.c:3580:5: warning: symbol 'alloc_tmp_rx_buf' was not declared. Should it be static? drivers/char/synclinkmp.c:3588:6: warning: symbol 'free_tmp_rx_buf' was not declared. Should it be static? drivers/char/synclinkmp.c:3594:5: warning: symbol 'claim_resources' was not declared. Should it be static? drivers/char/synclinkmp.c:3681:6: warning: symbol 'release_resources' was not declared. Should it be static? drivers/char/synclinkmp.c:3737:6: warning: symbol 'add_device' was not declared. Should it be static? drivers/char/synclinkmp.c:3860:6: warning: symbol 'device_init' was not declared. Should it be static? drivers/char/synclinkmp.c:4054:6: warning: symbol 'enable_loopback' was not declared. Should it be static? drivers/char/synclinkmp.c:4101:6: warning: symbol 'set_rate' was not declared. Should it be static? drivers/char/synclinkmp.c:4147:6: warning: symbol 'rx_stop' was not declared. Should it be static? drivers/char/synclinkmp.c:4168:6: warning: symbol 'rx_start' was not declared. Should it be static? drivers/char/synclinkmp.c:4225:6: warning: symbol 'tx_start' was not declared. Should it be static? drivers/char/synclinkmp.c:4295:6: warning: symbol 'tx_stop' was not declared. Should it be static? drivers/char/synclinkmp.c:4322:6: warning: symbol 'tx_load_fifo' was not declared. Should it be static? drivers/char/synclinkmp.c:4371:6: warning: symbol 'reset_port' was not declared. Should it be static? drivers/char/synclinkmp.c:4395:6: warning: symbol 'reset_adapter' was not declared. Should it be static? drivers/char/synclinkmp.c:4407:6: warning: symbol 'async_mode' was not declared. Should it be static? drivers/char/synclinkmp.c:4546:6: warning: symbol 'hdlc_mode' was not declared. Should it be static? drivers/char/synclinkmp.c:4748:6: warning: symbol 'tx_set_idle' was not declared. Should it be static? drivers/char/synclinkmp.c:4768:6: warning: symbol 'get_signals' was not declared. Should it be static? drivers/char/synclinkmp.c:4797:6: warning: symbol 'set_signals' was not declared. Should it be static? drivers/char/synclinkmp.c:4826:6: warning: symbol 'rx_reset_buffers' was not declared. Should it be static? drivers/char/synclinkmp.c:4837:6: warning: symbol 'rx_free_frame_buffers' was not declared. Should it be static? drivers/char/synclinkmp.c:4865:5: warning: symbol 'rx_get_frame' was not declared. Should it be static? drivers/char/synclinkmp.c:5040:6: warning: symbol 'tx_load_dma_buffer' was not declared. Should it be static? drivers/char/synclinkmp.c:5080:5: warning: symbol 'register_test' was not declared. Should it be static? drivers/char/synclinkmp.c:5119:5: warning: symbol 'irq_test' was not declared. Should it be static? drivers/char/synclinkmp.c:5211:5: warning: symbol 'init_adapter' was not declared. Should it be static? drivers/char/synclinkmp.c:5270:5: warning: symbol 'loopback_test' was not declared. Should it be static? drivers/char/synclinkmp.c:5335:5: warning: symbol 'adapter_test' was not declared. Should it be static? drivers/char/synclinkmp.c:5397:5: warning: symbol 'memory_test' was not declared. Should it be static? drivers/char/synclinkmp.c:5449:6: warning: symbol 'load_pci_memory' was not declared. Should it be static? drivers/char/synclinkmp.c:5468:6: warning: symbol 'trace_block' was not declared. Should it be static? drivers/char/synclinkmp.c:5503:6: warning: symbol 'tx_timeout' was not declared. Should it be static? drivers/char/synclinkmp.c:5530:6: warning: symbol 'status_timeout' was not declared. Should it be static? drivers/char/synclinkmp.c:5581:15: warning: symbol 'read_reg' was not declared. Should it be static? drivers/char/synclinkmp.c:5586:6: warning: symbol 'write_reg' was not declared. Should it be static? drivers/char/synclinkmp.c:5592:5: warning: symbol 'read_reg16' was not declared. Should it be static? drivers/char/synclinkmp.c:5598:6: warning: symbol 'write_reg16' was not declared. Should it be static? drivers/char/synclinkmp.c:5604:15: warning: symbol 'read_status_reg' was not declared. Should it be static? drivers/char/synclinkmp.c:5610:6: warning: symbol 'write_control_reg' was not declared. Should it be static? Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Cc: Paul Fulghum <paulkf@microgate.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | synclink drivers bool conversionJoe Perches2008-04-284-323/+319
| | | | | | | | | | | | | | | | | | | | | | | | Remove more TRUE/FALSE defines and uses Remove == TRUE tests Convert BOOLEAN to bool Convert int to bool where appropriate Signed-off-by: Joe Perches <joe@perches.com> Acked-by: Paul Fulghum <paulkf@microgate.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | mm: introduce node_zonelist() for accessing the zonelist for a GFP maskMel Gorman2008-04-281-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce a node_zonelist() helper function. It is used to lookup the appropriate zonelist given a node and a GFP mask. The patch on its own is a cleanup but it helps clarify parts of the two-zonelist-per-node patchset. If necessary, it can be merged with the next patch in this set without problems. Reviewed-by: Christoph Lameter <clameter@sgi.com> Signed-off-by: Mel Gorman <mel@csn.ul.ie> Signed-off-by: Lee Schermerhorn <lee.schermerhorn@hp.com> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Cc: Mel Gorman <mel@csn.ul.ie> Cc: Christoph Lameter <clameter@sgi.com> Cc: Hugh Dickins <hugh@veritas.com> Cc: Nick Piggin <nickpiggin@yahoo.com.au> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
OpenPOWER on IntegriCloud