FUZIX.git
6 years agoLibrary: add round and roundf
Alan Cox [Sat, 30 Sep 2017 19:12:07 +0000 (20:12 +0100)]
Library: add round and roundf

6 years agoLibrary: add round.c to the maths library
Alan Cox [Sat, 30 Sep 2017 18:35:24 +0000 (19:35 +0100)]
Library: add round.c to the maths library

6 years agoLibrary: update the API list
Alan Cox [Sat, 30 Sep 2017 18:28:08 +0000 (19:28 +0100)]
Library: update the API list

We still have some gaps in the odder bits of library space

6 years ago65c816: note more things to fix
Alan Cox [Sat, 30 Sep 2017 18:20:15 +0000 (19:20 +0100)]
65c816: note more things to fix

6 years agov65: note a 6502 assumption we are making
Alan Cox [Sat, 30 Sep 2017 18:19:49 +0000 (19:19 +0100)]
v65: note a 6502 assumption we are making

6 years agolibrary: add sgetl and sputl
Alan Cox [Sat, 30 Sep 2017 18:19:08 +0000 (19:19 +0100)]
library: add sgetl and sputl

6 years agogetopt: correct details of prototype (cc65 cares about the difference)
Alan Cox [Sat, 30 Sep 2017 18:18:47 +0000 (19:18 +0100)]
getopt: correct details of prototype (cc65 cares about the difference)

6 years ago6502: fix Library build
Alan Cox [Sat, 30 Sep 2017 18:18:25 +0000 (19:18 +0100)]
6502: fix Library build

6 years agoREADME.binfmt: Document executable format and related data
Alan Cox [Sat, 30 Sep 2017 17:56:24 +0000 (18:56 +0100)]
README.binfmt: Document executable format and related data

Also document the proposed changes

6 years agoMakefile: ensure fcc path is present
Alan Cox [Sat, 30 Sep 2017 13:06:29 +0000 (14:06 +0100)]
Makefile: ensure fcc path is present

6 years agoMakefile: split CPU and USERCPU
Alan Cox [Fri, 29 Sep 2017 21:52:48 +0000 (22:52 +0100)]
Makefile: split CPU and USERCPU

6 years ago65c816: ld config file
Alan Cox [Fri, 29 Sep 2017 21:46:54 +0000 (22:46 +0100)]
65c816: ld config file

6 years agold65-65c816: config file for near 64K sized binaries
Alan Cox [Fri, 29 Sep 2017 21:46:01 +0000 (22:46 +0100)]
ld65-65c816: config file for near 64K sized binaries

6 years agococo2cart: link file
Alan Cox [Fri, 29 Sep 2017 21:39:15 +0000 (22:39 +0100)]
coco2cart: link file

6 years agokernel: simplify Makefile
Alan Cox [Fri, 29 Sep 2017 21:38:50 +0000 (22:38 +0100)]
kernel: simplify Makefile

6 years agoMakefile: tweaks for some 6809 stuff
Alan Cox [Fri, 29 Sep 2017 21:38:27 +0000 (22:38 +0100)]
Makefile: tweaks for some 6809 stuff

With this 6809 works

6 years agoApplications: remove now dead Makefiles
Alan Cox [Fri, 29 Sep 2017 21:16:28 +0000 (22:16 +0100)]
Applications: remove now dead Makefiles

6 years agoMakefile: change top level makefile for new setup
Alan Cox [Fri, 29 Sep 2017 21:15:24 +0000 (22:15 +0100)]
Makefile: change top level makefile for new setup

6 years agoApplications: Update for new Makefile setup
Alan Cox [Fri, 29 Sep 2017 21:14:35 +0000 (22:14 +0100)]
Applications: Update for new Makefile setup

We now have a Makefile.$(CPU) for each - not all are complete yet but the
rest can be filled in, or null targetted if not relevant to that platform.

6 years agoLibrary: Makefile changes so we can have a saner build set up
Alan Cox [Fri, 29 Sep 2017 21:12:26 +0000 (22:12 +0100)]
Library: Makefile changes so we can have a saner build set up

6 years agoTODO: swap free reporting is now done
Alan Cox [Fri, 29 Sep 2017 21:11:35 +0000 (22:11 +0100)]
TODO: swap free reporting is now done

6 years agotools: fix makeversion
Alan Cox [Fri, 29 Sep 2017 21:11:21 +0000 (22:11 +0100)]
tools: fix makeversion

