1. 30 6月, 2008 1 次提交
  2. 28 6月, 2008 1 次提交
  3. 26 6月, 2008 9 次提交
  4. 19 6月, 2008 1 次提交
    • K
      powerpc/booke: Add support for new e500mc core · 3dfa8773
      Kumar Gala 提交于
      The new e500mc core from Freescale is based on the e500v2 but with the
      following changes:
      
      * Supports only the Enhanced Debug Architecture (DSRR0/1, etc)
      * Floating Point
      * No SPE
      * Supports lwsync
      * Doorbell Exceptions
      * Hypervisor
      * Cache line size is now 64-bytes (e500v1/v2 have a 32-byte cache line)
      Signed-off-by: NKumar Gala <galak@kernel.crashing.org>
      3dfa8773
  5. 18 6月, 2008 1 次提交
    • J
      powerpc/4xx: Workaround for PPC440EPx/GRx PCI_28 Errata · 5ce4b596
      Josh Boyer 提交于
      The 440EPx/GRx chips don't support PCI MRM commands.  Drivers determine this
      by looking for a zero value in the PCI cache line size register.  However,
      some drivers write to this register upon initialization.  This can cause
      MRMs to be used on these chips, which may cause deadlocks on PLB4.
      
      The workaround implemented here introduces a new indirect_type flag, called
      PPC_INDIRECT_TYPE_BROKEN_MRM.  This is set in the pci_controller structure in
      the pci fixup function for 4xx PCI bridges by determining if the bridge is
      compatible with 440EPx/GRx.  The flag is checked in the indirect_write_config
      function, and forces any writes to the PCI_CACHE_LINE_SIZE register to be
      zero, which will disable MRMs for these chips.
      
      A similar workaround has been tested by AMCC on various PCI cards, such as
      the Silicon Image ATA card and Intel E1000 GIGE card.  Hangs were seen with
      the Silicon Image card, and MRMs were seen on the bus with a PCI analyzer.
      With the workaround in place, the card functioned properly and only Memory
      Reads were seen on the bus with the analyzer.
      Acked-by: NStefan Roese <sr@denx.de>
      Signed-off-by: NJosh Boyer <jwboyer@linux.vnet.ibm.com>
      5ce4b596
  6. 16 6月, 2008 1 次提交
  7. 12 6月, 2008 2 次提交
  8. 11 6月, 2008 9 次提交
  9. 10 6月, 2008 8 次提交
  10. 09 6月, 2008 7 次提交
    • T
      powerpc: Improve (in|out)_[bl]eXX() asm code · 0f3d6bcd
      Trent Piepho 提交于
      Since commit 4cb3cee0 the code generated
      for the in_beXX() and out_beXX() mmio functions has been sub-optimal.
      
      The out_leXX() family of functions are created with the macro
      DEF_MMIO_OUT_LE() while the out_beXX() family are created with
      DEF_MMIO_OUT_BE().  In what was perhaps a bit too much macro use, both of
      these macros are in turn created via the macro DEF_MMIO_OUT().
      
      For the LE versions, eventually they boil down to an asm that will look
      something like this:
      asm("sync; stwbrx %1,0,%2" : "=m" (*addr) : "r" (val), "r" (addr));
      
      The issue is that the "stwbrx" instruction only comes in an indexed, or
      'x', version, in which the address is represented by the sum of two
      registers (the "0,%2").  Unfortunately, gcc doesn't have a constraint for
      an indexed memory reference.  The "m" constraint allows both indexed and
      offset, i.e. register plus constant, memory references and there is no
      "stwbr" version for offset references.  "m" also allows updating addresses
      and there is no 'u' version of "stwbrx" like there is with "stwux".
      
      The unused first operand to the asm is just to tell gcc that *addr is an
      output of the asm.  The address used is passed in a single register via the
      third asm operand, and the index register is just hard coded as 0.  This
      means gcc is forced to put the address in a single register and can't use
      index addressing, e.g. if one has the data in register 9, a base address in
      register 3 and an index in register 4, gcc must emit code like "add 11,4,3;
      stwbrx 9,0,11" instead of just "stwbrx 9,4,3".  This costs an extra add
      instruction and another register.
      
      For gcc 4.0 and older, there doesn't appear to be anything that can be
      done.  But for 4.1 and newer, there is a 'Z' constraint.  It does not allow
      "updating" addresses, but does allow both indexed and offset addresses.
      However, the only allowed constant offset is 0.  We can then use the
      undocumented 'y' operand modifier, which causes gcc to convert "0(reg)"
      into the equivilient "0,reg" format that can be used with stwbrx.
      
      This brings us the to problem with the BE version.  In this case, the "stw"
      instruction does have both indexed and non-indexed versions.  The final asm
      ends up looking like this:
      asm("sync; stw%U0%X0 %1,%0" : "=m" (*addr) : "r" (val), "r" (addr));
      
      The undocumented codes "%U0" and "%0X" will generate a 'u' if the memory
      reference should be an auto-updating one, and an 'x' if the memory
      reference is indexed, respectively.  The third operand is unused, it's just
      there because asm the code is reused from the LE version.  However, gcc
      does not know this, and generates unnecessary code to stick addr in a
      register!  To use the example from the LE version, gcc will generate "add
      11,4,3; stwx 9,4,3".  It is able to use the indexed address "4,3" for the
      "stwx", but still thinks it needs to put 4+3 into register 11, which will
      never be used.
      
      This also ends up happening a lot for the offset addressing mode, where
      common code like this:  out_be32(&device_registers->some_register, data);
      uses an instruction like "stw 9, 42(3)", where register 3 has the pointer
      device_registers and 42 is the offset of some_register in that structure.
      gcc will be forced to generate the unnecessary instruction "addi 11, 3, 42"
      to put the address into a single (unused) register.
      
      The in_* versions end up having these exact same problems as well.
      Signed-off-by: NTrent Piepho <tpiepho@freescale.com>
      CC: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      CC: Andreas Schwab <schwab@suse.de>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      0f3d6bcd
    • M
      powerpc: Fix irq_alloc_host() reference counting and callers · 19fc65b5
      Michael Ellerman 提交于
      When I changed irq_alloc_host() to take an of_node
      (52964f87: "Add an optional
      device_node pointer to the irq_host"), I botched the reference
      counting semantics.
      
      Stephen pointed out that it's irq_alloc_host()'s business if
      it needs to take an additional reference to the device_node,
      the caller shouldn't need to care.
      Signed-off-by: NMichael Ellerman <michael@ellerman.id.au>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      19fc65b5
    • M
      powerpc: Rework qe_ic_init() so we can avoid freeing the irq_host · 2272a55f
      Michael Ellerman 提交于
      If we do the call to of_address_to_resource() first, then we don't
      need to worry about freeing the irq_host (which the code doesn't do
      currently anyway).
      Signed-off-by: NMichael Ellerman <michael@ellerman.id.au>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      2272a55f
    • M
      powerpc: Rework ipic_init() so we can avoid freeing the irq_host · 84f1c1e0
      Michael Ellerman 提交于
      If we do the call to of_address_to_resource() first, then we don't
      need to worry about freeing the irq_host (which the code doesn't do
      currently anyway).
      Signed-off-by: NMichael Ellerman <michael@ellerman.id.au>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      84f1c1e0
    • M
      powerpc: Rework Axon MSI setup so we can avoid freeing the irq_host · 997526db
      Michael Ellerman 提交于
      If we do the call to irq_of_parse_and_map() first, then we don't
      need to worry about freeing the irq_host.
      Signed-off-by: NMichael Ellerman <michael@ellerman.id.au>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      997526db
    • R
      powerpc: Check that TASK_SIZE does not overlap KERNEL_START · 7c4f10b9
      Rune Torgersen 提交于
      Make sure CONFIG_TASK_SIZE does not overlap CONFIG_KERNEL_START
      This could happen when overriding settings to get 1GB lowmem, and would lead
      to userland mysteriousely hanging.
      
      This setting is only used by PPC32.
      Signed-off-by: NRune Torgersen <runet@innovsys.com>
      Acked-by: NKumar Gala <galak@kernel.crashing.org>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      7c4f10b9
    • S