Commit graph

2943 commits

Author SHA1 Message Date
cinap_lenrek c24dd620f9 e820: handle duplicate and overlapping e820 entries, handle overflows
new algorithm:

sort entries by top address first. then for each entry we use:

base = max(base, last)

so we'll never map the same addresses twice.
2013-09-16 23:36:06 +02:00
cinap_lenrek c3a8711d12 kbdfs: set exit status 2013-09-15 16:22:21 +02:00
cinap_lenrek f8cbd5d12f nusb/serial: set exit status 2013-09-15 16:21:43 +02:00
cinap_lenrek 319bb17e1c vncs: fix cmdpid fork bug
we cannot do:

cmdpid = rfork(... RFMEM);

because cmdpid is a global variable in the data segment
and hence shared between parent and child process. use a
temporary variable on the stack.
2013-09-15 16:04:32 +02:00
cinap_lenrek e220636fd3 vncv: fix missing free for window label 2013-09-15 15:14:12 +02:00
cinap_lenrek 474c2c8a2c upas/fs: fix potential filedescriptor leaks 2013-09-15 14:45:57 +02:00
cinap_lenrek 1d4fff69c6 pmmc: add support for Ricoh 5U23 SD/MMC controller 2013-09-15 01:24:08 +02:00
cinap_lenrek 56836bfdbd tls: fix various tlsClient()/tlsServer() related bugs
- TLSconn structure on stack but not initialized (zeroed)
- original filedescriptor double closed in error case
- original filedescriptor leaked in success case
- leaked TLSconn.sessionID and TLSconn.cert
- clarify in pushtls(2) and pushssl(2)
2013-09-14 19:19:08 +02:00
cinap_lenrek be5992955d acme: use threadexitsall() to tear down mouse and keyboard procs on error 2013-09-11 21:23:45 +02:00
cinap_lenrek 6c5deb9b50 pci: fix compiler warning about unused variables 2013-09-09 00:51:36 +02:00
cinap_lenrek 8aff0e5be6 mp/pci: msi support for hypertransport platform 2013-09-09 00:44:08 +02:00
cinap_lenrek 058188117b dossrv(4): remove reference to a:, b:, c:, d: and 9fat: 2013-09-08 20:59:09 +02:00
cinap_lenrek 699ea8bd1f cpu, ratrace, trace: remove unused #include <bio.h> 2013-09-08 20:34:58 +02:00
cinap_lenrek 9fd0b3bad1 md5sum, srv: remove unused #include <bio.h> 2013-09-08 19:52:44 +02:00
cinap_lenrek 9e695e5321 merge 2013-09-08 19:30:27 +02:00
cinap_lenrek eae48ac606 sha1sum: remove unused #include <bio.h> (thanks BurnZeZ) 2013-09-08 19:25:55 +02:00
stanley lieber 8c86eb0079 fortunes: "Not here, not here the darkness, in this twittering world." -- T.S. Eliot 2013-09-07 22:48:28 -04:00
cinap_lenrek b8c0243773 archacpi: make pcibusno() work on non pci bridges (fixes pciaddr()), distribute irqs in setuplink(), remove debug prints 2013-09-08 02:33:25 +02:00
cinap_lenrek 0182cc9db8 acme: avoid useless tagline/window redraw if not needed
window resize is only neccesary if tagline changed.
2013-09-07 20:07:00 +02:00
cinap_lenrek ebf2c5cd69 mk: handle rc blocks in shell quote
this is so we cna handle:

foo = `{echo `{echo bar}}

