FUZIX.git
6 years agoMakefile.6502: Fix minor buglet
Alan Cox [Sun, 31 Dec 2017 23:02:18 +0000 (23:02 +0000)]
Makefile.6502: Fix minor buglet

6 years agoutils: update remount to handle mtab etc
Alan Cox [Sun, 31 Dec 2017 23:01:28 +0000 (23:01 +0000)]
utils: update remount to handle mtab etc

Add a -n option for boot time

6 years agoutils: remove umount unused define and old comment
Alan Cox [Sun, 31 Dec 2017 23:01:13 +0000 (23:01 +0000)]
utils: remove umount unused define and old comment

6 years agodf; use mntent
Alan Cox [Sun, 31 Dec 2017 23:00:30 +0000 (23:00 +0000)]
df; use mntent

6 years agoremount: use mntent files
Alan Cox [Sun, 31 Dec 2017 22:24:33 +0000 (22:24 +0000)]
remount: use mntent files

This isn't sufficient for a proper remount but is a straight port of the
current usage model.

6 years agoutil: update fsck to use mntent facilities
Alan Cox [Sun, 31 Dec 2017 22:24:18 +0000 (22:24 +0000)]
util: update fsck to use mntent facilities

6 years agoutils: Make mount/umount do all the right things
Alan Cox [Sun, 31 Dec 2017 22:22:57 +0000 (22:22 +0000)]
utils: Make mount/umount do all the right things

Now uses mntent, does proper locking and correctly allows mount and umount -a

6 years agomntent: Continue work
Alan Cox [Sun, 31 Dec 2017 22:21:47 +0000 (22:21 +0000)]
mntent: Continue work

- Fix bugs in draft code
- Introduce getmntent_r

With these we have the calls needed to do the right thing.

6 years ago65c816: update TODO
Alan Cox [Sun, 31 Dec 2017 15:32:43 +0000 (15:32 +0000)]
65c816: update TODO

6 years agofilesys: fix typo
Alan Cox [Sun, 31 Dec 2017 15:31:58 +0000 (15:31 +0000)]
filesys: fix typo

6 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Thu, 21 Dec 2017 14:12:50 +0000 (14:12 +0000)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

6 years agomntent: add to build rules
Alan Cox [Thu, 21 Dec 2017 14:12:32 +0000 (14:12 +0000)]
mntent: add to build rules

6 years agomntent: Library methods for managing mtab and fstab
Alan Cox [Thu, 21 Dec 2017 14:11:38 +0000 (14:11 +0000)]
mntent: Library methods for managing mtab and fstab

We don't use these or hook them in yet but add them ready

6 years agoMerge pull request #575 from beretta42/vtmode
EtchedPixels [Tue, 19 Dec 2017 19:55:36 +0000 (19:55 +0000)]
Merge pull request #575 from beretta42/vtmode

coco3: take cmd line for default video mode

6 years agoMerge pull request #576 from beretta42/signal
EtchedPixels [Tue, 19 Dec 2017 19:55:12 +0000 (19:55 +0000)]
Merge pull request #576 from beretta42/signal

signals: fix precedence to report correct signal no.

6 years agosignals: fix precedence to report correct signal no.
Brett Gordon [Tue, 19 Dec 2017 05:06:18 +0000 (00:06 -0500)]
signals: fix precedence to report correct signal no.

6 years agococo3: take cmd line for default video mode
Brett Gordon [Mon, 18 Dec 2017 13:58:47 +0000 (08:58 -0500)]
coco3: take cmd line for default video mode

6 years ago65c816-big: We can't build it all -Oi, but we can do the core code
Alan Cox [Fri, 15 Dec 2017 13:05:31 +0000 (13:05 +0000)]
65c816-big: We can't build it all -Oi, but we can do the core code

6 years agov65c816-big: A development configuration for a 65C816 with loads of RAM
Alan Cox [Fri, 15 Dec 2017 00:09:49 +0000 (00:09 +0000)]
v65c816-big: A development configuration for a 65C816 with loads of RAM

8MB RAM testing work.

Lots to do here (plus some of the core code like the scheduler doesn't really
scale to 128 processes!)

6 years agolevel2: fix build errors from previous changes
Alan Cox [Fri, 15 Dec 2017 00:09:21 +0000 (00:09 +0000)]
level2: fix build errors from previous changes

6 years agov65c816: README
Alan Cox [Fri, 15 Dec 2017 00:08:50 +0000 (00:08 +0000)]
v65c816: README

Signals (from kernel side at least) are done

