1. 11 Sep, 2009 6 commits
    • Geoff Levand's avatar
      powerpc/ps3: Workaround for flash memory I/O error · bc00351e
      Geoff Levand authored
      A workaround for flash memory I/O errors when the PS3 internal
      hard disk has not been formatted for OtherOS use.
      
      This error condition mainly effects 'Live CD' users who have not
      formatted the PS3's internal hard disk for OtherOS.
      
      Fixes errors similar to these when using the ps3-flash-util
      or ps3-boot-game-os programs:
      
        ps3flash read failed 0x2050000
        os_area_header_read: read error: os_area_header: Input/output error
        main:627: os_area_read_hp error.
        ERROR: can't change boot flag
      Signed-off-by: default avatarGeoff Levand <geoffrey.levand@am.sony.com>
      Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
      bc00351e
    • Benjamin Herrenschmidt's avatar
      powerpc/booke: Don't set DABR on 64-bit BookE, use DAC1 instead · c6c9eace
      Benjamin Herrenschmidt authored
      Also remove a duplicate setting of it in the context switch path
      on BookE.
      Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
      c6c9eace
    • Paul Mackerras's avatar
      powerpc/perf_counters: Reduce stack usage of power_check_constraints · e51ee31e
      Paul Mackerras authored
      Michael Ellerman reported stack-frame size warnings being produced
      for power_check_constraints(), which uses an 8*8 array of u64 and
      two 8*8 arrays of unsigned long, which are currently allocated on the
      stack, along with some other smaller variables.  These arrays come
      to 1.5kB on 64-bit or 1kB on 32-bit, which is a bit too much for the
      stack.
      
      This fixes the problem by putting these arrays in the existing
      per-cpu cpu_hw_counters struct.  This is OK because two of the call
      sites have interrupts disabled already; for the third call site we
      use get_cpu_var, which disables preemption, so we know we won't
      get a context switch while we're in power_check_constraints().
      Note that power_check_constraints() can be called during context
      switch but is not called from interrupts.
      Reported-by: default avatarMichael Ellerman <michael@ellerman.id.au>
      Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
      Cc: <stable@kernel.org)
      Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
      e51ee31e
    • Paul Mackerras's avatar
      powerpc: Fix bug where perf_counters breaks oprofile · a6dbf93a
      Paul Mackerras authored
      Currently there is a bug where if you use oprofile on a pSeries
      machine, then use perf_counters, then use oprofile again, oprofile
      will not work correctly; it will lose the PMU configuration the next
      time the hypervisor does a partition context switch, and thereafter
      won't count anything.
      
      Maynard Johnson identified the sequence causing the problem:
      - oprofile setup calls ppc_enable_pmcs(), which calls
        pseries_lpar_enable_pmcs, which tells the hypervisor that we want
        to use the PMU, and sets the "PMU in use" flag in the lppaca.
        This flag tells the hypervisor whether it needs to save and restore
        the PMU config.
      - The perf_counter code sets and clears the "PMU in use" flag directly
        as it context-switches the PMU between tasks, and leaves it clear
        when it finishes.
      - oprofile setup, called for a new oprofile run, calls ppc_enable_pmcs,
        which does nothing because it has already been called.  In particular
        it doesn't set the "PMU in use" flag.
      
      This fixes the problem by arranging for ppc_enable_pmcs to always set
      the "PMU in use" flag.  It makes the perf_counter code call
      ppc_enable_pmcs also rather than calling the lower-level function
      directly, and removes the setting of the "PMU in use" flag from
      pseries_lpar_enable_pmcs, since that is now done in its caller.
      
      This also removes the declaration of pasemi_enable_pmcs because it
      isn't defined anywhere.
      Reported-by: default avatarMaynard Johnson <mpjohn@us.ibm.com>
      Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
      Cc: <stable@kernel.org)
      Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
      a6dbf93a
    • Kumar Gala's avatar
      powerpc/85xx: Fix SMP compile error and allow NULL for smp_ops · 757cbd46
      Kumar Gala authored
      The following commit introduced a compile error since it removed
      the implementation of smp_85xx_basic_setup:
      
      commit 77c0a700
      Author: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Date:   Fri Aug 28 14:25:04 2009 +1000
      
          powerpc: Properly start decrementer on BookE secondary CPUs
      
      Make it so that smp_ops probe() and setup_cpu() can be set to NULL.
      Signed-off-by: default avatarKumar Gala <galak@kernel.crashing.org>
      Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
      757cbd46
    • Wolfram Sang's avatar
      powerpc/irq: Improve nanodoc · 8708d002
      Wolfram Sang authored
      The OF helpers look like nanodoc but are missing the header. Fix this and a
      typo (s/nad/and/) while we are here.
      Signed-off-by: default avatarWolfram Sang <w.sang@pengutronix.de>
      Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
      8708d002
  2. 02 Sep, 2009 6 commits
  3. 31 Aug, 2009 6 commits
  4. 28 Aug, 2009 21 commits
  5. 27 Aug, 2009 1 commit