dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

58571 Commits

Author SHA1 Message Date
Joerg Roedel 3b03bb745e x86/amd-iommu: Search for existind dev_data before allocting a new one
Search for existing dev_data first will allow to switch
dev_data->alias to just store dev_data instead of struct
device.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:58 +02:00
Joerg Roedel 2b02b091ab x86/amd-iommu: Allow dev_data->alias to be NULL
Let dev_data->alias be just NULL if the device has no alias.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:58 +02:00
Joerg Roedel ec9e79ef06 x86/amd-iommu: Use only dev_data in low-level domain attach/detach functions
With this patch the low-level attach/detach functions only
work on dev_data structures. This allows to remove the
dev_data->dev pointer.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:58 +02:00
Joerg Roedel 6c54204793 x86/amd-iommu: Use only dev_data for dte and iotlb flushing routines
This patch make the functions flushing the DTE and IOTLBs
only take the dev_data structure instead of the struct
device directly.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:57 +02:00
Joerg Roedel ea61cddb9d x86/amd-iommu: Store ATS state in dev_data
This allows the low-level functions to operate on dev_data
exclusivly later.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:57 +02:00
Joerg Roedel f62dda66b5 x86/amd-iommu: Store devid in dev_data
This allows to use dev_data independent of struct device
later.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:57 +02:00
Joerg Roedel 8fa5f802ab x86/amd-iommu: Introduce global dev_data_list
This list keeps all allocated iommu_dev_data structs in a
list together. This is needed for instances that have no
associated device.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:57 +02:00
Joerg Roedel 39c555460c x86/amd-iommu: Remove redundant device_flush_dte() calls
Remove these function calls from places where the function
has already been called by another function.

Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-14 12:49:57 +02:00
Linus Torvalds c78a9b9b8e Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  ftrace: Revert 8ab2b7efd ftrace: Remove unnecessary disabling of irqs
  kprobes/trace: Fix kprobe selftest for gcc 4.6
  ftrace: Fix possible undefined return code
  oprofile, dcookies: Fix possible circular locking dependency
  oprofile: Fix locking dependency in sync_start()
  oprofile: Free potentially owned tasks in case of errors
  oprofile, x86: Add comments to IBS LVT offset initialization
2011-06-13 10:45:49 -07:00
Linus Torvalds 842c895d14 Merge branches 'x86-urgent-for-linus' and 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86: devicetree: Add missing early_init_dt_setup_initrd_arch stub
  x86: cpu-hotplug: Prevent softirq wakeup on wrong CPU

* 'irq-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  genirq: Prevent potential NULL dereference in irq_set_irq_wake()
2011-06-13 10:45:10 -07:00
Linus Torvalds acb11bcdbd Merge branch 's5p-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung
* 's5p-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/kgene/linux-samsung:
  ARM: S3C2410: remove the now empty mach-s3c2410/irq.c
  ARM: S3C24XX: Move s3c24xx_irq_syscore_ops to plat-s3c24xx/irq.c
  ARM: S3C24xx: Fix missing struct for s3c2410_dma_chan
  ARM: SAMSUNG: Remove unused onenand plat functions
  ARM: EXYNOS4: Remove compiler warning on exynos4_pwm4_resume
  ARM: S5P: Fix compilation error for exynos4_defconfig
  ARM: S5P: Should be S3C_VA_USB_HSPHY instead of S5P_VA_XX
  ARM: S5P64X0: Fix SPI platform device name
  ARM: S5PV210: Fix possible null pointer dereference
2011-06-13 10:32:53 -07:00
Linus Torvalds 08d63aac43 Merge branch 'gpio/merge' of git://git.secretlab.ca/git/linux-2.6
* 'gpio/merge' of git://git.secretlab.ca/git/linux-2.6:
  gpio/basic_mmio: add missing include of spinlock_types.h
  gpio/nomadik: fix sleepmode for elder Nomadik
