Changeset 9693835 in mainline for kernel/arch/sparc64/src/console.c


Ignore:
Timestamp:
2009-03-13T09:00:58Z (16 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
0b16e9d
Parents:
648c9d9
Message:

get back support for framebuffer and keyboard for sparc64 (generic)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/sparc64/src/console.c

    r648c9d9 r9693835  
    6363{
    6464#ifdef CONFIG_FB
    65         ofw_tree_property_t *prop;
    66         ofw_tree_node_t *screen;
    67         ofw_tree_node_t *keyboard;
     65        ofw_tree_property_t *prop_scr = ofw_tree_getprop(aliases, "screen");
     66        if (!prop_scr)
     67                panic("Cannot find property 'screen'.");
     68        if (!prop_scr->value)
     69                panic("Cannot find screen alias.");
     70        ofw_tree_node_t *screen = ofw_tree_lookup(prop_scr->value);
     71        if (!screen)
     72                panic("Cannot find %s.", prop_scr->value);
    6873       
    69         prop = ofw_tree_getprop(aliases, "screen");
    70         if (!prop)
    71                 panic("Cannot find property 'screen'.");
    72         if (!prop->value)
    73                 panic("Cannot find screen alias.");
    74         screen = ofw_tree_lookup(prop->value);
    75         if (!screen)
    76                 panic("Cannot find %s.", prop->value);
     74        scr_init(screen);
     75#endif
    7776
    78         scr_init(screen);
    79 
    80         prop = ofw_tree_getprop(aliases, "keyboard");
    81         if (!prop)
     77#ifdef CONFIG_SUN_KBD
     78        ofw_tree_property_t *prop_kbd = ofw_tree_getprop(aliases, "keyboard");
     79        if (!prop_kbd)
    8280                panic("Cannot find property 'keyboard'.");
    83         if (!prop->value)
     81        if (!prop_kbd->value)
    8482                panic("Cannot find keyboard alias.");
    85         keyboard = ofw_tree_lookup(prop->value);
     83        ofw_tree_node_t *keyboard = ofw_tree_lookup(prop_kbd->value);
    8684        if (!keyboard)
    87                 panic("Cannot find %s.", prop->value);
    88 
     85                panic("Cannot find %s.", prop_kbd->value);
     86       
    8987        kbd_init(keyboard);
    90 #else
    91         panic("Standard console requires FB, "
    92               "but the kernel is not compiled with FB support.");
    9388#endif
    9489}
Note: See TracChangeset for help on using the changeset viewer.