FUZIX.git
8 years agodragon-nx32: graphics: fix bounds checking for reading/writing
Brett Gordon [Fri, 23 Oct 2015 06:18:36 +0000 (02:18 -0400)]
dragon-nx32: graphics: fix bounds checking for reading/writing

axis where swapped.

8 years agodragon-nx32: graphics: fix little endian bug in read/write
Brett Gordon [Fri, 23 Oct 2015 06:17:03 +0000 (02:17 -0400)]
dragon-nx32: graphics: fix little endian bug in read/write

8 years agoMerge pull request #267 from beretta42/discard
EtchedPixels [Thu, 22 Oct 2015 12:14:09 +0000 (13:14 +0100)]
Merge pull request #267 from beretta42/discard

CoCo3: use discard space for extra buffers

8 years agoMerge pull request #266 from beretta42/uput
EtchedPixels [Thu, 22 Oct 2015 12:13:26 +0000 (13:13 +0100)]
Merge pull request #266 from beretta42/uput

coco3: added fast banked/windowing uget / uput xfer routines.

8 years agoMerge pull request #265 from beretta42/video
EtchedPixels [Thu, 22 Oct 2015 12:12:37 +0000 (13:12 +0100)]
Merge pull request #265 from beretta42/video

coco3: reset vert scroll reg on boot.

8 years agococo3: discard/buffers: make asm match C
Brett Gordon [Thu, 22 Oct 2015 06:36:41 +0000 (02:36 -0400)]
coco3: discard/buffers: make asm match C

8 years agococo3: discard: import of more dragon code
Brett Gordon [Thu, 22 Oct 2015 06:24:08 +0000 (02:24 -0400)]
coco3: discard: import of more dragon code

8 years agococo3: reset vert scroll reg on boot.
Brett Gordon [Wed, 14 Oct 2015 20:40:17 +0000 (16:40 -0400)]
coco3: reset vert scroll reg on boot.

8 years agococo3: added fast banked/windowing uget / uput xfer routines.
Brett Gordon [Thu, 22 Oct 2015 02:53:05 +0000 (22:53 -0400)]
coco3: added fast banked/windowing uget / uput xfer routines.

8 years agoAPI.list: so we know where we are with the SVID API
Alan Cox [Wed, 21 Oct 2015 20:54:51 +0000 (21:54 +0100)]
API.list: so we know where we are with the SVID API

8 years agolibs: update TODO
Alan Cox [Wed, 21 Oct 2015 20:54:13 +0000 (21:54 +0100)]
libs: update TODO

8 years agogethostname: Fix typo
Alan Cox [Wed, 21 Oct 2015 20:54:01 +0000 (21:54 +0100)]
gethostname: Fix typo

8 years agolibc: add new swab.c file
Alan Cox [Wed, 21 Oct 2015 20:53:41 +0000 (21:53 +0100)]
libc: add  new swab.c file

8 years agolibc: Add the missing swab() function from SYS5
Alan Cox [Wed, 21 Oct 2015 20:47:57 +0000 (21:47 +0100)]
libc: Add the missing swab() function from SYS5

8 years agoabort: note buglet
Alan Cox [Wed, 21 Oct 2015 20:47:37 +0000 (21:47 +0100)]
abort: note buglet

8 years agotypes.h: add useconds_t
Alan Cox [Wed, 21 Oct 2015 14:59:05 +0000 (15:59 +0100)]
types.h: add useconds_t

8 years agolibc: Add usleep
Alan Cox [Wed, 21 Oct 2015 11:46:09 +0000 (12:46 +0100)]
libc: Add usleep

It's just another mapping onto _pause()

8 years agolibclean: fix the changes to actually work
Alan Cox [Wed, 21 Oct 2015 10:09:49 +0000 (11:09 +0100)]
libclean: fix the changes to actually work

8 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Wed, 21 Oct 2015 09:59:06 +0000 (10:59 +0100)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

8 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Wed, 21 Oct 2015 09:14:08 +0000 (10:14 +0100)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

8 years agolibclean: find the libraries properly
Alan Cox [Wed, 21 Oct 2015 09:13:45 +0000 (10:13 +0100)]
libclean: find the libraries properly

8 years agotty: minor fixes to error handling in ioctls
Alan Cox [Tue, 20 Oct 2015 21:09:18 +0000 (22:09 +0100)]
tty: minor fixes to error handling in ioctls

8 years agoMerge pull request #263 from davidgiven/typos
EtchedPixels [Tue, 20 Oct 2015 20:37:43 +0000 (21:37 +0100)]
Merge pull request #263 from davidgiven/typos