thanks to erik and friedrich psiorz on 9fans for
bringing the issue up.
2013-09-07 18:42:40 +02:00
cinap_lenrek 12596736e9 libaml: fix formating 2013-09-07 16:22:35 +02:00
cinap_lenrek ad1edf7541 libaml: fix uninitialized variable in getle(), make amleval() work with buildin methods 2013-09-07 16:14:08 +02:00
cinap_lenrek 1b32bd5f0f libaml: use FP->env to access method arguments instead of FP->arg in evalosi() 2013-09-07 14:50:17 +02:00
cinap_lenrek dba77caa35 archacpi: implement amldelay(), remove unused variable in setuplink() 2013-09-07 14:41:08 +02:00
cinap_lenrek cf166c3850 libaml: amldelay(), _OSI(), fix bug in Load() (from plhk's acpi patch)
export amldelay() for microsecond sleeps.

implement _OSI() method.

fix rwreg argument in evalload()
2013-09-07 14:40:24 +02:00
cinap_lenrek 81618e61df libc: set malloctag for runesmprint() 2013-09-06 16:55:13 +02:00
cinap_lenrek 1eb2c757e7 scram: remove amlalloc()/amlfree()
these are now part of libaml but can still be overridden
when needed.
2013-09-06 16:54:02 +02:00
cinap_lenrek 616eb1f9ba archacpi: experimental handling of interrupt link devices, io access 2013-09-06 16:50:43 +02:00
cinap_lenrek 9add5b765f libaml: new io interface, add amlnew()/amltake()/amldrop(), late binding names, FindSetLeftBit/FindSetRightBit
new io interface was added. user defines amlmapio() and amlunmapio() functions
that will fill out Amlio structure with function pointers to read/write
routines for a particular region.

amlnew() function added allowing the creation of aml objects like buffers
or packages. these can be passed to amleval() with b, p or * format.

amltake()/amldrop() exclude an aml object from garbage collection.

on load, names are not always resolvable until the whole table is loaded.
for this, we create n objects that are just name strings. after load, we
recursively traverse the namespace and resolve them (see fixnames()).

the FindSetLeftBit and FindSetRightBit opcodes got implemened.
2013-09-06 16:48:27 +02:00
cinap_lenrek 95fac5e873 libhtml: fix potential linked list corruption
the difficulty is freeing items while parsing because items might already
be linked into various linked lists like in docinfo.images or form.fiels.
so we link images, tables and formfields to the docinfo as the final step
of getitems() pass using the new recursive function linkitems(). as only
reachable items get linked theres no danger of dangeling pointers.
2013-09-05 00:55:58 +02:00
cinap_lenrek cca9a1b523 abaco: fix memory leaks 2013-09-04 21:27:59 +02:00
cinap_lenrek 32236b4957 libhtml: fix memory leaks 2013-09-04 21:27:15 +02:00
cinap_lenrek 425338fd1f webfs: add exits(0) to main() 2013-09-03 21:27:48 +02:00
cinap_lenrek c1562daee0 libhtml: fix double free of form action 2013-09-02 23:18:46 +02:00
cinap_lenrek b14138c2ae 9bootfat: always try plan9 partition even when not marked active, fix bug
always look for 9fat in plan9 partition even tho the partition
is *not* maked active. marking partitions active is not
recommended anymore with grub so this makes life easier for
some people. multiple plan9 partitions on a single drive
is not supported.

have to copy partition table as buf gets trashed when reading
first block of fat partition. it worked only when the first
fat partition found (the one marked active) was the right one,
but conffat() can fail.
2013-09-01 21:18:11 +02:00
ppatience0 243cb68011 jpg(1), jpg: add -y flag to usage
png: colorspace will never be CYCbCr (this is no
doubt from copy-pasting from jpg)

tif: everyone else uses colorspace as a function
argument, so we will too

readtif, writetif: credit paul bourke
2013-08-31 13:39:51 -04:00
cinap_lenrek f104cc9d79 usbehci: portreset timing
assert port reset for 50ms, not 10ms.
2013-08-30 16:00:03 +02:00
mveety f459320bb4 removed unused variable resize in wind.c 2013-08-28 23:05:52 -04:00
mveety ba7c22f781 Added the p9p acme patch the allows multiline tags (thanks rsc and lf94). 2013-08-28 23:01:23 -04:00
cinap_lenrek 12ecb3e568 usbehci: fix portreset.
Port Reset R/W. 1=Port is in Reset. 0=Port is not in Reset. Default = 0. When
software writes a one to this bit (from a zero), the bus reset sequence as defined in the
USB Specification Revision 2.0 is started. Software writes a zero to this bit to terminate
the bus reset sequence. Software must keep this bit at a one long enough to ensure the
reset sequence, as specified in the USB Specification Revision 2.0, completes. Note:
when software writes this bit to a one, it must also write a zero to the Port Enable bit.
Note that when software writes a zero to this bit there may be a delay before the bit
status changes to a zero. The bit status will not read as a zero until after the reset
has completed.
2013-08-27 19:01:41 +02:00
cinap_lenrek d76eccaf88 imap4d: apply djc's patch to fix search (from /n/sources/patch/imap4d-cistrcmp)
Fix SEARCH command in imap4d by replacing the cistrstr typo with cistrcmp.
2013-08-27 00:34:17 +02:00
cinap_lenrek 43d3c87294 devproc: properly handle exclusive refcount for /proc/trace 2013-08-27 23:57:17 +02:00
cinap_lenrek 84109a3159 devshr, devaudio: openmode()/devopen() error handling 2013-08-27 23:27:46 +02:00
cinap_lenrek 52a84514ac devmouse: fix openmode() handling
openmode() can raise error with invalid mode passed, but we already
incremented the exclusive mouse refcount at that point! call openmode()
early to avoid this.
2013-08-27 23:26:30 +02:00
cinap_lenrek 244d2ee84b devkbd: fix wrong refcount on open error
only decrement refcount when file was successfully opend
on clunk, fix refcount when devopen() errors.
2013-08-27 23:23:29 +02:00
cinap_lenrek 5e37e6361c etheriwl: recover from rfkill toggle or firmware crash
spawn a kernel process to check the broken state of the controller.
if the firmware crashed, or rfkill was toggled we will reset and
reboot the firmware. also power down the card when rfkill is off.
2013-08-25 18:50:14 +02:00
ppatience0 334054e0e7 nusb/ether: add aue driver for admtek pegasus usb ethernet adapter 2013-08-24 19:18:15 -04:00
cinap_lenrek 808480f76b usbehci, usbuhci: paranoia
double the td abort delay and make sure the tsleep() isnt
shortened by a pending note. in that case, tsleep() would
raise error(Eintr); immidiately and would not sleep the
requested amount potentially cauing us to release active
dma memory too early! so we wrap the tsleep() call in a
while(waserror()) so we will at least wait the Abortdelay
amount if error is raised.

also, only try to idle the still active td's.

do not copy data in epio() when there was an error, theres
no reason to touch user buffer in that case.

for uhci, we also check that theres not more data in the
buffers than requested to avoid overflowing user buffer
in epio(). this should not happen but we'r paranoid.

for ehci, we also halt the queue head first in aborttds().
mark the queue heads as Qfree after unlinking and remove
some silly nil checks that are impossible.
2013-08-25 22:03:02 +02:00
stanley lieber 1556afae40 2c(1), torrent(1), uhtml(1), kbd(3), cwfs(4), hgfs(4), cifsd(8), cryptsetup(8), hjfs(8), kbdfs(8), realemu(8), wpa(8): fix spelling, typos 2013-08-23 15:48:52 -04:00
stanley lieber eca2dbed8b audio(1), hget(1), nusb(4), page(1): fix spelling, typos 2013-08-23 11:27:30 -04:00