aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/sched.c (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2007-11-15sched: fix __set_task_cpu() SMP raceDmitry Adamushko1-7/+13
Grant Wilson has reported rare SCHED_FAIR_USER crashes on his quad-core system, which crashes can only be explained via runqueue corruption. there is a narrow SMP race in __set_task_cpu(): after ->cpu is set up to a new value, task_rq_lock(p, ...) can be successfuly executed on another CPU. We must ensure that updates of per-task data have been completed by this moment. this bug has been hiding in the Linux scheduler for an eternity (we never had any explicit barrier for task->cpu in set_task_cpu() - so the bug was introduced in 2.5.1), but only became visible via set_task_cfs_rq() being accidentally put after the task->cpu update. It also probably needs a sufficiently out-of-order CPU to trigger. Reported-by: Grant Wilson <grant.wilson@zen.co.uk> Signed-off-by: Dmitry Adamushko <dmitry.adamushko@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
2007-11-15sched: fix SCHED_FIFO tasks & FAIR_GROUP_SCHEDOleg Nesterov1-1/+3
Suppose that the SCHED_FIFO task does switch_uid(new_user); Now, p->se.cfs_rq and p->se.parent both point into the old user_struct->tg because sched_move_task() doesn't call set_task_cfs_rq() for !fair_sched_class case. Suppose that old user_struct/task_group is freed/reused, and the task does sched_setscheduler(SCHED_NORMAL); __setscheduler() sets fair_sched_class, but doesn't update ->se.cfs_rq/parent which point to the freed memory. This means that check_preempt_wakeup() doing while (!is_same_group(se, pse)) { se = parent_entity(se); pse = parent_entity(pse); } may OOPS in a similar way if rq->curr or p did something like above. Perhaps we need something like the patch below, note that __setscheduler() can't do set_task_cfs_rq(). Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru> Signed-off-by: Ingo Molnar <mingo@elte.hu>
2007-11-15sched: fix accounting of interrupts during guest execution on s390Christian Borntraeger1-4/+2
Currently the scheduler checks for PF_VCPU to decide if this timeslice has to be accounted as guest time. On s390 host interrupts are not disabled during guest execution. This causes theses interrupts to be accounted as guest time if CONFIG_VIRT_CPU_ACCOUNTING is set. Solution is to check if an interrupt triggered account_system_time. As the tick is timer interrupt based, we have to subtract hardirq_offset. I tested the patch on s390 with CONFIG_VIRT_CPU_ACCOUNTING and on x86_64. Seems to work. CC: Avi Kivity <avi@qumranet.com> CC: Laurent Vivier <Laurent.Vivier@bull.net> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
2007-11-15i2c/eeprom: Recognize VGN as a valid Sony Vaio name prefixJean Delvare1-5/+9
Recent (i.e. 2005 and later) Sony Vaio laptops have names beginning with VGN rather than PCG. Update the eeprom driver so that it recognizes these. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-11-15i2c/eeprom: Hide Sony Vaio serial numbersJean Delvare1-8/+15
The sysfs interface to DMI data takes care to not make the system serial number and UUID world-readable, presumably due to privacy concerns. For consistency, we should not let the eeprom driver export these same strings to the world on Sony Vaio laptops. Instead, only make them readable by root, as we already do for BIOS passwords. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-11-15i2c-pasemi: Fix NACK detectionOlof Johansson1-0/+5
Turns out we don't actually check the status to see if there was a device out there to talk to, just if we had a timeout when doing so. Add the proper check, so we don't falsly think there are devices on the bus that are not there, etc. Signed-off-by: Olof Johansson <olof@lixom.net> Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-11-15i2c-pasemi: Replace obsolete "driverfs" reference with "sysfs"Robert P. J. Day1-1/+1
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-11-15i2c: Make i2c_check_addr staticJean Delvare2-7/+1
i2c_check_addr is only used inside i2c-core now, so we can make it static and stop exporting it. Thanks to David Brownell for noticing. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-11-15i2c-dev: Unbound new-style i2c clients aren't busyJean Delvare1-1/+25
Let i2c-dev deal properly with new-style i2c clients. Instead of considering them always busy, it needs to check wether a driver is bound to them or not. This is still not completely correct, as the client could become busy later, but the same problem already existed before new-style clients were introduced. We'll want to fix it someday. Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: David Brownell <dbrownell@users.sourceforge.net>
2007-11-15i2c-dev: "how does it work" commentsDavid Brownell1-1/+59
This adds some "how does this work" comments to the i2c-dev driver, plus separators between the three main components: - The parallel list of i2c_adapters ("i2c_dev_list"), each of which gets a "struct i2c_dev" and a /dev/i2c-X character special file. - An i2cdev_driver gets adapter add/remove notifications, which are used to maintain that list of adapters. - Special file operations, which let userspace talk either directly to the adapter (for i2c_msg operations) or through cached addressing info using an anonymous i2c_client (never registered anywhere). Plus there's the usual module load/unload record keeping. After making sense of this code, I think that the anonymous i2c_client is pretty shady. But since it's never registered, using this code with a system set up for "new style" I2C drivers is no more complicated than always using the I2C_SLAVE_FORCE ioctl (instead of I2C_SLAVE). Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Jean Delvare <khali@linux-fr.org>
2007-11-15Revert "skge: fix ram buffer size calculation"Linus Torvalds1-24/+27
This reverts commit 7fb7ac241162dc51ec0f7644d4a97b2855213c32. Heikki Orsila reports that it causes a regression: "Doing nc host port < /dev/zero on a sending machine (not skge) to an skge machine that is receiving: nc -l -p port >/dev/null with ~60 MiB/s speed, causes the interface go malfunct. A slow transfer doesn't cause a problem." See http://bugzilla.kernel.org/show_bug.cgi?id=9321 for some more information. There is a workaround (also reported by Heikki): "After some fiddling, I noticed that not changing the register write order on patch: + skge_write32(hw, RB_ADDR(q, RB_END), end); skge_write32(hw, RB_ADDR(q, RB_WP), start); skge_write32(hw, RB_ADDR(q, RB_RP), start); - skge_write32(hw, RB_ADDR(q, RB_END), end); fixes the visible effect.. Possibly not the root cause of the problem, but changing the order back fixes networking here." but that has yet to be ack'ed or tested more widely, so the whole problem-causing commit gets reverted until this is resolved properly. Bisected-and-requested-by: Heikki Orsila <shdl@zakalwe.fi> Cc: Stephen Hemminger <shemminger@linux-foundation.org> Cc: Jeff Garzik <jeff@garzik.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-15slob: fix memory corruptionNick Piggin1-1/+2
Previously, it would be possible for prev->next to point to &free_slob_pages, and thus we would try to move a list onto itself, and bad things would happen. It seems a bit hairy to be doing list operations with the list marker as an entry, rather than a head, but... this resolves the following crash: http://bugzilla.kernel.org/show_bug.cgi?id=9379 Signed-off-by: Nick Piggin <npiggin@suse.de> Signed-off-by: Ingo Molnar <mingo@elte.hu> Acked-by: Matt Mackall <mpm@selenic.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-15wait_task_stopped: Check p->exit_state instead of TASK_TRACEDRoland McGrath1-2/+1
The original meaning of the old test (p->state > TASK_STOPPED) was "not dead", since it was before TASK_TRACED existed and before the state/exit_state split. It was a wrong correction in commit 14bf01bb0599c89fc7f426d20353b76e12555308 to make this test for TASK_TRACED instead. It should have been changed when TASK_TRACED was introducted and again when exit_state was introduced. Signed-off-by: Roland McGrath <roland@redhat.com> Cc: Oleg Nesterov <oleg@tv-sign.ru> Cc: Alexey Dobriyan <adobriyan@sw.ru> Cc: Kees Cook <kees@ubuntu.com> Acked-by: Scott James Remnant <scott@ubuntu.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-15[AVR32] Export intc_get_pending symbolHaavard Skinnemoen1-1/+3
Oprofile needs to call intc_get_pending() in order to determine whether a performance counter interrupt is pending. Also, include the header which declares intc_get_pending() and fix the definition to match the prototype. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-11-15[AVR32] Add missing bit in PCCR sysregHaavard Skinnemoen1-0/+2
The enable bit was missing... Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-11-15[AVR32] Fix duplicate clock index in at32ap machine codeben.nizette@iinet.net.au1-1/+1
There's a duplicate clock index between USART0 and USART1 which may be causing system crashes when USART0 is used. Change the USART0 index to '3', indicating the clock that is actually used by USART0. Signed-off-by: Ben Nizette <ben@niasdigital.com> Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-11-15[AVR32] remove UID16 optionAdrian Bunk1-3/+0
avr32 already sees the option from init/Kconfig. Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-11-15[AVR32] Turn off debugging in SMC driverHaavard Skinnemoen1-1/+0
Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-11-15Extend I/O resource for wdt0 for at32ap7000 devicesHans-Christian Egtvedt1-1/+1
This patch extends the I/O resource to 0xfff000cf which will enable the watchdog driver to access the reset cause (RCAUSE) register. Making it capable of reporting boot status. Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel.com> Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-11-15[AVR32] pcmcia ioaddr_t should be 32 bits on AVR32Haavard Skinnemoen1-1/+1
Define ioaddr_t as u_int on AVR32 just like on ARM and MIPS. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-11-15[INET]: Fix potential kfree on vmalloc-ed area of request_sock_queuePavel Emelyanov2-17/+36
The request_sock_queue's listen_opt is either vmalloc-ed or kmalloc-ed depending on the number of table entries. Thus it is expected to be handled properly on free, which is done in the reqsk_queue_destroy(). However the error path in inet_csk_listen_start() calls the lite version of reqsk_queue_destroy, called __reqsk_queue_destroy, which calls the kfree unconditionally. Fix this and move the __reqsk_queue_destroy into a .c file as it looks too big to be inline. As David also noticed, this is an error recovery path only, so no locking is required and the lopt is known to be not NULL. reqsk_queue_yank_listen_sk is also now only used in net/core/request_sock.c so we should move it there too. Signed-off-by: Pavel Emelyanov <xemul@openvz.org> Acked-by: Eric Dumazet <dada1@cosmosbay.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-11-14[VIA_VELOCITY]: Don't oops on MTU change.Stephen Hemminger1-0/+5
Simple mtu change when device is down. Fix http://bugzilla.kernel.org/show_bug.cgi?id=9382. Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-11-14CRISv10 fasttimer: Scrap INLINE and name timeval_cmp betterJesper Nilsson1-9/+7
Scrap the local __INLINE__ macro, and rename timeval_cmp to fasttime_cmp. Inline macro was completely unnecessary since the macro was defined locally to be inline. timeval_cmp was inaccurately named since it does comparison on struct fasttimer_t and not on struct timeval. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv10 memset library add lineendings to asmJesper Nilsson1-41/+41
Add \n\ at end of lines inside asm statement to avoid warning. No change except adding \n\ to end of line and correcting whitespace has been done. Removes warning about multi-line string literals when compiling arch/cris/arch-v10/lib/memset.c Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv10 string library add lineendings to asmJesper Nilsson1-27/+27
Add \n\ at end of lines inside asm statement to avoid warning. No change except adding \n\ to end of line and correcting whitespace has been done. Removes warning about multi-line string literals when compiling arch/cris/arch-v10/lib/string.c Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv10 usercopy library add lineendings to asmJesper Nilsson1-157/+157
Removes warning when compiling arch/cris/arch-v10/lib/usercopy.c No change except adding \n\ on the end of the lines has been done. Removes warning about multi-line string literals. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv10 Ethernet declare mac fixJesper Nilsson1-1/+1
Declare mac using DECLARE_MAC_BUF for use when calling print_mac(). This fixes compile error where mac was undeclared. Also, remove unused variable i. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Cc: Jeff Garzik <jeff@garzik.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRIS tlb.h should include linux/pagemap.hJesper Nilsson1-0/+2
Include linux/pagemap.h for release_pages and page_cache_release. Fixes compilation error in arch/cris/mm/init.c when CONFIG_SWAP is unset. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv32: add cache flush operationsJesper Nilsson2-0/+127
These are needed due to a cache bug, and can be used to make sure that the DMA descriptors are flushed to memory and can be safely handled by DMA. flush_dma_descr - Flush one DMA descriptor. flush_dma_list - Flush a complete list of DMA descriptors. cris_flush_cache - Flush the complete cache. cris_flush_cache_range - Flush only the specified range Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv10 improve and bugfix fasttimerJesper Nilsson2-207/+124
Improve and bugfix CRIS v10 fast timers. - irq_handler_t now only takes two arguments. - Keep interrupts disabled as long as we have a reference to the fasttimer list and only enable them while doing the callback. del_fast_timer may be called from other interrupt context. - Fix bug where debug code could return without calling local_irq_restore. - Use jiffies instead of usec (change from struct timeval to fasttime_t). - Don't initialize static variables to zero. - Remove obsolete #ifndef DECLARE_WAITQUEUE code. - fast_timer_init should be __initcall. - Change status/debug variables to unsigned. - Remove CVS log and CVS id. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv10: fix timer interrupt parametersJesper Nilsson1-4/+7
Fix timer interrupt parameters for CRIS v10. - irq_handler_t only takes two arguments, use get_irq_regs to get regs for profiling. - Call update_process_times. - Remove CVS tag. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <mikael.starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRIS: remove MTD_AMSTD and MTD_OBSOLETE_CHIPS take twoJesper Nilsson6-17/+8
Remove MTD_AMDSTD and MTD_OBSOLETE_CHIPS from defconfig, Kconfig and code, instead we'll use MTD_CFI or MTD_JEDECPROBE. [akpm@linux-foundation.org: codingl-style cleanups] Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRISv10 serial driver rewriteJesper Nilsson2-859/+580
New and improved serial driver for CRISv10, take three, with improvements suggested by Jiri Slaby. - Call wait_event_interruptible with a _correct_ and sensible condition. - Removed superfluous test of info->flags & ASYNC_CLOSING, since that is done by wait_event_interruptible. - Moved common code for deregistering DMA and IRQ to deinit_port function. - Use setup_timer when initializing flush_timer. - Convert bit-field for uses_dma_in and uses_dma_out to regular bytes. - Removed CVS tags. - Removed defines and comments for CRIS_BUF_SIZE and TTY_THRESHOLD_THROTTLE (no longer used). - Cleaned up code to pass checkpatch. - Add crisv10.h header file. - Merge of CRISv10 from Axis internal CVS. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Reviewed-by: Jiri Slaby <jirislaby@gmail.com> Cc: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14CRIS don't include bitops.h in posix_types.hJesper Nilsson1-1/+0
In file included from include/asm/byteorder.h:23, from include/asm-generic/bitops/le.h:5, from include/asm-generic/bitops/ext2-non-atomic.h:4, from include/asm/bitops.h:163, from include/linux/bitops.h:17, from include/asm/posix_types.h:55, from include/linux/posix_types.h:47, from include/linux/types.h:11, from include/linux/capability.h:16, from include/linux/sched.h:49, from arch/cris/kernel/asm-offsets.c:1: include/linux/byteorder/little_endian.h:43: parse error before "__cpu_to_le64p" include/linux/byteorder/little_endian.h:44: warning: return type defaults to `int' include/linux/byteorder/little_endian.h: In function `__cpu_to_le64p': include/linux/byteorder/little_endian.h:45: `__le64' undeclared (first use in this function) Remove include of asm/bitops.h, not needed here, corrects compilation error (__le64 undeclared). Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris: ARRAY_SIZE() cleanupAlex Unleashed5-9/+7
I'm converting most array size calculations under arch/ to use ARRAY_SIZE(). This is the patch for CRIS. Signed-off-by: Alejandro Martinez Ruiz <alex@flawedcode.org> Cc: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: defconfig updatesJesper Nilsson1-43/+33
Remove some unused config lines, and add some others that needs to be off for a succesful compile. This is the minimal set of changes for 2.6.23. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: fix crisksyms.cJesper Nilsson1-14/+3
- Add __negdi2 to exported symbols. - Remove string functions from exported symbols. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: setup.c needs param.hJesper Nilsson1-0/+1
Include linux/param.h for HZ. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: fixes in arch/cris/kernel/time.cJesper Nilsson1-7/+3
- Remove debug print. - Change #if to #ifdef to avoid compile time warning if CONFIG_PROFILING isn't set. - Number of parameters to profile_tick has changed, drop the regs parameter. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: corrected and improved NMI and IRQ handlingJesper Nilsson7-29/+107
Corrects compile errors and the following: - Remove oldset parameter from do_signal and do_notify_resume. - Modified to fit new consolidated IRQ handling code. - Reverse check order between external nmi and watchdog nmi to avoid false watchdog oops in case of a glitch on the nmi pin. - Return from an pin-generated NMI the same way as for other interrupts. - Moved blocking of ethernet rx/tx irq from ethernet interrupt handler to low-level asm interrupt handlers. Fixed in the multiple interrupt handler also. - Add space for thread local storage in thread_info struct. - Add NO_DMA to Kconfig, and include arch specific Kconfig using arch independent path. Include subsystem Kconfigs for pcmcia, usb, i2c, rtc and pci. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris-build-fixes-update-eth_v10c-ethernet-driver-fixAndrew Morton1-4/+8
Fix locking bug noted by Roel Kluin <12o3l@tiscali.nl>. Cc: Jeff Garzik <jeff@garzik.org> Cc: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <starvik@axis.com> Cc: Roel Kluin <12o3l@tiscali.nl> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: update eth_v10.c ethernet driverJesper Nilsson2-152/+279
New (updated) version of ethernet driver for cris v10. - First steps to simplify and make the MII code more similar between the etrax100 and etraxfs ports. - Start the transmit queue before enabling tx interrupts to avoid race with the first frame. - Flip the comparition statement to stick to physical addresses to avoid phys_to_virt mapping a potential null pointer. This was not an error but the change simplifies debugging of address-space mappings. - Made myPrevRxDesc local to e100_rx since it was only used there. Fixed out of memory handling in e100_rx. If dev_alloc_skb() fails persistently the system is hosed anyway but at least it won't loop in an interrupt handler. - Correct some code formatting issues. - Add defines SET_ETH_ENABLE_LEDS, SET_ETH_DISABLE_LEDS and SET_ETH_AUTONEG used in new cris v10 ethernet driver. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Cc: Jeff Garzik <jeff@garzik.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: add baud rate definesJesper Nilsson1-0/+13
Add missing defines for (unsupported) baud rates. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: sys_cris.c needs fs.hJesper Nilsson1-0/+1
Include linux/fs.h, needed for do_pipe. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: irq fixesJesper Nilsson2-2/+8
- New file include/asm-cris/irq_regs.h. - Change handling of registers for do_IRQ. - Add GENERIC_HARDIRQS to Kconfig. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris-build-fixes-atomich-needs-compilerh-fixAndrew Morton1-1/+2
Cc: Jesper Nilsson <jesper.nilsson@axis.com> Cc: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: atomic.h needs compiler.hJesper Nilsson1-0/+1
Include file linux/compiler.h is needed for 'likely'. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: hardirq.h: include asm/irq.hJesper Nilsson1-0/+1
Include asm/irq.h to avoid undefined value warning. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: Add missing syscallsJesper Nilsson2-1/+74
Add missing syscalls to cris architecture. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14cris build fixes: fix csum_tcpudp_magic() declarationJesper Nilsson1-1/+1
Remove int from prototype, no longer needed and causes compile error. Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com> Acked-by: Mikael Starvik <starvik@axis.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>