Minor MSP430 fixes

8 years agoMerge from upstream.
David Given [Tue, 20 Oct 2015 17:23:28 +0000 (19:23 +0200)]
Merge from upstream.

8 years agoActually, let's just put <stdint.h> at the top of config.h instead of moving
David Given [Tue, 20 Oct 2015 17:23:12 +0000 (19:23 +0200)]
Actually, let's just put <stdint.h> at the top of config.h instead of moving
the queue stuff to cpu.h. (A hypothetical device with more memory wouldn't
want it.)

8 years agotrs80/dragon: should be setting the multimode flag
Alan Cox [Tue, 20 Oct 2015 16:49:54 +0000 (17:49 +0100)]
trs80/dragon: should be setting the multimode flag

8 years agographics: We defintiely want blit for some hardware
Alan Cox [Tue, 20 Oct 2015 16:45:03 +0000 (17:45 +0100)]
graphics: We defintiely want blit for some hardware

8 years agotrs80: recover discardable buffers
Alan Cox [Tue, 20 Oct 2015 14:50:17 +0000 (15:50 +0100)]
trs80: recover discardable buffers

8 years agokernel.def: add buffer size to Z80 port
Alan Cox [Tue, 20 Oct 2015 14:49:45 +0000 (15:49 +0100)]
kernel.def: add buffer size to Z80 port

8 years agogames: start adding our games stuff
Alan Cox [Tue, 20 Oct 2015 14:48:09 +0000 (15:48 +0100)]
games: start adding our games stuff

Begin with qrun, which promptly get us about 100 games 8)

8 years agoz80: add size_t / ssize_t as we now need them
Alan Cox [Tue, 20 Oct 2015 08:33:32 +0000 (09:33 +0100)]
z80: add size_t / ssize_t as we now need them

8 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Tue, 20 Oct 2015 08:28:57 +0000 (09:28 +0100)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

8 years agoFigure out the proper magic numbers for the header.
David Given [Mon, 19 Oct 2015 21:27:39 +0000 (23:27 +0200)]
Figure out the proper magic numbers for the header.

8 years agoNow that kernel.h no longer includes <stdint.h>, we need to move the queue
David Given [Mon, 19 Oct 2015 21:24:01 +0000 (23:24 +0200)]
Now that kernel.h no longer includes <stdint.h>, we need to move the queue
definitions to cpu.h (because we haven't seen stdint.h when config.h is
included).

8 years agoFix typo.
David Given [Mon, 19 Oct 2015 21:20:15 +0000 (23:20 +0200)]
Fix typo.

8 years agocpu-msp340: push bits back into the CPU header instead
Alan Cox [Mon, 19 Oct 2015 20:53:20 +0000 (21:53 +0100)]
cpu-msp340: push bits back into the CPU header instead

8 years agosyscall_exec16: revert unneeded ifdeffery in core code
Alan Cox [Mon, 19 Oct 2015 20:52:54 +0000 (21:52 +0100)]
syscall_exec16: revert unneeded ifdeffery in core code

8 years agokernel.h: small tidy up of queue ifdeffery
Alan Cox [Mon, 19 Oct 2015 20:52:30 +0000 (21:52 +0100)]
kernel.h: small tidy up of queue ifdeffery

8 years agobrk: revert the MSP340 change to brk()
Alan Cox [Mon, 19 Oct 2015 20:48:41 +0000 (21:48 +0100)]
brk: revert the MSP340 change to brk()

brk sets the memory address to the one asked. If you misalign in then it's
your problem in userspace.

Some of our sbrk() users in userspace may well be wrong, but they need to be
fixed not brk()!

8 years agokernel.h: remove stdint.h
Alan Cox [Mon, 19 Oct 2015 20:40:23 +0000 (21:40 +0100)]
kernel.h: remove stdint.h

This was added by the msp340 port, but
- Not all our compilers have stdint.h
- The msp340 includes it from cpu.h anyway

8 years agoMerge pull request #262 from davidgiven/msp430
EtchedPixels [Mon, 19 Oct 2015 20:37:36 +0000 (21:37 +0100)]
Merge pull request #262 from davidgiven/msp430

MSP430 port

8 years agoUndo more unnecessary changes from upstream.
David Given [Mon, 19 Oct 2015 18:30:59 +0000 (20:30 +0200)]
Undo more unnecessary changes from upstream.

8 years agoBackport the ugetp/uputp changes from upstream.
David Given [Mon, 19 Oct 2015 18:19:35 +0000 (20:19 +0200)]
Backport the ugetp/uputp changes from upstream.

