+/* loader.c
+ * ELF loading subroutines
+ * NetWatch multiboot loader
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#include <elf.h>
#include <output.h>
#include <minilib.h>
+/* multiboot_asm.S
+ * Multiboot header
+ * NetWatch multiboot loader
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
.globl _start
_start:
+/* multiboot_c.c
+ * Main program for starting SMM code
+ * NetWatch multiboot loader
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#include "console.h"
#include "loader.h"
#include <output.h>
+/* output.c
+ * Console output routines
+ * NetWatch multiboot loader
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
+
#include <stdarg.h>
#include <minilib.h>
#include <console.h>
+; realmode.asm
+; Routines to return the system to real mode
+; NetWatch multiboot loader
+;
+; Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+; This program is free software; you can redistribute and/or modify it under
+; the terms found in the file LICENSE in the root of this source tree.
+
[bits 32] ; Starts in 32 bit mode, then will drop back later.
org 0x4000
entry:
+/* ich2-timer.c
+ * High precision timer routines for ICH2 southbridge
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#include <pci.h>
#include <io.h>
#include <reg-82801b.h>
+/* smi.c
+ * System management interrupt dispatch routines for ICH2 southbridge
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
+
#include <smi.h>
#include <pci.h>
#include <io.h>
+/* smm-open-ich2.c
+ * SMRAM control utility for ICH2 southbridge
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
+
#include "reg-82815.h"
#include <unistd.h>
#include <getopt.h>
+/* ich2-timer.c
+ * SMRAM access utility for ICH2 chipset
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
+
#include "reg-82815.h"
#include <pci.h>
#include <smram.h>
+/* smram-ich2.h
+ * Definitions for SMRAM access for ICH2 southbridge
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
+
#ifndef __SMRAM_ICH2_H
#define __SMRAM_ICH2_H
+/* reg-82865.h
+ * SMRAM register definitions for Intel 82865 northbridge
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef _REG_82865_H
#define _REG_82865_H
+/* smm-open-ich7.c
+ * SMRAM open utility for Intel 82865 northbridge
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#include "reg-82865.h"
void main()
printf("SMRAM is locked, cannot load anything :-(\n");
return;
}
-}
\ No newline at end of file
+}
-/** @file console-ext.h
+/* console-ext.h
+ * Console definitions
+ * NetWatch system management mode administration console
*
- * @brief Forward declarations for extended console functions
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
*
- * @author Joshua Wise (jwise) <joshua@joshuawise.com>
- * @buf None known
*/
#ifndef __CONSOLE_EXT_H
+/* crc32.h
+ * CRC32 routine declarations
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef _CRC32_H
#define _CRC32_H
+/* fb.h
+ * Framebuffer definitions
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef __FB_H
#define __FB_H
+/* keyboard.h
+ * Keyboard injection definitions
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef KEYBOARD_H
#define KEYBOARD_H
+/* minilib.h
+ * Definitions for a very small libc
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef MINILIB_H
#define MINILIB_H
+/* msr.h
+ * Macros to read and write model specific registers
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef _MSR_H
#define _MSR_H
+/* minilib.h
+ * Definitions needed for a multiboot kernel
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef __MULTIBOOT_H
#define __MULTIBOOT_H
+/* output.h
+ * Definitions for needed output routines
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef __OUTPUT_H
#define __OUTPUT_H
+/* minilib.h
+ * Definitions for page-table mapping and demapping
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef __PAGING_H
#define __PAGING_H
+/* pci-bother.h
+ * Definitions for Bothering a PCI device
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
#ifndef _PCI_BOTHER_H
#define _PCI_BOTHER_H
+/* pci.h
+ * Definitions for PCI access
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
+
#ifndef PCI_H
#define PCI_H
+/* io.h
+ * I/O port access macros
+ * NetWatch system management mode administration console
+ *
+ * Copyright (c) 2008 Jacob Potter and Joshua Wise. All rights reserved.
+ * This program is free software; you can redistribute and/or modify it under
+ * the terms found in the file LICENSE in the root of this source tree.
+ *
+ */
+
+
#ifndef __IO_H
#define __IO_H