Build - Removed -Werror from kmode to allow scan-build to be run
authorJohn Hodge <[email protected]>
Thu, 1 Dec 2011 11:13:43 +0000 (19:13 +0800)
committerJohn Hodge <[email protected]>
Thu, 1 Dec 2011 11:13:43 +0000 (19:13 +0800)
BuildConf/host/Makefile.cfg [new file with mode: 0644]
BuildConf/host/Makefile.host.cfg [deleted file]
BuildConf/host/default.mk [new file with mode: 0644]
BuildConf/x86_64/Makefile.cfg
Kernel/Makefile
Modules/Makefile.tpl
Modules/Storage/ATA/io.c

diff --git a/BuildConf/host/Makefile.cfg b/BuildConf/host/Makefile.cfg
new file mode 100644 (file)
index 0000000..1a28638
--- /dev/null
@@ -0,0 +1,15 @@
+#
+# Acess2 Host Native makefile
+# - Used for forcing the architecture
+#
+
+SAVED_CC_ := $(CC)
+SAVED_LD_ := $(LD)
+
+include $(ACESSDIR)/BuildConf/x86_64/Makefile.cfg
+
+OBJDUMP := objdump -S
+
+CC := $(SAVED_CC_)
+LD := $(SAVED_LD_)
+
diff --git a/BuildConf/host/Makefile.host.cfg b/BuildConf/host/Makefile.host.cfg
deleted file mode 100644 (file)
index dee50de..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-#
-# Acess2 Host Native makefile
-# - Used for forcing the architecture
-#
-
-SAVED_CC_ := $(CC)
-SAVED_LD_ := $(LD)
-
-include $(ACESSDIR)/Makefile.x86_64.cfg
-
-OBJDUMP := objdump -S
-
-CC := $(SAVED_CC_)
-LD := $(SAVED_LD_)
-
diff --git a/BuildConf/host/default.mk b/BuildConf/host/default.mk
new file mode 100644 (file)
index 0000000..787d494
--- /dev/null
@@ -0,0 +1,9 @@
+
+MODULES += Storage/ATA
+MODULES += Storage/FDDv2
+MODULES += Network/NE2000 Network/RTL8139
+MODULES += Display/VESA
+MODULES += Display/BochsGA
+MODULES += Input/PS2KbMouse
+MODULES += x86/ISADMA x86/VGAText
+MODULES += USB/Core USB/UHCI
index 54bbf51..ab188fb 100644 (file)
@@ -3,7 +3,7 @@ CC = x86_64-none-elf-gcc
 LD = x86_64-none-elf-ld
 DISASM = x86_64-none-elf-objdump -d -M x86-64 -S
 
-KERNEL_CFLAGS := -mcmodel=kernel -nostdlib -mno-red-zone -Wall -Werror
+KERNEL_CFLAGS := -mcmodel=kernel -nostdlib -mno-red-zone -Wall
 DYNMOD_CFLAGS := -mcmodel=small -fPIC -mno-red-zone
 
 ARCHDIR = x86_64
index fc76c47..c972ed4 100644 (file)
@@ -21,7 +21,7 @@ MAKEDEP               = $(CC) -M
 CPPFLAGS       += -I./include -I./arch/$(ARCHDIR)/include -D_MODULE_NAME_=\"Kernel\"
 CPPFLAGS       += -DARCH=$(ARCH) -DARCHDIR=$(ARCHDIR) -DARCHDIR_IS_$(ARCHDIR)=1
 CPPFLAGS       += -DKERNEL_VERSION=$(KERNEL_VERSION)
-CFLAGS         += -Wall -Werror -fno-stack-protector -Wstrict-prototypes -g
+CFLAGS         += -Wall -fno-stack-protector -Wstrict-prototypes -g
 CFLAGS         += -Wshadow -Wpointer-arith -Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs -Winline -Wuninitialized
 CFLAGS          += -O3
 LDFLAGS                += -T arch/$(ARCHDIR)/link.ld -g
index 53a059f..f1c31a5 100644 (file)
@@ -13,7 +13,7 @@ CPPFLAGS := -I$(ACESSDIR)/Kernel/include -I$(ACESSDIR)/Kernel/arch/$(ARCHDIR)/in
 CPPFLAGS += -DARCH=$(ARCH) -DARCH_is_$(ARCH) -DARCHDIR_is_$(ARCHDIR)
 CPPFLAGS += $(_CPPFLAGS)
 CPPFLAGS += $(LIBINCLUDES)
-CFLAGS := -std=gnu99 -Wall -Werror -fno-stack-protector -g -O3
+CFLAGS := -std=gnu99 -Wall -fno-stack-protector -g -O3
 
 ifneq ($(CATEGORY),)
        FULLNAME := $(CATEGORY)_$(NAME)
index 128fdca..6304cb4 100644 (file)
@@ -285,7 +285,6 @@ int ATA_ReadDMA(Uint8 Disk, Uint64 Address, Uint Count, void *Buffer)
         int    disk = Disk & 1;
        Uint16  base;
        Sint64  timeoutTime;
-       Uint8   val;
 
        ENTER("iDisk XAddress iCount pBuffer", Disk, Address, Count, Buffer);
 
@@ -376,9 +375,15 @@ int ATA_ReadDMA(Uint8 Disk, Uint64 Address, Uint Count, void *Buffer)
        // Complete Transfer
        ATA_int_BusMasterWriteByte( cont * 8, 8 );      // Read and stop
 
-       val = inb(base+0x7);
-       LOG("Status byte = 0x%02x, Controller Status = 0x%02x",
-               val, ATA_int_BusMasterReadByte(cont * 8 + 2));
+       #if DEBUG
+       {
+               Uint8   val = inb(base+0x7);
+               LOG("Status byte = 0x%02x, Controller Status = 0x%02x",
+                       val, ATA_int_BusMasterReadByte(cont * 8 + 2));
+       }
+       #else
+       inb(base+0x7);
+       #endif
 
        if( gaATA_IRQs[cont] == 0 )
        {

UCC git Repository :: git.ucc.asn.au