1. 04 9月, 2013 18 次提交
  2. 30 8月, 2013 15 次提交
  3. 14 8月, 2013 7 次提交
    • C
      tile: provide traceability for hypervisor calls · 9ae09838
      Chris Metcalf 提交于
      This change adds infrastructure (CONFIG_TILE_HVGLUE_TRACE) that
      provides C code wrappers for the calls the kernel makes to the Tilera
      hypervisor.  This allows standard kernel infrastructure like FTRACE to
      be able to instrument hypervisor calls.
      
      To allow direct calls to the true API, we export their names with a
      leading underscore as well.  This is important for the few contexts
      where we need to make hypervisor calls without touching the stack.
      
      As part of this change, we also switch from creating the symbols
      with linker magic to creating them with assembler magic.  This lets
      us provide a symbol type and generally make them appear more as symbols
      and less as just random values in the Elf namespace.
      Signed-off-by: NChris Metcalf <cmetcalf@tilera.com>
      9ae09838
    • C
      tile: avoid struct vm_struct leak · fad052dc
      Chris Metcalf 提交于
      If ioreamp_prot() fails in ioremap_page_range() due to kernel memory
      exhaustion, we previously would leak a struct vm_struct.
      Signed-off-by: NChris Metcalf <cmetcalf@tilera.com>
      fad052dc
    • C
      tile: implement gettimeofday() via vDSO · 4a556f4f
      Chris Metcalf 提交于
      This change creates the framework for vDSO calls, makes the existing
      rt_sigreturn() mechanism use it, and adds a fast gettimeofday().
      Now that we need to expose the vDSO address to userspace, we add
      AT_SYSINFO_EHDR to the set of aux entries provided to userspace.
      (You can disable any extra vDSO support by booting with vdso=0,
      but the rt_sigreturn vDSO page will still be provided.)
      
      Note that glibc has supported the tile vDSO since release 2.17.
      Signed-off-by: NChris Metcalf <cmetcalf@tilera.com>
      4a556f4f
    • C
      tile: support simulator notification for ET_DYN objects · 0c1d1917
      Chris Metcalf 提交于
      The tile code notifies the simulator of new ET_EXEC objects starting
      to execute so that tracing code can properly annotate the objects.
      However, we didn't support ET_DYN executables like ld.so, so we
      didn't properly load symbols, etc.  This change enables that support;
      we use a variant of the SIM_CONTROL_DLOPEN simulator notification
      that newer simulators will recognize and use to set the base address
      for the next SIM_CONTROL_OS_EXEC notification.
      Signed-off-by: NChris Metcalf <cmetcalf@tilera.com>
      0c1d1917
    • C
      tile: improve illegal translation interrupt handling · 70d2b595
      Chris Metcalf 提交于
      First, don't re-enable interrupts blindly in the Linux trap handler.
      We already handle page faults this way; synchronous interrupts like
      ILL_TRANS will fire even when interrupts are disabled, and we don't
      want to re-enable interrupts in that case.
      
      For ILL_TRANS, we now pass the ILL_VA_PC reason into the trap handler
      so we can report it properly; this is the address that caused the
      illegal translation trap.  We print the address as part of the
      pr_alert() message now if it's coming from the kernel.
      Signed-off-by: NChris Metcalf <cmetcalf@tilera.com>
      70d2b595
    • C
      tile: make register dumps more readable · dadf78bf
      Chris Metcalf 提交于
      It's much easier to read register dumps if you read vertically
      rather than horizontally, since the register numbers line up
      and lead the eye down more than to the right.
      Signed-off-by: NChris Metcalf <cmetcalf@tilera.com>
      dadf78bf
    • C
      tile: improve big-endian support · ba02f0eb
      Chris Metcalf 提交于
      First, fix a bug in asm/unaligned.h; we need to just use the asm-generic
      unaligned.h so we properly choose endian-correct flavors.
      
      Second, keep the hv/hypervisor.h ABI fully "native" in the sense that
      we don't have __BIG_ENDIAN__ ifdefs there.  Instead, we use macros in
      the head_NN.S assembly code to properly extract two 32-bit structure
      members from a 64-bit register holding the structure.
      Signed-off-by: NChris Metcalf <cmetcalf@tilera.com>
      ba02f0eb