8 years agoDon't force alignment on platforms that don't need it.
David Given [Mon, 19 Oct 2015 17:56:23 +0000 (19:56 +0200)]
Don't force alignment on platforms that don't need it.

8 years agoFix some whitespace changes that shouldn't have been changed (for cleaner
David Given [Mon, 19 Oct 2015 17:50:44 +0000 (19:50 +0200)]
Fix some whitespace changes that shouldn't have been changed (for cleaner
diffs with upstream).

8 years agoMerge from master.
David Given [Mon, 19 Oct 2015 17:41:15 +0000 (19:41 +0200)]
Merge from master.

8 years agosyscall_6502: fix warning
Alan Cox [Mon, 19 Oct 2015 11:34:29 +0000 (12:34 +0100)]
syscall_6502: fix warning

8 years agoMerge branch 'master' of https://github.com/EtchedPixels/FUZIX
Alan Cox [Mon, 19 Oct 2015 10:52:08 +0000 (11:52 +0100)]
Merge branch 'master' of https://github.com/EtchedPixels/FUZIX

8 years agotrs80: add missed header file
Alan Cox [Mon, 19 Oct 2015 10:51:55 +0000 (11:51 +0100)]
trs80: add missed header file

8 years agoMerge pull request #261 from davidgiven/games
EtchedPixels [Mon, 19 Oct 2015 10:50:32 +0000 (11:50 +0100)]
Merge pull request #261 from davidgiven/games

Fix the games

8 years agoUpdate documentation to mention the MSP430.
David Given [Sun, 18 Oct 2015 20:17:11 +0000 (22:17 +0200)]
Update documentation to mention the MSP430.

8 years agoMove MSP430 README to the new Documentation directory.
David Given [Sun, 18 Oct 2015 20:13:32 +0000 (22:13 +0200)]
Move MSP430 README to the new Documentation directory.

8 years agoMerge from master.
David Given [Sun, 18 Oct 2015 17:53:52 +0000 (19:53 +0200)]
Merge from master.

8 years agoMerge pull request #259 from davidgiven/sh
EtchedPixels [Sun, 18 Oct 2015 12:49:35 +0000 (13:49 +0100)]
Merge pull request #259 from davidgiven/sh

sh now builds and runs on modern computers.

8 years agoBackgammon is small enough to fit now.
David Given [Sat, 17 Oct 2015 23:02:32 +0000 (01:02 +0200)]
Backgammon is small enough to fit now.

8 years agoReduce memory requirement; make sure buffers get flush properly before
David Given [Sat, 17 Oct 2015 23:02:22 +0000 (01:02 +0200)]
Reduce memory requirement; make sure buffers get flush properly before
waiting for the user; and remove the dependency on paper-based terminals.

8 years agoFlush stdout before getting the user's response (otherwise the user never
David Given [Sat, 17 Oct 2015 22:47:31 +0000 (00:47 +0200)]
Flush stdout before getting the user's response (otherwise the user never
sees anything).

8 years agoCleaned up the new kprintf a bit.
David Given [Sat, 17 Oct 2015 22:40:31 +0000 (00:40 +0200)]
Cleaned up the new kprintf a bit.

8 years agoReturn kputunum() to upstream's version.
David Given [Sat, 17 Oct 2015 22:33:46 +0000 (00:33 +0200)]
Return kputunum() to upstream's version.

8 years agoUpstream already got this fix, in a slightly different form. Use theirs.
David Given [Sat, 17 Oct 2015 22:28:33 +0000 (00:28 +0200)]
Upstream already got this fix, in a slightly different form. Use theirs.

8 years agoFix a whole bunch of show-stopping bugs --- how did this ever work?
David Given [Sat, 17 Oct 2015 22:10:19 +0000 (00:10 +0200)]
Fix a whole bunch of show-stopping bugs --- how did this ever work?

8 years agoFlush stdout before getting the user's response (otherwise the user never
David Given [Sat, 17 Oct 2015 22:47:31 +0000 (00:47 +0200)]
Flush stdout before getting the user's response (otherwise the user never
sees anything).

8 years agoReduce memory requirement; make sure buffers get flush properly before
David Given [Sat, 17 Oct 2015 23:02:22 +0000 (01:02 +0200)]
Reduce memory requirement; make sure buffers get flush properly before
waiting for the user; and remove the dependency on paper-based terminals.

8 years agoFix a whole bunch of show-stopping bugs --- how did this ever work?
David Given [Sat, 17 Oct 2015 22:10:19 +0000 (00:10 +0200)]
Fix a whole bunch of show-stopping bugs --- how did this ever work?

