1. 16 12月, 2011 7 次提交
    • S
      ARM: OMAP3+: hwmod data: Add the default clockactivity for I2C · 3e47dc6a
      Shubhrajyoti D 提交于
      For I2C clockactivity field is added for OMAP3 and OMAP4 that defines how the
      interface (OCP) and functional (system) clocks behave when the I2C module is
      idle.
      
      The configuration of the clock activity bit field (per TRM) is as follows:
      0x0: Both clocks can be cut off
      0x1: Only OCP clock must be kept active; system clock
           can be cut off
      0x3: Both clocks must be kept active
      0x2: Only system clock must be kept active; OCP clock
           can be cut off
      
      The patch makes 0x2(CLOCKACT_TEST_ICLK) the default for OMAP3 and OMAP4.
      Signed-off-by: NShubhrajyoti D <shubhrajyoti@ti.com>
      Signed-off-by: NJon Hunter <jon-hunter@ti.com>
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      3e47dc6a
    • P
      ARM: OMAP3: hwmod data: disable multiblock reads on MMC1/2 on OMAP34xx/35xx <= ES2.1 · a52e2ab6
      Paul Walmsley 提交于
      The HSMMC1/HSMMC2 host controllers on OMAP34xx and
      OMAP3503/3515/3525/3530 chips at ES levels prior to 3.0 can't do multiple
      block reads[1].  Mark the hwmod data appropriately.
      
      Reported by Dave Hylands <dhylands@gmail.com> and Steve Sakoman
      <sakoman@gmail.com>.  Thanks to Steve Sakoman for further help
      testing this patch.
      
      1. See for example Advisory 2.1.1.128 "MMC: Multiple Block Read
         Operation Issue" in _OMAP3530/3525/3515/3503 Silicon Errata_
         Revision F (October 2010) (SPRZ278F), available from
         http://focus.ti.com/lit/er/sprz278f/sprz278f.pdfSigned-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: Dave Hylands <dhylands@gmail.com>
      Cc: Steve Sakoman <sakoman@gmail.com>
      a52e2ab6
    • B
      ARM: OMAP: USB: EHCI and OHCI hwmod structures for OMAP4 · af88fa9a
      Benoit Cousson 提交于
      Following 2 hwmod structures are added
      1. usb_host_hs
           The hwmod of usbhs with uhh, ehci and ohci base addresses
           functional clock and ehci, ohci irqs
      
      2. usb_tll_hs
            hwmod of usbhs with the TLL base address and irq.
      Signed-off-by: NBenoit Cousson <b-cousson@ti.com>
      [keshava_mgowda@ti.com: rebased to kernel version 3.0, added workarounds for
       hardware issues]
      Signed-off-by: NKeshava Munegowda <keshava_mgowda@ti.com>
      Reviewed-by: NPartha Basak <parthab@india.ti.com>
      [paul@pwsan.com: fixed multi-line comments, fixed whitespace, fixed S-o-b
       notes, removed spurious TLL->L3 interface]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      af88fa9a
    • K
      ARM: OMAP: USB: EHCI and OHCI hwmod structures for OMAP3 · de231388
      Keshava Munegowda 提交于
      Following 2 hwmod structures are added
          1. usb_host_hs
               The hwmod of usbhs with uhh, ehci and ohci base addresses
               functional clock and ehci, ohci irqs
      
          2. usb_tll_hs
                hwmod of usbhs with the TLL base address and irq.
      Signed-off-by: NKeshava Munegowda <keshava_mgowda@ti.com>
      Reviewed-by: NPartha Basak <parthab@india.ti.com>
      [paul@pwsan.com: fixed whitespace; removed nonexistent TLL->L3 interface;
       added master & slave for L4 CORE->TLL interface; skip registration on
       3430ES1; fixed multiline comment style; updated to apply on Tony's cleanup
       branch; rebased]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      de231388
    • K
      ARM: OMAP: hwmod data: Add support for AM35xx UART4/ttyO3 · 4bf90f65
      Kyle Manna 提交于
      Add hwmod support to enable access to UART4 of the AM35xx series of
      chips.  The UART4 device referenced from the TRM will show up as ttyO3.
      
      This was tested on an AM3505.
      Signed-off-by: NKyle Manna <kyle.manna@fuel7.com>
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      4bf90f65
    • A
      ARM: OMAP: hwmod data: fix the panic on Nokia RM-680 during boot · 91a36bdb
      Aaro Koskinen 提交于
      Booting the Linux kernel on Nokia RM-680 board has been broken since
      2.6.39 due to the following:
      
      [    0.217193] omap_hwmod: timer12: enabling
      [    0.221435] Unhandled fault: external abort on non-linefetch (0x1028) at 0xfa304010
      [    0.229431] Internal error: : 1028 [#1] SMP
      [    0.233825] Modules linked in:
      [    0.237060] CPU: 0    Not tainted  (3.2.0-rc4-dirty #46)
      [    0.242645] PC is at _update_sysc_cache+0x2c/0x7c
      [    0.247589] LR is at _enable+0x1b0/0x2d8
      [    0.251708] pc : [<c0026108>]    lr : [<c0026df4>]    psr: 40000013
      [    0.251708] sp : ef831f40  ip : ef82f380  fp : c06ac0c0
      [    0.263702] r10: 00000000  r9 : c05dfb2c  r8 : ef830000
      [    0.269165] r7 : c0027494  r6 : 00000000  r5 : 00000000  r4 : c06608b0
      [    0.276000] r3 : fa304000  r2 : 00000010  r1 : c0661e28  r0 : c06608b0
      [    0.282806] Flags: nZcv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
      [    0.290405] Control: 10c5387d  Table: 80004019  DAC: 00000017
      [    0.296417] Process swapper (pid: 1, stack limit = 0xef8302f8)
      [    0.302520] Stack: (0xef831f40 to 0xef832000)
      [    0.307098] 1f40: c06608b0 c0026df4 c06ad094 c0035120 00000001 c06608b0 00000000 c0027530
      [    0.315612] 1f60: c0027604 ef830000 c05dfb2c c06608b0 c0642ac0 c0025bf0 c0621234 c062120c
      [    0.324127] 1f80: c0621738 00000013 ef830000 c05dfb6c c0621234 c0008688 c062c880 c009eadc
      [    0.332641] 1fa0: 0000005f 00000000 c0621738 35390013 00000000 00000000 00000000 0000019a
      [    0.341156] 1fc0: c0681cf4 c0621234 c062120c c0621738 00000013 00000000 00000000 00000000
      [    0.349670] 1fe0: 00000000 c05d5298 00000000 c05d5200 c0014fa8 c0014fa8 ffff0000 ffff0000
      [    0.358184] [<c0026108>] (_update_sysc_cache+0x2c/0x7c) from [<c0026df4>] (_enable+0x1b0/0x2d8)
      [    0.367248] [<c0026df4>] (_enable+0x1b0/0x2d8) from [<c0027530>] (_setup+0x9c/0x170)
      [    0.375335] [<c0027530>] (_setup+0x9c/0x170) from [<c0025bf0>] (omap_hwmod_for_each+0x38/0x58)
      [    0.384307] [<c0025bf0>] (omap_hwmod_for_each+0x38/0x58) from [<c05dfb6c>] (omap_hwmod_setup_all+0x40/0xa0)
      [    0.394409] [<c05dfb6c>] (omap_hwmod_setup_all+0x40/0xa0) from [<c0008688>] (do_one_initcall+0x34/0x180)
      [    0.404296] [<c0008688>] (do_one_initcall+0x34/0x180) from [<c05d5298>] (kernel_init+0x98/0x144)
      [    0.413452] [<c05d5298>] (kernel_init+0x98/0x144) from [<c0014fa8>] (kernel_thread_exit+0x0/0x8)
      [    0.422576] Code: e3130c01 1590304c 0590304c 119320b2 (07932002)
      [    0.429046] ---[ end trace 1b75b31a2719ed1c ]---
      [    0.433959] Kernel panic - not syncing: Attempted to kill init!
      
      Timer 12 is not necessarily available on non-GP devices (see e.g.
      http://marc.info/?l=linux-omap&m=129433066521102&w=2), so it should be
      registered only on GP OMAPs. With this change it's again possible to
      boot RM-680 into the shell. Tested with 3.2-rc4.
      Signed-off-by: NAaro Koskinen <aaro.koskinen@nokia.com>
      [paul@pwsan.com: changed subject line]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      91a36bdb
    • F
      ARM: OMAP: hwmod data: fix iva and mailbox hwmods for OMAP 3 · 7c17c770
      Felipe Contreras 提交于
      Seems the commit 7e89098c was overly aggressive in adding iva and mailbox
      hwmods so now they are registered twice.
      
      ------------[ cut here ]------------
      WARNING: at arch/arm/mach-omap2/omap_hwmod.c:1959 omap_hwmod_register+0x104/0x12c()
      omap_hwmod: iva: _register returned -22
      Modules linked in:
      [<c0012aa4>] (unwind_backtrace+0x0/0xec) from [<c002f970>] (warn_slowpath_common+0x4c/0x64)
      [<c002f970>] (warn_slowpath_common+0x4c/0x64) from [<c002fa08>] (warn_slowpath_fmt+0x2c/0x3c)
      [<c002fa08>] (warn_slowpath_fmt+0x2c/0x3c) from [<c02fdb4c>] (omap_hwmod_register+0x104/0x12c)
      [<c02fdb4c>] (omap_hwmod_register+0x104/0x12c) from [<c02fbb44>] (omap3_init_early+0x1c/0x28)
      [<c02fbb44>] (omap3_init_early+0x1c/0x28) from [<c02f9580>] (setup_arch+0x6b8/0x7a4)
      [<c02f9580>] (setup_arch+0x6b8/0x7a4) from [<c02f754c>] (start_kernel+0x6c/0x264)
      [<c02f754c>] (start_kernel+0x6c/0x264) from [<80008040>] (0x80008040)
      ---[ end trace 1b75b31a2719ed1c ]---
      ------------[ cut here ]------------
      WARNING: at arch/arm/mach-omap2/omap_hwmod.c:1959 omap_hwmod_register+0x104/0x12c()
      omap_hwmod: mailbox: _register returned -22
      Modules linked in:
      [<c0012aa4>] (unwind_backtrace+0x0/0xec) from [<c002f970>] (warn_slowpath_common+0x4c/0x64)
      [<c002f970>] (warn_slowpath_common+0x4c/0x64) from [<c002fa08>] (warn_slowpath_fmt+0x2c/0x3c)
      [<c002fa08>] (warn_slowpath_fmt+0x2c/0x3c) from [<c02fdb4c>] (omap_hwmod_register+0x104/0x12c)
      [<c02fdb4c>] (omap_hwmod_register+0x104/0x12c) from [<c02fbb44>] (omap3_init_early+0x1c/0x28)
      [<c02fbb44>] (omap3_init_early+0x1c/0x28) from [<c02f9580>] (setup_arch+0x6b8/0x7a4)
      [<c02f9580>] (setup_arch+0x6b8/0x7a4) from [<c02f754c>] (start_kernel+0x6c/0x264)
      [<c02f754c>] (start_kernel+0x6c/0x264) from [<80008040>] (0x80008040)
      ---[ end trace 1b75b31a2719ed1d ]---
      Signed-off-by: NFelipe Contreras <felipe.contreras@gmail.com>
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      7c17c770
  2. 09 12月, 2011 3 次提交
    • Y
      thp: add compound tail page _mapcount when mapped · b6999b19
      Youquan Song 提交于
      With the 3.2-rc kernel, IOMMU 2M pages in KVM works.  But when I tried
      to use IOMMU 1GB pages in KVM, I encountered an oops and the 1GB page
      failed to be used.
      
      The root cause is that 1GB page allocation calls gup_huge_pud() while 2M
      page calls gup_huge_pmd.  If compound pages are used and the page is a
      tail page, gup_huge_pmd() increases _mapcount to record tail page are
      mapped while gup_huge_pud does not do that.
      
      So when the mapped page is relesed, it will result in kernel oops
      because the page is not marked mapped.
      
      This patch add tail process for compound page in 1GB huge page which
      keeps the same process as 2M page.
      
      Reproduce like:
      1. Add grub boot option: hugepagesz=1G hugepages=8
      2. mount -t hugetlbfs -o pagesize=1G hugetlbfs /dev/hugepages
      3. qemu-kvm -m 2048 -hda os-kvm.img -cpu kvm64 -smp 4 -mem-path /dev/hugepages
      	-net none -device pci-assign,host=07:00.1
      
        kernel BUG at mm/swap.c:114!
        invalid opcode: 0000 [#1] SMP
        Call Trace:
          put_page+0x15/0x37
          kvm_release_pfn_clean+0x31/0x36
          kvm_iommu_put_pages+0x94/0xb1
          kvm_iommu_unmap_memslots+0x80/0xb6
          kvm_assign_device+0xba/0x117
          kvm_vm_ioctl_assigned_device+0x301/0xa47
          kvm_vm_ioctl+0x36c/0x3a2
          do_vfs_ioctl+0x49e/0x4e4
          sys_ioctl+0x5a/0x7c
          system_call_fastpath+0x16/0x1b
        RIP  put_compound_page+0xd4/0x168
      Signed-off-by: NYouquan Song <youquan.song@intel.com>
      Reviewed-by: NAndrea Arcangeli <aarcange@redhat.com>
      Cc: Andi Kleen <andi@firstfloor.org>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      b6999b19
    • M
      x86, efi: Calling __pa() with an ioremap()ed address is invalid · e8c71062
      Matt Fleming 提交于
      If we encounter an efi_memory_desc_t without EFI_MEMORY_WB set
      in ->attribute we currently call set_memory_uc(), which in turn
      calls __pa() on a potentially ioremap'd address.
      
      On CONFIG_X86_32 this is invalid, resulting in the following
      oops on some machines:
      
        BUG: unable to handle kernel paging request at f7f22280
        IP: [<c10257b9>] reserve_ram_pages_type+0x89/0x210
        [...]
      
        Call Trace:
         [<c104f8ca>] ? page_is_ram+0x1a/0x40
         [<c1025aff>] reserve_memtype+0xdf/0x2f0
         [<c1024dc9>] set_memory_uc+0x49/0xa0
         [<c19334d0>] efi_enter_virtual_mode+0x1c2/0x3aa
         [<c19216d4>] start_kernel+0x291/0x2f2
         [<c19211c7>] ? loglevel+0x1b/0x1b
         [<c19210bf>] i386_start_kernel+0xbf/0xc8
      
      A better approach to this problem is to map the memory region
      with the correct attributes from the start, instead of modifying
      it after the fact. The uncached case can be handled by
      ioremap_nocache() and the cached by ioremap_cache().
      
      Despite first impressions, it's not possible to use
      ioremap_cache() to map all cached memory regions on
      CONFIG_X86_64 because EFI_RUNTIME_SERVICES_DATA regions really
      don't like being mapped into the vmalloc space, as detailed in
      the following bug report,
      
      	https://bugzilla.redhat.com/show_bug.cgi?id=748516
      
      Therefore, we need to ensure that any EFI_RUNTIME_SERVICES_DATA
      regions are covered by the direct kernel mapping table on
      CONFIG_X86_64. To accomplish this we now map E820_RESERVED_EFI
      regions via the direct kernel mapping with the initial call to
      init_memory_mapping() in setup_arch(), whereas previously these
      regions wouldn't be mapped if they were after the last E820_RAM
      region until efi_ioremap() was called. Doing it this way allows
      us to delete efi_ioremap() completely.
      Signed-off-by: NMatt Fleming <matt.fleming@intel.com>
      Cc: H. Peter Anvin <hpa@zytor.com>
      Cc: Matthew Garrett <mjg@redhat.com>
      Cc: Zhang Rui <rui.zhang@intel.com>
      Cc: Huang Ying <huang.ying.caritas@gmail.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Link: http://lkml.kernel.org/r/1321621751-3650-1-git-send-email-matt@console-pimps.orgSigned-off-by: NIngo Molnar <mingo@elte.hu>
      e8c71062
    • M
      x86, hpet: Immediately disable HPET timer 1 if rtc irq is masked · 2ded6e6a
      Mark Langsdorf 提交于
      When HPET is operating in RTC mode, the TN_ENABLE bit on timer1
      controls whether the HPET or the RTC delivers interrupts to irq8. When
      the system goes into suspend, the RTC driver sends a signal to the
      HPET driver so that the HPET releases control of irq8, allowing the
      RTC to wake the system from suspend. The switchover is accomplished by
      a write to the HPET configuration registers which currently only
      occurs while servicing the HPET interrupt.
      
      On some systems, I have seen the system suspend before an HPET
      interrupt occurs, preventing the write to the HPET configuration
      register and leaving the HPET in control of the irq8. As the HPET is
      not active during suspend, it does not generate a wake signal and RTC
      alarms do not work.
      
      This patch forces the HPET driver to immediately transfer control of
      the irq8 channel to the RTC instead of waiting until the next
      interrupt event.
      Signed-off-by: NMark Langsdorf <mark.langsdorf@amd.com>
      Link: http://lkml.kernel.org/r/20111118153306.GB16319@alberich.amd.comTested-by: NAndreas Herrmann <andreas.herrmann3@amd.com>
      Signed-off-by: NAndreas Herrmann <andreas.herrmann3@amd.com>
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      Cc: stable@vger.kernel.org
      2ded6e6a
  3. 08 12月, 2011 1 次提交
  4. 07 12月, 2011 1 次提交
  5. 06 12月, 2011 7 次提交
  6. 05 12月, 2011 21 次提交