Permalink
Browse files

correct all warning

  • Loading branch information...
SegFault42 committed Jul 24, 2018
1 parent 1cefcf5 commit 3da44e8f8428b94ff6c3bf8ef9e928475ff30f71
Showing with 6 additions and 5 deletions.
  1. +3 −2 Makefile
  2. +1 −1 src/firmware.c
  3. +1 −1 src/hwinit/util.c
  4. +1 −1 src/start.s
View
@@ -16,7 +16,7 @@ dir_build := build
dir_out := out
ARCH := -march=armv4t -mtune=arm7tdmi -mthumb -mthumb-interwork
CFLAGS = $(ARCH) -Os -nostdlib -ffunction-sections -fdata-sections -fomit-frame-pointer -fno-inline -std=gnu11# -Wall
CFLAGS = $(ARCH) -Os -nostdlib -ffunction-sections -fdata-sections -fomit-frame-pointer -fno-inline -fno-builtin -std=gnu11# -Wall
LDFLAGS = $(ARCH) -nostartfiles -lgcc -Wl,--nmagic,--gc-sections
objects = $(patsubst $(dir_source)/%.s, $(dir_build)/%.o, \
@@ -32,6 +32,7 @@ all: $(dir_out)/$(name).bin
.PHONY: clean
clean:
@echo "clean ..."
@rm -rf $(dir_build)
@rm -rf $(dir_out)
@@ -51,4 +52,4 @@ $(dir_build)/%.o: $(dir_source)/%.c
$(dir_build)/%.o: $(dir_source)/%.s
@mkdir -p "$(@D)"
$(CC) $(CFLAGS) -c $< -o $@
$(CC) $(CFLAGS) -c $< -o $@
View
@@ -67,7 +67,7 @@ void drawSplash() {
pk11_offs *pkg11_offsentify(u8 *pkg1) {
for (u32 i = 0; _pk11_offs[i].id; i++)
if (!memcmp(pkg1 + 0x10, _pk11_offs[i].id, 12))
return &_pk11_offs[i];
return (pk11_offs *)&_pk11_offs[i];
return NULL;
}
View
@@ -57,7 +57,7 @@ void exec_cfg(u32 *base, const cfg_op_t *ops, u32 num_ops)
uPtr memsearch(const u8 *startPos, u32 searchSize, const void *pattern, u32 patternSize) {
if(!searchSize) return 0;
for (void *pos = startPos; pos <= startPos + searchSize - patternSize; pos++) {
for (u8 *pos = (u8 *)startPos; pos <= startPos + searchSize - patternSize; pos++) {
if (memcmp(pos, pattern, patternSize) == 0) return (uPtr)pos;
}
return 0;
View
@@ -87,4 +87,4 @@ rebootRCM:
LDR R1, [R2]
ORRS R3, R1
MOVS R0, #0
STR R3, [R2]
STR R3, [R2]

0 comments on commit 3da44e8

Please sign in to comment.