1. 18 8月, 2006 4 次提交
  2. 17 8月, 2006 6 次提交
  3. 08 8月, 2006 2 次提交
    • H
      [POWERPC] Fix might-sleep warning on removing cpus · 81b73dd9
      Haren Myneni 提交于
      Noticing the following might_sleep warning (dump_stack()) during kdump
      testing when CONFIG_DEBUG_SPINLOCK_SLEEP is enabled. All secondary CPUs
      will be calling rtas_set_indicator with interrupts disabled to remove
      them from global interrupt queue.
      
      BUG: sleeping function called from invalid context at
      arch/powerpc/kernel/rtas.c:463
      in_atomic():1, irqs_disabled():1
      Call Trace:
      [C00000000FFFB970] [C000000000010234] .show_stack+0x68/0x1b0 (unreliable)
      [C00000000FFFBA10] [C000000000059354] .__might_sleep+0xd8/0xf4
      [C00000000FFFBA90] [C00000000001D1BC] .rtas_busy_delay+0x20/0x5c
      [C00000000FFFBB20] [C00000000001D8A8] .rtas_set_indicator+0x6c/0xcc
      [C00000000FFFBBC0] [C000000000048BF4] .xics_teardown_cpu+0x118/0x134
      [C00000000FFFBC40] [C00000000004539C]
      .pseries_kexec_cpu_down_xics+0x74/0x8c
      [C00000000FFFBCC0] [C00000000002DF08] .crash_ipi_callback+0x15c/0x188
      [C00000000FFFBD50] [C0000000000296EC] .smp_message_recv+0x84/0xdc
      [C00000000FFFBDC0] [C000000000048E08] .xics_ipi_dispatch+0xf0/0x130
      [C00000000FFFBE50] [C00000000009EF10] .handle_IRQ_event+0x7c/0xf8
      [C00000000FFFBF00] [C0000000000A0A14] .handle_percpu_irq+0x90/0x10c
      [C00000000FFFBF90] [C00000000002659C] .call_handle_irq+0x1c/0x2c
      [C00000000058B9C0] [C00000000000CA10] .do_IRQ+0xf4/0x1a4
      [C00000000058BA50] [C0000000000044EC] hardware_interrupt_entry+0xc/0x10
       --- Exception: 501 at .plpar_hcall_norets+0x14/0x1c
         LR = .pseries_dedicated_idle_sleep+0x190/0x1d4
      [C00000000058BD40] [C00000000058BDE0] 0xc00000000058bde0 (unreliable)
      [C00000000058BDF0] [C00000000001270C] .cpu_idle+0x10c/0x1e0
      [C00000000058BE70] [C000000000009274] .rest_init+0x44/0x5c
      
      To fix this issue, rtas_set_indicator_fast() is added so that will not
      wait for RTAS 'busy' delay and this new function is used for kdump (in
      xics_teardown_cpu()) and for CPU hotplug ( xics_migrate_irqs_away() and
      xics_setup_cpu()).
      
      Note that the platform architecture spec says that set-indicator
      on the indicator we're using here is not permitted to return the
      busy or extended busy status codes.
      Signed-off-by: NHaren Myneni <haren@us.ibm.com>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      81b73dd9
    • S
      [POWERPC] fix PMU initialization on pseries lpar · dcc42f48
      Sonny Rao 提交于
      We should not be calling power4_enable_pmcs() in
      pseries_lpar_enable_pmcs(); just doing the hypercall is sufficient.
      Prior to 2.6.15 we did not call power4_enable_pmcs() for an lpar.
      
      power4_enable_pmcs() tries to read the hid0 register which is no
      longer legal for an lpar in newer Power processors.
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      dcc42f48
  4. 01 8月, 2006 4 次提交
    • M
      [PATCH] powermac: More powermac backlight fixes · 4b755999
      Michael Hanselmann 提交于
      This patch fixes several problems:
      - The legacy backlight value might be set at interrupt time. Introduced
        a worker to prevent it from directly calling the backlight code.
      - via-pmu allows the backlight to be grabbed, in which case we need to
        prevent other kernel code from changing the brightness.
      - Don't send PMU requests in via-pmu-backlight when the machine is about
        to sleep or waking up.
      - More Kconfig fixes.
      Signed-off-by: NMichael Hanselmann <linux-kernel@hansmi.ch>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: "Antonino A. Daplas" <adaplas@pol.net>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      4b755999
    • R
      [PATCH] vDSO hash-style fix · 0b0bf7a3
      Roland McGrath 提交于
      The latest toolchains can produce a new ELF section in DSOs and
      dynamically-linked executables.  The new section ".gnu.hash" replaces
      ".hash", and allows for more efficient runtime symbol lookups by the
      dynamic linker.  The new ld option --hash-style={sysv|gnu|both} controls
      whether to produce the old ".hash", the new ".gnu.hash", or both.  In some
      new systems such as Fedora Core 6, gcc by default passes --hash-style=gnu
      to the linker, so that a standard invocation of "gcc -shared" results in
      producing a DSO with only ".gnu.hash".  The new ".gnu.hash" sections need
      to be dealt with the same way as ".hash" sections in all respects; only the
      dynamic linker cares about their contents.  To work with older dynamic
      linkers (i.e.  preexisting releases of glibc), a binary must have the old
      ".hash" section.  The --hash-style=both option produces binaries that a new
      dynamic linker can use more efficiently, but an old dynamic linker can
      still handle.
      
      The new section runs afoul of the custom linker scripts used to build vDSO
      images for the kernel.  On ia64, the failure mode for this is a boot-time
      panic because the vDSO's PT_IA_64_UNWIND segment winds up ill-formed.
      
      This patch addresses the problem in two ways.
      
      First, it mentions ".gnu.hash" in all the linker scripts alongside ".hash".
       This produces correct vDSO images with --hash-style=sysv (or old tools),
      with --hash-style=gnu, or with --hash-style=both.
      
      Second, it passes the --hash-style=sysv option when building the vDSO
      images, so that ".gnu.hash" is not actually produced.  This is the most
      conservative choice for compatibility with any old userland.  There is some
      concern that some ancient glibc builds (though not any known old production
      system) might choke on --hash-style=both binaries.  The optimizations
      provided by the new style of hash section do not really matter for a DSO
      with a tiny number of symbols, as the vDSO has.  If someone wants to use
      =gnu or =both for their vDSO builds and worry less about that
      compatibility, just change the option and the linker script changes will
      make any choice work fine.
      Signed-off-by: NRoland McGrath <roland@redhat.com>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Sam Ravnborg <sam@ravnborg.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      0b0bf7a3
    • C
      [PATCH] cpu hotplug: replace __devinit* with __cpuinit* for cpu notifications · 8c78f307
      Chandra Seetharaman 提交于
      Few of the callback functions and notifier blocks that are associated with cpu
      notifications incorrectly have __devinit and __devinitdata.  They should be
      __cpuinit and __cpuinitdata instead.
      
      It makes no functional difference but wastes text area when CONFIG_HOTPLUG is
      enabled and CONFIG_HOTPLUG_CPU is not.
      
      This patch fixes all those instances.
      Signed-off-by: NChandra Seetharaman <sekharan@us.ibm.com>
      Cc: Ashok Raj <ashok.raj@intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      8c78f307
    • H
      [PATCH] panic_on_oops: remove ssleep() · cea6a4ba
      Horms 提交于
      This patch is part of an effort to unify the panic_on_oops behaviour across
      all architectures that implement it.
      
      It was pointed out to me by Andi Kleen that if an oops has occured in
      interrupt context, then calling sleep() in the oops path will only cause a
      panic, and that it would be really better for it not to be in the path at
      all.
      
      This patch removes the ssleep() call and reworks the console message
      accordinly.  I have a slght concern that the resulting console message is
      too long, feedback welcome.
      
      For powerpc it also unifies the 32bit and 64bit behaviour.
      
      Fror x86_64, this patch only updates the console message, as ssleep() is
      already not present.
      Signed-off-by: NHorms <horms@verge.net.au>
      Acked-by: NPaul Mackerras <paulus@samba.org>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Chris Zankel <chris@zankel.net>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      cea6a4ba
  5. 31 7月, 2006 2 次提交
  6. 29 7月, 2006 1 次提交
    • O
      [POWERPC] force 64bit mode in fwnmi handlers to workaround firmware bugs · 9fc0a92c
      Olaf Hering 提交于
      The firmware of POWER4 and JS20 systems does not switch the cpu to 64bit
      mode when the registered system_reset and machine_check handlers get called.
      If a 32bit process runs on that cpu at the time of the event, the cpu
      remains in 32bit mode. xmon and kdump can not deal with it, the result is
      an error like 'Bad kernel stack pointer fff2aad0 at 3200'.
      xmon just loses some register info, but booting the kdump kernel usually fails.
      
      Both handlers are not hot paths.  Duplicate the EXCEPTION_PROLOG_PSERIES macro
      and add two instructions to switch to 64bit:
      
       li     r11,5;
       rldimi r10,r11,61,0;
      Signed-off-by: NOlaf Hering <olh@suse.de>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      9fc0a92c
  7. 28 7月, 2006 3 次提交
  8. 25 7月, 2006 8 次提交
  9. 11 7月, 2006 5 次提交
    • M
      [PATCH] powermac: Combined fixes for backlight code · e01af038
      Michael Hanselmann 提交于
      This patch fixes several problems:
      - pmac_backlight_key() is called under interrupt context, and therefore
        can't use mutexes or semaphores, so defer the backlight level for
        later, as it's not critical (original code by Aristeu S. Rozanski F.
        <aris@valeta.org>).
      - Add exports for functions that might be called from modules
      - Fix Kconfig depdencies on PMAC_BACKLIGHT.
      - Fix locking issues on calls from inside the driver (reported by
        Aristeu S. Rozanski F., too)
      - Fix wrong calculation of backlight values in some of the drivers
      - Replace pmac_backlight_key_up/down by inline functions
      
      [akpm@osdl.org: fix function prototypes]
      Signed-off-by: NMichael Hanselmann <linux-kernel@hansmi.ch>
      Acked-by: NAristeu S. Rozanski F. <aris@valeta.org>
      Acked-by: NRene Nussbaumer <linux-kernel@killerfox.forkbomb.ch>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      e01af038
    • S
      [PATCH] powerpc: make OF interrupt tree parsing more strict · 58d383a6
      Segher Boessenkool 提交于
      This patch fixes a bit of boundchecking in the new Open Firmware interrupt
      tree parsing code.  It's important that it fails when things aren't correct in
      order to trigger fallback mecanisms that are necessary to make some machines
      work properly.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      58d383a6
    • B
      [PATCH] powerpc: fix MPIC OF tree parsing on Apple quad g5 · 06fe98e6
      Benjamin Herrenschmidt 提交于
      The quad g5 currently doesn't boot due to two problems.  This patch fixes the
      first one: Apple new way of doing interrupt specifiers in OF for devices using
      the HT APIC isn't properly parsed by the new MPIC driver code.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      06fe98e6
    • B
      [PATCH] powerpc: fix trigger handling in the new irq code · 6e99e458
      Benjamin Herrenschmidt 提交于
      This patch slightly reworks the new irq code to fix a small design error.  I
      removed the passing of the trigger to the map() calls entirely, it was not a
      good idea to have one call do two different things.  It also fixes a couple of
      corner cases.
      
      Mapping a linux virtual irq to a physical irq now does only that.  Setting the
      trigger is a different action which has a different call.
      
      The main changes are:
      
      - I no longer call host->ops->map() for an already mapped irq, I just return
        the virtual number that was already mapped.  It was called before to give an
        opportunity to change the trigger, but that was causing issues as that could
        happen while the interrupt was in use by a device, and because of the
        trigger change, map would potentially muck around with things in a racy way.
         That was causing much burden on a given's controller implementation of
        map() to get it right.  This is much simpler now.  map() is only called on
        the initial mapping of an irq, meaning that you know that this irq is _not_
        being used.  You can initialize the hardware if you want (though you don't
        have to).
      
      - Controllers that can handle different type of triggers (level/edge/etc...)
        now implement the standard irq_chip->set_type() call as defined by the
        generic code.  That means that you can use the standard set_irq_type() to
        configure an irq line manually if you wish or (though I don't like that
        interface), pass explicit trigger flags to request_irq() as defined by the
        generic kernel interfaces.  Also, using those interfaces guarantees that
        your controller set_type callback is called with the descriptor lock held,
        thus providing locking against activity on the same interrupt (including
        mask/unmask/etc...) automatically.  A result is that, for example, MPIC's
        own map() implementation calls irq_set_type(NONE) to configure the hardware
        to the default triggers.
      
      - To allow the above, the irq_map array entry for the new mapped interrupt
        is now set before map() callback is called for the controller.
      
      - The irq_create_of_mapping() (also used by irq_of_parse_and_map()) function
        for mapping interrupts from the device-tree now also call the separate
        set_irq_type(), and only does so if there is a change in the trigger type.
      
      - While I was at it, I changed pci_read_irq_line() (which is the helper I
        would expect most archs to use in their pcibios_fixup() to get the PCI
        interrupt routing from the device tree) to also handle a fallback when the
        DT mapping fails consisting of reading the PCI_INTERRUPT_PIN to know wether
        the device has an interrupt at all, and the the PCI_INTERRUPT_LINE to get an
        interrupt number from the device.  That number is then mapped using the
        default controller, and the trigger is set to level low.  That default
        behaviour works for several platforms that don't have a proper interrupt
        tree like Pegasos.  If it doesn't work for your platform, then either
        provide a proper interrupt tree from the firmware so that fallback isn't
        needed, or don't call pci_read_irq_line()
      
      - Add back a bit that got dropped by my main rework patch for properly
        clearing pending IPIs on pSeries when using a kexec
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      6e99e458
    • J
      [PATCH] tty: Remove include of screen_info.h from tty.h · 894673ee
      Jon Smirl 提交于
      screen_info.h doesn't have anything to do with the tty layer and shouldn't be
      included by tty.h.  This patches removes the include and modifies all users to
      directly include screen_info.h.  struct screen_info is mainly used to
      communicate with the console drivers in drivers/video/console.  Note that this
      patch touches every arch and I have no way of testing it.  If there is a
      mistake the worst thing that will happen is a compile error.
      
      [akpm@osdl.org: fix arm build]
      [akpm@osdl.org: fix alpha build]
      Signed-off-by: NJon Smirl <jonsmir@gmail.com>
      Signed-off-by: NAntonino Daplas <adaplas@pol.net>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      894673ee
  10. 06 7月, 2006 1 次提交
    • B
      [PATCH] powerpc: Fix loss of interrupts with MPIC · ba1826e5
      Benjamin Herrenschmidt 提交于
      With the new interrupt rework, an interrupt "host" map() callback can be
      called after the interrupt is already active.
      
      It's called again for an already mapped interrupt to allow changing the
      trigger setup, and currently this is not guarded with a test of wether
      the interrupt is requested or not.
      
      I plan to change some of this logic to be a bit less lenient against
      random reconfiguring of live interrupts but just not yet.
      
      The ported MPIC driver has a bug where when that happens, it will mask
      the interrupt.  This changes it to preserve the previous masking of the
      interrupt instead.
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      ba1826e5
  11. 04 7月, 2006 4 次提交