1. 23 4月, 2014 1 次提交
  2. 14 8月, 2013 1 次提交
    • B
      powerpc/pmac: Early debug output on screen on 64-bit macs · 7191b615
      Benjamin Herrenschmidt 提交于
      We have a bunch of CONFIG_PPC_EARLY_DEBUG_* options that are intended
      for bringup/debug only. They hard wire a machine specific udbg backend
      very early on (before we even probe the platform), and use whatever
      tricks are available on each machine/cpu to be able to get some kind
      of output out there early on.
      
      So far, on powermac with no serial ports, we have CONFIG_PPC_EARLY_DEBUG_BOOTX
      to use the low-level btext engine on the screen, but it doesn't do much, at
      least on 64-bit. It only really gets enabled after the platform has been
      probed and the MMU enabled.
      
      This adds a way to enable it much earlier. From prom_init.c (while still
      running with Open Firmware), we grab the screen details and set things up
      using the physical address of the frame buffer.
      
      Then btext itself uses the "rm_ci" feature of the 970 processor (Real
      Mode Cache Inhibited) to access it while in real mode.
      
      We need to do a little bit of reorg of the btext code to inline things
      better, in order to limit how much we touch memory while in this mode as
      the consequences might be ... interesting.
      
      This successfully allowed me to debug problems early on with the G5
      (related to gold being broken vs. ppc64 kernels).
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      7191b615
  3. 10 1月, 2013 1 次提交
    • A
      powerpc: Relocate prom_init.c on 64bit · 5ac47f7a
      Anton Blanchard 提交于
      The ppc64 kernel can get loaded at any address which means
      our very early init code in prom_init.c must be relocatable. We do
      this with a pretty nasty RELOC() macro that we wrap accesses of
      variables with. It is very fragile and sometimes we forget to add a
      RELOC() to an uncommon path or sometimes a compiler change breaks it.
      
      32bit has a much more elegant solution where we build prom_init.c
      with -mrelocatable and then process the relocations manually.
      Unfortunately we can't do the equivalent on 64bit and we would
      have to build the entire kernel relocatable (-pie), resulting in a
      large increase in kernel footprint (megabytes of relocation data).
      The relocation data will be marked __initdata but it still creates
      more pressure on our already tight memory layout at boot.
      
      Alan Modra pointed out that the 64bit ABI is relocatable even
      if we don't build with -pie, we just need to relocate the TOC.
      This patch implements that idea and relocates the TOC entries of
      prom_init.c. An added bonus is there are very few relocations to
      process which helps keep boot times on simulators down.
      
      gcc does not put 64bit integer constants into the TOC but to be
      safe we may want a build time script which passes through the
      prom_init.c TOC entries to make sure everything looks reasonable.
      Signed-off-by: NAnton Blanchard <anton@samba.org>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      5ac47f7a
  4. 20 9月, 2011 2 次提交
    • B
      powerpc/powernv: Get kernel command line accross OPAL takeover · 817c21ad
      Benjamin Herrenschmidt 提交于
      We stash it in boot_command_line which isn't in BSS and so won't
      be overwritten. We then use that as a default cmd_line before
      we walk the device-tree.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      817c21ad
    • B
      powerpc/powernv: Add OPAL takeover from PowerVM · 27f44888
      Benjamin Herrenschmidt 提交于
      On machines supporting the OPAL firmware version 1, the system
      is initially booted under pHyp. We then use a special hypercall
      to verify if OPAL is available and if it is, we then trigger
      a "takeover" which disables pHyp and loads the OPAL runtime
      firmware, giving control to the kernel in hypervisor mode.
      
      This patch add the necessary code to detect that the OPAL takeover
      capability is present when running under PowerVM (aka pHyp) and
      perform said takeover to get hypervisor control of the processor.
      
      To perform the takeover, we must first use RTAS (within Open
      Firmware runtime environment) to start all processors & threads,
      in order to give control to OPAL on all of them. We then call
      the takeover hypercall on everybody, OPAL will re-enter the kernel
      main entry point passing it a flat device-tree.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      27f44888
  5. 08 7月, 2010 1 次提交
    • S
      powerpc: Fix compile errors in prom_init_check for gcc 4.5 · 5afd878a
      Stephen Rothwell 提交于
      Just whitelist these extra compiler generated symbols.
      Fixes these errors:
      
      Error: External symbol '_restgpr0_14' referenced from prom_init.c
      Error: External symbol '_restgpr0_20' referenced from prom_init.c
      Error: External symbol '_restgpr0_22' referenced from prom_init.c
      Error: External symbol '_restgpr0_24' referenced from prom_init.c
      Error: External symbol '_restgpr0_25' referenced from prom_init.c
      Error: External symbol '_restgpr0_26' referenced from prom_init.c
      Error: External symbol '_restgpr0_27' referenced from prom_init.c
      Error: External symbol '_restgpr0_28' referenced from prom_init.c
      Error: External symbol '_restgpr0_29' referenced from prom_init.c
      Error: External symbol '_restgpr0_31' referenced from prom_init.c
      Error: External symbol '_savegpr0_14' referenced from prom_init.c
      Error: External symbol '_savegpr0_20' referenced from prom_init.c
      Error: External symbol '_savegpr0_22' referenced from prom_init.c
      Error: External symbol '_savegpr0_24' referenced from prom_init.c
      Error: External symbol '_savegpr0_25' referenced from prom_init.c
      Error: External symbol '_savegpr0_26' referenced from prom_init.c
      Error: External symbol '_savegpr0_27' referenced from prom_init.c
      Error: External symbol '_savegpr0_28' referenced from prom_init.c
      Error: External symbol '_savegpr0_29' referenced from prom_init.c
      Error: External symbol '_savegpr0_31' referenced from prom_init.c
      Signed-off-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Acked-by: NSegher Boessenkool <segher@kernel.crashing.org>
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      5afd878a
  6. 11 3月, 2009 1 次提交
  7. 21 10月, 2008 1 次提交
  8. 16 6月, 2008 1 次提交
  9. 23 5月, 2008 1 次提交
  10. 24 4月, 2008 1 次提交