Changeset 371bd7d in mainline for kernel/arch/ppc32/src


Ignore:
Timestamp:
2010-03-27T09:22:17Z (16 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/fix-logger-deadlock, topic/msim-upgrade, topic/simplify-dev-export
Children:
36a75a2
Parents:
cd82bb1 (diff), eaf22d4 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes.

Location:
kernel/arch/ppc32/src
Files:
2 added
7 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/ppc32/src/cpu/cpu.c

    rcd82bb1 r371bd7d  
    5454void cpu_print_report(cpu_t *m)
    5555{
    56         char *name;
     56        const char *name;
    5757       
    5858        switch (m->arch.version) {
  • kernel/arch/ppc32/src/ddi/ddi.c

    rcd82bb1 r371bd7d  
    3535#include <ddi/ddi.h>
    3636#include <proc/task.h>
    37 #include <arch/types.h>
     37#include <typedefs.h>
    3838
    3939/** Enable I/O space range for task.
  • kernel/arch/ppc32/src/interrupt.c

    rcd82bb1 r371bd7d  
    3636#include <interrupt.h>
    3737#include <arch/interrupt.h>
    38 #include <arch/types.h>
     38#include <typedefs.h>
    3939#include <arch.h>
    4040#include <time/clock.h>
  • kernel/arch/ppc32/src/mm/as.c

    rcd82bb1 r371bd7d  
    3535#include <arch/mm/as.h>
    3636#include <genarch/mm/as_pt.h>
     37#include <genarch/mm/page_pt.h>
    3738#include <genarch/mm/asid_fifo.h>
    3839#include <arch.h>
  • kernel/arch/ppc32/src/mm/page.c

    rcd82bb1 r371bd7d  
    5151            KA2PA(KERNEL_ADDRESS_SPACE_END_ARCH))
    5252                panic("Unable to map physical memory %p (%" PRIs " bytes).",
    53                     physaddr, size)
     53                    physaddr, size);
    5454       
    5555        uintptr_t virtaddr = PA2KA(last_frame);
  • kernel/arch/ppc32/src/mm/tlb.c

    rcd82bb1 r371bd7d  
    3838#include <interrupt.h>
    3939#include <mm/as.h>
     40#include <mm/page.h>
    4041#include <arch.h>
    4142#include <print.h>
     
    113114static void pht_refill_fail(uintptr_t badvaddr, istate_t *istate)
    114115{
    115         char *symbol;
    116         char *sym2;
    117 
    118         symbol = symtab_fmt_name_lookup(istate->pc);
    119         sym2 = symtab_fmt_name_lookup(istate->lr);
    120 
     116        const char *symbol = symtab_fmt_name_lookup(istate->pc);
     117        const char *sym2 = symtab_fmt_name_lookup(istate->lr);
     118       
    121119        fault_if_from_uspace(istate,
    122120            "PHT Refill Exception on %p.", badvaddr);
  • kernel/arch/ppc32/src/ppc32.c

    rcd82bb1 r371bd7d  
    3939#include <genarch/kbrd/kbrd.h>
    4040#include <arch/interrupt.h>
     41#include <interrupt.h>
    4142#include <genarch/fb/fb.h>
    4243#include <genarch/fb/visuals.h>
     
    4445#include <genarch/ofw/pci.h>
    4546#include <userspace.h>
     47#include <mm/page.h>
    4648#include <proc/uarg.h>
    4749#include <console/console.h>
     50#include <sysinfo/sysinfo.h>
    4851#include <ddi/irq.h>
    4952#include <arch/drivers/pic.h>
    5053#include <align.h>
    5154#include <macros.h>
    52 #include <string.h>
     55#include <str.h>
    5356#include <print.h>
    5457
     
    5760
    5861bootinfo_t bootinfo;
     62
     63static cir_t pic_cir;
     64static void *pic_cir_arg;
    5965
    6066/** Performs ppc32-specific initialization before main_bsp() is called. */
     
    185191        if (assigned_address) {
    186192                /* Initialize PIC */
    187                 cir_t cir;
    188                 void *cir_arg;
    189                 pic_init(assigned_address[0].addr, PAGE_SIZE, &cir, &cir_arg);
    190                
     193                pic_init(assigned_address[0].addr, PAGE_SIZE, &pic_cir,
     194                    &pic_cir_arg);
     195
    191196#ifdef CONFIG_MAC_KBD
    192197                uintptr_t pa = assigned_address[0].addr + 0x16000;
     
    200205                /* Initialize I/O controller */
    201206                cuda_instance_t *cuda_instance =
    202                     cuda_init(cuda, IRQ_CUDA, cir, cir_arg);
     207                    cuda_init(cuda, IRQ_CUDA, pic_cir, pic_cir_arg);
    203208                if (cuda_instance) {
    204209                        kbrd_instance_t *kbrd_instance = kbrd_init();
     
    210215                        }
    211216                }
     217
     218                /*
     219                 * This is the necessary evil until the userspace driver is entirely
     220                 * self-sufficient.
     221                 */
     222                sysinfo_set_item_val("cuda", NULL, true);
     223                sysinfo_set_item_val("cuda.inr", NULL, IRQ_CUDA);
     224                sysinfo_set_item_val("cuda.address.physical", NULL, pa);
     225                sysinfo_set_item_val("cuda.address.kernel", NULL,
     226                    (uintptr_t) cuda);
    212227#endif
    213228        }
     
    215230        /* Consider only a single device for now */
    216231        return false;
     232}
     233
     234void irq_initialize_arch(irq_t *irq)
     235{
     236        irq->cir = pic_cir;
     237        irq->cir_arg = pic_cir_arg;
     238        irq->preack = true;
    217239}
    218240
Note: See TracChangeset for help on using the changeset viewer.