]> git.lizzy.rs Git - plan9front.git/log
plan9front.git
10 years agoadd /lib/face/48x48x8/o/openbsd.1
stanley lieber [Wed, 26 Feb 2014 22:22:41 +0000 (17:22 -0500)]
add /lib/face/48x48x8/o/openbsd.1

10 years agolibsec: add aes_128_cbc and aes_256_cbc ciphers
mischief [Wed, 26 Feb 2014 01:37:59 +0000 (17:37 -0800)]
libsec: add aes_128_cbc and aes_256_cbc ciphers

10 years agodevtls: spelling
mischief [Wed, 26 Feb 2014 00:57:22 +0000 (16:57 -0800)]
devtls: spelling

10 years agolibsec: move static sendbuf into TlsConnection and give receive buffer a better name
mischief [Tue, 25 Feb 2014 20:48:17 +0000 (12:48 -0800)]
libsec: move static sendbuf into TlsConnection and give receive buffer a better name

10 years agoscribble(2): quashed false claims of quick-reference decadance.
glenda [Tue, 25 Feb 2014 20:05:34 +0000 (20:05 +0000)]
scribble(2): quashed false claims of quick-reference decadance.

10 years agocsdial: avoid useless werrstr() call on success (thanks mischief)
cinap_lenrek [Tue, 25 Feb 2014 19:14:08 +0000 (20:14 +0100)]
csdial: avoid useless werrstr() call on success (thanks mischief)

10 years agopython: add buffer length check in sock_recvfrom_into()
cinap_lenrek [Tue, 25 Feb 2014 17:51:03 +0000 (18:51 +0100)]
python: add buffer length check in sock_recvfrom_into()

10 years agoacid: fix errstr syscall data offset for truss library
mischief [Tue, 25 Feb 2014 17:31:58 +0000 (09:31 -0800)]
acid: fix errstr syscall data offset for truss library

10 years agomp(2): spelling
mischief [Mon, 24 Feb 2014 09:10:40 +0000 (01:10 -0800)]
mp(2): spelling

10 years agogames/nes: mmc3 chr inversion fixed
aiju [Tue, 25 Feb 2014 08:39:30 +0000 (09:39 +0100)]
games/nes: mmc3 chr inversion fixed

10 years agogames/nes: it's too late to write code
aiju [Tue, 25 Feb 2014 22:25:28 +0000 (23:25 +0100)]
games/nes: it's too late to write code

10 years agogames/nes: fixed reload flags
aiju [Tue, 25 Feb 2014 22:18:26 +0000 (23:18 +0100)]
games/nes: fixed reload flags

10 years agomerge
aiju [Mon, 24 Feb 2014 21:50:29 +0000 (22:50 +0100)]
merge

10 years agogames/nes: added dmc, fixed envelope, added cnrom
aiju [Mon, 24 Feb 2014 21:50:05 +0000 (22:50 +0100)]
games/nes: added dmc, fixed envelope, added cnrom

10 years agoacid: add some debugging aid function for counting kernel image cache page refs
cinap_lenrek [Mon, 24 Feb 2014 21:45:38 +0000 (22:45 +0100)]
acid: add some debugging aid function for counting kernel image cache page refs

10 years agomerge
cinap_lenrek [Mon, 24 Feb 2014 21:43:21 +0000 (22:43 +0100)]
merge

10 years agokernel: keep cached pages continuous at the end of the page list on imagereclaim()
cinap_lenrek [Mon, 24 Feb 2014 21:42:22 +0000 (22:42 +0100)]
kernel: keep cached pages continuous at the end of the page list on imagereclaim()

imagereclaim() sabotaged itself by breaking the invariant
that cached pages are kept at the end of the page list.

once we made a hole of uncached pages, we would stop
reclaiming cached pages before it as the loop breaks
once it hits a uncached page. (we iterate backwards from
the tail to the head of the pagelist until pages have been
reclaimed or we hit a uncached page).

the solution is to move pages to the head of the pagelist
after removing them from the image cache.

10 years agocontrol(2): spelling
mischief [Mon, 24 Feb 2014 21:02:54 +0000 (13:02 -0800)]
control(2): spelling

10 years agogames/nes: added uxrom (mapper 2)
aiju [Mon, 24 Feb 2014 18:50:02 +0000 (19:50 +0100)]
games/nes: added uxrom (mapper 2)

