# --- T2-COPYRIGHT-BEGIN --- # t2/package/*/aboot/hotfix-netboot.patch # Copyright (C) 2025 The T2 SDE Project # SPDX-License-Identifier: GPL-2.0 or patched project license # --- T2-COPYRIGHT-END --- --- aboot-dde7f7b85f7631668f1da7c0b0ecf7ddbbde004e/Makefile.vanilla 2025-09-09 14:34:59.035534860 +0200 +++ aboot-dde7f7b85f7631668f1da7c0b0ecf7ddbbde004e/Makefile 2025-09-09 14:49:59.652614705 +0200 @@ -35,14 +35,14 @@ ABOOT_LDFLAGS = -static -N -Taboot.lds --relax ifeq ($(TESTING),) -override CPPFLAGS += $(CFGDEFS) -U_FORTIFY_SOURCE -Iinclude -override CFLAGS += $(CPPFLAGS) -Os -Wall -ffreestanding -mno-fp-regs -msmall-data -msmall-text +CPPFLAGS += $(CFGDEFS) -U_FORTIFY_SOURCE -Iinclude +CFLAGS += $(CPPFLAGS) -Os -Wall -ffreestanding -mno-fp-regs -msmall-data -msmall-text else -override CPPFLAGS += -DTESTING $(CFGDEFS) -U_FORTIFY_SOURCE -Iinclude -override CFLAGS += $(CPPFLAGS) -O -g3 -Wall +CPPFLAGS += -DTESTING $(CFGDEFS) -U_FORTIFY_SOURCE -Iinclude +CFLAGS += $(CPPFLAGS) -O -g3 -Wall endif -override ASFLAGS += $(CPPFLAGS) +ASFLAGS += $(CPPFLAGS) .c.s: @@ -119,10 +119,10 @@ cat net_aboot.nh $(VMLINUXGZ) net_pad > $@ net_aboot.nh: net_aboot tools/objstrip - strip net_aboot + $(STRIP) net_aboot tools/objstrip -vb net_aboot $@ -net_aboot: $(ABOOT_OBJS) $(ABOOT_OBJS) $(NET_OBJS) $(LIBS) +net_aboot: $(ABOOT_OBJS) $(NET_OBJS) $(LIBS) $(LD) $(ABOOT_LDFLAGS) $(ABOOT_OBJS) $(NET_OBJS) -o $@ $(LIBS) net_pad: --- aboot-dde7f7b85f7631668f1da7c0b0ecf7ddbbde004e/netabootwrap.c.vanilla 2025-09-09 15:08:57.032733536 +0200 +++ aboot-dde7f7b85f7631668f1da7c0b0ecf7ddbbde004e/netabootwrap.c 2025-09-09 15:11:49.767348032 +0200 @@ -1,12 +1,16 @@ #include -#include -#include "system.h" #include #include #include #include #include #include + +/* from system.h */ +#define PAGE_SHIFT 13 +#define PAGE_SIZE (1UL << PAGE_SHIFT) +#define PAGE_OFFSET 0xfffffc0000000000UL + #include "netwrap.h" #include "bootloader.h"