aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2011-01-10xen/event: validate irq before get evtchn by irqJoe Jin1-0/+3
When retrieving the event channel number from irq, the irq number may not be valid under some conditions. So far that can be when we suspend/resume and irq ends with -1. Validate and return sanitized irq and provide diagnostics information. [v3: added unlikely on the WARN path] [v2: reworded the commit message] Signed-off-by: Joe Jin <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]> Tested-by: Gurudas Pai <[email protected]> Cc: Ian Campbell <[email protected]> Cc: Jeremy Fitzhardinge <[email protected]> Cc: Andrew Morton <[email protected]>
2011-01-10xen/fb: fix potential memory leakJoe Jin1-8/+9
This patch fixes a potential memory leak when xenfb connect to the backend fails. Thanks for Ian's review and comments. [v2: reworded the commit message a bit] Signed-off-by: Konrad Rzeszutek Wilk <[email protected]> Signed-off-by: Joe Jin <[email protected]> Tested-by: Gurudas Pai <[email protected]> Acked-by: Ian Campbell <[email protected]> Cc: Jeremy Fitzhardinge <[email protected]> Cc: Andrew Morton <[email protected]>
2011-01-10xen/fb: fix xenfb suspend/resume race.Joe Jin1-0/+2
When migrating guests over a long period we hit this: <1>BUG: unable to handle kernel paging request at 0000000b819fdb98 <1>IP: [<ffffffff812a588f>] notify_remote_via_irq+0x13/0x34 <4>PGD 94b10067 PUD 0 <0>Oops: 0000 [#1] SMP .. snip.. Call Trace: [<ffffffff812712c9>] xenfb_send_event+0x5c/0x5e [<ffffffff8100ea5f>] ? xen_restore_fl_direct_end+0x0/0x1 [<ffffffff81438d80>] ? _spin_unlock_irqrestore+0x16/0x18 [<ffffffff812714ee>] xenfb_refresh+0x1b1/0x1d7 [<ffffffff81270568>] ? sys_imageblit+0x1ac/0x458 [<ffffffff81271786>] xenfb_imageblit+0x2f/0x34 [<ffffffff8126a3e5>] soft_cursor+0x1b5/0x1c8 [<ffffffff8126a137>] bit_cursor+0x4b6/0x4d7 [<ffffffff8100ea5f>] ? xen_restore_fl_direct_end+0x0/0x1 [<ffffffff81438d80>] ? _spin_unlock_irqrestore+0x16/0x18 [<ffffffff81269c81>] ? bit_cursor+0x0/0x4d7 [<ffffffff812656b7>] fb_flashcursor+0xff/0x111 [<ffffffff812655b8>] ? fb_flashcursor+0x0/0x111 [<ffffffff81071812>] worker_thread+0x14d/0x1ed [<ffffffff81075a8c>] ? autoremove_wake_function+0x0/0x3d [<ffffffff81438d80>] ? _spin_unlock_irqrestore+0x16/0x18 [<ffffffff810716c5>] ? worker_thread+0x0/0x1ed [<ffffffff810756e3>] kthread+0x6e/0x76 [<ffffffff81012dea>] child_rip+0xa/0x20 [<ffffffff81011fd1>] ? int_ret_from_sys_call+0x7/0x1b [<ffffffff8101275d>] ? retint_restore_args+0x5/0x6 [<ffffffff81012de0>] ? child_rip+0x0/0x20 Code: 6b ff 0c 8b 87 a4 db 9f 81 66 85 c0 74 08 0f b7 f8 e8 3b ff ff ff c9 c3 55 48 89 e5 48 83 ec 10 0f 1f 44 00 00 89 ff 48 6b ff 0c <8b> 87 a4 db 9f 81 66 85 c0 74 14 48 8d 75 f0 0f b7 c0 bf 04 00 RIP [<ffffffff812a588f>] notify_remote_via_irq+0x13/0x34 RSP <ffff8800e7bf7bd0> CR2: 0000000b819fdb98 ---[ end trace 098b4b74827595d0 ]--- The root cause of the panic is the race between the resume and reconnect to the backend. Clearing the 'update_wanted' flag of xenfb before disconnecting from the backend fixes this issue. Signed-off-by: Joe Jin <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]> Tested-by: Gurudas Pai <[email protected]> Acked-by: Ian Campbell <[email protected]> Cc: Jeremy Fitzhardinge <[email protected]> Cc: Andrew Morton <[email protected]>
2011-01-10xen: disable ACPI NUMA for PV guestsIan Campbell1-0/+9
Xen does not currently expose PV-NUMA information to PV guests. Therefore disable NUMA for the time being to prevent the kernel picking up on an host-level NUMA information which it might come across in the firmware. [ Added comment - Jeremy ] Signed-off-by: Ian Campbell <[email protected]> Signed-off-by: Jeremy Fitzhardinge <[email protected]> Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
2011-01-10Merge branch 'for-linus' of ↵Linus Torvalds1-13/+50
git://git.kernel.org/pub/scm/linux/kernel/git/teigland/dlm * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/teigland/dlm: dlm: sanitize work_start() in lowcomms.c dlm: reduce cond_resched during send dlm: use TCP_NODELAY dlm: Use cmwq for send and receive workqueues dlm: Handle application limited situations properly.
2011-01-10Merge branch 'for-linus' of ↵Linus Torvalds6-77/+281
git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse: fuse: fix ioctl ABI fuse: allow batching of FORGET requests fuse: separate queue for FORGET requests fuse: ioctl cleanup Fix up trivial conflict in fs/fuse/inode.c due to RCU lookup having done the RCU-freeing of the inode in fuse_destroy_inode().
2011-01-10pipe_fs_i.h: fix kernel-doc warningRandy Dunlap1-0/+1
Fix kernel-doc notation warnings in pipe_fs_i.h: Warning(include/linux/pipe_fs_i.h:58): No description found for parameter 'buffers' Signed-off-by: Randy Dunlap <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2011-01-10hrtimer.h: fix kernel-doc warningRandy Dunlap1-1/+0
Fix new kernel-doc notation warning in hrtimer.h: Warning(include/linux/hrtimer.h:150): Excess struct/union/enum/typedef member 'first' description in 'hrtimer_clock_base' Signed-off-by: Randy Dunlap <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2011-01-10fs: fix dcache.h kernel-doc notationRandy Dunlap1-1/+1
Fix new kernel-doc notation warning in dcache.h: Warning(include/linux/dcache.h:316): Excess function parameter 'Returns' description in '__d_rcu_to_refcount' Signed-off-by: Randy Dunlap <[email protected]> Cc: Nick Piggin <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2011-01-10fs: fix namei.c kernel-doc notationRandy Dunlap1-4/+4
Fix new kernel-doc notation warnings in fs/namei.c and spell ECHILD correctly. Warning(fs/namei.c:218): No description found for parameter 'flags' Warning(fs/namei.c:425): Excess function parameter 'Returns' description in 'nameidata_drop_rcu' Warning(fs/namei.c:478): Excess function parameter 'Returns' description in 'nameidata_dentry_drop_rcu' Warning(fs/namei.c:540): Excess function parameter 'Returns' description in 'nameidata_drop_rcu_last' Signed-off-by: Randy Dunlap <[email protected]> Cc: Nick Piggin <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2011-01-10perf tools: Emit clearer message for sys_perf_event_open ENOENT returnArnaldo Carvalho de Melo2-0/+5
Improve sys_perf_event_open ENOENT return handling in top and record, just like 5a3446b does for stat. Cc: David Ahern <[email protected]> Cc: Frederic Weisbecker <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Mike Galbraith <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Stephane Eranian <[email protected]> Cc: Tom Zanussi <[email protected]> LKML-Reference: <new-submission> Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
2011-01-10perf stat: better error message for unsupported eventsDavid Ahern1-0/+2
For unsupported events (e.g., H/W events when running in a VM) perf stat currently fails with the error message: Error: open_counter returned with 2 (No such file or directory). /bin/dmesg may provide additional information. Fatal: Not all events could be opened. dmesg is of no help and it is not clear as to why it fails to open the counter. This patch changes the error message to Error: cache-misses event is not supported. Fatal: Not all events could be opened. Cc: Ingo Molnar <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: [email protected] LPU-Reference: <[email protected]> Signed-off-by: David Ahern <[email protected]> Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
2011-01-10perf sched: Fix allocation result checkArnaldo Carvalho de Melo1-1/+1
Bug introduced in ce47dc56. Reported-by: Mike Galbraith <[email protected]> Cc: Chris Samuel <[email protected]> Cc: Frederic Weisbecker <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Mike Galbraith <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Stephane Eranian <[email protected]> Cc: Tom Zanussi <[email protected]> LKML-Reference: <new-submission> Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
2011-01-10Blackfin: encode cpu-rev into uImage nameMike Frysinger2-3/+6
Encoding the cpu family name apparently confuses people when they try to boot an image on a sub-variant, so encode the specific cpu name and the silicon rev instead. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf54x: don't ack GPIO ints when unmasking themMike Frysinger1-1/+0
When unmasking a GPIO interrupt on a BF54x part, the code will implicitly ack any pending interrupts. This is not what unmasking should do and can cause people to miss interrupts from their devices, so punt the code. Reported-by: Rutger Hofman <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: sram_free_with_lsl: do not ignore return value of sram_freeMike Frysinger1-9/+9
If there was an error in the lower free functions, we need to pass that back up so the calling process is able to check things. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: boards: add missing "static" to peripheral listsMike Frysinger26-95/+95
Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: DNP5370: new board portAndreas Schallenberg4-0/+546
Signed-off-by: Andreas Schallenberg <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf518f-ezbrd: fix dsa resourcesSonic Zhang1-9/+8
On bf518-ezbrd with DSA Ethernet switch enabled, on chip MAC is connecting to phy at address 3. If allowing the netdevice framework to probe both 3 phys of the switch when registering MAC phy, phy at address 1 is checked for link active status other than phy at address 3. If connecting a cable to port 2 and leave port 1 open, link status in phy 2 and 3 are online, while that in phy 1 is offline. So, the phy layer sets wrong offline status to net device on port 3. In this case, no data can be transferred via ethernet port 2. Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: move "-m elf32bfin" to general LDFLAGSMike Frysinger1-1/+1
Common code now invokes the linker directly which causes build failures when using an FDPIC toolchain. So move the emulation setting out of the module-specific LDFLAGS and into the common LDFLAGS. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: kgdb_test: make sure to initialize num2Vivi Li1-0/+4
We check its value at runtime, so we want to avoid garbage across runs. Signed-off-by: Vivi Li <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: kgdb: disable preempt schedule when running single step in kgdbSonic Zhang1-1/+7
Otherwise, gdb continue operation after a breakpoint is hit may trap into endless breakpoint. Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: kgdb: disable interrupt when single stepping in ADEOSSonic Zhang1-0/+20
When ADEOS and kgdb are both enabled, single step in linux kernel may be scheduled to Xenomai core after return from interrupt handlers. This blocks gdb continue operation after a break point is hit. So, disable interrupt when running gdb single step. Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: kgdb: apply anomaly 257 work aroundSonic Zhang1-1/+5
When run kgdb testing, it looks like coreb hangs in single step or trap exception without handling anomaly 05000257 properly on bf561 v0.5. But, the anomaly list says it apply to bf561 v0.4 and bellow. Apply its work around to 0.5 temporarily until the behavior and the root cause can be confirmed by the hardware team. Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: fix building IPIPE code when XIP is enabledMike Frysinger1-2/+2
The low level assembly needs to use the pseudo_long_call helper so that we use the right call insn when doing kernel XIP. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: kgdb: flush core internal write buffer before flushinvSonic Zhang1-0/+5
KGDB single step in SMP kernel may hang forever in flushinv without a CSYNC ahead. This is because the core internal write buffers need to be flushed before invalidating the data cache to make sure the insn fetch is not out of sync. Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: sport_uart resources: remove unused secondary RX/TX pinsSonic Zhang18-36/+36
The SPORT/UART driver doesn't use the secondary channel pins, so don't try and request them thus keeping other drivers from using them. Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: tll6527m: fix spelling in unused code (struct name)Stefan Weil1-1/+1
platfrom -> platform This changes a struct name. The related code is conditionally compiled and won't work because the include file linux/gpio-decoder.h is missing, so removing this code would be an even better solution. If the missing include file is added, it must fix the spelling, too. Signed-off-by: Stefan Weil <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf527-ezkit: add adau1373 chip addressSonic Zhang1-0/+5
Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: no-mpu: fix masking of small uncached dma regionSonic Zhang1-1/+1
When using an uncached DMA region less than 1 MiB, we try to mask off the whole last 1 MiB for it. Unfortunately, this fails as we forgot to subtract one from the calculated mask, leading to the region still be marked as cacheable. Reported-by: Andrew Rook <[email protected]> Signed-off-by: Sonic Zhang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: pm: drop irq save/restore in standby and suspend to mem callbackSteven Miao1-10/+0
Since linux-2.6.31, the kernel suspend framework will do disable_irq/enable_irq, so save/restore irq in standby and suspend to mem callback should be dropped. Otherwise the common code notices things are enabled and complains. Signed-off-by: Steven Miao <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10MAINTAINERS: update Analog Devices support infoMichael Hennerich1-4/+78
Add more Analog Devices driver entries and refine the differences between Blackfin-specific code and processor independent drivers. Signed-off-by: Michael Hennerich <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: dpmc.h: pull in new pll.hMike Frysinger1-0/+2
Any consumer of dpmc.h expects to use VR_CTL, so also pull in the new mach/pll.h header for those functions. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf54x: add MMR layout for PINTMike Frysinger1-0/+22
Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf561: SMP: add multicore pll handlersMike Frysinger1-0/+53
Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: unify pll.h headersMike Frysinger8-435/+93
Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: rewrite IPI handling to avoid memory allocationYi Li3-133/+97
Currently, sending an interprocessor interrupt (IPI) requires building up a message dynamically which means memory allocation. But often times, we will want to send an IPI in low level contexts where allocation is not possible which may lead to a panic(). So create a per-cpu static array for the message queue and use that instead. Further, while we have two supplemental interrupts, we are currently only using one of them. So use the second one for the most common IPI message of all -- smp_send_reschedule(). This avoids ugly contention for locks which in turn would require an IPI message ... In general, this improves SMP performance, and in some cases allows the SMP port to work in places it wouldn't before. Such as the PREEMPT_RT state where the slab is protected by a per-cpu spin lock. If the slab kmalloc/kfree were to put the task to sleep, and that task was actually the IPI handler, then the system falls down yet again. After running some various stress tests on the system, the static limit of 5 messages seems to work. On the off chance even this overflows, we simply panic(), and we can review that scenario to see if the limit needs to be increased a bit more. Signed-off-by: Yi Li <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: relocate blackfin_core_id() definitionGraf Yang2-4/+3
Since we're breaking apart some inter-header dependencies to avoid more circular loops, move the blackfin_core_id() definition to the func that it is based upon. Signed-off-by: Graf Yang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: fix build breakage in cache.hMike Frysinger1-0/+2
The SMP code needs "asmlinkage" which linkage.h provides. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: add missing arch_{read,write}_lock_flags helpersGraf Yang1-0/+4
Common code expects these to be defined for SMP ports, so add them. Signed-off-by: Graf Yang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf561: fix mem_map.h SMP overridesGraf Yang1-7/+9
The BF561 mem_map.h header has the __ASSEMBLY__/CONFIG_SMP checks out of order which leads to build errors for assembly code that happens to include this file. Signed-off-by: Graf Yang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: tweak platform_request_ipi() usageGraf Yang3-3/+5
This function takes an irq_handler_t function, but the prototype in the header doesn't match the function definition. This is due to the smp headers needing to avoid circular dependencies. So change the function to take a simple pointer. Signed-off-by: Graf Yang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: fix asm/bitops.h errorsMike Frysinger1-0/+2
The common asm-generic non-atomic bitops.h defines test_bit() for us, but we need to use our own version. So redirect the definition of this func to avoid having to inline the rest of the asm-generic file. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: fix cpumask misbehaviorGraf Yang1-6/+1
The cpu maps are defines provided by common linux/cpumask.h, not local variables. So stop exporting them locally and include the right header for their definition. Signed-off-by: Graf Yang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: SMP: rename the arch_xxx lock funcs to __raw_xxxGraf Yang2-12/+15
The external functions are named __raw_xxx, not arch_xxx, so rename the prototypes to match reality. This fixes some simple build errors in the bfin_ksyms.c code which exports these helpers to modules. Signed-off-by: Graf Yang <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10serial: bfin_5xx: move resources into board filesSonic Zhang3-320/+400
Rather than maintain Kconfig entries where people have to enter raw numbers and hardcode lists of addresses/pins in the driver itself, push it all to platform resources. This lets us simplify the driver, the Kconfig, and gives board porters greater flexibility. In the process, we need to also start supporting the early platform interface. Not a big deal, but it causes the patch to be bigger than a simple resource relocation. All the Blackfin boards already have their resources updated and in place for this change. Signed-off-by: Sonic Zhang <[email protected]> Acked-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf561: update a few more SIC_SYSCR locationsMike Frysinger2-14/+14
Looks like I missed a few new spots when renaming the SICA macros. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: drop asm/irq.h include from mach headersMike Frysinger7-21/+0
These were only included because of the irq handling of the PLL funcs, and those PLL funcs have been moved out into their own header now. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: bf51x/bf52x: drop redundant "base" def/cdef headerMike Frysinger8-4953/+4893
The defBF512.h header exists only to include defBF51x_base.h, and it is the only place where defBF51x_base.h is included. So move the contents of the defBF51x_base.h header into the defBF512.h header. Same situation for the other def/cdef pairs. Signed-off-by: Mike Frysinger <[email protected]>
2011-01-10Blackfin: clean up mach header includesMike Frysinger45-2142/+1990
The main asm/blackfin.h header will pull in mach/blackfin.h to get all the fun Blackfin defines. So having any of the sub-mach headers trying to include asm/blackfin.h makes no sense -- punt it. The mach/blackfin.h header takes care of including the part-specific def headers which in turn will include any other needed def file. Similarly, it takes care of pulling in the part-specific cdef header. So move this logic out of the blackfin.h when necessary. Further, make sure the cdef headers do not waste time including the def headers again. Since all parts need the common def/cdef headers, move this logic out of the part-specific headers and into the mach/blackfin.h file. Finally, we need to split the BF539 def header since the BF538 does not have MXVR and we don't want to expose those MMRs. So now all parts should have the same behavior: mach/blackfin.h asm/def_LPBlackfin.h part-specific def.h if ! asm asm/cdef_LPBlackfin.h part-specific cdef.h And the sub def/cdef headers only tail into what they need. Signed-off-by: Mike Frysinger <[email protected]>