10 years agogames/nes: best commit (fixed audio and timing)
aiju [Mon, 24 Feb 2014 18:33:26 +0000 (19:33 +0100)]
games/nes: best commit (fixed audio and timing)

10 years agogames/nes: basic audio support, battery backup, bug fixes
aiju [Sun, 23 Feb 2014 20:46:16 +0000 (21:46 +0100)]
games/nes: basic audio support, battery backup, bug fixes

10 years agomerge
cinap_lenrek [Sun, 23 Feb 2014 17:42:01 +0000 (18:42 +0100)]
merge

10 years agopc64: fix mmu leak
cinap_lenrek [Sun, 23 Feb 2014 17:40:43 +0000 (18:40 +0100)]
pc64: fix mmu leak

10 years agogames/nes: added oflag
aiju [Sun, 23 Feb 2014 10:55:29 +0000 (11:55 +0100)]
games/nes: added oflag

10 years agogames/nes: minor ppu improvements
aiju [Sat, 22 Feb 2014 19:10:54 +0000 (20:10 +0100)]
games/nes: minor ppu improvements

10 years agogames/nes: mapper 7 fix
aiju [Sat, 22 Feb 2014 18:50:31 +0000 (19:50 +0100)]
games/nes: mapper 7 fix

10 years agogames/nes: mmc3 and bugfixes
aiju [Sat, 22 Feb 2014 16:43:15 +0000 (17:43 +0100)]
games/nes: mmc3 and bugfixes

10 years agorc-httpd/handlers/serve-static: restore Content-length
stanley lieber [Sat, 22 Feb 2014 07:24:37 +0000 (02:24 -0500)]
rc-httpd/handlers/serve-static: restore Content-length

10 years agogames(1): english
stanley lieber [Sat, 22 Feb 2014 02:06:57 +0000 (21:06 -0500)]
games(1): english

10 years agogames(1): add some of the new games, not all have full description tho
cinap_lenrek [Sat, 22 Feb 2014 01:46:46 +0000 (02:46 +0100)]
games(1): add some of the new games, not all have full description tho

10 years agoadd games/nes to mkfile
cinap_lenrek [Sat, 22 Feb 2014 00:11:42 +0000 (01:11 +0100)]
add games/nes to mkfile

10 years agofortunes: https://github.com/jfloren/plan9/commit/445b546003d071f3cf3cd6a0133b92397e5...
stanley lieber [Fri, 21 Feb 2014 21:14:16 +0000 (16:14 -0500)]
fortunes: https://github.com/jfloren/plan9/commit/445b546003d071f3cf3cd6a0133b92397e5c9024

10 years agoadded florenate
aiju [Fri, 21 Feb 2014 21:00:34 +0000 (22:00 +0100)]
added florenate

10 years agogames/nes: added state saving & bug fixes
aiju [Fri, 21 Feb 2014 19:48:23 +0000 (20:48 +0100)]
games/nes: added state saving & bug fixes

10 years agofork filter procs with RFREND in various programs
cinap_lenrek [Fri, 21 Feb 2014 04:32:20 +0000 (05:32 +0100)]
fork filter procs with RFREND in various programs

10 years agoaux/listen: rfork with RFREND
cinap_lenrek [Fri, 21 Feb 2014 04:29:43 +0000 (05:29 +0100)]
aux/listen: rfork with RFREND

child processes handling the connection should be all
independent of each another and not share rendezvous
group. the rendezvous group sharing caused a bug in
exportfs when we switched from using pid to memory
address as rendezvous tag.

10 years agoexportfs: bring back the changes, bug was due to rendezvous group being shared by...
cinap_lenrek [Fri, 21 Feb 2014 04:23:21 +0000 (05:23 +0100)]
exportfs: bring back the changes, bug was due to rendezvous group being shared by listen

exportfs used pid of slave proc as rendezvous tag. when we
changed it to use Proc* memory address, there where tag
collisions because listen didnt fork the rendezvous group (bug!).

for now, just do rfork(RFREND) in main just in case.

will fix aux/listen in a follow up changeset.

--
cinap

10 years agomerge
cinap_lenrek [Fri, 21 Feb 2014 00:03:31 +0000 (01:03 +0100)]
merge

