From a0d2bc60bdcc0a5ee9e790fa3b02fe5051a152d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20T=C3=B6rnblom?= Date: Sat, 4 Jul 2026 00:02:52 +0200 Subject: [PATCH] cosmetics --- crt/kernel.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/crt/kernel.c b/crt/kernel.c index 8e47c90..1a6a0ca 100644 --- a/crt/kernel.c +++ b/crt/kernel.c @@ -42,6 +42,9 @@ along with this program; see the file COPYING. If not, see #define IN6_PKTINFOSZ 5 +/** + * + **/ typedef union kernel_pipebuf { unsigned int n[IN6_PKTINFOSZ]; struct __attribute__((packed)) { @@ -58,7 +61,7 @@ typedef union kernel_pipebuf { } pbuf; struct __attribute__((packed)) { - unsigned long addr; + unsigned long kaddr; unsigned int reserved[3]; } vbuf; } kernel_pipebuf_t; @@ -498,13 +501,13 @@ __kernel_init(payload_args_t* args) { * Write data to an address in kernel space. **/ static int -kernel_write(unsigned long addr, void* data, unsigned long len) { +kernel_write(unsigned long kaddr, void* data, unsigned long len) { kernel_pipebuf_t buf = { - .vbuf.addr = addr, + .vbuf.kaddr = kaddr }; // sanity check for invalid kernel pointers - if(!(addr & 0xffff000000000000)) { + if(!(kaddr & 0xffff000000000000)) { SET_ERRNO(EFAULT); return -1; }