6 years ago65c816: fix bank != 0 case
Alan Cox [Fri, 15 Dec 2017 00:08:36 +0000 (00:08 +0000)]
65c816: fix bank != 0 case

6 years ago65c816: fix lib code when bank != 0
Alan Cox [Fri, 15 Dec 2017 00:08:19 +0000 (00:08 +0000)]
65c816: fix lib code when bank != 0

6 years agoinode: another SDCC size-ism fixup
Alan Cox [Thu, 14 Dec 2017 21:55:30 +0000 (21:55 +0000)]
inode: another SDCC size-ism fixup

6 years agokernel: another pipe 16bit fix
Alan Cox [Thu, 14 Dec 2017 21:38:31 +0000 (21:38 +0000)]
kernel: another pipe 16bit fix

6 years agoinode: do some more pipe maths in 16bit
Alan Cox [Thu, 14 Dec 2017 21:31:10 +0000 (21:31 +0000)]
inode: do some more pipe maths in 16bit

6 years ago65c816: documentation update
Alan Cox [Thu, 14 Dec 2017 21:25:23 +0000 (21:25 +0000)]
65c816: documentation update

6 years agov65c816: turn on more features, fix memory map bugs
Alan Cox [Thu, 14 Dec 2017 17:10:51 +0000 (17:10 +0000)]
v65c816: turn on more features, fix memory map bugs

Turn on networking core support
Correct the definitions so we are not 0x200 bytes off on the stacks
Move the IRQ DP into $FFxx as it can share with the vectors
Move discard into the upper bits of the stacks where it can be reclaimed

6 years ago65c816: add hints for process.c and also fix up the waitpid loop
Alan Cox [Thu, 14 Dec 2017 15:22:58 +0000 (15:22 +0000)]
65c816: add hints for process.c and also fix up the waitpid loop

Without this fix we can end up stalling in weird corner cases

6 years ago65c816: add register hints
Alan Cox [Thu, 14 Dec 2017 15:22:43 +0000 (15:22 +0000)]
65c816: add register hints

6 years ago65c816: use register ops here and there
Alan Cox [Thu, 14 Dec 2017 15:21:34 +0000 (15:21 +0000)]
65c816: use register ops here and there

We need this to get better performance out of cc65.

We may be able to justify -Oi but the code grows a lot so it may become a
size problem if we did.

6 years agolseek: Fix signed/unsigned complaint from cc65
Alan Cox [Thu, 14 Dec 2017 14:20:26 +0000 (14:20 +0000)]
lseek: Fix signed/unsigned complaint from cc65

6 years agofcntl: Fix F_GETFL bug
Alan Cox [Thu, 14 Dec 2017 13:54:59 +0000 (13:54 +0000)]
fcntl: Fix F_GETFL bug

6 years agokernel: fix typo in process change
Alan Cox [Thu, 14 Dec 2017 13:45:29 +0000 (13:45 +0000)]
kernel: fix typo in process change

6 years ago6502/65c816: introduce a regptr hint
Alan Cox [Thu, 14 Dec 2017 13:43:52 +0000 (13:43 +0000)]
6502/65c816: introduce a regptr hint

We need this because cc65 writes *far* better code if you tell it to mark
key structure pointers as register so it can then use zp based offset addressing
on them

6 years agoz80pack: map is always 8bit.. so use an 8bit value
Alan Cox [Thu, 14 Dec 2017 13:43:12 +0000 (13:43 +0000)]
z80pack: map is always 8bit.. so use an 8bit value

6 years agoprocess: re-arrange code for clarity
Alan Cox [Thu, 14 Dec 2017 13:42:49 +0000 (13:42 +0000)]
process: re-arrange code for clarity

6 years agokernel: introduce a u_done counter set to 0 in rwsetup
Alan Cox [Thu, 14 Dec 2017 13:42:16 +0000 (13:42 +0000)]
kernel: introduce a u_done counter set to 0 in rwsetup

We then use this to clean up psleep_flags_io and some other code. This also
saves us a few bytes

6 years agosignals: correct SIGCONT, optimize code slightly
Alan Cox [Thu, 14 Dec 2017 12:58:24 +0000 (12:58 +0000)]
signals: correct SIGCONT, optimize code slightly

6 years agofilesys: use the getmode helper in i_deref instead
Alan Cox [Thu, 14 Dec 2017 12:20:00 +0000 (12:20 +0000)]
filesys: use the getmode helper in i_deref instead

Cleans up a bit, uses 8bit compares and saves us another 26 bytes

6 years agoi_deref: remove repeated evaluations
Alan Cox [Thu, 14 Dec 2017 12:13:39 +0000 (12:13 +0000)]
i_deref: remove repeated evaluations

