aboutsummaryrefslogtreecommitdiff
path: root/src/resume.c
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2013-01-21 01:14:12 -0500
committerKevin O'Connor <kevin@koconnor.net>2013-02-05 20:00:29 -0500
commitd83c87bb20a8ac5faf80ead44ff8dc793bf25a84 (patch)
tree507ec4bf6d5885feb915f41807c18c3437ab7d3d /src/resume.c
parent88ab34e2cfbed34a848be8ec45248cf291c37049 (diff)
downloadseabios-d83c87bb20a8ac5faf80ead44ff8dc793bf25a84.zip
seabios-d83c87bb20a8ac5faf80ead44ff8dc793bf25a84.tar.gz
seabios-d83c87bb20a8ac5faf80ead44ff8dc793bf25a84.tar.bz2
Normalize POST initialization function name suffixes.
The POST phase has to invoke many initialization functions, and these functions can have complex inter-dependencies. Try to categorize the functions into 4 classes: preinit - functions called very early in POST where function ordering is very important and the code has limited access to other interfaces. init - functions that initialize internal interfaces and standard external interfaces. This code is generally not dependent on particular hardware and typically does not communicate directly with any hardware devices. setup - functions which access hardware or are dependent on particular hardware or platform devices. prepboot - functions that finalize internal interfaces and that prepare for the boot phase. This patch attempts to normalize the suffixes - functions that used _init(), _setup(), _finalize(), or similar that did not follow the above pattern were renamed. Other than function name changes, there should be no code impact to this patch. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'src/resume.c')
-rw-r--r--src/resume.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/resume.c b/src/resume.c
index f1a96ac..99265cd 100644
--- a/src/resume.c
+++ b/src/resume.c
@@ -19,7 +19,7 @@ int HaveRunPost VAR16VISIBLE;
// Reset DMA controller
void
-init_dma(void)
+dma_preinit(void)
{
// first reset the DMA controllers
outb(0, PORT_DMA1_MASTER_CLEAR);
@@ -35,12 +35,12 @@ void VISIBLE16
handle_resume(void)
{
ASSERT16();
- debug_serial_setup();
+ debug_serial_preinit();
int status = inb_cmos(CMOS_RESET_CODE);
outb_cmos(0, CMOS_RESET_CODE);
dprintf(1, "In resume (status=%d)\n", status);
- init_dma();
+ dma_preinit();
switch (status) {
case 0x01 ... 0x04:
@@ -109,9 +109,9 @@ s3_resume(void)
}
pic_setup();
- smm_init();
+ smm_setup();
- s3_resume_vga_init();
+ s3_resume_vga();
make_bios_readonly();