8 years agostaticify variable.
David Given [Sat, 17 Oct 2015 22:09:16 +0000 (00:09 +0200)]
staticify variable.

8 years agosh now builds and runs on modern computers.
David Given [Sat, 17 Oct 2015 22:09:04 +0000 (00:09 +0200)]
sh now builds and runs on modern computers.

8 years agosh now builds and runs on modern computers.
David Given [Sat, 17 Oct 2015 22:09:04 +0000 (00:09 +0200)]
sh now builds and runs on modern computers.

8 years agoEnsure that the break value is aligned.
David Given [Sat, 17 Oct 2015 21:26:49 +0000 (23:26 +0200)]
Ensure that the break value is aligned.

8 years agoAdded a quick and dirty MSP430 readme.
David Given [Thu, 15 Oct 2015 21:45:52 +0000 (23:45 +0200)]
Added a quick and dirty MSP430 readme.

8 years agoUpdate after changes.
David Given [Thu, 15 Oct 2015 21:07:16 +0000 (23:07 +0200)]
Update after changes.

8 years agokputunum() can now write the number 0.
David Given [Thu, 15 Oct 2015 21:06:57 +0000 (23:06 +0200)]
kputunum() can now write the number 0.

8 years agoDon't require EMAGIC and EMAGIC_2 to be defined. Align pointers correctly
David Given [Thu, 15 Oct 2015 21:04:18 +0000 (23:04 +0200)]
Don't require EMAGIC and EMAGIC_2 to be defined. Align pointers correctly
when writing an argument array.

8 years agoAdvance pointer correctly when doing block transfers.
David Given [Thu, 15 Oct 2015 21:03:20 +0000 (23:03 +0200)]
Advance pointer correctly when doing block transfers.

8 years agoMerge from master.
David Given [Thu, 15 Oct 2015 18:54:08 +0000 (20:54 +0200)]
Merge from master.

8 years agoMerge pull request #258 from beretta42/video
EtchedPixels [Wed, 14 Oct 2015 18:00:54 +0000 (19:00 +0100)]
Merge pull request #258 from beretta42/video

CoCo3: add first of low-level graphics

8 years agodragon-nx32: Some SPI fixes
Tormod Volden [Tue, 13 Oct 2015 16:03:58 +0000 (18:03 +0200)]
dragon-nx32: Some SPI fixes

Signed-off-by: Tormod Volden <debian.tormod@gmail.com>
8 years agococo3: compile usermem wrappers into common kernel/video area.
Brett Gordon [Tue, 13 Oct 2015 13:05:29 +0000 (09:05 -0400)]
coco3: compile usermem wrappers into common kernel/video area.

should be in official "common" area?

8 years agococo3: graphics: put uget's arguments in correct order.
Brett Gordon [Tue, 13 Oct 2015 13:02:53 +0000 (09:02 -0400)]
coco3: graphics: put uget's arguments in correct order.

8 years agococo3: connect graphic IOCTL to rendering routine.
Brett Gordon [Mon, 12 Oct 2015 12:58:28 +0000 (08:58 -0400)]
coco3: connect graphic IOCTL to rendering routine.

8 years agococo3: video: add exports.
Brett Gordon [Sat, 10 Oct 2015 11:18:32 +0000 (07:18 -0400)]
coco3: video: add exports.

8 years agococo3: fix typo
Brett Gordon [Fri, 9 Oct 2015 14:07:04 +0000 (10:07 -0400)]
coco3: fix typo

8 years agococo3: import of dragon's gfx code.
Brett Gordon [Fri, 9 Oct 2015 14:05:40 +0000 (10:05 -0400)]
coco3: import of dragon's gfx code.

8 years agouget() but direct to video memory
Brett Gordon [Fri, 9 Oct 2015 13:55:45 +0000 (09:55 -0400)]
uget() but direct to video memory

8 years agococo3: all graphics mode buffers start at 0x0000 in physical block 9
Brett Gordon [Fri, 9 Oct 2015 06:16:41 +0000 (02:16 -0400)]
coco3: all graphics mode buffers start at 0x0000 in physical block 9

8 years agoadd video mode register setting to private tty mode struct.
Brett Gordon [Fri, 9 Oct 2015 05:05:12 +0000 (01:05 -0400)]
add video mode register setting to private tty mode struct.

8 years agococo3: make detected hz a C global
Brett Gordon [Fri, 9 Oct 2015 05:03:09 +0000 (01:03 -0400)]
coco3: make detected hz a C global

