1. 08 9月, 2012 1 次提交
  2. 25 8月, 2012 7 次提交
    • J
      ARM: 7499/1: mm: Fix vmalloc overlap check for !HIGHMEM · 36418c51
      Jonathan Austin 提交于
      With !HIGHMEM, sanity_check_meminfo checks for banks that completely or
      partially overlap the vmalloc region. The test for partial overlap checks
      __va(bank->start + bank->size) > vmalloc_min. This is not appropriate if
      there is a non-linear translation between virtual and physical addresses,
      as bank->start + bank->size is actually in the bank following the one being
      interrogated.
      
      In most cases, even when using SPARSEMEM, this is not problematic as the
      subsequent bank will start at a higher va than the one in question. However
      if the physical to virtual address conversion is not monotonic increasing,
      the incorrect test could result in a bank not being truncated when it
      should be.
      
      This patch ensures we perform the va-pa conversion on memory from the
      bank we are interested in, not the following one.
      Reported-by: N??? (Steve) <zhanzhenbo@gmail.com>
      Signed-off-by: NJonathan Austin <jonathan.austin@arm.com>
      Acked-by: NNicolas Pitre <nico@linaro.org>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      36418c51
    • W
      ARM: 7503/1: mm: only flush both pmd entries for classic MMU · df547e08
      Will Deacon 提交于
      LPAE does not use two pmd entries for a pte, so the additional tlb
      flushing is not required.
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      df547e08
    • W
      ARM: 7502/1: contextidr: avoid using bfi instruction during notifier · ae3790b8
      Will Deacon 提交于
      The bfi instruction is not available on ARMv6, so instead use an and/orr
      sequence in the contextidr_notifier. This gets rid of the assembler
      error:
      
        Assembler messages:
        Error: selected processor does not support ARM mode `bfi r3,r2,#0,#8'
      Reported-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      ae3790b8
    • W
      ARM: 7501/1: decompressor: reset ttbcr for VMSA ARMv7 cores · dbece458
      Will Deacon 提交于
      When enabling the MMU for ARMv7 CPUs, the decompressor does not touch
      the ttbcr register, assuming that it will be zeroed (N == 0, EAE == 0).
      Given that only EAE is defined as 0 for non-secure copies of the
      register (and a bootloader such as kexec may leave it set to 1 anyway),
      we should ensure that we reset the register ourselves before turning on
      the MMU.
      
      This patch zeroes TTBCR.EAE and TTBCR.N prior to enabling the MMU for
      ARMv7 cores in the decompressor, configuring us exclusively for 32-bit
      translation tables via TTBR0.
      
      Cc: <stable@vger.kernel.org>
      Acked-by: NNicolas Pitre <nico@linaro.org>
      Signed-off-by: NMatthew Leach <matthew.leach@arm.com>
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      dbece458
    • W
      ARM: 7497/1: hw_breakpoint: allow single-byte watchpoints on all addresses · d968d2b8
      Will Deacon 提交于
      Breakpoint validation currently fails for single-byte watchpoints on
      addresses ending in 11b. There is no reason to forbid such a watchpoint,
      so extend the validation code to allow it.
      
      Cc: Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      d968d2b8
    • W
      ARM: 7496/1: hw_breakpoint: don't rely on dfsr to show watchpoint access type · bf880114
      Will Deacon 提交于
      From ARM debug architecture v7.1 onwards, a watchpoint exception causes
      the DFAR to be updated with the faulting data address. However, DFSR.WnR
      takes an UNKNOWN value and therefore cannot be used in general to
      determine the access type that triggered the watchpoint.
      
      This patch forbids watchpoints without an overflow handler from
      specifying a specific access type (load/store). Those with overflow
      handlers must be able to handle false positives potentially triggered by
      a watchpoint of a different access type on the same address. For
      SIGTRAP-based handlers (i.e. ptrace), this should have no impact.
      
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NWill Deacon <will.deacon@arm.com>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      bf880114
    • R
      ARM: Fix ioremap() of address zero · a849088a
      Russell King 提交于
      Murali Nalajala reports a regression that ioremapping address zero
      results in an oops dump:
      
      Unable to handle kernel paging request at virtual address fa200000
      pgd = d4f80000
      [fa200000] *pgd=00000000
      Internal error: Oops: 5 [#1] PREEMPT SMP ARM
      Modules linked in:
      CPU: 0    Tainted: G        W (3.4.0-g3b5f728-00009-g638207a #13)
      PC is at msm_pm_config_rst_vector_before_pc+0x8/0x30
      LR is at msm_pm_boot_config_before_pc+0x18/0x20
      pc : [<c0078f84>]    lr : [<c007903c>]    psr: a0000093
      sp : c0837ef0  ip : cfe00000  fp : 0000000d
      r10: da7efc17  r9 : 225c4278  r8 : 00000006
      r7 : 0003c000  r6 : c085c824  r5 : 00000001  r4 : fa101000
      r3 : fa200000  r2 : c095080c  r1 : 002250fc  r0 : 00000000
      Flags: NzCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM Segment kernel
      Control: 10c5387d  Table: 25180059  DAC: 00000015
      [<c0078f84>] (msm_pm_config_rst_vector_before_pc+0x8/0x30) from [<c007903c>] (msm_pm_boot_config_before_pc+0x18/0x20)
      [<c007903c>] (msm_pm_boot_config_before_pc+0x18/0x20) from [<c007a55c>] (msm_pm_power_collapse+0x410/0xb04)
      [<c007a55c>] (msm_pm_power_collapse+0x410/0xb04) from [<c007b17c>] (arch_idle+0x294/0x3e0)
      [<c007b17c>] (arch_idle+0x294/0x3e0) from [<c000eed8>] (default_idle+0x18/0x2c)
      [<c000eed8>] (default_idle+0x18/0x2c) from [<c000f254>] (cpu_idle+0x90/0xe4)
      [<c000f254>] (cpu_idle+0x90/0xe4) from [<c057231c>] (rest_init+0x88/0xa0)
      [<c057231c>] (rest_init+0x88/0xa0) from [<c07ff890>] (start_kernel+0x3a8/0x40c)
      Code: c0704256 e12fff1e e59f2020 e5923000 (e5930000)
      
      This is caused by the 'reserved' entries which we insert (see
      19b52abe - ARM: 7438/1: fill possible PMD empty section gaps)
      which get matched for physical address zero.
      
      Resolve this by marking these reserved entries with a different flag.
      
      Cc: <stable@vger.kernel.org>
      Tested-by: NMurali Nalajala <mnalajal@codeaurora.org>
      Acked-by: NNicolas Pitre <nico@linaro.org>
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      a849088a
  3. 15 8月, 2012 1 次提交
  4. 13 8月, 2012 1 次提交
  5. 11 8月, 2012 7 次提交
  6. 10 8月, 2012 3 次提交
    • A
      ARM: davinci: remove broken ntosd2_init_i2c · de923430
      Arnd Bergmann 提交于
      ntosd2_init_i2c walks the ntosd2_i2c_info array, which it expects to
      be populated with at least one member. gcc correctly warns about
      the out-of-bounds access here.
      
      Since this can not possibly work, it's better to disable i2c
      support entirely on this board.
      
      Without this patch, building davinci_all_defconfig results in:
      
      arch/arm/mach-davinci/board-neuros-osd2.c: In function 'davinci_ntosd2_init':
      arch/arm/mach-davinci/board-neuros-osd2.c:187:20: warning: array subscript is above array bounds [-Warray-bounds]
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Acked-by: NSekhar Nori <nsekhar@ti.com>
      Cc: Kevin Hilman <khilman@ti.com>
      Cc: Andrey Porodko <panda@chelcom.ru>
      de923430
    • A
      ARM: s3c24xx: enable CONFIG_BUG for tct_hammer · 15b5eb2d
      Arnd Bergmann 提交于
      Disabling CONFIG_BUG creates an insane amount of build warnings, which
      makes it useless to check for building defconfigs to see if new
      warnings show up.
      
      Without this patch, building tct_hammer_defconfig results in:
      
      net/packet/af_packet.c: In function 'tpacket_rcv':
      net/packet/af_packet.c:1889:30: warning: 'hdrlen' may be used uninitialized in this function [-Wuninitialized]
      net/core/ethtool.c: In function 'ethtool_get_feature_mask':
      net/core/ethtool.c:213:1: warning: control reaches end of non-void function [-Wreturn-type]
      block/cfq-iosched.c: In function 'cfq_async_queue_prio':
      block/cfq-iosched.c:2914:1: warning: control reaches end of non-void function [-Wreturn-type]
      mm/bootmem.c: In function 'mark_bootmem':
      mm/bootmem.c:352:1: warning: control reaches end of non-void function [-Wreturn-type]
      net/core/dev.c: In function 'skb_warn_bad_offload':
      net/core/dev.c:1904:33: warning: unused variable 'null_features' [-Wunused-variable]
      drivers/mtd/chips/cfi_probe.c: In function 'cfi_chip_setup':
      include/linux/mtd/cfi.h:489:3: warning: 'r.x[0]' may be used uninitialized in this function [-Wuninitialized]
      include/linux/mtd/map.h:394:11: note: 'r.x[0]' was declared here
      include/linux/mtd/cfi.h:489:3: warning: 'r.x[0]' may be used uninitialized in this function [-Wuninitialized]
      (and many more)
      
      The size of vmlinux increases by 1.78% because of this:
      
      size obj-arm/vmlinux.nobug
         text    data     bss     dec     hex filename
         2108474  116916   55352 2280742  22cd26 obj-arm/vmlinux
      size obj-arm/vmlinux.bug
         text    data     bss     dec     hex filename
         2150804  116916   53696 2321416  236c08 obj-arm/vmlinux
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Acked-by: NKukjin Kim <kgene.kim@samsung.com>
      Cc: Ben Dooks <ben-linux@fluff.org>
      15b5eb2d
    • A
      ARM: exynos: exynos_pm_add_dev_to_genpd may be unused · 8ab08c0c
      Arnd Bergmann 提交于
      exynos_pm_add_dev_to_genpd is used if one or more out of a large
      number of Kconfig symbols are enabled. However the new
      exynos_defconfig selects none of those, so the function becomes
      unused. Marking it so lets the compiler automatically discard
      it.
      
      Without this patch, building exynos_defconfig results in:
      
      arch/arm/mach-exynos/pm_domains.c:118:123: warning: 'exynos_pm_add_dev_to_genpd' defined but not used [-Wunused-function]
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Acked-by: NThomas Abraham <thomas.abraham@linaro.org>
      Acked-by: NKukjin Kim <kgene.kim@samsung.com>
      Cc: Rafael J. Wysocki <rjw@sisk.pl>
      8ab08c0c
  7. 09 8月, 2012 9 次提交
    • A
      ARM: imx: gpmi-nand depends on mxs-dma · a3349377
      Arnd Bergmann 提交于
      It is not currently possible to build the gpmi-nand driver without
      also building the mxs-dma driver. Clarify this Kconfig and enable
      both in the defconfig file so we can build it again with both enabled.
      
      drivers/built-in.o: In function `gpmi_dma_filter':
      clk-fixed-factor.c:(.text+0xafc18): undefined reference to `mxs_dma_is_apbh'
      make[1]: *** [vmlinux] Error 1
      make: *** [sub-make] Error 2
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Acked-by: NDirk Behme <dirk.behme@de.bosch.com>
      Cc: Shawn Guo <shawn.guo@linaro.org>
      Cc: Sascha Hauer <kernel@pengutronix.de>
      a3349377
    • A
      ARM: integrator: include <linux/export.h> · b434f5c9
      Arnd Bergmann 提交于
      Without this patch, building integrator_defconfig results in:
      
      arch/arm/mach-integrator/core.c:150:1: warning: data definition has no type or storage class [enabled by default]
      arch/arm/mach-integrator/core.c:150:1: warning: type defaults to 'int' in declaration of 'EXPORT_SYMBOL' [-Wimplicit-int]
      arch/arm/mach-integrator/core.c:150:1: warning: parameter names (without types) in function declaration [enabled by default]
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Acked-by: NLinus Walleij <linus.walleij@linaro.org>
      Cc: Russell King <linux@arm.linux.org.uk>
      b434f5c9
    • A
      ARM: s3c24xx: use new PWM driver · 35e79061
      Arnd Bergmann 提交于
      The samsung PWM driver has moved to the new PWM subsystem, which
      changed the Kconfig symbol for that driver, but the rx1950 and
      gta02 boards still uses the old one.
      
      Without this patch, building s3c2410_defconfig results in:
      
      arch/arm/mach-s3c24xx/built-in.o: In function `rx1950_lcd_power':
      arch/arm/mach-s3c24xx/mach-rx1950.c:430: undefined reference to `pwm_config'
      arch/arm/mach-s3c24xx/mach-rx1950.c:431: undefined reference to `pwm_disable'
      arch/arm/mach-s3c24xx/mach-rx1950.c:437: undefined reference to `pwm_config'
      arch/arm/mach-s3c24xx/mach-rx1950.c:438: undefined reference to `pwm_enable'
      arch/arm/mach-s3c24xx/built-in.o: In function `rx1950_backlight_exit':
      arch/arm/mach-s3c24xx/mach-rx1950.c:504: undefined reference to `pwm_free'
      arch/arm/mach-s3c24xx/built-in.o: In function `rx1950_backlight_init':
      arch/arm/mach-s3c24xx/mach-rx1950.c:487: undefined reference to `pwm_request'
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Reported-by: NTushar Behera <tushar.behera@linaro.org>
      Cc: Kukjin Kim <kgene.kim@samsung.com>
      35e79061
    • A
      ARM: sa1100: include linux/io.h in hackkit leds code · 9c97738c
      Arnd Bergmann 提交于
      The sa1100 definition of the io_p2v macro has changed in v3.6, and this one
      file stopped working because of that.
      
      Without this patch, building hackkit_defconfig results in:
      
      arch/arm/mach-sa1100/leds-hackkit.c: In function 'hackkit_leds_event':
      arch/arm/mach-sa1100/leds-hackkit.c:39:4: error: implicit declaration of function 'IOMEM' [-Werror=implicit-function-declaration]
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Cc: Russell King <linux@arm.linux.org.uk>
      9c97738c
    • A
      Input: eeti_ts: pass gpio value instead of IRQ · 4eef6cbf
      Arnd Bergmann 提交于
      The EETI touchscreen asserts its IRQ line as soon as it has data in its
      internal buffers. The line is automatically deasserted once all data has
      been read via I2C. Hence, the driver has to monitor the GPIO line and
      cannot simply rely on the interrupt handler reception.
      
      In the current implementation of the driver, irq_to_gpio() is used to
      determine the GPIO number from the i2c_client's IRQ value.
      
      As irq_to_gpio() is not available on all platforms, this patch changes
      this and makes the driver ignore the passed in IRQ. Instead, a GPIO is
      added to the platform_data struct and gpio_to_irq is used to derive the
      IRQ from that GPIO. If this fails, bail out. The driver is only able to
      work in environments where the touchscreen GPIO can be mapped to an
      IRQ.
      
      Without this patch, building raumfeld_defconfig results in:
      
      drivers/input/touchscreen/eeti_ts.c: In function 'eeti_ts_irq_active':
      drivers/input/touchscreen/eeti_ts.c:65:2: error: implicit declaration of function 'irq_to_gpio' [-Werror=implicit-function-declaration]
      Signed-off-by: NDaniel Mack <zonque@gmail.com>
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Cc: stable@vger.kernel.org (v3.2+)
      Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
      Cc: Sven Neumann <s.neumann@raumfeld.com>
      Cc: linux-input@vger.kernel.org
      Cc: Haojian Zhuang <haojian.zhuang@gmail.com>
      4eef6cbf
    • S
      ARM: tegra: more regulator fixes for Harmony · 798bd59c
      Stephen Warren 提交于
      Commit 3d55c29f "ARM: tegra: harmony: add regulator supply name and its
      input supply" was supposed to fix all the problems with regulators on
      Harmony. However, it appears that I only tested it when booting using
      board files, not when booting using device tree. This change fixes two
      problems with regulators when booting using device tree:
      
      1) That patch only created the vdd_sys regulator when booting using a
         board file. Since this is the root of the whole regulator tree, this
         caused no regulators to successfully initialize when booting using
         device tree. The registration of vdd_sys is moved to fix this.
      
      2) When booting use DT, the regulator core sets has_full_constraints,
         which in turn causes the core to turn off any regulators not marked
         as always on. Some of the affected regulators are required for basic
         system operation. To solve this, add always on constraints to all
         relevant regulators. This doesn't affect booting using a board file
         since nothing sets has_full_constraints in that case.
      Signed-off-by: NStephen Warren <swarren@nvidia.com>
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      798bd59c
    • A
      ARM: dma-mapping: fix incorrect freeing of atomic allocations · d9e0d149
      Aaro Koskinen 提交于
      Commit e9da6e99 (ARM: dma-mapping:
      remove custom consistent dma region) changed the way atomic allocations
      are handled. However, arm_dma_free() was not modified accordingly, and
      as a result freeing of atomic allocations does not work correctly when
      CMA is disabled. Memory is leaked and following WARNINGs are seen:
      
      [   57.698911] ------------[ cut here ]------------
      [   57.753518] WARNING: at arch/arm/mm/dma-mapping.c:263 arm_dma_free+0x88/0xe4()
      [   57.811473] trying to free invalid coherent area: e0848000
      [   57.867398] Modules linked in: sata_mv(-)
      [   57.921373] [<c000d270>] (unwind_backtrace+0x0/0xf0) from [<c0015430>] (warn_slowpath_common+0x50/0x68)
      [   58.033924] [<c0015430>] (warn_slowpath_common+0x50/0x68) from [<c00154dc>] (warn_slowpath_fmt+0x30/0x40)
      [   58.152024] [<c00154dc>] (warn_slowpath_fmt+0x30/0x40) from [<c000dc18>] (arm_dma_free+0x88/0xe4)
      [   58.219592] [<c000dc18>] (arm_dma_free+0x88/0xe4) from [<c008fa30>] (dma_pool_destroy+0x100/0x148)
      [   58.345526] [<c008fa30>] (dma_pool_destroy+0x100/0x148) from [<c019a64c>] (release_nodes+0x144/0x218)
      [   58.475782] [<c019a64c>] (release_nodes+0x144/0x218) from [<c0197e10>] (__device_release_driver+0x60/0xb8)
      [   58.614260] [<c0197e10>] (__device_release_driver+0x60/0xb8) from [<c0198608>] (driver_detach+0xd8/0xec)
      [   58.756527] [<c0198608>] (driver_detach+0xd8/0xec) from [<c0197c54>] (bus_remove_driver+0x7c/0xc4)
      [   58.901648] [<c0197c54>] (bus_remove_driver+0x7c/0xc4) from [<c004bfac>] (sys_delete_module+0x19c/0x220)
      [   59.051447] [<c004bfac>] (sys_delete_module+0x19c/0x220) from [<c0009140>] (ret_fast_syscall+0x0/0x2c)
      [   59.207996] ---[ end trace 0745420412c0325a ]---
      [   59.287110] ------------[ cut here ]------------
      [   59.366324] WARNING: at arch/arm/mm/dma-mapping.c:263 arm_dma_free+0x88/0xe4()
      [   59.450511] trying to free invalid coherent area: e0847000
      [   59.534357] Modules linked in: sata_mv(-)
      [   59.616785] [<c000d270>] (unwind_backtrace+0x0/0xf0) from [<c0015430>] (warn_slowpath_common+0x50/0x68)
      [   59.790030] [<c0015430>] (warn_slowpath_common+0x50/0x68) from [<c00154dc>] (warn_slowpath_fmt+0x30/0x40)
      [   59.972322] [<c00154dc>] (warn_slowpath_fmt+0x30/0x40) from [<c000dc18>] (arm_dma_free+0x88/0xe4)
      [   60.070701] [<c000dc18>] (arm_dma_free+0x88/0xe4) from [<c008fa30>] (dma_pool_destroy+0x100/0x148)
      [   60.256817] [<c008fa30>] (dma_pool_destroy+0x100/0x148) from [<c019a64c>] (release_nodes+0x144/0x218)
      [   60.445201] [<c019a64c>] (release_nodes+0x144/0x218) from [<c0197e10>] (__device_release_driver+0x60/0xb8)
      [   60.634148] [<c0197e10>] (__device_release_driver+0x60/0xb8) from [<c0198608>] (driver_detach+0xd8/0xec)
      [   60.823623] [<c0198608>] (driver_detach+0xd8/0xec) from [<c0197c54>] (bus_remove_driver+0x7c/0xc4)
      [   61.013268] [<c0197c54>] (bus_remove_driver+0x7c/0xc4) from [<c004bfac>] (sys_delete_module+0x19c/0x220)
      [   61.203472] [<c004bfac>] (sys_delete_module+0x19c/0x220) from [<c0009140>] (ret_fast_syscall+0x0/0x2c)
      [   61.393390] ---[ end trace 0745420412c0325b ]---
      
      The patch fixes this.
      Signed-off-by: NAaro Koskinen <aaro.koskinen@iki.fi>
      Signed-off-by: NMarek Szyprowski <m.szyprowski@samsung.com>
      d9e0d149
    • A
      ARM: dma-mapping: fix atomic allocation alignment · e4ea6918
      Aaro Koskinen 提交于
      The alignment mask is calculated incorrectly. Fixing the calculation
      makes strange hangs/lockups disappear during the boot with Amstrad E3
      and 3.6-rc1 kernel.
      Signed-off-by: NAaro Koskinen <aaro.koskinen@iki.fi>
      Signed-off-by: NMarek Szyprowski <m.szyprowski@samsung.com>
      e4ea6918
    • C
      ARM: mm: fix MMU mapping of CMA regions · 39f78e70
      Chris Brand 提交于
      Fix dma_contiguous_remap() so that it continues through all the
      regions, even after encountering one that is outside lowmem.
      Without this change, if you have two CMA regions, the first outside
      lowmem and the seocnd inside lowmem, only the second one will get
      set up in the MMU. Data written to that region then doesn't get
      automatically flushed from the cache into memory.
      Signed-off-by: NChris Brand <cbrand@broadcom.com>
      [extended patch subject with 'fix' word]
      Signed-off-by: NMarek Szyprowski <m.szyprowski@samsung.com>
      39f78e70
  8. 07 8月, 2012 4 次提交
  9. 04 8月, 2012 2 次提交
  10. 03 8月, 2012 5 次提交