Changeset f8ddd17 in mainline for kernel/generic/src/console/klog.c
- Timestamp:
- 2006-12-09T20:20:50Z (18 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- b82a13c
- Parents:
- 9ab9c2ec
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/console/klog.c
r9ab9c2ec rf8ddd17 39 39 #include <ddi/device.h> 40 40 #include <ddi/irq.h> 41 #include <ddi/ddi.h> 41 42 #include <ipc/irq.h> 42 43 44 /** Physical memory area used for klog. */ 45 static parea_t klog_parea; 46 43 47 /* 44 48 * For now, we use 0 as INR. 45 * However, on some architectures 0 is the clock interrupt (e.g. amd64 and ia32).46 * It is therefore desirable to have architecture specific definition of KLOG_VIRT_INR47 * in the future.49 * However, on some architectures 0 is the clock interrupt (e.g. amd64 and 50 * ia32). It is therefore desirable to have architecture specific definition of 51 * KLOG_VIRT_INR in the future. 48 52 */ 49 53 #define KLOG_VIRT_INR 0 … … 76 80 if (!faddr) 77 81 panic("Cannot allocate page for klog"); 78 klog = (char *) PA2KA(faddr);82 klog = (char *) PA2KA(faddr); 79 83 80 84 devno_t devno = device_assign_devno(); 81 85 82 sysinfo_set_item_val("klog.faddr", NULL, (unative_t)faddr); 86 klog_parea.pbase = (uintptr_t) faddr; 87 klog_parea.vbase = (uintptr_t) klog; 88 klog_parea.frames = 1 << KLOG_ORDER; 89 klog_parea.cacheable = true; 90 ddi_parea_register(&klog_parea); 91 92 sysinfo_set_item_val("klog.faddr", NULL, (unative_t) faddr); 93 sysinfo_set_item_val("klog.fcolor", NULL, (unative_t) 94 PAGE_COLOR((uintptr_t) klog)); 83 95 sysinfo_set_item_val("klog.pages", NULL, 1 << KLOG_ORDER); 84 96 sysinfo_set_item_val("klog.devno", NULL, devno);
Note:
See TracChangeset
for help on using the changeset viewer.