01 Nov, 2006

2 commits

  • Changed qe_issue_cmd() to write cmd_input to the CECDR unmodified. It
    was treating cmd_input as a virtual address and tried to convert it to
    a physical address.

    Signed-off-by: Timur Tabi
    Signed-off-by: Paul Mackerras

    Timur Tabi
     
  • The 10Gigabit ethernet device drivers appear to be able to chew
    up all 256MB of TCE mappings on pSeries systems, as evidenced by
    numerous error messages:

    iommu_alloc failed, tbl c0000000010d5c48 vaddr c0000000d875eff0 npages 1

    Some experimentation indicates that this is essentially because
    one 1500 byte ethernet MTU gets mapped as a 64K DMA region when
    the large 64K pages are enabled. Thus, it doesn't take much to
    exhaust all of the available DMA mappings for a high-speed card.

    This patch changes the iommu allocator to work with its own
    unique, distinct page size. Although the patch is long, its
    actually quite simple: it just #defines a distinct IOMMU_PAGE_SIZE
    and then uses this in all the places that matter.

    As a side effect, it also dramatically improves network performance
    on platforms with H-calls on iommu translation inserts/removes (since
    we no longer call it 16 times for a 1500 bytes packet when the iommu HW
    is still 4k).

    In the future, we might want to make the IOMMU_PAGE_SIZE a variable
    in the iommu_table instance, thus allowing support for different HW
    page sizes in the iommu itself.

    Signed-off-by: Linas Vepstas
    Signed-off-by: Benjamin Herrenschmidt
    Acked-by: Olof Johansson
    Acked-by: Stephen Rothwell
    Signed-off-by: Paul Mackerras

    Linas Vepstas
     

25 Oct, 2006

3 commits

  • On CHRP platforms with only a 8259 controller, we should set the
    default IRQ host to the 8259 driver's one for the IRQ probing
    fallbacks to work in case the IRQ tree is incorrect (like on
    Pegasos for example). Without this fix, we get a bunch of WARN_ON's
    during boot.

    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Benjamin Herrenschmidt
     
  • This causes ipic_set_irq_type to set the handler directly rather
    than call set_irq_handler, which causes spinlock recursion because
    the lock is already held when ipic_set_irq_type is called.

    I'm also not convinced that ipic_set_irq_type should be changing the
    handler at all. There seem to be several controllers that don't and
    several that do. Those that do would break what appears to be a common
    usage of calling set_irq_chip_and_handler followed by set_irq_type, if a
    non-standard handler were to be used. OTOH, irq_create_of_mapping()
    doesn't set the handler, but only calls set_irq_type().

    This patch gets things working in the spinlock-debugging-enabled case,
    but I'm curious as to where the handler setting is ideally supposed to be
    done. I don't see any documentation on set_irq_type() that clarifies
    what the semantics are supposed to be.

    Signed-off-by: Scott Wood
    Signed-off-by: Paul Mackerras

    Scott Wood
     
  • MPC8323EMDS board ethernet interface with RMII uses the CLK16 divisor
    for the rx and tx clock, but the ucc_set_qe_mux_rxtx() function doesn't
    handle the CLK16 setting of the CMXUCR3 and CMXUCR4 registers. This
    fixes it.

    Signed-off-by: Dave Liu
    Signed-off-by: Paul Mackerras

    Liu Dave-r63238
     

23 Oct, 2006

2 commits


10 Oct, 2006

1 commit


07 Oct, 2006