10 years agoexportfs: reverting previous changes
cinap_lenrek [Fri, 21 Feb 2014 00:02:32 +0000 (01:02 +0100)]
exportfs: reverting previous changes

getting strange tag mismatches on some machines. needs
to be debugged. until then, reverting the change.

10 years agomerge
aiju [Thu, 20 Feb 2014 21:14:41 +0000 (22:14 +0100)]
merge

10 years agogames/nes: cleanup and resize handling
aiju [Thu, 20 Feb 2014 21:13:59 +0000 (22:13 +0100)]
games/nes: cleanup and resize handling

10 years agogames/nes: bug fixing
aiju [Thu, 20 Feb 2014 22:22:14 +0000 (23:22 +0100)]
games/nes: bug fixing

10 years agofix blowfish endianess confusion (thanks erik)
cinap_lenrek [Thu, 20 Feb 2014 17:32:47 +0000 (18:32 +0100)]
fix blowfish endianess confusion (thanks erik)

from /n/sources/patch/blowfish/readme:

Blowfish is broken. The order of the bytes in the ciphertext
is wrong. The problem is the conversion from the ciphertext
plaintext block to the array of u32int used by the core funcions
and vice versa.

This code has been tested on big endian and little endian
machines.

A test program is also included, bftets.c. It uses the
test vectors of blowfish available at
https://www.schneier.com/code/vectors.txt

10 years agoexportfs: fix flush races, proc sweeping
cinap_lenrek [Tue, 18 Feb 2014 21:15:06 +0000 (22:15 +0100)]
exportfs: fix flush races, proc sweeping

10 years agoaux/cpuid: hack for amd64
cinap_lenrek [Mon, 17 Feb 2014 18:50:02 +0000 (19:50 +0100)]
aux/cpuid: hack for amd64

10 years agoprof: properly save and restore RARG for amd64
cinap_lenrek [Mon, 17 Feb 2014 12:25:24 +0000 (13:25 +0100)]
prof: properly save and restore RARG for amd64

amd64 passes first argument in RARG (BP) register
which has the be preserved duing _profin() and
_profout() calls. to handle this we introduce
_saveret() and _savearg(). _saveret() returns
AX, _savearg() returns RARG (BP). for archs other
and amd64, _saveret() and _savearg() are the
same function, doing nothing.

restoing works with dummy function:

uintptr
_restore(uintptr, uintptr ret)
{
return ret;
}

...

ret = _saveret();
arg = _savearg();
...
return _restore(arg, ret);

as we pass arg as the first argument, RARG (BP) is
restored.

10 years agogames/nes: add mapper 7 support
cinap_lenrek [Sun, 16 Feb 2014 20:40:33 +0000 (21:40 +0100)]
games/nes: add mapper 7 support

10 years agoxd: changed -s option to switch to little-endian units
aap [Sun, 16 Feb 2014 20:32:14 +0000 (21:32 +0100)]
xd: changed -s option to switch to little-endian units

10 years agoadded games/nes
aiju [Sun, 16 Feb 2014 19:51:11 +0000 (20:51 +0100)]
added games/nes

10 years agomothra: remove unused local variables from pl_nextc()
cinap_lenrek [Sun, 16 Feb 2014 18:40:50 +0000 (19:40 +0100)]
mothra: remove unused local variables from pl_nextc()

10 years agotruss: use A instead of X as address format for data dump
cinap_lenrek [Sun, 16 Feb 2014 18:20:57 +0000 (19:20 +0100)]
truss: use A instead of X as address format for data dump

10 years agotruss: fix syscall address formats
cinap_lenrek [Sun, 16 Feb 2014 18:08:49 +0000 (19:08 +0100)]
truss: fix syscall address formats

10 years agomothra: fix unicode rendering for plaintext
cinap_lenrek [Sun, 16 Feb 2014 17:50:30 +0000 (18:50 +0100)]
mothra: fix unicode rendering for plaintext

we did the utf-8 to unicode conversion in pl_nextc(),
but the plaintext handler uses pl_readc() which only
translates newlines but otherwise returns bytes.

move unicode conversion in pl_readc() fixes it.

10 years agodocumented usbwait in plan9.ini(8)
Matthew Veety [Sat, 15 Feb 2014 22:18:58 +0000 (17:18 -0500)]
documented usbwait in plan9.ini(8)