Cleans up the code and saves us another 26 bytes as a side effect

6 years agokernel: remove a single use variable
Alan Cox [Thu, 14 Dec 2017 12:04:54 +0000 (12:04 +0000)]
kernel: remove a single use variable

Tidying up - and shorter cc65 code. Bizarrely sdcc also can't figure out that
this could just be a temporary so it also saves 12 bytes

6 years agosyscall_fs: diet lseek another 80 bytes or so
Alan Cox [Thu, 14 Dec 2017 11:56:11 +0000 (11:56 +0000)]
syscall_fs: diet lseek another 80 bytes or so

6 years agokernel: avoid switch in lseek
Alan Cox [Thu, 14 Dec 2017 11:48:30 +0000 (11:48 +0000)]
kernel: avoid switch in lseek

Not all our compilers do the smart thing with this, and we get better code using
if statements on those that don't.

6 years agoprocess: Fix mask size in ssig
Alan Cox [Thu, 14 Dec 2017 11:32:35 +0000 (11:32 +0000)]
process: Fix mask size in ssig

We don't need a 32bit value any more, and using 16bits saves us 100 bytes
(That's how expensive SDCC longs are!)

6 years agoinodeL small optimization
Alan Cox [Thu, 14 Dec 2017 00:45:14 +0000 (00:45 +0000)]
inodeL small optimization

Pipes always wrap at 18 * 512 bytes so we don't need to do a 32bit comparison
here

6 years agokernel: Make signal handling 16bit clean
Alan Cox [Wed, 13 Dec 2017 23:32:25 +0000 (23:32 +0000)]
kernel: Make signal handling 16bit clean

SDCC makes a complete hash of 32bit maths and the other compilers don't handle
it that well either so rework the signals as 16bit chunks. This saves us a
whopping 350 bytes as well as speeding stuff up.

Also copy over the held bits - something we forgot to do before.

6 years agofsck: some cleaning and tuning
Alan Cox [Wed, 13 Dec 2017 21:31:19 +0000 (21:31 +0000)]
fsck: some cleaning and tuning

6 years ago65c816: remove some debug
Alan Cox [Wed, 13 Dec 2017 20:57:25 +0000 (20:57 +0000)]
65c816: remove some debug

6 years ago65c816: signal fixes
Alan Cox [Wed, 13 Dec 2017 20:36:30 +0000 (20:36 +0000)]
65c816: signal fixes

With this we seem to have working signals

6 years ago65c816: signal improvements
Alan Cox [Wed, 13 Dec 2017 20:18:32 +0000 (20:18 +0000)]
65c816: signal improvements

We now correctly call the vector for the signal and process it. We return to the
correct recovery code, and then fail to recover correctly.

6 years agosize: add 6502
Alan Cox [Wed, 13 Dec 2017 19:16:14 +0000 (19:16 +0000)]
size: add 6502

6 years ago65c816: handle interrupt race
Alan Cox [Wed, 13 Dec 2017 19:14:50 +0000 (19:14 +0000)]
65c816: handle interrupt race

Handle the 1 instruction window where we interrupt just as we do the RTL to go
back to user space. Without this additional check we see user space as the mode
and instead of executing the RTL after the CLI we end up executing something in
the user bank at that address.

6 years ago6502: Fix longmp
Alan Cox [Wed, 13 Dec 2017 19:13:00 +0000 (19:13 +0000)]
6502: Fix longmp

This is ugly. For the 6502/6509/65C02 and friends we need to just deal with the
8bit S register. For the 65C816 we have to change the low 8bits of S only, while
keeping interrupts off as we might otherwise get swapped out and change S mid
calculation.

Not always my favourite processor for multi-tasking..

6 years agoz80: crt0 - let binman fill in the header properly
Alan Cox [Wed, 13 Dec 2017 14:13:42 +0000 (14:13 +0000)]
z80: crt0 - let binman fill in the header properly

6 years agobinman: set up sizes correctly
Alan Cox [Wed, 13 Dec 2017 14:12:58 +0000 (14:12 +0000)]
binman: set up sizes correctly

6 years ago65c816: document tweaks
Alan Cox [Mon, 11 Dec 2017 16:02:14 +0000 (16:02 +0000)]
65c816: document tweaks

(Yes this should probably get turned into markdown as well)

6 years ago65c816: draft porting guide for this architecture
Alan Cox [Mon, 11 Dec 2017 15:46:05 +0000 (15:46 +0000)]
65c816: draft porting guide for this architecture

6 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Mon, 11 Dec 2017 15:45:44 +0000 (15:45 +0000)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

6 years agokillall: don't kill empty ptab slots!
Alan Cox [Mon, 11 Dec 2017 15:45:24 +0000 (15:45 +0000)]
killall: don't kill empty ptab slots!

6 years agoMerge pull request #572 from davidgiven/nc200
EtchedPixels [Sun, 10 Dec 2017 14:38:52 +0000 (14:38 +0000)]
Merge pull request #572 from davidgiven/nc200

NC200 floppy boot support

6 years agoAdd README.
David Given [Sun, 10 Dec 2017 11:16:50 +0000 (12:16 +0100)]
Add README.

6 years agoBodge together a floppy-bootable nc200 platform.
David Given [Sun, 10 Dec 2017 11:10:14 +0000 (12:10 +0100)]
Bodge together a floppy-bootable nc200 platform.

6 years agoConvert bootblock.s to sdasz80 syntax, and add Makefile rules to compile it.
David Given [Sun, 10 Dec 2017 10:47:34 +0000 (11:47 +0100)]
Convert bootblock.s to sdasz80 syntax, and add Makefile rules to compile it.

6 years agoRename the boot skeleton file to avoid confusing with the kernel bootblock.
David Given [Sun, 10 Dec 2017 10:27:54 +0000 (11:27 +0100)]
Rename the boot skeleton file to avoid confusing with the kernel bootblock.

6 years agoIncrease the boot partition size to allow three 16kB banks, not just two.
David Given [Sat, 9 Dec 2017 23:21:23 +0000 (00:21 +0100)]
Increase the boot partition size to allow three 16kB banks, not just two.

6 years agoThe boot loader now works (probably).
David Given [Sat, 9 Dec 2017 22:50:17 +0000 (23:50 +0100)]
The boot loader now works (probably).

6 years agoAdd a more-or-less working NC200 bootable file system image and auto.prg.
David Given [Sat, 9 Dec 2017 16:02:36 +0000 (17:02 +0100)]
Add a more-or-less working NC200 bootable file system image and auto.prg.

6 years agoMerge pull request #571 from beretta42/netd2
EtchedPixels [Sat, 9 Dec 2017 13:23:48 +0000 (13:23 +0000)]
Merge pull request #571 from beretta42/netd2

netd: let Fuzix choose local port

6 years agoMerge pull request #570 from beretta42/killall
EtchedPixels [Sat, 9 Dec 2017 13:23:20 +0000 (13:23 +0000)]
Merge pull request #570 from beretta42/killall

utils: add 'killall' to install script

6 years agonetd: let fuzix do the local port binding
Brett Gordon [Thu, 7 Dec 2017 19:36:34 +0000 (14:36 -0500)]
netd: let fuzix do the local port binding

6 years agonetd: unneccessary packet type check.
Brett Gordon [Sun, 19 Nov 2017 03:19:08 +0000 (22:19 -0500)]
netd: unneccessary packet type check.

6 years agoutils: add 'killall' to install script
Brett Gordon [Thu, 7 Dec 2017 18:05:27 +0000 (13:05 -0500)]
utils: add 'killall' to install script

6 years agoseq: move initializers to SDCC is happy
Alan Cox [Thu, 7 Dec 2017 15:11:52 +0000 (15:11 +0000)]
seq: move initializers to SDCC is happy

6 years ago65c816: fix documentation
Alan Cox [Thu, 7 Dec 2017 15:11:24 +0000 (15:11 +0000)]
65c816: fix documentation

6 years agov65c816: fix incorrect define
Alan Cox [Thu, 7 Dec 2017 15:10:46 +0000 (15:10 +0000)]
v65c816: fix incorrect define

It's right in the asm but the C one is used in swap which we don't yet do..

6 years agov65c816: expose the load base to asm for the doexec fixups
Alan Cox [Mon, 4 Dec 2017 13:46:39 +0000 (13:46 +0000)]
v65c816: expose the load base to asm for the doexec fixups

6 years agov65: put signal vectors in low if the binary is loaded above the normal base
Alan Cox [Mon, 4 Dec 2017 13:45:57 +0000 (13:45 +0000)]
v65: put signal vectors in low if the binary is loaded above the normal base

6 years ago65c816: signal vector copy
Alan Cox [Mon, 4 Dec 2017 02:14:25 +0000 (02:14 +0000)]
65c816: signal vector copy

6 years agofsck: Fix standalone handling of zero indirect
Alan Cox [Mon, 4 Dec 2017 01:58:08 +0000 (01:58 +0000)]
fsck: Fix standalone handling of zero indirect

6 years agov65c816: actually tick rate is 100Hz
Alan Cox [Mon, 4 Dec 2017 01:57:39 +0000 (01:57 +0000)]
v65c816: actually tick rate is 100Hz

6 years ago65c816: multiple fixes - pre-empt support
Alan Cox [Mon, 4 Dec 2017 01:49:17 +0000 (01:49 +0000)]
65c816: multiple fixes - pre-empt support

6 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Sun, 3 Dec 2017 20:27:38 +0000 (20:27 +0000)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

6 years agoutils: add a SYS5 killall
Alan Cox [Sun, 3 Dec 2017 20:27:15 +0000 (20:27 +0000)]
utils: add a SYS5 killall

Not yet tested

6 years agoMerge pull request #569 from beretta42/netd2
EtchedPixels [Mon, 27 Nov 2017 18:31:45 +0000 (18:31 +0000)]
Merge pull request #569 from beretta42/netd2

Quick fixes for netd

6 years agodragon-nx32: Move fonts to high memory
Tormod Volden [Sun, 26 Nov 2017 17:50:26 +0000 (18:50 +0100)]
dragon-nx32: Move fonts to high memory

The lower memory segment was running full.

Signed-off-by: Tormod Volden <debian.tormod@gmail.com>
6 years agoStandalone/fsck: Add -y option
Tormod Volden [Sat, 25 Nov 2017 18:26:02 +0000 (19:26 +0100)]
Standalone/fsck: Add -y option

Signed-off-by: Tormod Volden <debian.tormod@gmail.com>
6 years agobuild-filesystem-ng: Print exit status from tool, not from "system"
Tormod Volden [Sat, 25 Nov 2017 18:06:47 +0000 (19:06 +0100)]
build-filesystem-ng: Print exit status from tool, not from "system"

Interpret exit status 1 from fsck as non-fatal.

Also list package filenames if running verbose.

Signed-off-by: Tormod Volden <debian.tormod@gmail.com>
6 years agoutil: Add a (long) integer-only seq command
Tormod Volden [Sat, 25 Nov 2017 00:27:42 +0000 (01:27 +0100)]
util: Add a (long) integer-only seq command

Signed-off-by: Tormod Volden <debian.tormod@gmail.com>
6 years agonetd: remote connect is an asynchronous event, kill udp straight away.
Brett Gordon [Sat, 25 Nov 2017 23:33:42 +0000 (18:33 -0500)]
netd: remote connect is an asynchronous event, kill udp straight away.

6 years agonetd: fix copying of query arg in 'dig'
Brett Gordon [Sat, 25 Nov 2017 23:13:12 +0000 (18:13 -0500)]
netd: fix copying of query arg in 'dig'

6 years agonetd: shut off gethost's alarm after matching answer arrives
Brett Gordon [Sat, 25 Nov 2017 23:11:15 +0000 (18:11 -0500)]
netd: shut off gethost's alarm after matching answer arrives

6 years ago65c816: complete support for signal handling in syscall
Alan Cox [Fri, 24 Nov 2017 21:46:07 +0000 (21:46 +0000)]
65c816: complete support for signal handling in syscall

Pure IRQ/context switch time handling is not yet debugged

6 years agokernel.def: Fix dumb error
Alan Cox [Fri, 24 Nov 2017 20:34:09 +0000 (20:34 +0000)]
kernel.def: Fix dumb error

6 years ago65c816: gets the signal handling path via syscall closer
Alan Cox [Fri, 24 Nov 2017 20:33:20 +0000 (20:33 +0000)]
65c816: gets the signal handling path via syscall closer

We now call the signal handler correctly, but the handler return blows up

6 years ago6502: correct signal stubs
Alan Cox [Fri, 24 Nov 2017 20:33:00 +0000 (20:33 +0000)]
6502: correct signal stubs

6 years ago65c816: pass the correct A X Y values to the 6502 user space
Alan Cox [Fri, 24 Nov 2017 17:54:09 +0000 (17:54 +0000)]
65c816: pass the correct A X Y values to the 6502 user space

We don't use these but we do specify them so we should follow what 6502
expects

6 years ago6502: add more apps
Alan Cox [Fri, 24 Nov 2017 17:53:19 +0000 (17:53 +0000)]
6502: add more apps

6 years agolib: Install driveiwre.h
Alan Cox [Thu, 23 Nov 2017 23:20:47 +0000 (23:20 +0000)]
lib: Install driveiwre.h

6 years agofsck: Add fixes to standalone fsck from native
Alan Cox [Thu, 23 Nov 2017 23:07:43 +0000 (23:07 +0000)]
fsck: Add fixes to standalone fsck from native