2011-06-12 11:03:29 -07:00
Linus Torvalds 152b92db7a Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (55 commits)
  ISDN, hfcsusb: Don't leak in hfcsusb_ph_info()
  netpoll: call dev_put() on error in netpoll_setup()
  net: ep93xx_eth: fix DMA API violations
  net: ep93xx_eth: drop GFP_DMA from call to dma_alloc_coherent()
  net: ep93xx_eth: allocate buffers using kmalloc()
  net: ep93xx_eth: pass struct device to DMA API functions
  ep93xx: set DMA masks for the ep93xx_eth
  vlan: Fix the ingress VLAN_FLAG_REORDER_HDR check
  dl2k: EEPROM CRC calculation wrong endianess on bigendian machine
  NET: am79c961: fix assembler warnings
  NET: am79c961: ensure multicast filter is correctly set at open
  NET: am79c961: ensure asm() statements are marked volatile
  ethtool.h: fix typos
  ep93xx_eth: Update MAINTAINERS
  ipv4: Fix packet size calculation for raw IPsec packets in __ip_append_data
  netpoll: prevent netpoll setup on slave devices
  net: pmtu_expires fixes
  gianfar:localized filer table
  iwlegacy: fix channel switch locking
  mac80211: fix IBSS teardown race
  ...
2011-06-12 11:03:08 -07:00
Mika Westerberg fa70cf472c ep93xx: set DMA masks for the ep93xx_eth
Since the driver uses the DMA API, we should pass it valid DMA masks.

Signed-off-by: Mika Westerberg <mika.westerberg@iki.fi>
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Tested-by: Petr Stetiar <ynezz@true.cz>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-11 16:25:15 -07:00
Linus Torvalds 7f45e5cd17 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6:
  sparc32, leon: bugfix in LEON SMP interrupt init
  sparc32, sun4m: bugfix in SMP IPI traphandler
  sparc: Remove unnecessary semicolons
  Add support for allocating irqs for bootbus devices
  Do not skip interrupt sources in sun4d interrupt handler and acknowledge interrupts correctly
  Restructure sun4d_build_device_irq so that timer interrupts can be allocated
  sparc: PCIC_PCI needs SPARC32 dependency
  sparc: Do not select GENERIC_HARDIRQS_NO_DEPRECATED
  sparc32,leon: add GRPCI2 PCI Host driver
  sparc32,leon: added LEON-common low-level PCI routines
  sparc32: added CONFIG_PCIC_PCI Kconfig setting