10 years agofactotum/authsrv: fix padding for mschap on amd64, use constants for structure sizes
cinap_lenrek [Sat, 15 Feb 2014 18:57:13 +0000 (19:57 +0100)]
factotum/authsrv: fix padding for mschap on amd64, use constants for structure sizes

10 years agopc64: fix mistake
cinap_lenrek [Sat, 15 Feb 2014 15:58:35 +0000 (16:58 +0100)]
pc64: fix mistake

10 years agopc64: simplify mmuwalk by factoring out mmu page table creation into separate function
cinap_lenrek [Sat, 15 Feb 2014 15:43:55 +0000 (16:43 +0100)]
pc64: simplify mmuwalk by factoring out mmu page table creation into separate function

10 years agomerge
cinap_lenrek [Sat, 15 Feb 2014 05:19:25 +0000 (06:19 +0100)]
merge

10 years agopc64: support for vmware PCnet ethernet
cinap_lenrek [Sat, 15 Feb 2014 05:17:38 +0000 (06:17 +0100)]
pc64: support for vmware PCnet ethernet

10 years agopc64: move VMAP into its own PDP (for vmware)
cinap_lenrek [Sat, 15 Feb 2014 05:17:05 +0000 (06:17 +0100)]
pc64: move VMAP into its own PDP (for vmware)

modifying the kernel pdp (CPU0PDP) hangs vmware. so
we initialize the pdp with KZERO and KZERO+1GB map
in l.s and never change it. (except when removing
the zero double map which seems to work).

VMAP has its own pdp now allowing to map 512GB of
physical address space. this simplifies the code
a bit and gives nice virtual addresses.

10 years agoadded in a way to make net.rc wait for the network hardware to come up before running...
Matthew Veety [Sat, 15 Feb 2014 03:05:25 +0000 (22:05 -0500)]
added in a way to make net.rc wait for the network hardware to come up before running ip/ipconfig. This fixes the issue with the Raspberry Pi where ip/ipconfig tried running prior to /net/etherU3 exists

10 years agolibc: remove malloc.acid and pool.acid
cinap_lenrek [Fri, 14 Feb 2014 14:20:34 +0000 (15:20 +0100)]
libc: remove malloc.acid and pool.acid

10 years agopage: fix compiler warning
cinap_lenrek [Fri, 14 Feb 2014 14:01:14 +0000 (15:01 +0100)]
page: fix compiler warning

10 years agosocksd: close inside udp server one we get a connection (udprelay)
cinap_lenrek [Fri, 14 Feb 2014 13:57:05 +0000 (14:57 +0100)]
socksd: close inside udp server one we get a connection (udprelay)

10 years agocifsd: fix compiler warning
cinap_lenrek [Fri, 14 Feb 2014 13:21:07 +0000 (14:21 +0100)]
cifsd: fix compiler warning

10 years agonusb/ether: fix pointer truncation
cinap_lenrek [Fri, 14 Feb 2014 13:18:09 +0000 (14:18 +0100)]
nusb/ether: fix pointer truncation

10 years agowebfs: fix compiler warning
cinap_lenrek [Fri, 14 Feb 2014 13:14:17 +0000 (14:14 +0100)]
webfs: fix compiler warning

10 years agoip/torrent: remove unneeded assignment
cinap_lenrek [Fri, 14 Feb 2014 13:12:02 +0000 (14:12 +0100)]
ip/torrent: remove unneeded assignment

10 years agoacid: add semacquire/semrelease/tsemacquire syscalls, handle _seek hack for amd64...
cinap_lenrek [Fri, 14 Feb 2014 13:02:33 +0000 (14:02 +0100)]
acid: add semacquire/semrelease/tsemacquire syscalls, handle _seek hack for amd64 (thanks erik)

10 years agosimilar to my last commit, but combined the two waits for the usb devices. still...
Matthew Veety [Fri, 14 Feb 2014 05:11:11 +0000 (00:11 -0500)]
similar to my last commit, but combined the two waits for the usb devices. still configurable, but with usbwait. If usbwait is not defined then it defaults to the original 2 seconds.

10 years agopc64: add ahci.h to PCHEADERS so it will be removed on mk clean
mischief [Wed, 12 Feb 2014 11:02:23 +0000 (03:02 -0800)]
pc64: add ahci.h to PCHEADERS so it will be removed on mk clean