6 years agoREADME: update and remove obsolete bits
Alan Cox [Fri, 29 Sep 2017 21:10:58 +0000 (22:10 +0100)]
README: update and remove obsolete bits

6 years agoLibrary: preparations for sorting out Makefiles
Alan Cox [Fri, 29 Sep 2017 21:10:39 +0000 (22:10 +0100)]
Library: preparations for sorting out Makefiles

6 years agosyscalls.h: fix error in headers
Alan Cox [Fri, 29 Sep 2017 21:10:09 +0000 (22:10 +0100)]
syscalls.h: fix error in headers

6 years agokernel: remove obsolete CP/M bits
Alan Cox [Fri, 29 Sep 2017 14:54:32 +0000 (15:54 +0100)]
kernel: remove obsolete CP/M bits

6 years agobank16: trivial tidy
Alan Cox [Thu, 28 Sep 2017 20:43:53 +0000 (21:43 +0100)]
bank16: trivial tidy

6 years agoswap: add reporting of swap space free/available
Alan Cox [Thu, 28 Sep 2017 20:43:37 +0000 (21:43 +0100)]
swap: add reporting of swap space free/available

6 years agokernel.h: add CPu types
Alan Cox [Thu, 28 Sep 2017 20:42:13 +0000 (21:42 +0100)]
kernel.h: add CPu types

6 years agouanme: extend the sysinfo block and add swap bits to it
Alan Cox [Thu, 28 Sep 2017 20:40:59 +0000 (21:40 +0100)]
uanme: extend the sysinfo block and add swap bits to it

Yes this breaks uname() calls so one or two things need recompiling but better
to do it now than later.

For the moment it adds the CPU identifier, more space for CPU info data,
space for some expansion and also gets ready to add the swap info so free
can show swap state.

6 years agoMakefile pieces for 65c816
Alan Cox [Tue, 26 Sep 2017 13:23:14 +0000 (14:23 +0100)]
Makefile pieces for 65c816

6 years ago65c816: fix bank setting bug
Alan Cox [Tue, 26 Sep 2017 13:21:38 +0000 (14:21 +0100)]
65c816: fix bank setting bug

With this fixed we return from syscalls on the right DP and lo and behold
init now runs as far as fork().

6 years ago65c816: fix uputw()
Alan Cox [Tue, 26 Sep 2017 13:01:38 +0000 (14:01 +0100)]
65c816: fix uputw()

6 years ago65c816: note syscall vector in readme
Alan Cox [Tue, 26 Sep 2017 13:01:23 +0000 (14:01 +0100)]
65c816: note syscall vector in readme

6 years agoexecve: note a thing to check, do a spot tidy
Alan Cox [Tue, 26 Sep 2017 13:00:23 +0000 (14:00 +0100)]
execve: note a thing to check, do a spot tidy

6 years ago65c816: fix more asm paths
Alan Cox [Tue, 26 Sep 2017 12:59:55 +0000 (13:59 +0100)]
65c816: fix more asm paths

6 years agov65c816: fix platform code silliness
Alan Cox [Mon, 25 Sep 2017 14:31:30 +0000 (15:31 +0100)]
v65c816: fix platform code silliness

6 years ago65c816: fix various bugs in the core code
Alan Cox [Mon, 25 Sep 2017 14:30:36 +0000 (15:30 +0100)]
65c816: fix various bugs in the core code

With the platform bugs also fixed this takes us to the point that we start
running init and begin to make progress until we take an interrupt in user
mode, at which point badness happens

6 years agocpu-65c816: note 8MB limit in current logic
Alan Cox [Mon, 25 Sep 2017 14:30:11 +0000 (15:30 +0100)]
cpu-65c816: note 8MB limit in current logic

6 years agov65c816: fix disk driver bug
Alan Cox [Sun, 24 Sep 2017 23:59:41 +0000 (00:59 +0100)]
v65c816: fix disk driver bug

Did I ever mention how much I hate the 6402 lda $n,x syntax being for two
completely different things and magically determined unless you remember to
threaten the assembler with violence ?

6 years ago65c816: tidy up hardcoded offset
Alan Cox [Sun, 24 Sep 2017 23:41:41 +0000 (00:41 +0100)]
65c816: tidy up hardcoded offset

6 years agov658c16: fix memory size reporting
Alan Cox [Sun, 24 Sep 2017 23:00:27 +0000 (00:00 +0100)]
v658c16: fix memory size reporting