2 commits

  • Remove struct pt_regs * from all handlers.
    Also remove the regs argument from get_irq() functions.
    Compile tested with arch/powerpc/config/* and
    arch/ppc/configs/prep_defconfig

    Signed-off-by: Olaf Hering
    Signed-off-by: Paul Mackerras

    Olaf Hering
     
  • Hrm, there's no way this ever built at time of merge. There's a missing } and
    the wrong type on phy_irq.

    Also, another const for get_property().

    CC arch/powerpc/sysdev/fsl_soc.o
    arch/powerpc/sysdev/fsl_soc.c: In function 'fs_enet_of_init':
    arch/powerpc/sysdev/fsl_soc.c:625: error: assignment of read-only variable 'phy_irq'
    arch/powerpc/sysdev/fsl_soc.c:625: warning: assignment makes integer from pointer without a cast
    arch/powerpc/sysdev/fsl_soc.c:661: warning: assignment discards qualifiers from pointer target type
    arch/powerpc/sysdev/fsl_soc.c:684: error: subscripted value is neither array nor pointer
    arch/powerpc/sysdev/fsl_soc.c:687: error: subscripted value is neither array nor pointer
    arch/powerpc/sysdev/fsl_soc.c:722: warning: ISO C90 forbids mixed declarations and code
    arch/powerpc/sysdev/fsl_soc.c:728: error: invalid storage class for function 'cpm_uart_of_init'
    arch/powerpc/sysdev/fsl_soc.c:798: error: initializer element is not constant
    arch/powerpc/sysdev/fsl_soc.c:798: error: expected declaration or statement at end of input
    make[1]: *** [arch/powerpc/sysdev/fsl_soc.o] Error 1

    Signed-off-by: Olof Johansson
    Signed-off-by: Paul Mackerras

    Olof Johansson
     

06 Oct, 2006

1 commit


05 Oct, 2006

2 commits

  • Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
    of passing regs around manually through all ~1800 interrupt handlers in the
    Linux kernel.

    The regs pointer is used in few places, but it potentially costs both stack
    space and code to pass it around. On the FRV arch, removing the regs parameter
    from all the genirq function results in a 20% speed up of the IRQ exit path
    (ie: from leaving timer_interrupt() to leaving do_IRQ()).

    Where appropriate, an arch may override the generic storage facility and do
    something different with the variable. On FRV, for instance, the address is
    maintained in GR28 at all times inside the kernel as part of general exception
    handling.

    Having looked over the code, it appears that the parameter may be handed down
    through up to twenty or so layers of functions. Consider a USB character
    device attached to a USB hub, attached to a USB controller that posts its
    interrupts through a cascaded auxiliary interrupt controller. A character
    device driver may want to pass regs to the sysrq handler through the input
    layer which adds another few layers of parameter passing.

    I've build this code with allyesconfig for x86_64 and i386. I've runtested the
    main part of the code on FRV and i386, though I can't test most of the drivers.
    I've also done partial conversion for powerpc and MIPS - these at least compile
    with minimal configurations.

    This will affect all archs. Mostly the changes should be relatively easy.
    Take do_IRQ(), store the regs pointer at the beginning, saving the old one:

    struct pt_regs *old_regs = set_irq_regs(regs);

    And put the old one back at the end:

    set_irq_regs(old_regs);

    Don't pass regs through to generic_handle_irq() or __do_IRQ().

    In timer_interrupt(), this sort of change will be necessary:

    - update_process_times(user_mode(regs));
    - profile_tick(CPU_PROFILING, regs);
    + update_process_times(user_mode(get_irq_regs()));
    + profile_tick(CPU_PROFILING);

    I'd like to move update_process_times()'s use of get_irq_regs() into itself,
    except that i386, alone of the archs, uses something other than user_mode().

    Some notes on the interrupt handling in the drivers:

    (*) input_dev() is now gone entirely. The regs pointer is no longer stored in
    the input_dev struct.

    (*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does
    something different depending on whether it's been supplied with a regs
    pointer or not.

    (*) Various IRQ handler function pointers have been moved to type
    irq_handler_t.

    Signed-Off-By: David Howells
    (cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)

    David Howells
     
  • * master.kernel.org:/pub/scm/linux/kernel/git/davej/configh:
    Remove all inclusions of

    Manually resolved trivial path conflicts due to removed files in
    the sound/oss/ subdirectory.

    Linus Torvalds
     

04 Oct, 2006

7 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (25 commits)
    [POWERPC] Add support for the mpc832x mds board
    [POWERPC] Add initial support for the e300c2 core
    [POWERPC] Add MPC8360EMDS default dts file
    [POWERPC] Add MPC8360EMDS board support
    [POWERPC] Add QUICC Engine (QE) infrastructure
    [POWERPC] Add QE device tree node definition
    [POWERPC] Don't try to just continue if xmon has no input device
    [POWERPC] Fix a printk in pseries_mpic_init_IRQ
    [POWERPC] Get default baud rate in udbg_scc
    [POWERPC] Fix zImage.coff on oldworld PowerMac
    [POWERPC] Fix xmon=off and cleanup xmon initialisation
    [POWERPC] Cleanup include/asm-powerpc/xmon.h
    [POWERPC] Update swim3 printk after blkdev.h change
    [POWERPC] Cell interrupt rework
    POWERPC: mpc82xx merge: board-specific/platform stuff(resend)
    POWERPC: 8272ads merge to powerpc: common stuff
    POWERPC: Added devicetree for mpc8272ads board
    [POWERPC] iSeries has no legacy I/O
    [POWERPC] implement BEGIN/END_FW_FTR_SECTION
    [POWERPC] iSeries does not need pcibios_fixup_resources
    ...

    Linus Torvalds
     
  • This adds defines for the hypertransport capability subtypes and starts
    using them a little.

    [akpm@osdl.org: fix typo]
    Signed-off-by: Eric W. Biederman
    Acked-by: Benjamin Herrenschmidt
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Eric W. Biederman
     
  • kbuild explicitly includes this at build time.

    Signed-off-by: Dave Jones

    Dave Jones
     
  • Add QUICC Engine (QE) configuration, header files, and
    QE management and library code that are used by QE devices
    drivers.

    Includes Leo's modifications up to, and including, the
    platform_device to of_device adaptation:

    "The series of patches add generic QE infrastructure called
    qe_lib, and MPC8360EMDS board support. Qe_lib is used by
    QE device drivers such as ucc_geth driver.

    This version updates QE interrupt controller to use new irq
    mapping mechanism, addresses all the comments received with
    last submission and includes some style fixes.

    v2: Change to use device tree for BCSR and MURAM;
    Remove I/O port interrupt handling code as it is not generic
    enough.

    v3: Address comments from Kumar; Update definition of several
    device tree nodes; Copyright style change."

    In addition, the following changes have been made:

    o removed typedefs
    o uint -> u32 conversions
    o removed following defines:
    QE_SIZEOF_BD, BD_BUFFER_ARG, BD_BUFFER_CLEAR, BD_BUFFER,
    BD_STATUS_AND_LENGTH_SET, BD_STATUS_AND_LENGTH, and BD_BUFFER_SET
    because they hid sizeof/in_be32/out_be32 operations from the reader.
    o fixed qe_snums_init() serial num assignment to use a const array
    o made CONFIG_UCC_FAST select UCC_SLOW
    o reduced NR_QE_IC_INTS from 128 to 64
    o remove _IO_BASE, etc. defines (not used)
    o removed irrelevant comments, added others to resemble removed BD_ defines
    o realigned struct definitions in headers
    o various other style fixes including things like pinMask -> pin_mask
    o fixed a ton of whitespace issues
    o marked ioregs as __be32/__be16
    o removed platform_device code and redundant get_qe_base()
    o removed redundant comments
    o added cpu_relax() to qe_reset
    o uncasted all get_property() assignments
    o eliminated unneeded casts
    o eliminated immrbar_phys_to_virt (not used)

    Signed-off-by: Li Yang
    Signed-off-by: Shlomi Gridish
    Signed-off-by: Kim Phillips
    Signed-off-by: Paul Mackerras

    Li Yang
     
  • Paul Mackerras
     
  • Many files include the filename at the beginning, serveral used a wrong one.

    Signed-off-by: Uwe Zeisberger
    Signed-off-by: Adrian Bunk

    Uwe Zeisberger
     
  • This has modules of common directories related to the
    mpc8272ADS board, mainly common cpm2 changes and fsl_soc.c
    portions related to the bitbang MDIO and other mechanisms specific
    for this family.

    Signed-off-by: Vitaly Bordug

    Vitaly Bordug
     

03 Oct, 2006

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (29 commits)
    [POWERPC] Fix rheap alignment problem
    [POWERPC] Use check_legacy_ioport() for ISAPnP
    [POWERPC] Avoid NULL pointer in gpio1_interrupt
    [POWERPC] Enable generic rtc hook for the MPC8349 mITX
    [POWERPC] Add powerpc get/set_rtc_time interface to new generic rtc class
    [POWERPC] Create a "wrapper" script and use it in arch/powerpc/boot
    [POWERPC] fix spin lock nesting in hvc_iseries
    [POWERPC] EEH failure to mark pci slot as frozen.
    [POWERPC] update powerpc defconfig files after libata kconfig breakage
    [POWERPC] enable sysrq in pmac32_defconfig
    [POWERPC] UPIO_TSI cleanup
    [POWERPC] rewrite mkprep and mkbugboot in sane C
    [POWERPC] maple/pci iomem annotations
    [POWERPC] powerpc oprofile __user annotations
    [POWERPC] cell spufs iomem annotations
    [POWERPC] NULL noise removal: spufs
    [POWERPC] ppc math-emu needs -fno-builtin-fabs for math.c and fabs.c
    [POWERPC] update mpc8349_itx_defconfig and remove some debug settings
    [POWERPC] Always call cede in pseries dedicated idle loop
    [POWERPC] Fix loop logic in irq_alloc_virt()
    ...

    Linus Torvalds
     

28 Sep, 2006

1 commit


27 Sep, 2006

1 commit

  • 0x08 is the HT capability, while PCI_CAP_ID_HT_IRQCONF would be
    the subtype 0x80 that mpic_scan_ht_pic() uses.
    Rename PCI_CAP_ID_HT_IRQCONF into PCI_CAP_ID_HT.

    And by the way, use it in the ipath driver instead of defining its
    own HT_CAPABILITY_ID.

    Signed-off-by: Brice Goglin
    Signed-off-by: Greg Kroah-Hartman

    Brice Goglin
     

22 Sep, 2006

6 commits

  • This patch causes fsl_soc.h to import the definition of phys_addr_t
    itself, rather than relying on its includer to do so.

    Signed-off-by: Scott Wood
    Signed-off-by: Paul Mackerras

    Scott Wood
     
  • This patch fixes the assignment of pending registers to IRQ numbers for
    the IPIC; the code previously assigned all IRQs to the high pending word
    regardless of which word the interrupt belonged to.

    Signed-off-by: Scott Wood
    Signed-off-by: Paul Mackerras

    Scott Wood
     
  • The fs_no mean used to be fs_enet driver driven, hence it was an
    enumeration across all the possible fs_enet "users" in the SoC. Now, with
    QE on the pipeline, and to make DTS descriptions more clear, fs_no features
    relevant SoC part number, with additional field to describe the SoC type.

    Another reason for that is now not only fs_enet is going to utilize those
    stuff. There might be UART, HLDC, and even USB, so to prevent confusion and
    be ready for upcoming OF_device transfer, fs_enet and cpm_uart drivers were
    updated in that concern, as well as the relevant DTS.

    Signed-off-by: Vitaly Bordug

    Vitaly Bordug
     
  • Incorporating the new way of cpm2 immr access, introduced in the previous
    patch, into CPM2 peripheral devices (fs_enet and cpm_uart). Both ppc and
    powerpc approved working( real actions taken in powerpc only, ppc just
    has a wrapper to keep init stuff consistent).

    Signed-off-by: Vitaly Bordug

    Vitaly Bordug
     
  • The stuff below cleans up the code attempting to remap the whole cpm2_immr
    early, as well as places happily assuming that fact. This is more like the 2.4
    legacy stuff, and is at least confusing and unclear now.

    To keep the world comfortable, a new mechanism is introduced: before accessing
    specific immr register/register set, one needs to map it, using cpm2_map(),
    for instance, access to CPM command register will look like
    volatile cpm_cpm2_t *cp = cpm2_map(im_cpm);
    keeping the code clear, yet without "already defined somewhere" cpm2_immr.

    So far, unmapping code is not implemented, but it's not a big deal to add it,
    if the whole idea makes sense.

    Signed-off-by: Vitaly Bordug

    Vitaly Bordug
     
  • This moves the cpm2 common code and PIC stuff to the powerpc. Most of the files
    were just copied from ppc/, with minor tuning to make it compile, and, subsequently, work.

    Signed-off-by: Vitaly Bordug

    Vitaly Bordug
     

21 Sep, 2006

1 commit

  • This patch contains necessary modifications to support the CPM2 SoC peripherals.
    For the time being, those are fs_enet Ethernet driver and cpm_uart serial.
    Written initially to support mpc8560, it also suites to the part of the large PQ2
    (more specifically, mpc8260) family.

    Signed-off-by: Vitaly Bordug

    Vitaly Bordug
     

14 Sep, 2006

1 commit


13 Sep, 2006

1 commit


31 Aug, 2006

1 commit


30 Aug, 2006

3 commits

  • This adds a new hardware information table for mpic. This enables
    the mpic code to deal with mpic controllers with different register
    layouts and hardware behaviours.

    This introduces CONFIG_MPIC_WEIRD. For boards with non standard mpic
    controllers, select CONFIG_MPIC_WEIRD and add its hardware information
    in the mpic_infos[] array.

    TSI108/109 PIC takes the first index of weird hardware information
    table. :) The table can be extended. The Tsi108/109 PIC looks like
    standard OpenPIC but, in fact, is different in register mapping and
    behavior.

    The patch does not affect the behavior of standard mpic. If
    CONFIG_MPIC_WEIRD is not defined, the code is essentially identical to
    the current code.

    [benh@kernel.crashing.org:
    This patch is a slightly cleaned up version of Zang Roy's support for
    the TSI108 MPIC variant. It also fixes up MPC7448_hpc2 to use the new
    version of the type macros and changes the way MPIC is selected in
    Kconfig to better match what is done for other system devices.
    ]

    Signed-off-by: Roy Zang
    Signed-off-by: Benjamin Herrenschmidt
    Signed-off-by: Paul Mackerras

    Zang Roy-r61911
     
  • This converts ipic code to Benh's IRQ mods. For the IPIC, IRQ sense values in the device tree equal those in include/linux/irq.h; that's 8 for low assertion (most internal IRQs on mpc83xx), and 2 for high-to-low change.

    spinlocks added to [un]mask, ack operations; default handler and type now set in host_map; and redundant condition check eliminated.

    Signed-off-by: Kim Phillips
    Signed-off-by: Li Yang
    Signed-off-by: Paul Mackerras

    Kim Phillips
     
  • Keep from breaking 83xx arch/ppc build. Back up old school arch/powerpc/sysdev/ipic.[hc] to arch/ppc/syslib.

    Signed-off-by: Kim Phillips
    Signed-off-by: Paul Mackerras

    Kim Phillips
     

25 Aug, 2006

1 commit


23 Aug, 2006

2 commits


18 Aug, 2006

1 commit