10 years agopc64: remove ethermii.h and copy it from pc instead
mischief [Wed, 12 Feb 2014 11:00:12 +0000 (03:00 -0800)]
pc64: remove ethermii.h and copy it from pc instead

10 years agoadded pccpu64 for cpuservers. also enabled etherigbe in pc64 and pccpu64
Matthew Veety [Thu, 13 Feb 2014 02:05:04 +0000 (21:05 -0500)]
added pccpu64 for cpuservers. also enabled etherigbe in pc64 and pccpu64

10 years agoacid: fix acid/network, fix address formats from X to A
cinap_lenrek [Wed, 12 Feb 2014 19:04:07 +0000 (20:04 +0100)]
acid: fix acid/network, fix address formats from X to A

10 years agotruss: support for amd64
cinap_lenrek [Wed, 12 Feb 2014 18:27:08 +0000 (19:27 +0100)]
truss: support for amd64

10 years agopool(2): fix ulong -> uintptr
cinap_lenrek [Wed, 12 Feb 2014 17:53:03 +0000 (18:53 +0100)]
pool(2): fix ulong -> uintptr

10 years agoramfs: remove mainmem pool limit when called with -u flag
cinap_lenrek [Mon, 10 Feb 2014 03:04:51 +0000 (04:04 +0100)]
ramfs: remove mainmem pool limit when called with -u flag

10 years agopc64: limit memory of per processor mmu freelist to 1MB
cinap_lenrek [Mon, 10 Feb 2014 01:37:45 +0000 (02:37 +0100)]
pc64: limit memory of per processor mmu freelist to 1MB

10 years agoacid: remove objchar, prefering foobar.$objtype.acid
cinap_lenrek [Mon, 10 Feb 2014 00:53:26 +0000 (01:53 +0100)]
acid: remove objchar, prefering foobar.$objtype.acid

acid already sets up objtype for us.

10 years agopc64: return up in RUSER (BP) for devproc kregs file
cinap_lenrek [Mon, 10 Feb 2014 22:12:52 +0000 (23:12 +0100)]
pc64: return up in RUSER (BP) for devproc kregs file

10 years agocc: emit right acid format for address
cinap_lenrek [Mon, 10 Feb 2014 22:10:47 +0000 (23:10 +0100)]
cc: emit right acid format for address

we could use 'A' here but then it would require the new acid.

10 years agoacid: update acid libraries for amd64
cinap_lenrek [Mon, 10 Feb 2014 22:07:37 +0000 (23:07 +0100)]
acid: update acid libraries for amd64

10 years agoacid: make 'a' and 'A' format to have the same size as mach->szaddr
cinap_lenrek [Sun, 9 Feb 2014 21:43:09 +0000 (22:43 +0100)]
acid: make 'a' and 'A' format to have the same size as mach->szaddr

to make it easier to write portable acid code, we
introduce 'A' format in the same meaning as in db(1):

A    Print the value of dot in hexadecimal.  Dot is
     unaffected.

both 'a' (symbolic) and 'A' will both have 64 or 32 bit
size depending on the mach, so pointer array indexing
works the same.

10 years agopc64: pass Ureg* argument in BP to userspace note handler
cinap_lenrek [Sun, 9 Feb 2014 01:23:33 +0000 (02:23 +0100)]
pc64: pass Ureg* argument in BP to userspace note handler

10 years agoacid: fix memory corruption due to gc
cinap_lenrek [Sun, 9 Feb 2014 00:37:05 +0000 (01:37 +0100)]
acid: fix memory corruption due to gc

we cannot call gc() in execute() because it will gc
anonyous intermediate results which happens when we
construct a list and the elements are calculated by
calling a function thru ocall() which calls execute().

also, the _thiscmd symbol; which is used to keep
a reference to a statement so it wont get garbage
collected; does not work as yyparse() is recursive
(include statements).

we add execrec() function which *only* gets called from
yyparse() when evaluating a statement. it will
keep a stack on the _thiscmd symbol handling the yyparse()
recursion.

we also only call gc() in execrec() before calling
execute(). so execute() will never gc() while evaluating
a statement which prevents the intermediate results
from getting collected.