512K not 8K !

6 years ago65c816: fix interrupt return path for the kernel case
Alan Cox [Sun, 24 Sep 2017 22:57:46 +0000 (23:57 +0100)]
65c816: fix interrupt return path for the kernel case

Was pulling A as 8 not 16bit, grrr.

With this fixed we can try (and fail) to mount a rootfs, but we are messing
something up as bootdev: 0 return gives us a psleep: voododo panic.

6 years agov64: ouch .... how did that ever work ?
Alan Cox [Sun, 24 Sep 2017 01:05:23 +0000 (02:05 +0100)]
v64: ouch .... how did that ever work ?

6 years ago65c816: update the fork code to copy the DP/S area and move S
Alan Cox [Sun, 24 Sep 2017 01:04:54 +0000 (02:04 +0100)]
65c816: update the fork code to copy the DP/S area and move S

6 years ago65c816: further updates
Alan Cox [Sun, 24 Sep 2017 01:04:12 +0000 (02:04 +0100)]
65c816: further updates

This is sufficient to get us to the point we enable interrupts, run platform
interrupt the first time and then explode on the return path due to what looks
like a stack imbalance

6 years agocpu-65c816: add notes
Alan Cox [Sat, 23 Sep 2017 17:58:04 +0000 (18:58 +0100)]
cpu-65c816: add notes

6 years agov65c816: remove dead code
Alan Cox [Sat, 23 Sep 2017 17:57:48 +0000 (18:57 +0100)]
v65c816: remove dead code

6 years agov65c816: make bank code auto-select right number of banks
Alan Cox [Sat, 23 Sep 2017 17:57:27 +0000 (18:57 +0100)]
v65c816: make bank code auto-select right number of banks

6 years ago65c816: further updates
Alan Cox [Sat, 23 Sep 2017 17:19:44 +0000 (18:19 +0100)]
65c816: further updates

At this point it compiles although there is stuff to finish fixing up before
it's even worth trying to boot an image.

6 years ago6502: fix a bug in ugets()
Alan Cox [Sat, 23 Sep 2017 17:18:56 +0000 (18:18 +0100)]
6502: fix a bug in ugets()

Fortunately we never hit this in current uses

7 years ago65c816: Makefile
Alan Cox [Fri, 22 Sep 2017 22:38:38 +0000 (23:38 +0100)]
65c816: Makefile

7 years ago65c816: further updates
Alan Cox [Fri, 22 Sep 2017 22:37:41 +0000 (23:37 +0100)]
65c816: further updates

7 years agov658c16: intial sketches of the needed platform code
Alan Cox [Fri, 22 Sep 2017 22:36:49 +0000 (23:36 +0100)]
v658c16: intial sketches of the needed platform code

Lots to do before this even compiles

7 years ago65c816: this mornings fiddling
Alan Cox [Thu, 21 Sep 2017 21:17:50 +0000 (22:17 +0100)]
65c816: this mornings fiddling

7 years ago65c816: first sketch of needed code
Alan Cox [Wed, 20 Sep 2017 22:10:22 +0000 (23:10 +0100)]
65c816: first sketch of needed code

Lots to fill in yet but this is the basic idea

- Load kernel somewhere
- Bank 0 gets the CPU stacks
- Each process gets a bank
- Kernel gets stuffed in bank 0 if it'll fit, somewhere else if not
- C code runs with cc65 so it's using an external C stack in its own bank
  which should mean we don't have to worry about funny stack accesses (and
  can fix any in the support lib)

