[LinksOS CVS Commit]kernel/hal/prototypes hal.h,NONE,1.1 io.h,1.3,NONE kstdio.h,1.1,NONE
Status: Inactive
Brought to you by:
terencevs
|
From: <ke...@to...> - 2003-01-13 02:35:19
|
Update of /cvsroot/linksos/kernel/hal/prototypes In directory router-internal.tossell.net:/tmp/cvs-serv7935/hal/prototypes Added Files: hal.h Removed Files: io.h kstdio.h Log Message: Title: Namespaced. Changes: Broken inportb, outportb, and kstdio into namespace hal. Effects: hal::raw::inportb hal::raw::outportb hal::kio::printf a=kennyt b=19 --- NEW FILE: hal.h --- #ifndef _HAL_H #define _HAL_H namespace hal { /* Hardware Abstraction Layer Root */ namespace raw { /* Raw Port IO */ inline unsigned char inportb(unsigned int port) { /* Input a byte from a port */ unsigned char ret; asm volatile ("inb %%dx,%%al":"=a" (ret):"d" (port)); return ret; } inline void outportb(unsigned int port,unsigned char value) { /* Output a byte to a port */ asm volatile ("outb %%al,%%dx": :"d" (port), "a" (value)); } } /* raw */ namespace kio { /* Basic Kernel IO */ void printf(char*, ...); } /* kio */ } /* hal */ #endif /* ! _HAL_H */ --- io.h DELETED --- --- kstdio.h DELETED --- |