Be sure to add "void" to all function prototypes that take no args.
authorKevin O'Connor <kevin@koconnor.net>
Sun, 3 Jan 2010 22:43:37 +0000 (17:43 -0500)
committerKevin O'Connor <kevin@koconnor.net>
Sun, 3 Jan 2010 22:43:37 +0000 (17:43 -0500)
Omitting "void" leads to a K&R style declaration which was not intended.

54 files changed:
Makefile
src/acpi.c
src/acpi.h
src/apm.c
src/ata.c
src/ata.h
src/biosvar.h
src/block.c
src/boot.c
src/boot.h
src/cdrom.c
src/clock.c
src/coreboot.c
src/disk.c
src/disk.h
src/farptr.h
src/floppy.c
src/kbd.c
src/memmap.c
src/memmap.h
src/misc.c
src/mouse.c
src/optionroms.c
src/output.c
src/pci.c
src/pci.h
src/pcibios.c
src/pic.c
src/pic.h
src/pirtable.c
src/pmm.c
src/pnpbios.c
src/post.c
src/ps2port.c
src/ps2port.h
src/ramdisk.c
src/resume.c
src/serial.c
src/shadow.c
src/smm.c
src/smp.c
src/stacks.c
src/types.h
src/usb-hid.c
src/usb-hid.h
src/usb.c
src/usb.h
src/util.c
src/util.h
src/vgahooks.c
vgasrc/clext.c
vgasrc/vga.c
vgasrc/vgaio.c
vgasrc/vgatables.h

index a4463bd6ec1e1ac50188d436831b2189f2684fde..1021e66632e2ce9ca8ebc517391e77d4ee5e0fb2 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -25,12 +25,12 @@ cc-option = $(shell if test -z "`$(1) $(2) -S -o /dev/null -xc \
               /dev/null 2>&1`"; then echo "$(2)"; else echo "$(3)"; fi ;)
 
 # Default compiler flags
-COMMONCFLAGS = -Wall -Os -MD -m32 -march=i386 -mregparm=3 \
-               -mpreferred-stack-boundary=2 -mrtd -freg-struct-return \
-               -ffreestanding -fomit-frame-pointer \
-               -fno-delete-null-pointer-checks -Wno-strict-aliasing \
-               -ffunction-sections -fdata-sections -fno-common \
-               -minline-all-stringops
+COMMONCFLAGS = -Os -MD -Wall -Wold-style-definition -Wno-strict-aliasing \
+               -m32 -march=i386 -mregparm=3 -mpreferred-stack-boundary=2 \
+               -mrtd -minline-all-stringops \
+               -freg-struct-return -ffreestanding -fomit-frame-pointer \
+               -fno-delete-null-pointer-checks \
+               -ffunction-sections -fdata-sections -fno-common
 COMMONCFLAGS += $(call cc-option,$(CC),-nopie,)
 COMMONCFLAGS += $(call cc-option,$(CC),-fno-stack-protector,)
 COMMONCFLAGS += $(call cc-option,$(CC),-fno-stack-protector-all,)
index 9e5a4fccf3f72b52d24478b41f9d1d5712dcc5d6..f613b034120d3595f9e9c4104acffbeae8dbd228 100644 (file)
@@ -677,7 +677,7 @@ acpi_bios_init(void)
 }
 
 u32
-find_resume_vector()
+find_resume_vector(void)
 {
     dprintf(4, "rsdp=%p\n", RsdpAddr);
     if (!RsdpAddr || RsdpAddr->signature != RSDP_SIGNATURE)
index 63d3024843357d6c77a70291dee212a3b3f8ff1e..c3ae84cf4724a58ad98dddff0362926b4575b8e1 100644 (file)
@@ -4,7 +4,7 @@
 #include "types.h" // u32
 
 void acpi_bios_init(void);
-u32 find_resume_vector();
+u32 find_resume_vector(void);
 
 #define RSDP_SIGNATURE 0x2052545020445352LL // "RSD PTR "
 
index f30c22caeada5d157ff8fd251d9db6fdb9b56490..479d47c5629ba21a9564f6b02031f4f9884458fb 100644 (file)
--- a/src/apm.c
+++ b/src/apm.c
@@ -53,8 +53,8 @@ handle_155301(struct bregs *regs)
 }
 
 // Assembler entry points defined in romlayout.S
-extern void apm16protected_entry();
-extern void apm32protected_entry();
+extern void apm16protected_entry(void);
+extern void apm32protected_entry(void);
 
 // APM 16 bit protected mode interface connect
 static void
