25.06.2014 Views

Núcleo de un Sistema Operativo

Núcleo de un Sistema Operativo

Núcleo de un Sistema Operativo

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

i80x86. Este núcleo es el que usaremos en el laboratorio. El f<strong>un</strong>cionamiento <strong>de</strong>l núcleo <strong>de</strong><br />

presentará en la siguiente sección.<br />

USUARIO<br />

Rutinas<br />

<strong>de</strong><br />

Librería<br />

NIVEL<br />

SISTEMA<br />

Rutinas<br />

internas<br />

Nivel <strong>Sistema</strong><br />

Primitivas<br />

Nivel <strong>Sistema</strong><br />

NIVEL<br />

BFS<br />

Rutinas<br />

internas<br />

Nivel BFS<br />

Primitivas<br />

Nivel BFS<br />

NIVEL<br />

NUCLEO<br />

Rutinas<br />

internas<br />

Nivel Núcleo<br />

Primitivas<br />

Nivel Núcleo<br />

Rutinas<br />

<strong>de</strong>pendientes<br />

<strong>de</strong>l Hardware<br />

HARDWARE<br />

Figura 1. Niveles en <strong>un</strong> sistema operativo<br />

3.1 Rutinas <strong>de</strong>pendientes <strong>de</strong>l hardware<br />

Son las rutinas <strong>de</strong>l núcleo <strong>de</strong> más bajo nivel. Distinguiremos dos grupos. Las más elementales<br />

están escritas en ensamblador y tratan con direcciones específicas <strong>de</strong> E/S o <strong>de</strong> memoria (para<br />

los dispositivos memory-mapped), o bien inhiben/activan interrupciones o manipulan<br />

directamente la pila <strong>de</strong>l programa para proporcionar los cambios <strong>de</strong> contexto. Sus prototipos<br />

se <strong>de</strong>scriben en la Figura 2. El seg<strong>un</strong>do grupo <strong>de</strong> rutinas internas <strong>de</strong>l núcleo, que programan<br />

los dispositivos, están codificadas en C. Estas se <strong>de</strong>scriben en la Figura 3.<br />

Las rutinas <strong>de</strong>pendientes <strong>de</strong>l hardware se llamarán únicamente <strong>de</strong>s<strong>de</strong> el núcleo. Encapsulan<br />

las características <strong>de</strong> la arquitectura.<br />

UPV/EHU ATC Laboratorio <strong>de</strong> <strong>Sistema</strong>s <strong>Operativo</strong>s 4

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!