1. 22 Jan, 2016 6 commits
    • Tony Lindgren's avatar
      ARM: omap2plus_defconfig: Enable ARM_KERNMEM_PERMS and few loadable modules · 143c6fe3
      Tony Lindgren authored
      With recent omap assembly fixes for CONFIG_DEBUG_RODATA, we can
      now use DEBUG_RODATA. Let's enable ARM_KERNMEM_PERMS so that
      DEBUG_RODATA gets selected by default. This way we can make sure
      any related issues are caught early.
      
      And while testing things on various devices, I noticed we're
      missing few loadable modules to make things more usable:
      
      - USB Ethernet for smsc75xx, we only have smsc97xx right now
      
      - Basic USB serial drivers for things like ftdi and pl2303 ports
      
      - Blinking leds with pca963x
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      143c6fe3
    • Tony Lindgren's avatar
      ARM: OMAP2+: Fix ppa_zero_params and ppa_por_params for rodata · 4da597d1
      Tony Lindgren authored
      We don't want to write to .text so let's move ppa_zero_params and
      ppa_por_params to .data and access them via pointers.
      
      Note that I have not been able to test as we I don't have a HS
      omap4 to test with. The code has been changed in similar way as
      for omap3 though.
      
      Cc: Kees Cook <keescook@chromium.org>
      Cc: Laura Abbott <labbott@redhat.com>
      Cc: Nishanth Menon <nm@ti.com>
      Cc: Richard Woodruff <r-woodruff2@ti.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Tero Kristo <t-kristo@ti.com>
      Acked-by: default avatarNicolas Pitre <nico@linaro.org>
      Cc: stable@vger.kernel.org # v4.0+
      Fixes: 1e6b4811 ("ARM: mm: allow non-text sections to be
      non-executable")
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      4da597d1
    • Tony Lindgren's avatar
      ARM: OMAP2+: Fix l2_inv_api_params for rodata · 0a0b1327
      Tony Lindgren authored
      We don't want to write to .text, so let's move l2_inv_api_params
      to .data and access it via a pointer.
      
      Cc: Kees Cook <keescook@chromium.org>
      Cc: Laura Abbott <labbott@redhat.com>
      Cc: Nishanth Menon <nm@ti.com>
      Cc: Richard Woodruff <r-woodruff2@ti.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Tero Kristo <t-kristo@ti.com>
      Acked-by: default avatarNicolas Pitre <nico@linaro.org>
      Cc: stable@vger.kernel.org # v4.0+
      Fixes: 1e6b4811 ("ARM: mm: allow non-text sections to be
      non-executable")
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      0a0b1327
    • Tony Lindgren's avatar
      ARM: OMAP2+: Fix save_secure_ram_context for rodata · a5311d4d
      Tony Lindgren authored
      We don't want to write to .text and we can move save_secure_ram_context
      into .data as it all gets copied into SRAM anyways.
      
      Cc: Kees Cook <keescook@chromium.org>
      Cc: Laura Abbott <labbott@redhat.com>
      Cc: Nishanth Menon <nm@ti.com>
      Cc: Richard Woodruff <r-woodruff2@ti.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
      Cc: Tero Kristo <t-kristo@ti.com>
      Acked-by: default avatarNicolas Pitre <nico@linaro.org>
      Cc: stable@vger.kernel.org # v4.0+
      Fixes: 1e6b4811 ("ARM: mm: allow non-text sections to be
      non-executable")
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      a5311d4d
    • Tony Lindgren's avatar
      ARM: OMAP2+: Fix l2dis_3630 for rodata · eeaf9646
      Tony Lindgren authored
      We don't want to write to .text section. Let's move l2dis_3630
      to .data and access it via a pointer.
      
      For calculating the offset, let's optimize out the add and do it
      in ldr/str as suggested by Nicolas Pitre <nicolas.pitre@linaro.org>.
      
      Cc: Kees Cook <keescook@chromium.org>
      Cc: Laura Abbott <labbott@redhat.com>
      Cc: Nishanth Menon <nm@ti.com>
      Cc: Richard Woodruff <r-woodruff2@ti.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Tero Kristo <t-kristo@ti.com>
      Cc: stable@vger.kernel.org # v4.0+
      Acked-by: default avatarNicolas Pitre <nico@linaro.org>
      Cc: stable@vger.kernel.org # v4.0+
      Fixes: 1e6b4811 ("ARM: mm: allow non-text sections to be
      non-executable")
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      eeaf9646
    • Tony Lindgren's avatar
      ARM: OMAP2+: Fix wait_dll_lock_timed for rodata · d9db5910
      Tony Lindgren authored
      We don't want to be writing to .text so it can be set rodata.
      Fix error "Unable to handle kernel paging request at virtual address
      c012396c" in wait_dll_lock_timed if CONFIG_DEBUG_RODATA is selected.
      
      As these counters are for debugging only and unused, we can just
      remove them.
      
      Cc: Kees Cook <keescook@chromium.org>
      Cc: Laura Abbott <labbott@redhat.com>
      Cc: Nishanth Menon <nm@ti.com>
      Cc: Richard Woodruff <r-woodruff2@ti.com>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Tero Kristo <t-kristo@ti.com>
      Acked-by: default avatarNicolas Pitre <nico@linaro.org>
      Cc: stable@vger.kernel.org # v4.0+
      Fixes: 1e6b4811 ("ARM: mm: allow non-text sections to be
      non-executable")
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      d9db5910
  2. 21 Jan, 2016 3 commits
  3. 15 Jan, 2016 2 commits
  4. 11 Jan, 2016 1 commit
    • Tony Lindgren's avatar
      ARM: dts: Fix omap5 PMIC control lines for RTC writes · af756bbc
      Tony Lindgren authored
      The palmas PMIC has two control lines that need to be muxed properly
      for things to work. The sys_nirq pin is used for interrupts, and msecure
      pin is used for enabling writes to some PMIC registers.
      
      Without these pins configured properly things can fail in mysterious
      ways. For example, we can't update the RTC registers on palmas PMIC
      unless the msecure pin is configured. And this is probably the reason
      why we had RTC missing from the omap5 dts file.
      
      According to "OMAP5430 ES2.0 Data Manual [Public] VErsion A (Rev. F)"
      swps052f.pdf, mux mode 1 is for sys_drm_msecure so in theory there's
      should be no need to configure it as a GPIO pin.
      
      However, it seems there are some reliability issues using the msecure
      mux mode. And the TI trees configure the msecure pin as GPIO out high
      instead.
      
      As the PMIC only cares that the msecure line is high to allow access
      to the RTC registers, let's use a GPIO hog as suggested by Nishanth
      Menon <nm@ti.com>. Also the use of the internal pull was considered
      but supposedly that may not be capable of keeping the line high in
      a noisy environment.
      
      If we ever see high security omap5 products in the mainline tree,
      those need to skip the msecure pin muxing and ignore setting the GPIO
      hog. Chances are the related pin mux registers are locked in that case
      and the msecure pin is managed by whatever software may be running in
      the ARM TrustZone.
      
      Who knows what the original intention of the msecure pin was. Maybe
      it was supposed to prevent the system time to be set back for some
      game demo modes to time out? Anyways, it seems that later PMICs like
      tps659037 have recycled this pin for "powerhold" and devices like
      beagle-x15 do not need changes to the msecure pin configuration.
      
      To avoid further confusion with TWL variant PMICs, beagle-x15 does
      not have a back-up battery for RTC palmas. Instead the mcp79410 RTC
      is used with rtc-ds1307 driver. There is a "powerhold" jumper j5
      holes near the palmas PMIC, and shorting it seems to power up
      beagle-x15 automatically. It is unknown if it also has other side
      effects to the beagle-x15 power up sequence.
      
      Cc: stable@vger.kernel.org # v4.4
      Signed-off-by: default avatarTony Lindgren <tony@atomide.com>
      af756bbc
  5. 10 Jan, 2016 1 commit
  6. 09 Jan, 2016 4 commits
    • Linus Torvalds's avatar
      Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi · eac6f76a
      Linus Torvalds authored
      Pull SCSI fix from James Bottomley:
       "A single fix for machines with pages > 4k (PPC mostly).
      
        There's a bug in our optimal transfer size code where we don't account
        for pages > 4k and can set the transfer size to be less than the page
        size causing nasty failures"
      
      * tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
        sd: Reject optimal transfer length smaller than page size
      eac6f76a
    • Linus Torvalds's avatar
      Merge tag 'pci-v4.4-fixes-4' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci · c0cb1393
      Linus Torvalds authored
      Pull PCI fixlet from Bjorn Helgaas:
       "This marks the TI DRA7xx host bridge driver as broken.  Apparently it
        has never worked without some additional out-of-tree code, so I'm
        going to mark it broken now and remove it completely next cycle unless
        it's fixed"
      
      * tag 'pci-v4.4-fixes-4' of git://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci:
        PCI: dra7xx: Mark driver as broken
      c0cb1393
    • Michal Hocko's avatar
      vmstat: allocate vmstat_wq before it is used · 751e5f5c
      Michal Hocko authored
      kernel test robot has reported the following crash:
      
        BUG: unable to handle kernel NULL pointer dereference at 00000100
        IP: [<c1074df6>] __queue_work+0x26/0x390
        *pdpt = 0000000000000000 *pde = f000ff53f000ff53 *pde = f000ff53f000ff53
        Oops: 0000 [#1] PREEMPT PREEMPT SMP SMP
        CPU: 0 PID: 24 Comm: kworker/0:1 Not tainted 4.4.0-rc4-00139-g373ccbe5 #1
        Workqueue: events vmstat_shepherd
        task: cb684600 ti: cb7ba000 task.ti: cb7ba000
        EIP: 0060:[<c1074df6>] EFLAGS: 00010046 CPU: 0
        EIP is at __queue_work+0x26/0x390
        EAX: 00000046 EBX: cbb37800 ECX: cbb37800 EDX: 00000000
        ESI: 00000000 EDI: 00000000 EBP: cb7bbe68 ESP: cb7bbe38
         DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
        CR0: 8005003b CR2: 00000100 CR3: 01fd5000 CR4: 000006b0
        Stack:
        Call Trace:
          __queue_delayed_work+0xa1/0x160
          queue_delayed_work_on+0x36/0x60
          vmstat_shepherd+0xad/0xf0
          process_one_work+0x1aa/0x4c0
          worker_thread+0x41/0x440
          kthread+0xb0/0xd0
          ret_from_kernel_thread+0x21/0x40
      
      The reason is that start_shepherd_timer schedules the shepherd work item
      which uses vmstat_wq (vmstat_shepherd) before setup_vmstat allocates
      that workqueue so if the further initialization takes more than HZ we
      might end up scheduling on a NULL vmstat_wq.  This is really unlikely
      but not impossible.
      
      Fixes: 373ccbe5 ("mm, vmstat: allow WQ concurrency to discover memory reclaim doesn't make any progress")
      Reported-by: default avatarkernel test robot <ying.huang@linux.intel.com>
      Signed-off-by: default avatarMichal Hocko <mhocko@suse.com>
      Tested-by: default avatarTetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>
      Cc: stable@vger.kernel.org
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      751e5f5c
    • Linus Torvalds's avatar
      Merge tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc · 44d8a7d5
      Linus Torvalds authored
      Pull ARM SoC fixes from Arnd Bergmann:
       "This is the final small set of ARM SoC bug fixes for linux-4.4, almost
        all regressions:
      
        OMAP:
         - data corruption on the Nokia N900 flash
      
        Allwinner:
         - Two defconfig change to get USB working again
      
        ARM Versatile:
         - Interrupt numbers gone bad after an older bug fix
      
        Nomadik:
         - Crashes from incorrect L2 cache settings
      
        VIA vt8500:
         - SD/MMC support on WM8650 never worked"
      
      * tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
        dts: vt8500: Add SDHC node to DTS file for WM8650
        ARM: Fix broken USB support in multi_v7_defconfig for sunxi devices
        ARM: versatile: fix MMC/SD interrupt assignment
        ARM: nomadik: set latencies to 8 cycles
        ARM: OMAP2+: Fix onenand rate detection to avoid filesystem corruption
        ARM: Fix broken USB support in sunxi_defconfig
      44d8a7d5
  7. 08 Jan, 2016 15 commits
  8. 07 Jan, 2016 8 commits