index 90e03923c1381420b479ed4a823f46c175fcf050..add1d67b4cd7de8d7c5ccf1216d17c42afef864a 100644 (file)
--- a/src/ata.c
+++ b/src/ata.c
@@ -990,7 +990,7 @@ init_controller(struct ata_channel_s *atachannel
 
 // Locate and init ata controllers.
 static void
-ata_init()
+ata_init(void)
 {
     // Scan PCI bus for ATA adapters
     int count=0, pcicount=0;
@@ -1052,7 +1052,7 @@ ata_init()
 }
 
 void
-ata_setup()
+ata_setup(void)
 {
     if (!CONFIG_ATA)
         return;
index 149bacfea0df74f46ad14c9882289c04220c2ef0..df53a01e6a32979d4bdd3347ced0a76fa83447be 100644 (file)
--- a/src/ata.h
+++ b/src/ata.h
@@ -17,7 +17,7 @@ extern struct ata_channel_s ATA_channels[CONFIG_MAX_ATA_INTERFACES];
 int cdrom_read(struct disk_op_s *op);
 int ata_cmd_packet(struct drive_s *drive_g, u8 *cmdbuf, u8 cmdlen
                    , u32 length, void *buf_fl);
-void ata_setup();
+void ata_setup(void);
 int process_ata_op(struct disk_op_s *op);
 int process_atapi_op(struct disk_op_s *op);
 void describe_ata(struct drive_s *drive_g);
index db6783e07b2421c5e92d9ca5e719d7e7f1c45a8e..b6e061b99cdb311f6c2fc206326b1e06a08d7ad1 100644 (file)
@@ -232,11 +232,11 @@ struct extended_bios_data_area_s {
     FLATPTR_TO_SEG(BUILD_LOWRAM_END - EBDA_SIZE_START*1024)
 
 // Accessor functions
-static inline u16 get_ebda_seg() {
+static inline u16 get_ebda_seg(void) {
     return GET_BDA(ebda_seg);
 }
 static inline struct extended_bios_data_area_s *
-get_ebda_ptr()
+get_ebda_ptr(void)
 {
     ASSERT32FLAT();
     return MAKE_FLATPTR(get_ebda_seg(), 0);
@@ -279,7 +279,7 @@ static inline u32 __attribute_const get_global_offset(void) {
     return 0;
 }
 #endif
-static inline u16 get_global_seg() {
+static inline u16 get_global_seg(void) {
     return GET_SEG(GLOBAL_SEGREG);
 }
 #define GET_GLOBAL(var)                                                 \
index 3fb5e91da9ecb446d6c394f0920339b0d67e0da6..c6787e25b2ef38f2f65b50cf2db69b5d26a2b272 100644 (file)
@@ -31,7 +31,7 @@ getDrive(u8 exttype, u8 extdriveoffset)
 }
 
 struct drive_s *
-allocDrive()
+allocDrive(void)
 {
     int driveid = Drives.drivecount;
     if (driveid >= ARRAY_SIZE(Drives.drives))
@@ -369,7 +369,7 @@ send_disk_op(struct disk_op_s *op)
  ****************************************************************/
 
 void
-drive_setup()
+drive_setup(void)
 {
     memset(&Drives, 0, sizeof(Drives));
     memset(&Drives.idmap, 0xff, sizeof(Drives.idmap));
index c427c00bd333882ed94d9194601add23b2a97970..151b0d36905d379dfbd98b04d6eac292d46418cb 100644 (file)
@@ -22,7 +22,7 @@ struct ipl_s IPL;
  ****************************************************************/
 
 void
-boot_setup()
+boot_setup(void)
 {
     if (! CONFIG_BOOT)
         return;
@@ -222,7 +222,7 @@ menu_show_cbfs(struct ipl_entry_s *ie, int menupos)
 
 // Show IPL option menu.
 static void
-interactive_bootmenu()
+interactive_bootmenu(void)
 {
     if (! CONFIG_BOOTMENU || ! qemu_cfg_show_boot_menu())
         return;
@@ -309,7 +309,7 @@ run_bcv(struct ipl_entry_s *ie)
 
 // Prepare for boot - show menu and run bcvs.
 void
-boot_prep()
+boot_prep(void)
 {
     if (! CONFIG_BOOT)
         return;
@@ -487,7 +487,7 @@ do_boot(u16 seq_nr)
 
 // Boot Failure recovery: try the next device.
 void VISIBLE32FLAT
-handle_18()
+handle_18(void)
 {
     debug_serial_setup();
     debug_enter(NULL, DEBUG_HDL_18);
@@ -499,7 +499,7 @@ handle_18()
 
 // INT 19h Boot Load Service Entry Point
 void VISIBLE32FLAT
-handle_19()
+handle_19(void)
 {
     debug_serial_setup();
     debug_enter(NULL, DEBUG_HDL_19);
index 1aa1bdc017ec5db89cba06e04f035f0ce7d4b71c..db046e3571cefaf98ddffc23be54c179a9819ad2 100644 (file)
@@ -38,11 +38,11 @@ struct ipl_s {
 
 // boot.c
 extern struct ipl_s IPL;
-void boot_setup();
+void boot_setup(void);
 void add_bev(u16 seg, u16 bev, u16 desc);
 void add_bcv(u16 seg, u16 ip, u16 desc);
 struct drive_s;
 void add_bcv_internal(struct drive_s *drive_g);
-void boot_prep();
+void boot_prep(void);
 
 #endif // __BOOT_H
index 8d1ec9adafdf94e0cd670304b57e049db4a96dcc..883bffa6545b9268671a4691284611d9e68f9e94 100644 (file)
@@ -107,7 +107,7 @@ process_cdemu_op(struct disk_op_s *op)
 struct drive_s *cdemu_drive VAR16VISIBLE;
 
 void
-cdemu_setup()
+cdemu_setup(void)
 {
     if (!CONFIG_CDROM_EMU)
         return;
index 6b4acb9933ca251b291922820e7a23e00bc9540a..e32bf1b717a51a77c2bfb918368f6f4d47d2e59d 100644 (file)
@@ -62,7 +62,7 @@
 u32 cpu_khz VAR16VISIBLE;
 
 static void
-calibrate_tsc()
+calibrate_tsc(void)
 {
     // Setup "timer2"
     u8 orig = inb(PORT_PS2_CTRLB);
@@ -150,7 +150,7 @@ calc_future_tsc_usec(u32 usecs)
  ****************************************************************/
 
 static int
-rtc_updating()
+rtc_updating(void)
 {
     // This function checks to see if the update-in-progress bit
     // is set in CMOS Status Register A.  If not, it returns 0.
@@ -173,7 +173,7 @@ rtc_updating()
 }
 
 static void
-pit_setup()
+pit_setup(void)
 {
     // timer0: binary count, 16bit count, mode 2
     outb(PM_SEL_TIMER0|PM_ACCESS_WORD|PM_MODE2|PM_CNT_BINARY, PORT_PIT_MODE);
@@ -183,7 +183,7 @@ pit_setup()
 }
 
 static void
-init_rtc()
+init_rtc(void)
 {
     outb_cmos(0x26, CMOS_STATUS_A);    // 32,768Khz src, 976.5625us updates
     u8 regB = inb_cmos(CMOS_STATUS_B);
@@ -199,7 +199,7 @@ bcd2bin(u8 val)
 }
 
 void
-timer_setup()
+timer_setup(void)
 {
     dprintf(3, "init timer\n");
     calibrate_tsc();
@@ -435,7 +435,7 @@ handle_1a(struct bregs *regs)
 
 // INT 08h System Timer ISR Entry Point
 void VISIBLE16
-handle_08()
+handle_08(void)
 {
     debug_isr(DEBUG_ISR_08);
 
@@ -467,7 +467,7 @@ handle_08()
  ****************************************************************/
 
 void
-useRTC()
+useRTC(void)
 {
     u16 ebda_seg = get_ebda_seg();
     int count = GET_EBDA2(ebda_seg, RTCusers);
@@ -480,7 +480,7 @@ useRTC()
 }
 
 void
-releaseRTC()
+releaseRTC(void)
 {
     u16 ebda_seg = get_ebda_seg();
     int count = GET_EBDA2(ebda_seg, RTCusers);
@@ -507,7 +507,7 @@ set_usertimer(u32 usecs, u16 seg, u16 offset)
 }
 
 static void
-clear_usertimer()
+clear_usertimer(void)
 {
     if (!(GET_BDA(rtc_wait_flag) & RWS_WAIT_PENDING))
         return;
@@ -576,7 +576,7 @@ handle_1583(struct bregs *regs)
 
 // int70h: IRQ8 - CMOS RTC
 void VISIBLE16
-handle_70()
+handle_70(void)
 {
     debug_isr(DEBUG_ISR_70);
 
index 3dc6a7fd775a8505f7aefef58ccfbc20e4b9785c..7ad46cedbd3b310898b3536695572332edd19ad6 100644 (file)
@@ -122,7 +122,7 @@ static struct cb_memory *CBMemTable;
 
 // Populate max ram and e820 map info by scanning for a coreboot table.
 static void
-coreboot_fill_map()
+coreboot_fill_map(void)
 {
     dprintf(3, "Attempting to find coreboot table\n");
 
@@ -282,7 +282,7 @@ scan_tables(u32 start, u32 size)
 }
 
 void
-coreboot_copy_biostable()
+coreboot_copy_biostable(void)
 {
     struct cb_memory *cbm = CBMemTable;
     if (! CONFIG_COREBOOT || !cbm)
@@ -368,7 +368,7 @@ struct cbfs_header {
 static struct cbfs_header *CBHDR;
 
 static void
-cbfs_setup()
+cbfs_setup(void)
 {
     if (! CONFIG_COREBOOT_FLASH)
         return;
@@ -411,7 +411,7 @@ cbfs_verify(struct cbfs_file *file)
 
 // Return the first file in the CBFS archive
 static struct cbfs_file *
-cbfs_getfirst()
+cbfs_getfirst(void)
 {
     if (! CBHDR)
         return NULL;
index 70f237f1e96b8eafbdcd14ff6f12b59f386d5a5a..4457ea9171d4b53bc8c7e477369e4ac7d190b2ad 100644 (file)
@@ -852,7 +852,7 @@ handle_13(struct bregs *regs)
 
 // record completion in BIOS task complete flag
 void VISIBLE16
-handle_76()
+handle_76(void)
 {
     debug_isr(DEBUG_ISR_76);
     SET_BDA(disk_interrupt_flag, 0xff);
index 7feb9afec0c4998f60ce2a0fb8aa485159fc861e..ac5748ec655952917190accdd22cabe4ea2397e4 100644 (file)
@@ -230,7 +230,7 @@ struct drives_s {
 // block.c
 extern struct drives_s Drives;
 struct drive_s *getDrive(u8 exttype, u8 extdriveoffset);
-struct drive_s *allocDrive();
+struct drive_s *allocDrive(void);
 void setup_translation(struct drive_s *drive_g);
 void map_floppy_drive(struct drive_s *drive_g);
 void map_hd_drive(struct drive_s *drive_g);
@@ -238,27 +238,27 @@ void map_cd_drive(struct drive_s *drive_g);
 void describe_drive(struct drive_s *drive_g);
 int process_op(struct disk_op_s *op);
 int send_disk_op(struct disk_op_s *op);
-void drive_setup();
+void drive_setup(void);
 
 // floppy.c
 extern struct floppy_ext_dbt_s diskette_param_table2;
-void floppy_setup();
+void floppy_setup(void);
 struct drive_s *addFloppy(int floppyid, int ftype, int driver);
 void describe_floppy(struct drive_s *drive_g);
 int find_floppy_type(u32 size);
 int process_floppy_op(struct disk_op_s *op);
-void floppy_tick();
+void floppy_tick(void);
 
 // cdrom.c
 extern struct drive_s *cdemu_drive;
 int process_cdemu_op(struct disk_op_s *op);
-void cdemu_setup();
+void cdemu_setup(void);
 void cdemu_134b(struct bregs *regs);
 int cdrom_boot(int cdid);
 
 // ramdisk.c
 void describe_ramdisk(struct drive_s *drive_g);
-void ramdisk_setup();
+void ramdisk_setup(void);
 int process_ramdisk_op(struct disk_op_s *op);
 
 #endif // disk.h
index 0bd92483beac2c55a86b6bcf4877b400fbac1e6b..3dbf545c83d50f9d140e8a77b56a6b109bcb6a94 100644 (file)
@@ -50,7 +50,7 @@ extern u16 __segment_FS, __segment_GS;
 
 // Macros for automatically choosing the appropriate memory size
 // access method.
-extern void __force_link_error__unknown_type();
+extern void __force_link_error__unknown_type(void);
 
 #define __GET_VAR(prefix, seg, var) ({          \
     typeof(var) __val;                          \
index a8e2ac9bb63a932c23f190542d7c1523a0c6ae1a..a7bd0ddd23cf59c8f86bab4f209ff38ca44d91cb 100644 (file)
@@ -119,7 +119,7 @@ describe_floppy(struct drive_s *drive_g)
 }
 
 void
-floppy_setup()
+floppy_setup(void)
 {
     if (! CONFIG_FLOPPY)
         return;
@@ -159,7 +159,7 @@ find_floppy_type(u32 size)
  ****************************************************************/
 
 static void
-floppy_reset_controller()
+floppy_reset_controller(void)
 {
     // Reset controller
     u8 val8 = inb(PORT_FD_DOR);
@@ -172,7 +172,7 @@ floppy_reset_controller()
 }
 
 static int
-wait_floppy_irq()
+wait_floppy_irq(void)
 {
     ASSERT16();
     u8 v;
@@ -570,7 +570,7 @@ process_floppy_op(struct disk_op_s *op)
 
 // INT 0Eh Diskette Hardware ISR Entry Point
 void VISIBLE16
-handle_0e()
+handle_0e(void)
 {
     debug_isr(DEBUG_ISR_0e);
     if (! CONFIG_FLOPPY)
@@ -593,7 +593,7 @@ done:
 
 // Called from int08 handler.
 void
-floppy_tick()
+floppy_tick(void)
 {
     if (! CONFIG_FLOPPY)
         return;
index 39294a7c1cd6b45fffc4d9997d78d57a990283ee..6f3ae15d5b5556fb92a8989458603c45f3b17f88 100644 (file)
--- a/src/kbd.c
+++ b/src/kbd.c
@@ -34,7 +34,7 @@
 #define KF2_101KBD     (1<<4)
 
 void
-kbd_setup()
+kbd_setup(void)
 {
     dprintf(3, "init keyboard\n");
     u16 x = offsetof(struct bios_data_area_s, kbd_buf);
@@ -220,7 +220,7 @@ handle_16XX(struct bregs *regs)
 }
 
 static void
-set_leds()
+set_leds(void)
 {
     u8 shift_flags = (GET_BDA(kbd_flag0) >> 4) & 0x07;
     u8 kbd_led = GET_BDA(kbd_led);
index 45f5012c7e6804599bcf80481d437536218c4a61..aa695031e266d877adfc48934e0551334b74ee5b 100644 (file)
@@ -42,7 +42,7 @@ insert_e820(int i, u64 start, u64 size, u32 type)
 
 // Show the current e820_list.
 static void
-dump_map()
+dump_map(void)
 {
     dprintf(1, "e820 map has %d items:\n", e820_count);
     int i;
@@ -138,14 +138,14 @@ find_high_area(u32 size)
 
 // Prep for memmap stuff - init bios table locations.
 void
-memmap_setup()
+memmap_setup(void)
 {
     e820_count = 0;
 }
 
 // Report on final memory locations.
 void
-memmap_finalize()
+memmap_finalize(void)
 {
     dump_map();
 }
index 616ae3534e400d6cfd5d3a739527556dad260dd5..68eb6ac51b941cd841f17a3c794443320483d49a 100644 (file)
@@ -17,8 +17,8 @@ struct e820entry {
 };
 
 void add_e820(u64 start, u64 size, u32 type);
-void memmap_setup();
-void memmap_finalize();
+void memmap_setup(void);
+void memmap_finalize(void);
 struct e820entry *find_high_area(u32 size);
 
 // A typical OS page size
index 7d6e954caf21225e0ef200e147e9a5596e50a46d..b33ef6458c2fa993992f625991bd7df06a72fb08 100644 (file)
@@ -55,13 +55,13 @@ handle_10(struct bregs *regs)
 
 // NMI handler
 void VISIBLE16
-handle_02()
+handle_02(void)
 {
     debug_isr(DEBUG_ISR_02);
 }
 
 void
-mathcp_setup()
+mathcp_setup(void)
 {
     dprintf(3, "math cp init\n");
     // 80x87 coprocessor installed
@@ -71,7 +71,7 @@ mathcp_setup()
 
 // INT 75 - IRQ13 - MATH COPROCESSOR EXCEPTION
 void VISIBLE16
-handle_75()
+handle_75(void)
 {
     debug_isr(DEBUG_ISR_75);
 
index ac37cc018df514069f7d1c4f8da04ee0bbfb1aac..52e225c35a17af1b48f9070015c69b24a6c091d3 100644 (file)
@@ -12,7 +12,7 @@
 #include "ps2port.h" // aux_command
 
 void
-mouse_setup()
+mouse_setup(void)
 {
     if (! CONFIG_MOUSE)
         return;
index 31bb98be34c338f28841c94ad6e95ecbe25a7a27..ace0c0ee09f61dbb4a71f9e7bb303bf60cba06ab 100644 (file)
@@ -170,7 +170,7 @@ get_pci_rom(struct rom_header *rom)
 
 // Return the memory position up to which roms may be located.
 static inline u32
-max_rom()
+max_rom(void)
 {
     extern u8 code32flat_start[];
     if ((u32)code32flat_start > BUILD_BIOS_ADDR)
@@ -364,7 +364,7 @@ init_pcirom(u16 bdf, int isvga)
  ****************************************************************/
 
 void
-optionrom_setup()
+optionrom_setup(void)
 {
     if (! CONFIG_OPTIONROMS)
         return;
@@ -435,7 +435,7 @@ optionrom_setup()
 
 // Call into vga code to turn on console.
 void
-vga_setup()
+vga_setup(void)
 {
     VGAbdf = -1;
     RomEnd = BUILD_ROM_START;
@@ -477,7 +477,7 @@ vga_setup()
 }
 
 void
-s3_resume_vga_init()
+s3_resume_vga_init(void)
 {
     if (!CONFIG_S3_RESUME_VGA_INIT)
         return;
index 2e7175e4f90195b095dde6da3899004ed1a8406c..3de565a18a7d7e0da87e69be3924e0fb175d2eda 100644 (file)
@@ -25,7 +25,7 @@ struct putcinfo {
 #define DEBUG_TIMEOUT 100000
 
 void
-debug_serial_setup()
+debug_serial_setup(void)
 {
     if (!CONFIG_DEBUG_SERIAL)
         return;
@@ -59,7 +59,7 @@ debug_serial(char c)
 
 // Make sure all serial port writes have been completely sent.
 static void
-debug_serial_flush()
+debug_serial_flush(void)
 {
     if (!CONFIG_DEBUG_SERIAL)
         return;
index 143acf634910c32a7a9616c5aec23253965c4c03..1ab3c2c56b3c0c798069c27a6ba72036a0f1cef3 100644 (file)
--- a/src/pci.c
+++ b/src/pci.c
@@ -104,7 +104,7 @@ pci_next(int bdf, int *pmax)
 
 // Find a vga device with legacy address decoding enabled.
 int
-pci_find_vga()
+pci_find_vga(void)
 {
     int bdf = 0x0000, max = 0x0100;
     for (;;) {
index 3c04529fae6177ca8e397c62b0e6a07db9392bfb..eea5b09c3b399be0ae1bac1db1c46049834e3b3c 100644 (file)
--- a/src/pci.h
+++ b/src/pci.h
@@ -30,7 +30,7 @@ u16 pci_config_readw(u16 bdf, u32 addr);
 u8 pci_config_readb(u16 bdf, u32 addr);
 void pci_config_maskw(u16 bdf, u32 addr, u16 off, u16 on);
 
-int pci_find_vga();
+int pci_find_vga(void);
 int pci_find_device(u16 vendid, u16 devid);
 int pci_find_class(u16 classid);
 
@@ -41,7 +41,7 @@ int pci_next(int bdf, int *pmax);
          ; BDF=pci_next(BDF+1, &MAX))
 
 // pirtable.c
-void create_pirtable();
+void create_pirtable(void);
 
 
 /****************************************************************
index 2425a65c7f4898ccc1499d0062c157ca341bb911..2e44c015d4b72d2eeb87ffa047d3fcadf1dc5451 100644 (file)
@@ -13,8 +13,8 @@
 #include "pci_regs.h" // PCI_VENDOR_ID
 
 // romlayout.S
-extern void bios32_entry();
-extern void pcibios32_entry();
+extern void bios32_entry(void);
+extern void pcibios32_entry(void);
 
 #define RET_FUNC_NOT_SUPPORTED 0x81
 #define RET_BAD_VENDOR_ID      0x83
index 382dcbb09a59c16e223f97f8cc2c5f83bb21a42c..f421bec837569dadc4a1353161cc9ddf0317494d 100644 (file)
--- a/src/pic.c
+++ b/src/pic.c
@@ -10,7 +10,7 @@
 #include "config.h" // CONFIG_*
 
 void
-pic_setup()
+pic_setup(void)
 {
     dprintf(3, "init pic\n");
     // Send ICW1 (select OCW1 + will send ICW4)
index 3056676ccbf9a3476daa1cc4f2424b08f71aa83f..290fcb075b1fc01e9f931c2758fb3ccc4e94a703 100644 (file)
--- a/src/pic.h
+++ b/src/pic.h
 #define PIC2_IRQ14 (1<<6)
 
 static inline void
-eoi_pic1()
+eoi_pic1(void)
 {
     // Send eoi (select OCW2 + eoi)
     outb(0x20, PORT_PIC1_CMD);
 }
 
 static inline void
-eoi_pic2()
+eoi_pic2(void)
 {
     // Send eoi (select OCW2 + eoi)
     outb(0x20, PORT_PIC2_CMD);
@@ -61,7 +61,7 @@ mask_pic2(u8 irq)
 }
 
 static inline u8
-get_pic1_isr()
+get_pic1_isr(void)
 {
     // 0x0b == select OCW1 + read ISR
     outb(0x0b, PORT_PIC1_CMD);
@@ -69,7 +69,7 @@ get_pic1_isr()
 }
 
 static inline u8
-get_pic2_isr()
+get_pic2_isr(void)
 {
     // 0x0b == select OCW1 + read ISR
     outb(0x0b, PORT_PIC2_CMD);
@@ -98,6 +98,6 @@ __enable_hwirq(int hwirq, void (*func)(void))
         __enable_hwirq(irq, func);              \
     } while (0)
 
-void pic_setup();
+void pic_setup(void);
 
 #endif // pic.h
index 18d3ff5133bf9fd7f78fbfc20ca8b31dff775e3e..4c3f1ffc486d7afc725f43687c63f0f1138da5d0 100644 (file)
@@ -92,7 +92,7 @@ struct pir_table PIR_TABLE __aligned(16) VAR16EXPORT = {
 #endif // CONFIG_PIRTABLE && !CONFIG_COREBOOT
 
 void
-create_pirtable()
+create_pirtable(void)
 {
     if (! CONFIG_PIRTABLE)
         return;
index dab8fb36b13c48cf09813720e2680bd5af48b077..0461e4139eb810688531c490f91cc931209568f1 100644 (file)
--- a/src/pmm.c
+++ b/src/pmm.c
@@ -150,7 +150,7 @@ zone_free(void *data, u32 olddata)
 
 // Report the status of all the zones.
 static void
-dumpZones()
+dumpZones(void)
 {
     int i;
     for (i=0; i<ARRAY_SIZE(Zones); i++) {
@@ -282,7 +282,7 @@ pmm_find(u32 handle)
 }
 
 void
-malloc_setup()
+malloc_setup(void)
 {
     ASSERT32FLAT();
     dprintf(3, "malloc setup\n");
@@ -327,7 +327,7 @@ malloc_setup()
 }
 
 void
-malloc_finalize()
+malloc_finalize(void)
 {
     dprintf(3, "malloc finalize\n");
 
@@ -482,10 +482,10 @@ handle_pmm(u16 *args)
 }
 
 // romlayout.S
-extern void entry_pmm();
+extern void entry_pmm(void);
 
 void
-pmm_setup()
+pmm_setup(void)
 {
     if (! CONFIG_PMM)
         return;
@@ -498,7 +498,7 @@ pmm_setup()
 }
 
 void
-pmm_finalize()
+pmm_finalize(void)
 {
     if (! CONFIG_PMM)
         return;
index 4e7abc69785f0d0c6bc62f65efcf10b767633748..b1bebc9bf7c5f3a35d86e4b9704dc9f185204991 100644 (file)
@@ -78,7 +78,7 @@ handle_pnp(u16 *args)
 }
 
 u16
-get_pnp_offset()
+get_pnp_offset(void)
 {
     if (! CONFIG_PNPBIOS)
         return (u32)pnp_string + 1 - BUILD_BIOS_ADDR;
@@ -86,11 +86,11 @@ get_pnp_offset()
 }
 
 // romlayout.S
-extern void entry_pnp_real();
-extern void entry_pnp_prot();
+extern void entry_pnp_real(void);
+extern void entry_pnp_prot(void);
 
 void
-pnp_setup()
+pnp_setup(void)
 {
     if (! CONFIG_PNPBIOS)
         return;
index db9d8f724077799441f2db1fc190a6df50f019b4..2d20ffa3ce921e652baaa1751014f617db380870 100644 (file)
@@ -36,7 +36,7 @@ __set_irq(int vector, void *loc)
     } while (0)
 
 static void
-init_ivt()
+init_ivt(void)
 {
     dprintf(3, "init ivt\n");
 
@@ -78,7 +78,7 @@ init_ivt()
 }
 
 static void
-init_bda()
+init_bda(void)
 {
     dprintf(3, "init bda\n");
 
@@ -163,7 +163,7 @@ init_bios_tables(void)
 
 // Main setup code.
 static void
-post()
+post(void)
 {
     // Detect and init ram.
     init_ivt();
@@ -236,7 +236,7 @@ post()
 
 // 32-bit entry point.
 void VISIBLE32FLAT
-_start()
+_start(void)
 {
     init_dma();
 
index 150529bc2124c67d6082276afda991ef48f9ce94..fb9d24ae092f89a44079d940a147e2a6505a0dcf 100644 (file)
@@ -304,7 +304,7 @@ aux_command(int command, u8 *param)
  ****************************************************************/
 
 static void
-process_ps2irq()
+process_ps2irq(void)
 {
     u8 status = inb(PORT_PS2_STATUS);
     if (!(status & I8042_STR_OBF)) {
@@ -318,7 +318,7 @@ process_ps2irq()
 
 // INT74h : PS/2 mouse hardware interrupt
 void VISIBLE16
-handle_74()
+handle_74(void)
 {
     if (! CONFIG_PS2PORT)
         return;
@@ -330,7 +330,7 @@ handle_74()
 
 // INT09h : Keyboard Hardware Service Entry Point
 void VISIBLE16
-handle_09()
+handle_09(void)
 {
     if (! CONFIG_PS2PORT)
         return;
@@ -346,7 +346,7 @@ handle_09()
  ****************************************************************/
 
 static void
-keyboard_init()
+keyboard_init(void *data)
 {
     /* flush incoming keys */
     int ret = i8042_flush();
@@ -414,7 +414,7 @@ keyboard_init()
 }
 
 void
-ps2port_setup()
+ps2port_setup(void)
 {
     if (! CONFIG_PS2PORT)
         return;
index e13f85903e0f1731f41c01c8ebee1febb615dd79..bc049033d7794fad1b537561f05f84325dddbcde 100644 (file)
@@ -59,6 +59,6 @@ int i8042_flush(void);
 int i8042_command(int command, u8 *param);
 int kbd_command(int command, u8 *param);
 int aux_command(int command, u8 *param);
-void ps2port_setup();
+void ps2port_setup(void);
 
 #endif // ps2port.h
index c1e0b8af0516f8cb38ec31a52b64443d1279946a..16c8b258b555cf3586a85a54c3453d7ca18f268c 100644 (file)
@@ -17,7 +17,7 @@ describe_ramdisk(struct drive_s *drive_g)
 }
 
 void
-ramdisk_setup()
+ramdisk_setup(void)
 {
     if (!CONFIG_COREBOOT_FLASH || !CONFIG_FLASH_FLOPPY)
         return;
index 59bb90195427e01be1525aeb4d4a3f1813f61f69..6cdfc69e0b3ef8b1889ee5849bf6860888748225 100644 (file)
@@ -13,7 +13,7 @@
 
 // Reset DMA controller
 void
-init_dma()
+init_dma(void)
 {
     // first reset the DMA controllers
     outb(0, PORT_DMA1_MASTER_CLEAR);
@@ -95,7 +95,7 @@ handle_resume(u8 status)
 
 #if MODESEGMENT == 0
 void VISIBLE32FLAT
-s3_resume()
+s3_resume(void)
 {
     if (!CONFIG_S3_RESUME)
         panic("S3 resume support not compiled in.\n");
index 493d4213a5ecac83ee099a75d5f23a7f329f515f..3f68bc47026c47ba87fc7df6f4614fb63cc0cf4f 100644 (file)
@@ -57,7 +57,7 @@ detect_serial(u16 port, u8 timeout, u8 count)
 }
 
 void
-serial_setup()
+serial_setup(void)
 {
     if (! CONFIG_SERIAL)
         return;
@@ -224,7 +224,7 @@ detect_parport(u16 port, u8 timeout, u8 count)
 }
 
 void
-lpt_setup()
+lpt_setup(void)
 {
     if (! CONFIG_LPT)
         return;
index 3f443ed59657176973ec2ddaf57bcb5ccb2dd305..978424efbe01f2f9b1a955c0ee4ad222589eba66 100644 (file)
@@ -57,7 +57,7 @@ __make_bios_writable(u16 bdf)
 
 // Make the 0xc0000-0x100000 area read/writable.
 void
-make_bios_writable()
+make_bios_writable(void)
 {
     if (CONFIG_COREBOOT)
         return;
@@ -88,7 +88,7 @@ make_bios_writable()
 
 // Make the BIOS code segment area (0xf0000) read-only.
 void
-make_bios_readonly()
+make_bios_readonly(void)
 {
     if (CONFIG_COREBOOT)
         return;
index be2291bc7e8dc6c42c19d48d904d73acf9dc8360..3f53ef97e16a112b02a6984a751342e58a83d871 100644 (file)
--- a/src/smm.c
+++ b/src/smm.c
@@ -73,7 +73,7 @@ extern u8 smm_relocation_start, smm_relocation_end;
 extern u8 smm_code_start, smm_code_end;
 
 void
-smm_init()
+smm_init(void)
 {
     if (CONFIG_COREBOOT)
         // SMM only supported on emulators.
index 913d3a2b6b6e5b5681eef50538055f2a5296aac3..dac95bf41cff333079b3359d0462d03d79e39bf5 100644 (file)
--- a/src/smp.c
+++ b/src/smp.c
@@ -34,7 +34,7 @@ wrmsr_smp(u32 index, u64 val)
 
 u32 CountCPUs VAR16VISIBLE;
 u32 MaxCountCPUs VAR16VISIBLE;
-extern void smp_ap_boot_code();
+extern void smp_ap_boot_code(void);
 ASM16(
     "  .global smp_ap_boot_code\n"
     "smp_ap_boot_code:\n"
index 0ddb9a89f64f60809f6b0917b1788afac288138c..a35ca3de7717a3bafed840689e3fdea40e5c3611 100644 (file)
@@ -8,7 +8,7 @@
 #include "util.h" // dprintf
 #include "bregs.h" // CR0_PE
 
-static inline u32 getcr0() {
+static inline u32 getcr0(void) {
     u32 cr0;
     asm("movl %%cr0, %0" : "=r"(cr0));
     return cr0;
@@ -126,7 +126,7 @@ struct thread_info VAR16VISIBLE MainThread;
 int VAR16VISIBLE CanPreempt;
 
 void
-thread_setup()
+thread_setup(void)
 {
     MainThread.next = &MainThread;
     MainThread.stackpos = NULL;
@@ -135,7 +135,7 @@ thread_setup()
 
 // Return the 'struct thread_info' for the currently running thread.
 struct thread_info *
-getCurThread()
+getCurThread(void)
 {
     u32 esp = getesp();
     if (esp <= BUILD_STACK_ADDR)
@@ -166,7 +166,7 @@ switch_next(struct thread_info *cur)
 
 // Briefly permit irqs to occur.
 void
-yield()
+yield(void)
 {
     if (MODESEGMENT || !CONFIG_THREADS) {
         // Just directly check irqs.
@@ -239,7 +239,7 @@ fail:
 
 // Wait for all threads (other than the main thread) to complete.
 void
-wait_threads()
+wait_threads(void)
 {
     ASSERT32FLAT();
     if (! CONFIG_THREADS)
@@ -257,7 +257,7 @@ static u32 PreemptCount;
 
 // Turn on RTC irqs and arrange for them to check the 32bit threads.
 void
-start_preempt()
+start_preempt(void)
 {
     if (! CONFIG_THREADS || ! CONFIG_THREAD_OPTIONROMS)
         return;
@@ -268,7 +268,7 @@ start_preempt()
 
 // Turn off RTC irqs / stop checking for thread execution.
 void
-finish_preempt()
+finish_preempt(void)
 {
     if (! CONFIG_THREADS || ! CONFIG_THREAD_OPTIONROMS)
         return;
@@ -277,11 +277,11 @@ finish_preempt()
     dprintf(1, "Done preempt - %d checks\n", PreemptCount);
 }
 
-extern void yield_preempt();
+extern void yield_preempt(void);
 #if MODESEGMENT == 0
 // Try to execute 32bit threads.
 void VISIBLE32FLAT
-yield_preempt()
+yield_preempt(void)
 {
     PreemptCount++;
     switch_next(&MainThread);
@@ -290,7 +290,7 @@ yield_preempt()
 
 // 16bit code that checks if threads are pending and executes them if so.
 void
-check_preempt()
+check_preempt(void)
 {
     if (! CONFIG_THREADS || ! CONFIG_THREAD_OPTIONROMS
         || !GET_GLOBAL(CanPreempt)
index 59999c5a093f23ecdb1b4b5c3a4c539815628c58..7b87b8670d823ec3b5ff85e935d2795c96fbcedd 100644 (file)
@@ -34,9 +34,9 @@ union u64_u32_u {
 #define UNIQSEC __FILE__ "." __stringify(__LINE__)
 
 #define __noreturn __attribute__((noreturn))
-extern void __force_link_error__only_in_32bit_flat() __noreturn;
-extern void __force_link_error__only_in_32bit_segmented() __noreturn;
-extern void __force_link_error__only_in_16bit() __noreturn;
+extern void __force_link_error__only_in_32bit_flat(void) __noreturn;
+extern void __force_link_error__only_in_32bit_segmented(void) __noreturn;
+extern void __force_link_error__only_in_16bit(void) __noreturn;
 
 #define __ASM(code) asm(".section .text.asm." UNIQSEC "\n\t" code)
 
index 8cb501ad6e5a1408a1ecdbe727fd10bde12aaf83..7756c620faf85d10041260ef955221bc76e49772 100644 (file)
@@ -88,7 +88,7 @@ usb_keyboard_init(u32 endp, struct usb_interface_descriptor *iface, int imax)
 }
 
 void
-usb_keyboard_setup()
+usb_keyboard_setup(void)
 {
     if (! CONFIG_USB_KEYBOARD)
         return;
@@ -168,7 +168,7 @@ handle_key(struct keyevent *data)
 }
 
 void
-usb_check_key()
+usb_check_key(void)
 {
     if (! CONFIG_USB_KEYBOARD)
         return;
index 26ca91a7d95175d2866befdb4dd7ce254cfc14aa..6dbb2ada2a0964c27fd7f699a181ea4e0a38f4a1 100644 (file)
@@ -5,8 +5,8 @@
 struct usb_interface_descriptor;
 int usb_keyboard_init(u32 endp, struct usb_interface_descriptor *iface
                       , int imax);
-void usb_keyboard_setup();
-void usb_check_key();
+void usb_keyboard_setup(void);
+void usb_check_key(void);
 
 
 /****************************************************************
index fcc404bebde77a7336869dd99027e5f55fbca48a..2bd5832f6d12dca2b6fcaa03c187d16cfd91a59f 100644 (file)
--- a/src/usb.c
+++ b/src/usb.c
@@ -195,7 +195,7 @@ fail:
 }
 
 void
-usb_setup()
+usb_setup(void)
 {
     if (! CONFIG_USB)
         return;
index fe674c0bc9aeafc7bb70974bc21bddd3ab567c8d..cc71c31a5de5a366c9dc23a245150b1105ffa094 100644 (file)
--- a/src/usb.h
+++ b/src/usb.h
@@ -32,7 +32,7 @@ struct usb_pipe {
 #define USB_MAXADDR 127
 
 // usb.c
-void usb_setup();
+void usb_setup(void);
 int configure_usb_device(struct usb_s *cntl, int lowspeed);
 struct usb_ctrlrequest;
 int send_default_control(u32 endp, const struct usb_ctrlrequest *req
index 552f944bbcb8e130db71b2a0f7364c5482cb7af6..b89a2b5b756f589634040455a351f6d8b221083d 100644 (file)
@@ -66,7 +66,7 @@ ASM16(
     );
 
 void
-check_irqs()
+check_irqs(void)
 {
     if (MODE16) {
         asm volatile(
@@ -288,7 +288,7 @@ biosusleep(u32 usec)
 
 // See if a keystroke is pending in the keyboard buffer.
 static int
-check_for_keystroke()
+check_for_keystroke(void)
 {
     struct bregs br;
     memset(&br, 0, sizeof(br));
@@ -300,7 +300,7 @@ check_for_keystroke()
 
 // Return a keystroke - waiting forever if necessary.
 static int
-get_raw_keystroke()
+get_raw_keystroke(void)
 {
     struct bregs br;
     memset(&br, 0, sizeof(br));
index 50cb33645113fb5d071bdd1aeaa678cf66b5c956..60a72599a1457c4e00613f18a6d6943b44bcae3d 100644 (file)
@@ -101,7 +101,7 @@ static inline u32 __fls(u32 word)
     return word;
 }
 
-static inline u32 getesp() {
+static inline u32 getesp(void) {
     u32 esp;
     asm("movl %%esp, %0" : "=rm"(esp));
     return esp;
@@ -164,7 +164,7 @@ inline void __call16_int(struct bregs *callregs, u16 offset);
         extern void irq_trampoline_ ##nr ();                    \
         __call16_int((callregs), (u32)&irq_trampoline_ ##nr );  \
     } while (0)
-void check_irqs();
+void check_irqs(void);
 u8 checksum_far(u16 buf_seg, void *buf_far, u32 len);
 u8 checksum(void *buf, u32 len);
 size_t strlen(const char *s);
@@ -188,17 +188,17 @@ int get_keystroke(int msec);
 // stacks.c
 inline u32 stack_hop(u32 eax, u32 edx, u32 ecx, void *func);
 extern struct thread_info MainThread;
-void thread_setup();
-struct thread_info *getCurThread();
-void yield();
+void thread_setup(void);
+struct thread_info *getCurThread(void);
+void yield(void);
 void run_thread(void (*func)(void*), void *data);
-void wait_threads();
-void start_preempt();
-void finish_preempt();
-void check_preempt();
+void wait_threads(void);
+void start_preempt(void);
+void finish_preempt(void);
+void check_preempt(void);
 
 // output.c
-void debug_serial_setup();
+void debug_serial_setup(void);
 void panic(const char *fmt, ...)
     __attribute__ ((format (printf, 1, 2))) __noreturn;
 void printf(const char *fmt, ...)
@@ -227,28 +227,28 @@ void __debug_isr(const char *fname);
 void hexdump(const void *d, int len);
 
 // kbd.c
-void kbd_setup();
+void kbd_setup(void);
 void handle_15c2(struct bregs *regs);
 void process_key(u8 key);
 
 // mouse.c
-void mouse_setup();
+void mouse_setup(void);
 void process_mouse(u8 data);
 
 // system.c
 extern u32 RamSize;
 extern u64 RamSizeOver4G;
-void mathcp_setup();
+void mathcp_setup(void);
 
 // serial.c
-void serial_setup();
-void lpt_setup();
+void serial_setup(void);
+void lpt_setup(void);
 
 // clock.c
 static inline int check_time(u64 end) {
     return (s64)(rdtscll() - end) > 0;
 }
-void timer_setup();
+void timer_setup(void);
 void ndelay(u32 count);
 void udelay(u32 count);
 void mdelay(u32 count);
@@ -259,8 +259,8 @@ u64 calc_future_tsc(u32 msecs);
 u64 calc_future_tsc_usec(u32 usecs);
 void handle_1583(struct bregs *regs);
 void handle_1586(struct bregs *regs);
-void useRTC();
-void releaseRTC();
+void useRTC(void);
+void releaseRTC(void);
 
 // apm.c
 void handle_1553(struct bregs *regs);
@@ -270,14 +270,14 @@ void handle_1ab1(struct bregs *regs);
 void bios32_setup(void);
 
 // shadow.c
-void make_bios_writable();
-void make_bios_readonly();
+void make_bios_writable(void);
+void make_bios_readonly(void);
 
 // pciinit.c
 void pci_setup(void);
 
 // smm.c
-void smm_init();
+void smm_init(void);
 
 // smp.c
 extern u32 CountCPUs;
@@ -295,37 +295,37 @@ int cbfs_copyfile(struct cbfs_file *file, void *dst, u32 maxlen);
 int cbfs_copy_optionrom(void *dst, u32 maxlen, u32 vendev);
 void cbfs_run_payload(struct cbfs_file *file);
 
-void coreboot_copy_biostable();
-void coreboot_setup();
+void coreboot_copy_biostable(void);
+void coreboot_setup(void);
 
 // vgahooks.c
 extern int VGAbdf;
-void handle_155f();
+void handle_155f(struct bregs *regs);
 void vgahook_setup(const char *vendor, const char *part);
 
 // optionroms.c
 void call_bcv(u16 seg, u16 ip);
-void optionrom_setup();
-void vga_setup();
-void s3_resume_vga_init();
+void optionrom_setup(void);
+void vga_setup(void);
+void s3_resume_vga_init(void);
 extern u32 RomEnd;
 
 // resume.c
-void init_dma();
+void init_dma(void);
 
 // pnpbios.c
 #define PNP_SIGNATURE 0x506e5024 // $PnP
-u16 get_pnp_offset();
-void pnp_setup();
+u16 get_pnp_offset(void);
+void pnp_setup(void);
 
 // pmm.c
 extern struct zone_s ZoneLow, ZoneHigh, ZoneFSeg, ZoneTmpLow, ZoneTmpHigh;
-void malloc_setup();
-void malloc_finalize();
+void malloc_setup(void);
+void malloc_finalize(void);
 void *pmm_malloc(struct zone_s *zone, u32 handle, u32 size, u32 align);
 int pmm_free(void *data);
-void pmm_setup();
-void pmm_finalize();
+void pmm_setup(void);
+void pmm_finalize(void);
 #define PMM_DEFAULT_HANDLE 0xFFFFFFFF
 // Minimum alignment of malloc'd memory
 #define MALLOC_MIN_ALIGN 16
@@ -359,7 +359,7 @@ static inline void free(void *data) {
 void mtrr_setup(void);
 
 // romlayout.S
-void reset_vector() __noreturn;
+void reset_vector(void) __noreturn;
 
 // misc.c
 extern u8 BiosChecksum;
index ef33be5690eb4f104f2e626b5ba388254840a300..26ae1563b199e9f7770c45f886daac231687ee0f 100644 (file)
@@ -69,7 +69,7 @@ getViaRamSpeed(u16 bdf)
 }
 
 static int
-getAMDRamSpeed()
+getAMDRamSpeed(void)
 {
     int bdf = pci_find_device(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_K8_NB_MEMCTL);
     if (bdf < 0)
index 13e3c2bdb0d6d624bab25affa02ebfb3e8a7ce0d..36ccad3556176f468f7aee855baa9e3ae9094a9e 100644 (file)
@@ -315,7 +315,7 @@ cirrus_switch_mode_setregs(u16 *data, u16 port)
 }
 
 static u16
-cirrus_get_crtc()
+cirrus_get_crtc(void)
 {
     if (inb(VGAREG_READ_MISC_OUTPUT) & 1)
         return VGAREG_VGA_CRTC_ADDRESS;
@@ -364,14 +364,14 @@ cirrus_set_video_mode(u8 mode)
 }
 
 static int
-cirrus_check()
+cirrus_check(void)
 {
     outw(0x9206, VGAREG_SEQU_ADDRESS);
     return inb(VGAREG_SEQU_DATA) == 0x12;
 }
 
 void
-cirrus_init()
+cirrus_init(void)
 {
     dprintf(1, "cirrus init\n");
     if (! cirrus_check())
index 888c71118cb52abb30e441e54284541abd751d08..e38298e780622b2e216576870129e77dd2559062 100644 (file)
@@ -1330,7 +1330,7 @@ handle_10(struct bregs *regs)
  ****************************************************************/
 
 static void
-init_bios_area()
+init_bios_area(void)
 {
     // init detected hardware BIOS Area
     // set 80x25 color (not clear from RBIL but usual)
index d341b89ab114443d97b9fd47e7b7803d9fad2c99..ffded3453d269fe4161daad4f7fce97eedcb0808 100644 (file)
  ****************************************************************/
 
 void
-vgahw_screen_disable()
+vgahw_screen_disable(void)
 {
     inb(VGAREG_ACTL_RESET);
     outb(0x00, VGAREG_ACTL_ADDRESS);
 }
 
 void
-vgahw_screen_enable()
+vgahw_screen_enable(void)
 {
     inb(VGAREG_ACTL_RESET);
     outb(0x20, VGAREG_ACTL_ADDRESS);
@@ -65,7 +65,7 @@ vgahw_set_overscan_border_color(u8 color)
 }
 
 u8
-vgahw_get_overscan_border_color()
+vgahw_get_overscan_border_color(void)
 {
     inb(VGAREG_ACTL_RESET);
     outb(0x11, VGAREG_ACTL_ADDRESS);
@@ -240,7 +240,7 @@ vgahw_set_pel_mask(u8 val)
 }
 
 u8
-vgahw_get_pel_mask()
+vgahw_get_pel_mask(void)
 {
     return inb(VGAREG_PEL_MASK);
 }
@@ -288,7 +288,7 @@ vgahw_set_text_block_specifier(u8 spec)
 }
 
 void
-get_font_access()
+get_font_access(void)
 {
     outw(0x0100, VGAREG_SEQU_ADDRESS);
     outw(0x0402, VGAREG_SEQU_ADDRESS);
@@ -300,7 +300,7 @@ get_font_access()
 }
 
 void
-release_font_access()
+release_font_access(void)
 {
     outw(0x0100, VGAREG_SEQU_ADDRESS);
     outw(0x0302, VGAREG_SEQU_ADDRESS);
@@ -318,7 +318,7 @@ release_font_access()
  ****************************************************************/
 
 static u16
-get_crtc()
+get_crtc(void)
 {
     return GET_BDA(crtc_address);
 }
@@ -365,7 +365,7 @@ vgahw_set_scan_lines(u8 lines)
 
 // Get vertical display end
 u16
-vgahw_get_vde()
+vgahw_get_vde(void)
 {
     u16 crtc_addr = get_crtc();
     outb(0x12, crtc_addr);
@@ -545,7 +545,7 @@ vgahw_enable_video_addressing(u8 disable)
 }
 
 void
-vgahw_init()
+vgahw_init(void)
 {
     // switch to color mode and enable CPU access 480 lines
     outb(0xc3, VGAREG_WRITE_MISC_OUTPUT);
index e5f3309cc5e74d541c5937961de89bfd56a0259e..1e76b3aafe7117ea25c6a7a876b1c7c02efbf0db 100644 (file)
@@ -169,11 +169,11 @@ void vgafb_load_font(u16 seg, void *src_far, u16 count
                      , u16 start, u8 destflags, u8 fontsize);
 
 // vgaio.c
-void vgahw_screen_disable();
-void vgahw_screen_enable();
+void vgahw_screen_disable(void);
+void vgahw_screen_enable(void);
 void vgahw_set_border_color(u8 color);
 void vgahw_set_overscan_border_color(u8 color);
-u8 vgahw_get_overscan_border_color();
+u8 vgahw_get_overscan_border_color(void);
 void vgahw_set_palette(u8 palid);
 void vgahw_set_single_palette_reg(u8 reg, u8 val);
 u8 vgahw_get_single_palette_reg(u8 reg);
@@ -185,33 +185,33 @@ void vgahw_read_video_dac_state(u8 *pmode, u8 *curpage);
 void vgahw_set_dac_regs(u16 seg, u8 *data_far, u8 start, int count);
 void vgahw_get_dac_regs(u16 seg, u8 *data_far, u8 start, int count);
 void vgahw_set_pel_mask(u8 val);
-u8 vgahw_get_pel_mask();
+u8 vgahw_get_pel_mask(void);
 void vgahw_save_dac_state(u16 seg, struct saveDACcolors *info);
 void vgahw_restore_dac_state(u16 seg, struct saveDACcolors *info);
 void vgahw_sequ_write(u8 index, u8 value);
 void vgahw_grdc_write(u8 index, u8 value);
 void vgahw_set_text_block_specifier(u8 spec);
-void get_font_access();
-void release_font_access();
+void get_font_access(void);
+void release_font_access(void);
 void vgahw_set_cursor_shape(u8 start, u8 end);
 void vgahw_set_active_page(u16 address);
 void vgahw_set_cursor_pos(u16 address);
 void vgahw_set_scan_lines(u8 lines);
-u16 vgahw_get_vde();
+u16 vgahw_get_vde(void);
 void vgahw_save_state(u16 seg, struct saveVideoHardware *info);
 void vgahw_restore_state(u16 seg, struct saveVideoHardware *info);
 void vgahw_set_mode(struct VideoParam_s *vparam_g);
 void vgahw_enable_video_addressing(u8 disable);
-void vgahw_init();
+void vgahw_init(void);
 
 // clext.c
 void cirrus_set_video_mode(u8 mode);
-void cirrus_init();
+void cirrus_init(void);
 
 // vbe.c -- not implemented yet.
 #define VBE_DISPI_DISABLED              0x00
 void dispi_set_enable(int enable);
-void vbe_init();
-int vbe_has_vbe_display();
+void vbe_init(void);
+int vbe_has_vbe_display(void);
 
 #endif // vgatables.h