10 years agopc64: handle negative file offsets when accessing kernel memory with devproc
cinap_lenrek [Sat, 8 Feb 2014 02:50:41 +0000 (03:50 +0100)]
pc64: handle negative file offsets when accessing kernel memory with devproc

file offset is 64 bit signed integer, negative offsets
are invalid and rejected by the kernel. to still access
kernel memory on amd64, we unconditionally clear the sign
bit of the 64 bit offset in libmach and devproc sign
extends the offset back to a 64 bit address.

10 years agomtrr: fix mistake
cinap_lenrek [Sat, 8 Feb 2014 02:40:17 +0000 (03:40 +0100)]
mtrr: fix mistake

10 years agojpg: center image in screen
cinap_lenrek [Sat, 8 Feb 2014 01:33:29 +0000 (02:33 +0100)]
jpg: center image in screen

when using the jpg(1) programs interactively, draw the
image in the center of it. this avoids wasting space
with always on borders on small windows and looks better
when used in fullscreen.

10 years agoreuse mtrr slots with default memory type
cinap_lenrek [Sat, 8 Feb 2014 00:01:26 +0000 (01:01 +0100)]
reuse mtrr slots with default memory type

10 years agoaux/vga: fix format string error with 6c
cinap_lenrek [Fri, 7 Feb 2014 23:29:06 +0000 (00:29 +0100)]
aux/vga: fix format string error with 6c

10 years agopc64: bump segment limit to 64GB
cinap_lenrek [Fri, 7 Feb 2014 23:23:18 +0000 (00:23 +0100)]
pc64: bump segment limit to 64GB

10 years agopc64: dont reuse mtrr slots that are above 4GB
cinap_lenrek [Fri, 7 Feb 2014 19:04:19 +0000 (20:04 +0100)]
pc64: dont reuse mtrr slots that are above 4GB

we used to override/reuse mtrr slots over 4GB as the
kernel wasnt able to use that memory. pc64 can.

10 years agopc64: ensure user pc is never set to a non-canonical address through setregisters
mischief [Fri, 7 Feb 2014 02:03:17 +0000 (18:03 -0800)]
pc64: ensure user pc is never set to a non-canonical address through setregisters

on intel processors, a general protection exception is fired if a non-canonical address is loaded into PC during SYSRET. this will cause the kernel to panic.

see http://www.kb.cert.org/vuls/id/649219 and the intel software developer manual for more information.

10 years agopc64: fix devcons format strings for memory sizes
cinap_lenrek [Fri, 7 Feb 2014 22:35:27 +0000 (23:35 +0100)]
pc64: fix devcons format strings for memory sizes

10 years agocwfs: limit memsize() to 1GB until pool can handle huge allocations
cinap_lenrek [Fri, 7 Feb 2014 22:33:34 +0000 (23:33 +0100)]
cwfs: limit memsize() to 1GB until pool can handle huge allocations

10 years agopc64: fix poolsummary() string format
cinap_lenrek [Fri, 7 Feb 2014 22:02:56 +0000 (23:02 +0100)]
pc64: fix poolsummary() string format

10 years agopool: use uintptr for pool size
cinap_lenrek [Thu, 6 Feb 2014 21:47:05 +0000 (22:47 +0100)]
pool: use uintptr for pool size

note, arenas and blocks still use ulong for sizes. so
we have to check for overflow when attempting to merge
arenas.

10 years agopc64: fix note handling
cinap_lenrek [Thu, 6 Feb 2014 21:43:33 +0000 (22:43 +0100)]
pc64: fix note handling

10 years agopc64: fix kmap()
cinap_lenrek [Thu, 6 Feb 2014 21:41:42 +0000 (22:41 +0100)]
pc64: fix kmap()

kmapindex has to be per process, not per mach, as the process
can be switched to another processor while the mapping is
established.

to bootstrap the first process, we have to temporarily set up
so the kmap MMU's can be attached to the process. previously
we assumed that the first two pages for the initial process
where below 2GB and could be accessed with KADDR() directly.
with 16GB machine, all the 2GB above KZERO are dedicated to
the kernel so the user pages returned by newpage() need to
be mapped.

10 years agohave to use NULL instead of nil for ape programs...
cinap_lenrek [Wed, 5 Feb 2014 18:52:09 +0000 (19:52 +0100)]
have to use NULL instead of nil for ape programs...