2011-06-09 16:33:01 -07:00
Daniel Hellstrom 10f0d07c51 sparc32, leon: bugfix in LEON SMP interrupt init
During converting per-cpu ticker to genirq layer some
IRQ initialization code was removed by commit
2cf9530420 ("sparc32,leon:
per-cpu ticker use genirq per-cpu handler").

This patch reintroduces the code at the same place it was
removed from. IRQ12 - IRQ14 will crash on LEON SMP without
this patch because it will run the SUN4M IRQ trap handler.

Reported-by: Jan Andersson <jan@gaisler.com>
Signed-off-by: Daniel Hellstrom <daniel@gaisler.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-09 16:12:34 -07:00
Daniel Hellstrom a7d82a0a3c sparc32, sun4m: bugfix in SMP IPI traphandler
Three new IPIs were introduced by commit
ecbc42b70a ("sparc32, sun4m:
Implemented SMP IPIs support for SUN4M machines"), the
old handler was already prepared for IPIs but handled only
IRQ14 and IRQ13, this patch adds support for the new IPI at
IRQ12.

The IPI trap handler looks at the mask rather than the
pending IRQ/IPI, this bug may have masked the problem
above, introduced by the same commit.

Signed-off-by: Daniel Hellstrom <daniel@gaisler.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-09 16:12:34 -07:00
Linus Walleij 33d78647dc gpio/nomadik: fix sleepmode for elder Nomadik
The mach-nomadik machine did not compile properly due to bad
ux500-specific functions being called. Introduce new state
variables to fix this up.

Reported-by: Axel Lin <axel.lin@gmail.com>
Cc: Alessandro Rubini <rubini@unipv.it>
Cc: Prafulla Wadaskar <prafulla.wadaskar@st.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2011-06-09 15:03:38 -06:00
Linus Torvalds dfb863a714 Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc
* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc:
  powerpc: Force page alignment for initrd reserved memory
  dtc/powerpc: remove obsolete .gitignore entries
  powerpc/85xx: fix race bug of calling request_irq after enable elbc interrupts
  powerpc/book3e: Fix CPU feature handling on e5500 in 32-bit mode
  powerpc/fsl_rio: Fix compile error when CONFIG_FSL_RIO not set
2011-06-09 13:50:25 -07:00
Linus Torvalds 5ebe5500fb Merge branch 'unicore32' of git://git.kernel.org/pub/scm/linux/kernel/git/epip/linux-2.6-unicore32
* 'unicore32' of git://git.kernel.org/pub/scm/linux/kernel/git/epip/linux-2.6-unicore32:
  unicore32: using generic-y format for one line asm-generic files
  unicore32: change PERCPU to PERCPU_SECTION
  unicore32: add KBUILD_DEFCONFIG with unicore32_defconfig (old debug_defconfig)
  unicore32: change zImage physical address, though it's PIC codes
  unicore32: move rtc-puv3.c to drivers/rtc directory
2011-06-09 12:52:05 -07:00
Mathias Krause dac853ae89 exec: delay address limit change until point of no return
Unconditionally changing the address limit to USER_DS and not restoring
it to its old value in the error path is wrong because it prevents us
using kernel memory on repeated calls to this function.  This, in fact,
breaks the fallback of hard coded paths to the init program from being
ever successful if the first candidate fails to load.

With this patch applied switching to USER_DS is delayed until the point
of no return is reached which makes it possible to have a multi-arch
rootfs with one arch specific init binary for each of the (hard coded)
probed paths.

Since the address limit is already set to USER_DS when start_thread()
will be invoked, this redundancy can be safely removed.

Signed-off-by: Mathias Krause <minipli@googlemail.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-06-09 12:50:05 -07:00
Florian Fainelli 977cb76d52 x86: devicetree: Add missing early_init_dt_setup_initrd_arch stub
This patch fixes the following build failure:

drivers/built-in.o: In function `early_init_dt_check_for_initrd':
/home/florian/dev/kernel/x86/linux-2.6-x86/drivers/of/fdt.c:571:
undefined reference to `early_init_dt_setup_initrd_arch'
make: *** [.tmp_vmlinux1] Error 1

which happens as soon as we enable initrd support on a x86 devicetree
platform such as Intel CE4100.

Signed-off-by: Florian Fainelli <ffainelli@freebox.fr>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Cc: Maxime Bizon <mbizon@freebox.fr>
Acked-by: Sebastian Andrzej Siewior <sebastian@breakpoint.cc>
Cc: stable@kernel.org # 2.6.39
Link: http://lkml.kernel.org/r/201106061015.50039.ffainelli@freebox.fr
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2011-06-09 15:39:43 +02:00
Guan Xuetao 62b62c5c29 unicore32: using generic-y format for one line asm-generic files
The patch adds one-line asm-generic files in arch/unicore32/include/asm/Kbuild
Also, remove the old implementation in arch/unicore32/Makefile
see commit from Sam Ravnborg <d8ecc5cd8e227bc318513b5306ae88a474b8886d>
  kbuild: asm-generic support

Signed-off-by: Guan Xuetao <gxt@mprc.pku.edu.cn>
Acked-by: Arnd Bergmann <arnd@arndb.de>
2011-06-09 16:29:52 +08:00
Guan Xuetao 42733b3c48 unicore32: change PERCPU to PERCPU_SECTION
The patch changes PERCPU to PERCPU_SECTION
see commit from Tejun Heo <0415b00d175e0d8945e6785aad21b5f157976ce0>
  percpu: Always align percpu output section to PAGE_SIZE

Signed-off-by: Guan Xuetao <gxt@mprc.pku.edu.cn>
Acked-by: Tejun Heo <tj@kernel.org>
2011-06-09 16:27:46 +08:00
Guan Xuetao 978b42e6f6 unicore32: add KBUILD_DEFCONFIG with unicore32_defconfig (old debug_defconfig)
Rename debug_defconfig to unicore32_defconfig, which is a minimal config for
PKUnity-v3 (130nm) SoC board.
Also, add KBUILD_DEFCONFIG to use 'make defconfig'.

Signed-off-by: Guan Xuetao <gxt@mprc.pku.edu.cn>
Acked-by: Arnd Bergmann <arnd@arndb.de>
2011-06-09 16:24:42 +08:00
Guan Xuetao f4728fd21f unicore32: change zImage physical address, though it's PIC codes
U-boot will load the kernel image to 48M physical memory address.
The patch changes it to the correct address, though it's PIC codes.

Signed-off-by: Guan Xuetao <gxt@mprc.pku.edu.cn>
Acked-by: Arnd Bergmann <arnd@arndb.de>
2011-06-09 16:19:44 +08:00
Guan Xuetao 2809e80b8a unicore32: move rtc-puv3.c to drivers/rtc directory
The patch moves rtc driver for PKUnity-v3 SoC from arch/unicore32/kernel/
to drivers/rtc/, with renaming it to rtc-puv3.c.
Also, Kconfig, Makefile, and MAINTAINERS are modified correspondingly.

Signed-off-by: Guan Xuetao <gxt@mprc.pku.edu.cn>
Acked-by: Arnd Bergmann <arnd@arndb.de>
2011-06-09 16:15:24 +08:00
Benjamin Herrenschmidt 307cfe7153 powerpc: Force page alignment for initrd reserved memory
When using 64K pages with a separate cpio rootfs, U-Boot will align
the rootfs on a 4K page boundary. When the memory is reserved, and
subsequent early memblock_alloc is called, it will allocate memory
between the 64K page alignment and reserved memory. When the reserved
memory is subsequently freed, it is done so by pages, causing the
early memblock_alloc requests to be re-used, which in my case, caused
the device-tree to be clobbered.

This patch forces the reserved memory for initrd to be kernel page
aligned, and will move the device tree if it overlaps with the range
extension of initrd. This patch will also consolidate the identical
function free_initrd_mem() from mm/init_32.c, init_64.c to mm/mem.c,
and adds the same range extension when freeing initrd. free_initrd_mem()
is also moved to the __init section.

Many thanks to Milton Miller for his input on this patch.

[BenH: Fixed build without CONFIG_BLK_DEV_INITRD]

Signed-off-by: Dave Carroll <dcarroll@astekcorp.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2011-06-09 16:52:38 +10:00
Benjamin Herrenschmidt d660474e84 Merge remote branch 'kumar/merge' into merge 2011-06-09 14:46:32 +10:00
Benjamin Herrenschmidt 43d795c632 Merge remote branch 'gcl/powerpc/merge' into merge 2011-06-09 14:46:12 +10:00
Wolfram Sang c49f8789f5 dtc/powerpc: remove obsolete .gitignore entries
dtc was moved and .gitignores have been added to the new location. So, we can
delete the old, forgotten ones.

Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2011-06-08 18:51:18 -06:00
Linus Torvalds 467701e286 Merge branch 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen
* 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen:
  xen: off by one errors in multicalls.c
  xen: use the trigger info we already have to choose the irq handler
2011-06-08 12:03:37 -07:00
Ingo Molnar 86dd7909c2 Merge branch 'urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/rric/oprofile into perf/urgent 2011-06-08 15:49:03 +02:00
Thomas Gleixner fd8a7de177 x86: cpu-hotplug: Prevent softirq wakeup on wrong CPU
After a newly plugged CPU sets the cpu_online bit it enables
interrupts and goes idle. The cpu which brought up the new cpu waits
for the cpu_online bit and when it observes it, it sets the cpu_active
bit for this cpu. The cpu_active bit is the relevant one for the
scheduler to consider the cpu as a viable target.

With forced threaded interrupt handlers which imply forced threaded
softirqs we observed the following race:

cpu 0                         cpu 1

bringup(cpu1);
                              set_cpu_online(smp_processor_id(), true);
		              local_irq_enable();
while (!cpu_online(cpu1));
                              timer_interrupt()
                                -> wake_up(softirq_thread_cpu1);
                                     -> enqueue_on(softirq_thread_cpu1, cpu0);

                                                                        ^^^^

cpu_notify(CPU_ONLINE, cpu1);
  -> sched_cpu_active(cpu1)
     -> set_cpu_active((cpu1, true);

When an interrupt happens before the cpu_active bit is set by the cpu
which brought up the newly onlined cpu, then the scheduler refuses to
enqueue the woken thread which is bound to that newly onlined cpu on
that newly onlined cpu due to the not yet set cpu_active bit and
selects a fallback runqueue. Not really an expected and desirable
behaviour.

So far this has only been observed with forced hard/softirq threading,
but in theory this could happen without forced threaded hard/softirqs
as well. It's probably unobservable as it would take a massive
interrupt storm on the newly onlined cpu which causes the softirq loop
to wake up the softirq thread and an even longer delay of the cpu
which waits for the cpu_online bit.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Peter Zijlstra <peterz@infradead.org>
Cc: stable@kernel.org # 2.6.39
2011-06-08 11:21:19 +02:00
Linus Torvalds d681f1204d Merge branch 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'x86-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  x86/amd-iommu: Fix boot crash with hidden PCI devices
  x86/amd-iommu: Use only per-device dma_ops
  x86/amd-iommu: Fix 3 possible endless loops
2011-06-07 19:20:53 -07:00
Linus Torvalds 58a9a36b54 Merge branch 'kvm-updates/3.0' of git://git.kernel.org/pub/scm/virt/kvm/kvm
* 'kvm-updates/3.0' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
  KVM: Initialize kvm before registering the mmu notifier
  KVM: x86: use proper port value when checking io instruction permission
  KVM: add missing void __user * cast to access_ok() call
2011-06-07 19:06:28 -07:00
David Howells 40182373ac MN10300: Add missing _sdata declaration
_sdata needs to be declared in the linker script now as of commit
a2d063ac21 ("extable, core_kernel_data(): Make sure all archs define
_sdata")

Signed-off-by: David Howells <dhowells@redhat.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-06-07 19:03:53 -07:00
David Howells db1c9dfa64 MN10300: die_if_no_fixup() shouldn't use get_user() as it doesn't call set_fs()
die_if_no_fixup() shouldn't use get_user() as it doesn't call set_fs() to
indicate that it wants to probe a kernel address.  Instead it should use
probe_kernel_read().

This fixes the problem of gdb seeing SIGILL rather than SIGTRAP when hitting
the KGDB special breakpoint upon SysRq+g being seen.  The problem was that
die_if_no_fixup() was failing to read the opcode of the instruction that caused
the exception, and thus not fixing up the exception.

This caused gdb to get a S04 response to the $? request in its remote protocol
rather than S05 - which would then cause it to continue with $C04 rather than
$c in an attempt to pass the signal onto the inferior process.  The kernel,
however, does not support $Cnn, and so objects by returning an E22 response,
indicating an error.  gdb does not expect this and prints:

	warning: Remote failure reply: E22

and then returns to the gdb command prompt unable to continue.

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-06-07 19:03:52 -07:00
David Howells 2e65d1f6ee MN10300: Fix one of the kernel debugger cacheflush variants
One of the kernel debugger cacheflush variants escaped proper testing.  Two of
the labels are wrong, being derived from the code that was copied to construct
the variant.

The first label results in the following assembler message:

    AS      arch/mn10300/mm/cache-dbg-flush-by-reg.o
  arch/mn10300/mm/cache-dbg-flush-by-reg.S: Assembler messages:
  arch/mn10300/mm/cache-dbg-flush-by-reg.S:123: Error: symbol `debugger_local_cache_flushinv_no_dcache' is already defined

And the second label results in the following linker message:

  arch/mn10300/mm/built-in.o:(.text+0x1d39): undefined reference to `mn10300_local_icache_inv_range_reg_end'
  arch/mn10300/mm/built-in.o:(.text+0x1d39): relocation truncated to fit: R_MN10300_PCREL16 against undefined symbol `mn10300_local_icache_inv_range_reg_end'

To test this file the following configuration pieces must be set:

	CONFIG_AM34=y
	CONFIG_MN10300_CACHE_WBACK=y
	CONFIG_MN10300_DEBUGGER_CACHE_FLUSH_BY_REG=y
	CONFIG_MN10300_CACHE_MANAGE_BY_REG=y
	CONFIG_AM34_HAS_CACHE_SNOOP=n

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-06-07 19:03:52 -07:00
Linus Torvalds aec040e29e Merge branch 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6
* 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6:
  [S390] fix kvm defines for 31 bit compile
  [S390] use generic RCU page-table freeing code
  [S390] qdio: Split SBAL entry flags
  [S390] kvm-s390: fix stfle facilities numbers >=64
  [S390] kvm-s390: Fix host crash on misbehaving guests
2011-06-07 18:47:53 -07:00
Linus Torvalds 8ea656bdc9 Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6
* 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6: (21 commits)
  ARM: OMAP4: MMC: increase delay for pbias
  arm: omap2plus: move NAND_BLOCK_SIZE out of boards
  omap4: hwmod: Enable the keypad
  omap3: Free Beagle rev gpios when they are read, so others can read them later
  arm: omap3: beagle: Ensure msecure is mux'd to be able to set the RTC
  omap: rx51: Don't power up speaker amplifier at bootup
  omap: rx51: Set regulator V28_A always on
  ARM: OMAP4: MMC: no regulator off during probe for eMMC
  arm: omap2plus: fix ads7846 pendown gpio request
  ARM: OMAP2: Add missing iounmap in omap4430_phy_init
  ARM: omap4: Pass core and wakeup mux tables to omap4_mux_init
  ARM: omap2+: mux: Allow board mux settings to be NULL
  OMAP4: fix return value of omap4_l3_init
  OMAP: iovmm: fix SW flags passed by user
  arch/arm/mach-omap1/dma.c: Invert calls to platform_device_put and platform_device_del
  OMAP2+: mux: fix compilation warnings
  OMAP: SRAM: Fix warning: format '%08lx' expects type 'long unsigned int'
  arm: omap3: cm-t3517: fix section mismatch warning
  OMAP2+: Fix 9 section mismatch(es) warnings from mach-omap2/built-in.o
  ARM: OMAP2: Add missing include of linux/gpio.h
  ...
2011-06-07 18:46:37 -07:00
Joe Perches 6cb79b3f3b sparc: Remove unnecessary semicolons
Semicolons are not necessary after switch/while/for/if braces
so remove them.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-07 16:06:34 -07:00
oftedal 9eeb08986f Add support for allocating irqs for bootbus devices
Some devices that can generate interrupts are connected directly to the
CPU through the bootbus on sun4d. This patch allows IRQs to be allocated
for such devices. The information used for allocating interrupts for
sbus devices are present at the corresponding SBI node. For bootbus
devices this information is present in the bootbus node.

Signed-off-by: Kjetil Oftedal <oftedal@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-07 16:06:33 -07:00
oftedal ea16058457 Do not skip interrupt sources in sun4d interrupt handler and acknowledge interrupts correctly
During the introduction of genirq on sparc32 bugs were introduced in
the interrupt handler for sun4d. The interrupts handler checks the status
of the various sbus interfaces in the system and generates a virtual
interrupt, based upon the location of the interrupt source. This lookup
was broken by restructuring the code in such a way that index and shift
operations were performed prior to comparing this against the values
read from the interrupt controllers.

This could cause the handler to loop eternally as the interrupt source
could be skipped before any check was performed. Additionally
sun4d_encode_irq performs shifting internally, so it should not be performed
twice.

In sun4d_unmask interrupts were not correctly acknowledged, as the
corresponding bit it the interrupt mask was not actually cleared.

Signed-off-by: Kjetil Oftedal <oftedal@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-07 16:06:33 -07:00
oftedal 5fba17084e Restructure sun4d_build_device_irq so that timer interrupts can be allocated
sun4d_build_device_irq was called without a valid platform_device when
the system timer was initialized on sun4d systems. This caused a NULL
pointer crash.

Josip Rodin suggested that the current sun4d_build_device_irq should be
split into two functions. So that the timer initialization could skip
the slot and sbus interface detection code in sun4d_build_device_irq, as
this does not make sence due to the timer interrupts not being generated
from a device located on sbus.

Signed-off-by: Kjetil Oftedal <oftedal@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-06-07 16:06:32 -07:00
Joerg Roedel 26018874e3 x86/amd-iommu: Fix boot crash with hidden PCI devices
Some PCIe cards ship with a PCI-PCIe bridge which is not
visible as a PCI device in Linux. But the device-id of the
bridge is present in the IOMMU tables which causes a boot
crash in the IOMMU driver.
This patch fixes by removing these cards from the IOMMU
handling. This is a pure -stable fix, a real fix to handle
this situation appriatly will follow for the next merge
window.

Cc: stable@kernel.org	# > 2.6.32
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-07 10:06:59 +02:00
Joerg Roedel 27c2127a15 x86/amd-iommu: Use only per-device dma_ops
Unfortunatly there are systems where the AMD IOMMU does not
cover all devices. This breaks with the current driver as it
initializes the global dma_ops variable. This patch limits
the AMD IOMMU to the devices listed in the IVRS table fixing
DMA for devices not covered by the IOMMU.

Cc: stable@kernel.org
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-06 17:37:27 +02:00
Joerg Roedel 0de66d5b35 x86/amd-iommu: Fix 3 possible endless loops
The driver contains several loops counting on an u16 value
where the exit-condition is checked against variables that
can have values up to 0xffff. In this case the loops will
never exit. This patch fixed 3 such loops.

Cc: stable@kernel.org
Signed-off-by: Joerg Roedel <joerg.roedel@amd.com>
2011-06-06 16:10:15 +02:00
Martin Schwidefsky 6c61cfe91b [S390] fix kvm defines for 31 bit compile
KVM is not available for 31 bit but the KVM defines cause warnings:

arch/s390/include/asm/pgtable.h: In function 'ptep_test_and_clear_user_dirty':
arch/s390/include/asm/pgtable.h:817: warning: integer constant is too large for 'unsigned long' type
arch/s390/include/asm/pgtable.h:818: warning: integer constant is too large for 'unsigned long' type
arch/s390/include/asm/pgtable.h: In function 'ptep_test_and_clear_user_young':
arch/s390/include/asm/pgtable.h:837: warning: integer constant is too large for 'unsigned long' type
arch/s390/include/asm/pgtable.h:838: warning: integer constant is too large for 'unsigned long' type

Add 31 bit versions of the KVM defines to remove the warnings.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2011-06-06 14:14:56 +02:00
Martin Schwidefsky 36409f6353 [S390] use generic RCU page-table freeing code
Replace the s390 specific rcu page-table freeing code with the
generic variant. This requires to duplicate the definition for the
struct mmu_table_batch as s390 does not use the generic tlb flush
code.

While we are at it remove the restriction that page table fragments
can not be reused after a single fragment has been freed with rcu
and split out allocation and freeing of page tables with pgstes.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
2011-06-06 14:14:56 +02:00