Skip to content
  1. Nov 19, 2012
  2. Oct 14, 2012
    • Russell King's avatar
      ARM: config: make sure that platforms are ordered by option string · 93e22567
      Russell King authored
      
      
      The large platform selection choice should be sorted by option string
      so it's easy to find the platform you're looking for.  Fix the few
      options which are out of this order.
      
      Acked-by: default avatarTony Lindgren <tony@atomide.com>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      93e22567
    • Russell King's avatar
      ARM: config: sort select statements alphanumerically · b1b3f49c
      Russell King authored
      
      
      As suggested by Andrew Morton:
      
        This is a pet peeve of mine.  Any time there's a long list of items
        (header file inclusions, kconfig entries, array initalisers, etc) and
        someone wants to add a new item, they *always* go and stick it at the
        end of the list.
      
        Guys, don't do this.  Either put the new item into a randomly-chosen
        position or, probably better, alphanumerically sort the list.
      
      lets sort all our select statements alphanumerically.  This commit was
      created by the following perl:
      
      while (<>) {
      	while (/\\\s*$/) {
      		$_ .= <>;
      	}
      	undef %selects if /^\s*config\s+/;
      	if (/^\s+select\s+(\w+).*/) {
      		if (defined($selects{$1})) {
      			if ($selects{$1} eq $_) {
      				print STDERR "Warning: removing duplicated $1 entry\n";
      			} else {
      				print STDERR "Error: $1 differently selected\n".
      					"\tOld: $selects{$1}\n".
      					"\tNew: $_\n";
      				exit 1;
      			}
      		}
      		$selects{$1} = $_;
      		next;
      	}
      	if (%selects and (/^\s*$/ or /^\s+help/ or /^\s+---help---/ or
      			  /^endif/ or /^endchoice/)) {
      		foreach $k (sort (keys %selects)) {
      			print "$selects{$k}";
      		}
      		undef %selects;
      	}
      	print;
      }
      if (%selects) {
      	foreach $k (sort (keys %selects)) {
      		print "$selects{$k}";
      	}
      }
      
      It found two duplicates:
      
      Warning: removing duplicated S5P_SETUP_MIPIPHY entry
      Warning: removing duplicated HARDIRQS_SW_RESEND entry
      
      and they are identical duplicates, hence the shrinkage in the diffstat
      of two lines.
      
      We have four testers reporting success of this change (Tony, Stephen,
      Linus and Sekhar.)
      
      Acked-by: default avatarJason Cooper <jason@lakedaemon.net>
      Acked-by: default avatarTony Lindgren <tony@atomide.com>
      Acked-by: default avatarStephen Warren <swarren@nvidia.com>
      Acked-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Acked-by: default avatarSekhar Nori <nsekhar@ti.com>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      b1b3f49c
  3. Oct 13, 2012
  4. Oct 12, 2012
  5. Oct 10, 2012
    • Jean-Nicolas Graux's avatar
      pinctrl/nomadik: support other alternate-C functions · c22df08c
      Jean-Nicolas Graux authored
      
      
      Upgrade nomadik pinctrl driver to enable selection of other
      alternate-C[1-4] functions on some specific ux500 SoC pins.
      Handling of those functions is done thanks to PRCM GPIOCR
      registers. This was previously managed in PRCMU driver and
      it was not really convenient. Idea is to provide a common
      way to control all alternate functions.
      
      Note that this improvement does not support the old-fashioned way
      used to control nomadik pins, namely the "nmk_config_pin()" function
      and its derivatives.
      
      Signed-off-by: default avatarJean-Nicolas Graux <jean-nicolas.graux@stericsson.com>
      Reviewed-by: default avatarPhilippe Langlais <philippe.langlais@stericsson.com>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      c22df08c
    • Arnd Bergmann's avatar
      ARM: pxa: armcore: fix PCI PIO warnings · bfbad32a
      Arnd Bergmann authored
      
      
      The it8152 PCI host used on the pxa/cm_x2xx machines
      uses the old-style I/O window registration. This should
      eventually get converted to pci_ioremap_io() but for
      now, let's cast the IT8152_IO_BASE constant to an integer
      type to get rid of the warnings.
      
      Without this patch, building cm_x2xx_defconfig results in:
      
      arch/arm/common/it8152.c: In function 'it8152_pci_setup':
      arch/arm/common/it8152.c:287:18: warning: assignment makes integer from pointer without a cast [enabled by default]
      arch/arm/common/it8152.c:288:16: warning: assignment makes integer from pointer without a cast [enabled by default]
      arch/arm/common/it8152.c:291:17: warning: assignment makes integer from pointer without a cast [enabled by default]
      
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Acked-by: default avatarIgor Grinberg <grinberg@compulab.co.il>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Krzysztof Halasa <khc@pm.waw.pl>
      Cc: Mike Rapoport <mike@compulab.co.il>
      Cc: Haojian Zhuang <haojian.zhuang@gmail.com>
      Cc: Eric Miao <eric.y.miao@gmail.com>
      bfbad32a
  6. Oct 09, 2012
    • Arnd Bergmann's avatar
      ARM: integrator: use __iomem pointers for MMIO, part 2 · 21c8715f
      Arnd Bergmann authored
      
      
      Due to some interesting merges in the integrator code, not
      all users of mmio pointers were converted before, this
      fixes all warnings that got introduced as a consequence.
      
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Linus Walleij <linus.walleij@linaro.org>
      Cc: Russell King <rmk+kernel@arm.linux.org.uk>
      21c8715f
    • Arnd Bergmann's avatar
      ARM: assabet: fix bogus warning in get_assabet_scr (again) · c6e9fbbf
      Arnd Bergmann authored
      
      
      Russell fixed this bogus warning before in 2f3eca8b "Shut up gcc
      warning in assabet.c", but apparently gcc has become smarter (or dumber)
      since 2005, and the same warning came up again.
      
      This uses the uninitialized_var() macro to convince gcc that the
      variable is actually being initialized. 100 times in fact.
      
      Without this patch, building assabet_defconfig results in:
      
      arch/arm/mach-sa1100/assabet.c: In function 'fixup_assabet':
      arch/arm/mach-sa1100/assabet.c:397:6: warning: 'scr' may be used uninitialized in this function [-Wuninitialized]
      arch/arm/mach-sa1100/assabet.c:389:16: note: 'scr' was declared here
      
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Russell King <rmk+kernel@arm.linux.org.uk>
      c6e9fbbf
    • Arnd Bergmann's avatar
      ARM: shmobile: mark shmobile_init_late as __init · b3796d92
      Arnd Bergmann authored
      
      
      Patch 35f2b0bd "ARM: shmobile: Move definition of shmobile_init_late()
      to header" moved the definition of the shmobile_init_late function, but
      dropped the __init annotation, which is now causing warnings because
      the function calls shmobile_suspend_init, which is also marked init.
      
      Without this patch, building kota2_defconfig results in:
      
      WARNING: vmlinux.o(.text+0xb7c8): Section mismatch in reference from the function shmobile_init_late() to the function .init.text:shmobile_suspend_init()
      The function shmobile_init_late() references
      the function __init shmobile_suspend_init().
      This is often because shmobile_init_late lacks a __init
      annotation or the annotation of shmobile_suspend_init is wrong.
      
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Rafael J. Wysocki <rjw@sisk.pl>
      Cc: Magnus Damm <damm@opensource.se>
      Cc: Simon Horman <horms@verge.net.au>
      b3796d92
    • Olof Johansson's avatar
      ARM: integrator_cp: fix build failure · 6e3a78d9
      Olof Johansson authored
      
      
      arch/arm/mach-integrator/integrator_cp.c:272:32: error: 'of_aliases'
      undeclared (first use in this function)
      
      Move the OF-only timer init under #ifdef CONFIG_OF, just like
      integrator_ap has it.
      
      Reviewed-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      6e3a78d9
    • Russell King's avatar
      ARM: vfp: fix saving d16-d31 vfp registers on v6+ kernels · 846a1368
      Russell King authored
      
      
      Michael Olbrich reported that his test program fails when built with
      -O2 -mcpu=cortex-a8 -mfpu=neon, and a kernel which supports v6 and v7
      CPUs:
      
      volatile int x = 2;
      volatile int64_t y = 2;
      
      int main() {
      	volatile int a = 0;
      	volatile int64_t b = 0;
      	while (1) {
      		a = (a + x) % (1 << 30);
      		b = (b + y) % (1 << 30);
      		assert(a == b);
      	}
      }
      
      and two instances are run.  When built for just v7 CPUs, this program
      works fine.  It uses the "vadd.i64 d19, d18, d16" VFP instruction.
      
      It appears that we do not save the high-16 double VFP registers across
      context switches when the kernel is built for v6 CPUs.  Fix that.
      
      Cc: <stable@vger.kernel.org>
      Tested-By: default avatarMichael Olbrich <m.olbrich@pengutronix.de>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      846a1368
    • Marc Zyngier's avatar
      ARM: 7549/1: HYP: fix boot on some ARM1136 cores · 2a552d5e
      Marc Zyngier authored
      
      
      It appears that performing a "movs pc, lr" to force the kernel into
      SVC mode on the OMAP2420 (ARM1136) prevents the platform from booting
      correctly (change introduced in 80c59daf [ARM: virt: allow the kernel
      to be entered in HYP mode]).
      
      While the reason it fails is not understood yet (the same code runs
      fine on the OMAP2430, ARM1136 as well), partially revert that change
      for platforms that do not enter in HYP mode, preserving the new
      feature and restoring a working kernel on the OMAP2420.
      
      Reported-by: default avatarTony Lindgren <tony@atomide.com>
      Acked-by: default avatarNicolas Pitre <nico@linaro.org>
      Tested-by: default avatarTony Lindgren <tony@atomide.com>
      Signed-off-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      2a552d5e
    • Shaohua Li's avatar
      readahead: fault retry breaks mmap file read random detection · 45cac65b
      Shaohua Li authored
      
      
      .fault now can retry.  The retry can break state machine of .fault.  In
      filemap_fault, if page is miss, ra->mmap_miss is increased.  In the second
      try, since the page is in page cache now, ra->mmap_miss is decreased.  And
      these are done in one fault, so we can't detect random mmap file access.
      
      Add a new flag to indicate .fault is tried once.  In the second try, skip
      ra->mmap_miss decreasing.  The filemap_fault state machine is ok with it.
      
      I only tested x86, didn't test other archs, but looks the change for other
      archs is obvious, but who knows :)
      
      Signed-off-by: default avatarShaohua Li <shaohua.li@fusionio.com>
      Cc: Rik van Riel <riel@redhat.com>
      Cc: Wu Fengguang <fengguang.wu@intel.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      45cac65b
    • Michel Lespinasse's avatar
      mm: replace vma prio_tree with an interval tree · 6b2dbba8
      Michel Lespinasse authored
      
      
      Implement an interval tree as a replacement for the VMA prio_tree.  The
      algorithms are similar to lib/interval_tree.c; however that code can't be
      directly reused as the interval endpoints are not explicitly stored in the
      VMA.  So instead, the common algorithm is moved into a template and the
      details (node type, how to get interval endpoints from the node, etc) are
      filled in using the C preprocessor.
      
      Once the interval tree functions are available, using them as a
      replacement to the VMA prio tree is a relatively simple, mechanical job.
      
      Signed-off-by: default avatarMichel Lespinasse <walken@google.com>
      Cc: Rik van Riel <riel@redhat.com>
      Cc: Hillf Danton <dhillf@gmail.com>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Andrea Arcangeli <aarcange@redhat.com>
      Cc: David Woodhouse <dwmw2@infradead.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      6b2dbba8
    • Catalin Marinas's avatar
      Kconfig: clean up the long arch list for the DEBUG_KMEMLEAK config option · b69ec42b
      Catalin Marinas authored
      
      
      Introduce HAVE_DEBUG_KMEMLEAK config option and select it in corresponding
      architecture Kconfig files.  DEBUG_KMEMLEAK now only depends on
      HAVE_DEBUG_KMEMLEAK.
      
      Signed-off-by: default avatarCatalin Marinas <catalin.marinas@arm.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Chris Metcalf <cmetcalf@tilera.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      b69ec42b
    • Catalin Marinas's avatar
      Kconfig: clean up the long arch list for the UID16 config option · af1839eb
      Catalin Marinas authored
      
      
      Introduce HAVE_UID16 config option and select it in corresponding
      architecture Kconfig files.  UID16 now only depends on HAVE_UID16.
      
      Signed-off-by: default avatarCatalin Marinas <catalin.marinas@arm.com>
      Acked-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Mike Frysinger <vapier@gentoo.org>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: Jesper Nilsson <jesper.nilsson@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Richard Weinberger <richard@nod.at>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      af1839eb
    • Paul Walmsley's avatar
      ARM: OMAP4/AM335x: hwmod: fix disable_module regression in hardreset handling · e9332b6e
      Paul Walmsley authored
      
      
      Commit eb05f691 ("ARM: OMAP: hwmod:
      partially un-reset hwmods might not be properly enabled") added code
      to skip the IP block disable sequence if all of the block's hardreset
      lines weren't asserted.  But this did not handle the case when no
      hardreset lines were associated with a module, which is the general
      case.  In that situation, the IP block disable would be skipped.  This
      is likely to cause PM regressions.
      
      So, modify _omap4_disable_module() and _am33xx_disable_module() to
      only bail out early if there are any hardreset lines asserted.  And
      move the AM33xx test above the actual module disable code to ensure
      that the behavior is consistent.
      
      Reported-by: default avatarArchit Taneja <a0393947@ti.com>
      Tested-by: Archit Taneja <a0393947@ti.com> # DSS
      Cc: Omar Ramirez Luna <omar.luna@linaro.org>
      Cc: Vaibhav Hiremath <hvaibhav@ti.com>
      Acked-by: default avatarVaibhav Hiremath <hvaibhav@ti.com>
      Tested-by: Vaibhav Hiremath <hvaibhav@ti.com> # AM335x
      Signed-off-by: default avatarPaul Walmsley <paul@pwsan.com>
      e9332b6e