8 years agococo3: add display basic graphics mode 256x192x2.
Brett Gordon [Fri, 9 Oct 2015 04:32:42 +0000 (00:32 -0400)]
coco3: add display basic graphics mode 256x192x2.

8 years agobuffers: enum is evil, use a uint8_t instead and save a byte a buffer
Alan Cox [Mon, 12 Oct 2015 22:20:10 +0000 (23:20 +0100)]
buffers: enum is evil, use a uint8_t instead and save a byte a buffer

520 is also a cheaper multiply on processors without mul instructions

8 years agols: fix one stupid performance bug
Alan Cox [Mon, 12 Oct 2015 22:17:52 +0000 (23:17 +0100)]
ls: fix one stupid performance bug

No point doing a stat on each node when we don't actually need it !

We should chdir into the directory before doing the stats on the short path.
That avoids all the name walking overhead and thrash. Likewise it might be
sensible to stat in inode order and batched, but that may cost more than
the saving !

8 years agodragon-nx-32: use the new "reclaim discard as buffer cache feature"
Alan Cox [Mon, 12 Oct 2015 22:01:34 +0000 (23:01 +0100)]
dragon-nx-32: use the new "reclaim discard as buffer cache feature"

This gets me another 7 buffers on my build.

8 years agobuffers: Allow for the buffer cache to be expandable.
Alan Cox [Mon, 12 Oct 2015 21:58:27 +0000 (22:58 +0100)]
buffers: Allow for the buffer cache to be expandable.

Some of our platforms have no userspace mapped when in kernel space. That
prevents them putting the discard code/data into the userspace area during
boot and binning it when loading init over the top.

Instead we allow the buffer cache to grow. The platform can then put the
buffer cache just before the discard area, and once the root fs is mounted
and we are ready to load init we can convert the entire discard area into
cache pages.

Even better we only need enough buffers to mount the root fs to be present
at boot time (2 or 3).

8 years agotc3: add selection logic (untested)
Alan Cox [Sat, 10 Oct 2015 20:51:40 +0000 (21:51 +0100)]
tc3: add selection logic (untested)

8 years agodragon-nx-32: make detection prettier, add HDBDOS/TC3 sigs
Alan Cox [Sat, 10 Oct 2015 20:51:14 +0000 (21:51 +0100)]
dragon-nx-32: make detection prettier, add HDBDOS/TC3 sigs

8 years agodragon-nx-32: record the slot of the TC3 SCSI if present
Alan Cox [Sat, 10 Oct 2015 20:49:35 +0000 (21:49 +0100)]
dragon-nx-32: record the slot of the TC3 SCSI if present

8 years agodevscsi: introduce a deselect
Alan Cox [Sat, 10 Oct 2015 20:48:52 +0000 (21:48 +0100)]
devscsi: introduce a deselect

Needed for things like MPI or bank switched cartridges containing MMIO
controllers (MSX as well I suspect)

8 years agodragon-nx-32: turn on tc3 probing logic and fix tc3 bugs
Alan Cox [Sat, 10 Oct 2015 20:12:21 +0000 (21:12 +0100)]
dragon-nx-32: turn on tc3 probing logic and fix tc3 bugs

B is the 8bit return
Remove bogus push of pc in the cmd write

8 years agodevscsi: keep naming of probe code akin to IDE
Alan Cox [Sat, 10 Oct 2015 20:12:01 +0000 (21:12 +0100)]
devscsi: keep naming of probe code akin to IDE

8 years agodragon-nx32: add first test bits of scsi support
Alan Cox [Sat, 10 Oct 2015 19:49:59 +0000 (20:49 +0100)]
dragon-nx32: add first test bits of scsi support

We now scan 0xFF7x for a TC3 controller and maybe even probe it properly but
not yet tested out.

Also sort out the discard segment properly. Right now it's not important but
at some point we'll find a way to reuse that space nicely.

Still lots to do including the proper autodetect for the TC3 and bank
switching the TC3 in/out if (as it basically has to be) it's in an MPI, and
handling swap or userspace I/O (so even running programs off it won't work
yet in the unlikely event it gets that far)

8 years agodev: add first draft of the SCSI layer
Alan Cox [Sat, 10 Oct 2015 19:49:28 +0000 (20:49 +0100)]
dev: add first draft of the SCSI layer

Still working on an xroar emulation of the tc3 to debug test this

8 years ago6809: move data into discard for discard code
Alan Cox [Sat, 10 Oct 2015 19:49:05 +0000 (20:49 +0100)]
6809: move data into discard for discard code