Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/console/cmd.c

    rb2fa1204 r2f33fbc  
    4545#include <console/kconsole.h>
    4646#include <print.h>
    47 #include <log.h>
    4847#include <panic.h>
    4948#include <typedefs.h>
     
    640639        for (i = 0; basic_commands[i]; i++) {
    641640                if (!cmd_register(basic_commands[i])) {
    642                         log(LF_OTHER, LVL_ERROR,
    643                             "Cannot register command %s",
     641                        printf("Cannot register command %s\n",
    644642                            basic_commands[i]->name);
    645643                }
     
    658656       
    659657        size_t len = 0;
    660         list_foreach(cmd_list, link, cmd_info_t, hlp) {
     658        list_foreach(cmd_list, cur) {
     659                cmd_info_t *hlp;
     660                hlp = list_get_instance(cur, cmd_info_t, link);
     661               
    661662                spinlock_lock(&hlp->lock);
    662663                if (str_length(hlp->name) > len)
     
    667668        unsigned int _len = (unsigned int) len;
    668669        if ((_len != len) || (((int) _len) < 0)) {
    669                 log(LF_OTHER, LVL_ERROR, "Command length overflow");
     670                printf("Command length overflow\n");
    670671                return 1;
    671672        }
    672673       
    673         list_foreach(cmd_list, link, cmd_info_t, hlp) {
     674        list_foreach(cmd_list, cur) {
     675                cmd_info_t *hlp;
     676                hlp = list_get_instance(cur, cmd_info_t, link);
     677               
    674678                spinlock_lock(&hlp->lock);
    675679                printf("%-*s %s\n", _len, hlp->name, hlp->description);
     
    908912        spinlock_lock(&cmd_lock);
    909913       
    910         list_foreach(cmd_list, link, cmd_info_t, hlp) {
     914        list_foreach(cmd_list, cur) {
     915                cmd_info_t *hlp;
     916               
     917                hlp = list_get_instance(cur, cmd_info_t, link);
    911918                spinlock_lock(&hlp->lock);
    912919               
Note: See TracChangeset for help on using the changeset viewer.