shithub: drawcpu

Download patch

ref: 6ca7a7fcb03e0ef651368e5a782b29c392e16149
parent: 9c00c613885deba1ed19e905604571ef432cab11
author: halfwit <michaelmisch1985@gmail.com>
date: Thu Jan 8 17:50:57 EST 2026

Works with tlssrv -A, nice

--- a/kern/arm.c
+++ b/kern/arm.c
@@ -52,7 +52,7 @@
     ulong amount, val;
     val = up->R[instr & 15];
     if(instr & (1<<4)) {
-        if(instr & (1<<7))
+        if((instr & (1<<7)) && ((instr >> 8) & 0xF) != 0)
             invalid(instr);
         amount = up->R[(instr >> 8) & 15] & 0xFF;
         if(amount == 0)
--- a/kern/devroot.c
+++ b/kern/devroot.c
@@ -13,10 +13,12 @@
 	Qroot,
 	Qcpu,
 	Qterm,
+	Qtemp,
+	Qplumb,
 
 	Nrootfiles = 32,
 	Nbootfiles = 32,
-	Nmntfiles = 5,
+	Nmntfiles = 7,
 };
 
 typedef struct Dirlist Dirlist;
@@ -64,6 +66,8 @@
 	"root", {Qroot, 0, QTDIR}, 0, DMDIR|0555,
 	"cpu", {Qcpu, 0, QTDIR}, 0, DMDIR|0555,
 	"term", {Qterm, 0, QTDIR}, 0, DMDIR|0555,
+	"temp", {Qtemp, 0, QTDIR}, 0, DMDIR|0555,
+	"plumb", {Qplumb, 0, QTDIR}, 0, DMDIR|0555,
 };
 static Dirlist mntlist =
 {
@@ -70,7 +74,7 @@
 	Qmnt,
 	mntdir,
 	mntdata,
-	5,
+	7,
 	Nmntfiles
 };
 
--- a/main.c
+++ b/main.c
@@ -151,7 +151,7 @@
 	ksetenv("rootdir", "/root", 0);
 	ksetenv("auth", auth, 0);
 	ksetenv("user", eve, 0);
-	ksetenv("service", "cpu", 0);
+	ksetenv("service", "unix", 0);
 	ksetenv("sysname", sysname, 0);
 	ksetenv("prompt", "unix\% ", 0);
 	ksetenv("nvram", "/tmp/nvram", 0); /* Set up in the host /tmp */
--