Processes aren't allowed to do long operations, or to save/restore bank
registers. Only awkward one here is the block move ops. We probably need
a blockmove 'syscall' that puts in th banks and avoids a process moving
bank while mvn/mvp executes (as it's interruptible).

As there is only one configuration of banking we can hopefully put all the glue
in the shared file to make platform support easier.

7 years agosmallc: remove literal buffer
Alan Cox [Wed, 20 Sep 2017 13:04:31 +0000 (14:04 +0100)]
smallc: remove literal buffer

Restructure the code so that literal data is generated inline relying upon the
assembler segment functionality to sort out the interleaving. A platform whose
assembler isn't good enough can always switch between two files...

This saves us about 3K and means that the literal space is no longer limited
to 2.5K per compiled file.

You stil can't initialize pointers but the framework is now there to do this.

7 years agooutstack: error checking
Alan Cox [Wed, 20 Sep 2017 13:01:35 +0000 (14:01 +0100)]
outstack: error checking

7 years agocode6801: use the standard routines for code/data switching
Alan Cox [Wed, 20 Sep 2017 12:59:02 +0000 (13:59 +0100)]
code6801: use the standard routines for code/data switching

This will matter big time with the literal changes

7 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Tue, 15 Aug 2017 21:31:31 +0000 (22:31 +0100)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

7 years agoMerge pull request #511 from beretta42/socket
EtchedPixels [Tue, 15 Aug 2017 21:31:24 +0000 (22:31 +0100)]
Merge pull request #511 from beretta42/socket

Various fixes/bugs for recent socket changes

7 years agotty: fix bugs in the maywait changes
Alan Cox [Tue, 15 Aug 2017 21:28:55 +0000 (22:28 +0100)]
tty: fix bugs in the maywait changes

(Courtesy of Brett and combined with my change to use uint8_t to make it work
 more nicely on Z80)

7 years agoZ80: add a flat binary to Z80 snapshot maker
Alan Cox [Tue, 15 Aug 2017 21:21:26 +0000 (22:21 +0100)]
Z80: add a flat binary to Z80 snapshot maker

Yes one day we'll need a boot loader but for emulator debug work it's so much
easier to work on snapshots

7 years agoplus3: do some initial changes
Alan Cox [Tue, 15 Aug 2017 21:20:50 +0000 (22:20 +0100)]
plus3: do some initial changes

At this point we are not yet booting. We start the image but not everything
ends up in the right place to enter the C code

7 years agonetd: fix name collisions in ntpdate
Brett Gordon [Tue, 15 Aug 2017 17:14:15 +0000 (13:14 -0400)]
netd: fix name collisions in ntpdate

7 years agonetd: fix ping symbol name collisions
Brett Gordon [Tue, 15 Aug 2017 17:10:53 +0000 (13:10 -0400)]
netd: fix ping symbol name collisions

7 years agolib: so compiler can find size_t and ssize_t
Brett Gordon [Tue, 15 Aug 2017 17:03:57 +0000 (13:03 -0400)]
lib: so compiler can find size_t and ssize_t

7 years agolib: bring liberror.c up to date with kernel
Brett Gordon [Tue, 15 Aug 2017 15:23:53 +0000 (11:23 -0400)]
lib: bring liberror.c up to date with kernel

7 years agoadd new sendto() error numbers
Brett Gordon [Tue, 15 Aug 2017 15:23:12 +0000 (11:23 -0400)]
add new sendto() error numbers

7 years agonet: easy fix to sendto()
Brett Gordon [Tue, 15 Aug 2017 13:45:50 +0000 (09:45 -0400)]
net: easy fix to sendto()

7 years agoplus3: get things back into a compiling state
Alan Cox [Sat, 12 Aug 2017 19:01:44 +0000 (20:01 +0100)]
plus3: get things back into a compiling state

7 years agoplus3: add a header for generic 8bit IDE
Alan Cox [Sat, 12 Aug 2017 18:51:11 +0000 (19:51 +0100)]
plus3: add a header for generic 8bit IDE

7 years agozx128: switch to level 0, get building ok
Alan Cox [Sat, 12 Aug 2017 18:47:20 +0000 (19:47 +0100)]
zx128: switch to level 0, get building ok

7 years agoplus3: update README ready for doing some actual work on this port
Alan Cox [Sat, 12 Aug 2017 18:47:00 +0000 (19:47 +0100)]
plus3: update README ready for doing some actual work on this port

7 years agoz80: update lowlevel-banked to account for hard_ei change
Alan Cox [Sat, 12 Aug 2017 18:46:20 +0000 (19:46 +0100)]
z80: update lowlevel-banked to account for hard_ei change

7 years agotty: revert to reporting success/fail on inproc
Alan Cox [Sat, 12 Aug 2017 18:46:02 +0000 (19:46 +0100)]
tty: revert to reporting success/fail on inproc

7 years agotty: restore inproc return
Alan Cox [Sat, 12 Aug 2017 13:43:25 +0000 (14:43 +0100)]
tty: restore inproc return

We need this for vt.c where there are multibyte input symbols so undo the
removal.

7 years agozx128: update notes
Alan Cox [Sat, 12 Aug 2017 13:32:29 +0000 (14:32 +0100)]
zx128: update notes

7 years agotty: first cut at O_NDELAY support for write()
Alan Cox [Sat, 12 Aug 2017 13:32:08 +0000 (14:32 +0100)]
tty: first cut at O_NDELAY support for write()

7 years agodevio: remove FIXME
Alan Cox [Thu, 3 Aug 2017 10:59:46 +0000 (11:59 +0100)]
devio: remove FIXME

We taught the linker to do this

7 years agotty: inproc is now void
Alan Cox [Thu, 3 Aug 2017 10:58:17 +0000 (11:58 +0100)]
tty: inproc is now void

7 years agousermem: remove old FIXME
Alan Cox [Thu, 3 Aug 2017 10:58:05 +0000 (11:58 +0100)]
usermem: remove old FIXME

7 years agoprocess: fix reparenting also handle new complications posixisms add
Alan Cox [Thu, 3 Aug 2017 10:56:56 +0000 (11:56 +0100)]
process: fix reparenting also handle new complications posixisms add

7 years agotty: deal with FIXME's from code review
Alan Cox [Thu, 3 Aug 2017 10:50:40 +0000 (11:50 +0100)]
tty: deal with FIXME's from code review

7 years agosyscall_proc: code review notes/fix
Alan Cox [Tue, 25 Jul 2017 10:44:30 +0000 (11:44 +0100)]
syscall_proc: code review notes/fix

Fix getpgrp(), note other stuff for further review

7 years agotty: note another possible tidy
Alan Cox [Tue, 25 Jul 2017 10:44:13 +0000 (11:44 +0100)]
tty: note another possible tidy

7 years agofilesys: correct error return code
Alan Cox [Tue, 25 Jul 2017 10:43:17 +0000 (11:43 +0100)]
filesys: correct error return code

7 years agomicropack: updates
Alan Cox [Sat, 8 Jul 2017 13:45:59 +0000 (14:45 +0100)]
micropack: updates

Use one less buffer via the kn_open change

This is still iffy so I may well undo the lot and abandon the idea
of a level 0 port

7 years agofilesys: we don't need to buffer the name on a tiny pure swap box
Alan Cox [Sat, 8 Jul 2017 13:45:27 +0000 (14:45 +0100)]
filesys: we don't need to buffer the name on a tiny pure swap box

7 years agoprocess.c: code review comments
Alan Cox [Sat, 8 Jul 2017 13:45:04 +0000 (14:45 +0100)]
process.c: code review comments

7 years agovt and tty: code review notes
Alan Cox [Sat, 8 Jul 2017 13:44:43 +0000 (14:44 +0100)]
vt and tty: code review notes

7 years agofilesys: code review comments
Alan Cox [Sat, 8 Jul 2017 13:43:50 +0000 (14:43 +0100)]
filesys: code review comments

7 years agolibc: add resolver
Alan Cox [Fri, 23 Jun 2017 17:09:06 +0000 (18:09 +0100)]
libc: add resolver

This isn't yet usable but it's buildable and heading in the right direction

7 years agolibc: First cut at send/sendto/recv/recvfrom
Alan Cox [Fri, 23 Jun 2017 17:07:55 +0000 (18:07 +0100)]
libc: First cut at send/sendto/recv/recvfrom

Not yet tested

7 years agoerrno.h: resync with kernel
Alan Cox [Fri, 23 Jun 2017 17:07:05 +0000 (18:07 +0100)]
errno.h: resync with kernel

Still needs the .txt file updating

7 years agosyscall_net: rework sendto()
Alan Cox [Fri, 23 Jun 2017 17:06:34 +0000 (18:06 +0100)]
syscall_net: rework sendto()

Without these changes we can't get sensible answers nor make the wrapper work

7 years agobinman: Fix a corner case
Alan Cox [Fri, 23 Jun 2017 17:06:16 +0000 (18:06 +0100)]
binman: Fix a corner case

7 years agosyscall: introduce level 0
Alan Cox [Fri, 23 Jun 2017 17:05:56 +0000 (18:05 +0100)]
syscall: introduce level 0

7 years agomicropack: more experimentation
Alan Cox [Fri, 23 Jun 2017 17:05:19 +0000 (18:05 +0100)]
micropack: more experimentation

Still not useful but we now have the notion of a 'level 0' implementation and
takes us a bit closer to the goal

7 years agomicropack: build the boot blocks
Alan Cox [Fri, 23 Jun 2017 17:04:08 +0000 (18:04 +0100)]
micropack: build the boot blocks