]> git.lizzy.rs Git - plan9front.git/log
plan9front.git
3 years agonewuser(8): fix reference to incorrect file server console command
Alex Musolino [Fri, 23 Oct 2020 07:21:03 +0000 (17:51 +1030)]
newuser(8): fix reference to incorrect file server console command

3 years agovmx/vga: fix allocimage leaks
Sigrid [Thu, 22 Oct 2020 22:16:47 +0000 (00:16 +0200)]
vmx/vga: fix allocimage leaks

3 years agoupas/fs/mbox.c: fix cosmetic typo
khm [Thu, 22 Oct 2020 20:46:00 +0000 (13:46 -0700)]
upas/fs/mbox.c:  fix cosmetic typo

3 years agolibaml: add (nop) "signal" op
Sigrid [Wed, 21 Oct 2020 10:06:25 +0000 (12:06 +0200)]
libaml: add (nop) "signal" op

3 years agovncv: pick an auth type that we support
Ori Bernstein [Mon, 19 Oct 2020 02:30:14 +0000 (19:30 -0700)]
vncv: pick an auth type that we support

We used to pick the highest auth type regardless of whether
we supported it. Now we filter down to types that we support.

3 years agosdiahci: accept AHCI controllers from ASMedia vendor id (thanks mischief)
cinap_lenrek [Sun, 18 Oct 2020 23:20:29 +0000 (01:20 +0200)]
sdiahci: accept AHCI controllers from ASMedia vendor id (thanks mischief)

3 years agopc, pc64: remove mystery "type" bits in pcicfgrw*raw() (fixes qemu, thanks mischief)
cinap_lenrek [Sun, 18 Oct 2020 21:39:07 +0000 (23:39 +0200)]
pc, pc64: remove mystery "type" bits in pcicfgrw*raw() (fixes qemu, thanks mischief)

the access functions for pci config space in config mode #1
used to set bit 0 in the register offset if the access was
to a device on any bus different from 0.

it is completely unclear why this was done and i can't find
any documentation on this.

but for sure, this breaks all pci config spacess access to
pci devices behind a bridge on qemu. with -trace pci* it
was discovered that all config space register offsets on
devies behind pci brige where off by one.

on real hardware, setting bit 0 in the offset doesnt appear
to be an issue.

thanks mischief for reporting and providing a qemu demo
configuration to reproduce the problem.

3 years agosdnvme: use PCIWADDR() instead of PADDR()
cinap_lenrek [Sun, 18 Oct 2020 15:02:42 +0000 (17:02 +0200)]
sdnvme: use PCIWADDR() instead of PADDR()

3 years agoetherbcm: handle 64-bit host addresses, use PCIWADDR() instead of PADDR()
cinap_lenrek [Sun, 18 Oct 2020 15:01:50 +0000 (17:01 +0200)]
etherbcm: handle 64-bit host addresses, use PCIWADDR() instead of PADDR()

3 years agoaudiohda: use PCIWADDR() instead of PADDR(), handle 64-bit dma addresses
cinap_lenrek [Sun, 18 Oct 2020 15:00:04 +0000 (17:00 +0200)]
audiohda: use PCIWADDR() instead of PADDR(), handle 64-bit dma addresses

3 years agoetheriwl: delay before crystal calibration
Ori Bernstein [Sun, 18 Oct 2020 14:50:07 +0000 (10:50 -0400)]
etheriwl: delay before crystal calibration

On my 6235 card, if we calibrate the crystal
immediately after disabling wimax, the the
firmware gets unhappy. A short nap before
sending the command prevents the command from
timing out.

3 years agonusb/serial: add ids for FT230X (thanks mischief)
Ori Bernstein [Sun, 18 Oct 2020 02:27:21 +0000 (19:27 -0700)]
nusb/serial: add ids for FT230X (thanks mischief)

3 years agomerge
Ori Bernstein [Sun, 18 Oct 2020 02:04:17 +0000 (19:04 -0700)]
merge

3 years agoupas: fix appendfolder timestamps (thanks umbraticus)
Ori Bernstein [Sun, 18 Oct 2020 01:59:36 +0000 (18:59 -0700)]
upas: fix appendfolder timestamps (thanks umbraticus)

When moving messages between folders, mbappend,
deliver, and nedmail were trying to parse the
timestamp ouut of the message. They were doing
it incorrectly, trying to include the user name
as part of the date format.

Change to pass just the date to the date parser.

3 years agoetheriwl: don't break controller on command flush timeout
cinap_lenrek [Sun, 18 Oct 2020 01:05:35 +0000 (03:05 +0200)]
etheriwl: don't break controller on command flush timeout

ori and echoline are reporting regression on some 6000 cards;
which sometimes time out on crystal calibration command;
which is expected by the driver. but the new code used
to force a device reset on any command timeout.

reverting to old behaviour until for now until we have
a chance investigating.

3 years agosdnvme: handle machines with more cpu's than submit queues (thanks mischief)
cinap_lenrek [Sun, 18 Oct 2020 00:51:32 +0000 (02:51 +0200)]
sdnvme: handle machines with more cpu's than submit queues (thanks mischief)

We used to assume a 1:1 pairing of processors to submit queues.
With recent machines, we now got more cpu cores than what some
nvme drives support so we need to distribute the queues across
these cpu's which requires locking on command submission.

There is a feature get/set command to probe the number of submit
and completion queues, but we decided to just handling
submission queue create command error gracefully as it is simpler
and has less chance of regression with existing setups.

Thanks to mischief for investigating and writing the code.

3 years agomerge
cinap_lenrek [Sat, 17 Oct 2020 19:30:10 +0000 (21:30 +0200)]
merge

3 years agondb/dnsdebug: add -c flag to debug caching dns server behaviour
cinap_lenrek [Sat, 17 Oct 2020 19:28:56 +0000 (21:28 +0200)]
ndb/dnsdebug: add -c flag to debug caching dns server behaviour

3 years agondb/dns: mark ns record authoritative when in our area for delegation
cinap_lenrek [Sat, 17 Oct 2020 19:28:25 +0000 (21:28 +0200)]
ndb/dns: mark ns record authoritative when in our area for delegation

I have the problem that i need to delegate a subdomain
to another name server that is confused about its own zone
(and its own name) returning unusable ns records.

With this, one can make up a nameserver entry in ndb that
is authoritative and owned by us for that nameserver,
and then put it in the soa=delegated ns entry.

This promotes the ns record in the soa=delegated to
Authoritative, which avoids overriding the ns rr's from
the confused server for the delegated zone.

3 years agogames/nes: workaround for truncated chr
Sigrid [Thu, 15 Oct 2020 08:30:40 +0000 (10:30 +0200)]
games/nes: workaround for truncated chr

3 years agoip/torrent: try harder allocating ports
cinap_lenrek [Mon, 12 Oct 2020 00:03:52 +0000 (02:03 +0200)]
ip/torrent: try harder allocating ports

we used to only allocate ports from 6881 to 6890,
which limits the maximum of parallel torrents to 9.

this change make it go up to 9000, which gives us
at best 2120 ports, which is overkill but ports might
be randomly occupied by other connections.

3 years agoupas/fs: fix truncation of plumb date
cinap_lenrek [Sun, 11 Oct 2020 12:59:49 +0000 (14:59 +0200)]
upas/fs: fix truncation of plumb date

the new date format introduced by the previous commit;
using numeric timezone offsets; needs one character more,
so increase the date format buffer to 31 characters.

3 years agokernel: get rid of unused ucallocb
cinap_lenrek [Fri, 9 Oct 2020 20:05:32 +0000 (22:05 +0200)]
kernel: get rid of unused ucallocb

the whole idea of a ucallocb() is bad, as even access to the
metadata header would be in uncached memory. also, it tuns out
that it was never used by anyone.

3 years agovmx: add Kmod4
Sigrid [Fri, 9 Oct 2020 14:47:34 +0000 (16:47 +0200)]
vmx: add Kmod4

3 years agoetheriwl: add Wireless 8260 card
Ori Bernstein [Mon, 5 Oct 2020 21:10:12 +0000 (14:10 -0700)]
etheriwl: add Wireless 8260 card

After the latest tweaks to the order of operations,
the card works.

3 years agomerge
cinap_lenrek [Mon, 5 Oct 2020 20:43:25 +0000 (22:43 +0200)]
merge

3 years agoetheriwl: remove stations *after* disabling binding quotas, drain all queues in rxoff...
cinap_lenrek [Mon, 5 Oct 2020 20:42:13 +0000 (22:42 +0200)]
etheriwl: remove stations *after* disabling binding quotas, drain all queues in rxoff7000()

3 years agorio: move the code for 'send' into a function
kvik [Sun, 4 Oct 2020 20:45:22 +0000 (22:45 +0200)]
rio: move the code for 'send' into a function

Makes the code a bit nicer and allows reusing wsend() in patches.

3 years agoetheriwl: add for Intel Wireless-AC 9260
cinap_lenrek [Sun, 4 Oct 2020 19:10:53 +0000 (21:10 +0200)]
etheriwl: add for Intel Wireless-AC 9260

the 9000 series uses a new receive descriptor format
wich appears to reqire 4k aligned buffers. the old
format "halfworks" and just makes the firmware not
respond to any commands after the enable paging command.

the smartfifo command appears to causes problems.
but apparently not issuing it at all seems to work
fine on both the 8265 and 9260. so removing the code
for now.

issuing the bindingquota command before associated
makes association impossible. but enabling afterwards
works fine. (tested in 8265 and 9260).

the prph access functions now mask the address with
0xfffff. it is unclear why linux and openbsd drivers
specify addresses beyond that in ther register constants.

the timeevent change is interesting. the timeevent
needs to be restarted when it has stoped to make sure
probing/association packets are sent during the evnet.

3 years agobootrc: allow kbmap to be set via plan9.ini (thanks Aaron Bieber)
kvik [Thu, 1 Oct 2020 15:47:52 +0000 (17:47 +0200)]
bootrc: allow kbmap to be set via plan9.ini (thanks Aaron Bieber)

3 years agoacme: revert stray changes
Ori Bernstein [Tue, 29 Sep 2020 14:28:47 +0000 (07:28 -0700)]
acme: revert stray changes

forgot I had local changes when testing, re-revert scrolling.

3 years agovncv: implement rfb 3.8 protocol (thanks Iruatã)
Ori Bernstein [Sun, 27 Sep 2020 16:43:43 +0000 (09:43 -0700)]
vncv: implement rfb 3.8 protocol (thanks Iruatã)

Gnome and bhyve's VNC servers implement the RFB 3.8
protocol, so we need to support it in the client in
order to connect.

3 years agoaux/vga: eepc igfx support (thanks p.kosyh)
Ori Bernstein [Sun, 27 Sep 2020 03:47:17 +0000 (20:47 -0700)]
aux/vga: eepc igfx support (thanks p.kosyh)

This patch to makes 1024x600x32 work. Without it
only 800x600 is supported.

To load this mode, run:

aux/vga -m eeepc -l 1024x600x32

3 years agoupas: convert to tmdate, change timezone format
Ori Bernstein [Sat, 26 Sep 2020 18:20:42 +0000 (11:20 -0700)]
upas: convert to tmdate, change timezone format

Complete the conversion of upas to remove ctime,
use the new date library, and print time zones
in +hhmm format, instead of NNN format.

This may affect code that expects specific names
for timezones. Fix that code.

3 years agotmdate(1): fix missing arg, fix formatting (thanks joe9)
Ori Bernstein [Sat, 26 Sep 2020 04:22:47 +0000 (21:22 -0700)]
tmdate(1): fix missing arg, fix formatting (thanks joe9)

3 years agomerge
Ori Bernstein [Fri, 25 Sep 2020 23:51:08 +0000 (16:51 -0700)]
merge

3 years agotmdate(2): fix mistakes in prototype (thanks moody)
Ori Bernstein [Fri, 25 Sep 2020 23:32:32 +0000 (16:32 -0700)]
tmdate(2): fix mistakes in prototype (thanks moody)

3 years agoaux/acpi: connect EC region handler, fixes battery status on eeepc 1000px (thanks...
Sigrid [Fri, 25 Sep 2020 08:28:25 +0000 (10:28 +0200)]
aux/acpi: connect EC region handler, fixes battery status on eeepc 1000px (thanks Peter Kosyh)

3 years agosyscall: fix build problem caused by stale tab.h
kvik [Wed, 23 Sep 2020 15:17:52 +0000 (17:17 +0200)]
syscall: fix build problem caused by stale tab.h

Recently the script which generates tab.h and the code including it got
incompatibly changed.  People reported problems involving syntax errors
when trying to rebuild the system following a sysupdate.

The problem was with the script being embedded within a mkfile rule,
meaning that mk didn't notice it changing and therefore didn't rebuild
the target file.  For people who were rebuilding the system this meant
that the old tab.h got included, causing syntax errors.

This patch moves the codegen script into a file and tells mk about this
new dependency, so that tab.h will get rebuilt for everyone.  I also
took an opportunity to rewrite the script, hopefuly making it easier to
follow.

3 years agoftpd: handle "allo" command by treating it as a no-op
Alex Musolino [Wed, 23 Sep 2020 03:14:05 +0000 (12:44 +0930)]
ftpd: handle "allo" command by treating it as a no-op

RFC959 says:

"The ALLO command should be treated as a NOOP (no
operation) by those servers which do not require
that the maximum size of the file be declared
beforehand..."

3 years agolibc: ignore '?' in date format strings
Ori Bernstein [Wed, 23 Sep 2020 02:24:01 +0000 (19:24 -0700)]
libc: ignore '?' in date format strings

Ignoring '?' when formatting date strings allows
the format strings to be reused for parsing. This
is convenient, since we don't need to duplicate
the format strings.

3 years agolibc: make yday 0-based, as docs suggest
Ori Bernstein [Wed, 23 Sep 2020 02:21:51 +0000 (19:21 -0700)]
libc: make yday 0-based, as docs suggest

Tm.yday is docuemnted as being 0-based, and our new api
should respect that. Fix the code so that this is true.

3 years agoacme: import changes from plan9port (thanks jxy)
Ori Bernstein [Tue, 22 Sep 2020 18:42:15 +0000 (11:42 -0700)]
acme: import changes from plan9port (thanks jxy)

Import the following improvements and bugfixes from plan9port:

4650064a acme: scale window bodies on resize, not including tag space
d28913a9 acme: save/restore multiline tags in Dump/Load
d2df5d6c acme: fix crash in X |cat with multiple windows
3d6e5cb5 acme: preserve window position and selection during Get

3 years agoape/limits.h: fix typo in (U)LLONG_MAX
Ori Bernstein [Mon, 21 Sep 2020 18:43:31 +0000 (11:43 -0700)]
ape/limits.h: fix typo in (U)LLONG_MAX

Fix missing 'L' in the size suffix, so we were overflowing the
maximum size.

3 years agodiff: support unified diff via -u
Ori Bernstein [Mon, 21 Sep 2020 16:40:42 +0000 (09:40 -0700)]
diff: support unified diff via -u

The format produced by `diff -u` is inferior to that
produced by `diff -c`, but it's what ape/patch and
unix patch expect, so it's useful to generate it.

This patch adds `diff -u`.

3 years agosyscall: utility overhaul
kvik [Sun, 20 Sep 2020 12:49:12 +0000 (14:49 +0200)]
syscall: utility overhaul

Following is a list of functional changes:

* The -o flag outputs the entire buffer to the length returned
  by the syscall, or, in case of fd2path(2) and errstr(2), to '\0'.
* The -x flag is removed; the above makes it possible to pipe
  into xd(1) to get the same result.
* The -s flag uses dirfmt(2) to format the stat message, instead
  of trying to imitate ls(1).
* Stderr reports are normalized and made easier to parse.

The code also suffered a number of stylistic changes.

3 years agoupas/fs: fix handing of multi-line header fields (thanks theinicke)
Ori Bernstein [Thu, 17 Sep 2020 23:11:10 +0000 (16:11 -0700)]
upas/fs: fix handing of multi-line header fields (thanks theinicke)

Right now, upasfs exposes header lines as is, without stripping
out new lines. It also documents that it provides one header per
line in the info file.

As a result, when we get a mail with headers that span lines,
our tools get confused.

These split lines are not semantically meaningful. From RFC5322:

  2.2.3.  Long Header Fields

   Each header field is logically a single line of characters comprising
   the field name, the colon, and the field body.  For convenience
   however, and to deal with the 998/78 character limitations per line,
   the field body portion of a header field can be split into a
   multiple-line representation; this is called "folding".  The general
   rule is that wherever this specification allows for folding white
   space (not simply WSP characters), a CRLF may be inserted before any
   WSP.

As a result, to simplify processing, we should just strip out the
line separators when exposing the headers from upasfs.

3 years agoptrap: fix /env/status always being set on main process exit
BurnZeZ [Wed, 16 Sep 2020 20:45:49 +0000 (20:45 +0000)]
ptrap: fix /env/status always being set on main process exit

3 years agosyscall: don't append '\n' to the output
kvik [Wed, 16 Sep 2020 11:18:43 +0000 (13:18 +0200)]
syscall: don't append '\n' to the output

3 years agowindow: fix error exit with the -m flag
kvik [Wed, 16 Sep 2020 11:12:13 +0000 (13:12 +0200)]
window: fix error exit with the -m flag

When called with the -m flag window would always exit with
some error, usually status='no match', because of an if-match
being the last status-setting command in the script.

3 years agowin: fix window recreation command
kvik [Wed, 16 Sep 2020 10:41:24 +0000 (12:41 +0200)]
win: fix window recreation command

3 years ago/lib/rob, /lib/rsc, /lib/theo: So it sounds like everyone is in favor of the entire...
stanley lieber [Tue, 15 Sep 2020 03:10:16 +0000 (23:10 -0400)]
/lib/rob, /lib/rsc, /lib/theo: So it sounds like everyone is in favor of the entire generics proposal and all the semantics, and all we have left to hammer out is the bracket characters? Do I have that right?

3 years agomerge
cinap_lenrek [Sun, 13 Sep 2020 18:34:30 +0000 (20:34 +0200)]
merge

3 years agokernel: massive pci code rewrite
cinap_lenrek [Sun, 13 Sep 2020 18:33:17 +0000 (20:33 +0200)]
kernel: massive pci code rewrite

The new pci code is moved to port/pci.[hc] and shared by
all ports.

Each port has its own PCI controller implementation,
providing the pcicfgrw*() functions for low level pci
config space access. The locking for pcicfgrw*() is now
done by the caller (only port/pci.c).

Device drivers now need to include "../port/pci.h" in
addition to "io.h".

The new code now checks bridge windows and membars,
while enumerating the bus, giving the pc driver a chance
to re-assign them. This is needed because some UEFI
implementations fail to assign the bars for some devices,
so we need to do it outselfs. (See pcireservemem()).

While working on this, it was discovered that the pci
code assimed the smallest I/O bar size is 16 (pcibarsize()),
which is wrong. I/O bars can be as small as 4 bytes.
Bit 1 in an I/O bar is also reserved and should be masked off,
making the port mask: port = bar & ~3;

3 years agogames/4s: increase thread size (thanks majiru)
Ori Bernstein [Sun, 13 Sep 2020 18:21:21 +0000 (11:21 -0700)]
games/4s: increase thread size (thanks majiru)

It seems like on amd64, we're overflowing the stack.
Let's not do that.

3 years agofaces: remove log support
Ori Bernstein [Sun, 13 Sep 2020 00:40:41 +0000 (17:40 -0700)]
faces: remove log support

Use a damn plumber, you animals!

3 years agotmdate(1): document tz field
Ori Bernstein [Sun, 13 Sep 2020 00:36:14 +0000 (17:36 -0700)]
tmdate(1): document tz field

3 years agoctime(2), tmdate(2): document ctime/tmparse incompatibility
Ori Bernstein [Thu, 10 Sep 2020 23:26:42 +0000 (16:26 -0700)]
ctime(2), tmdate(2): document ctime/tmparse incompatibility

Tmparse and ctime don't mix. The timezone name may be
too long for the number of characters ctime mandates.
Document this footgun.

3 years agotmdate(2): one more typo
Ori Bernstein [Tue, 8 Sep 2020 02:32:50 +0000 (19:32 -0700)]
tmdate(2): one more typo

no more top arse. only bottom arse.

3 years agotmdate(2): fix examples, stale references (thanks deuteron)
Ori Bernstein [Tue, 8 Sep 2020 02:28:30 +0000 (19:28 -0700)]
tmdate(2): fix examples, stale references (thanks deuteron)

There were a number of ideas that were tried out as the tmdate
api evolved. As a result, there were some references in the
manpage to things that are no more.

Fix them.

3 years agotmdate(2): fix name of tm struct
Ori Bernstein [Tue, 8 Sep 2020 01:49:00 +0000 (18:49 -0700)]
tmdate(2): fix name of tm struct

There was a leftover from when this library was separate
with different types.

3 years agoetheriwl: add support for Intel Wireless AC 8265
cinap_lenrek [Sun, 6 Sep 2020 14:53:39 +0000 (16:53 +0200)]
etheriwl: add support for Intel Wireless AC 8265

3 years agowifi: add packet timestamping support
cinap_lenrek [Sun, 6 Sep 2020 14:51:02 +0000 (16:51 +0200)]
wifi: add packet timestamping support

3 years agowalk(1): improve wording, formatting
Ori Bernstein [Fri, 4 Sep 2020 03:07:44 +0000 (20:07 -0700)]
walk(1): improve wording, formatting

Clean up the wording of the walk(1) manpage,
improve the formatting of the format characters.

3 years agotmparse: put in local timezone hack
Ori Bernstein [Wed, 2 Sep 2020 02:32:45 +0000 (19:32 -0700)]
tmparse: put in local timezone hack

Ctime is defined as printing a 3-character timezone
name. The timezone name is ambiguous. For example,
EST refers to both Australian and American eastern
time. On top of that, we don't want to make the
tzabbrev table exhaustive. So, we put in this hack:

Before we consult the well known table of timezones,
we check if the local time matches the timezone name.

On top of that, tm2sec

If you want unambiguous timezone parsing, use numeric
timezone offsets (Z, ZZ formats).

3 years agoseconds: tolerate trailing whitespace in dates
Ori Bernstein [Wed, 2 Sep 2020 02:03:17 +0000 (19:03 -0700)]
seconds: tolerate trailing whitespace in dates

This allows handling dates with leading and trailing whitespace,
including newlines.

3 years agoupas: appendfolder() don't be picky about the timezone of ctime()
cinap_lenrek [Tue, 1 Sep 2020 21:08:58 +0000 (23:08 +0200)]
upas: appendfolder() don't be picky about the timezone of ctime()

This is temporary fix, we should try to emulate the previous
behaviour where we accept at least our local timezone, and
otherwise ignore the offset.

3 years agoupas: appendfolder(): skip the address from unix header before date
cinap_lenrek [Tue, 1 Sep 2020 21:01:45 +0000 (23:01 +0200)]
upas: appendfolder(): skip the address from unix header before date

3 years agoupas/fs: extract proper date from unix header
cinap_lenrek [Tue, 1 Sep 2020 19:39:45 +0000 (21:39 +0200)]
upas/fs: extract proper date from unix header

do not try to parse the m->unixfrom field, it only contains
the unix mail address.

instead, have parseunix() save a pointer into the unixheader
after the unix mail address for the unixdate, and later use
it to derive the mails timestamp.

3 years agoupas/fs: remove unused function date822tounix
Alex Musolino [Tue, 1 Sep 2020 12:55:06 +0000 (22:25 +0930)]
upas/fs: remove unused function date822tounix

3 years agopng: remove bogus chanlen warning
Alex Musolino [Tue, 1 Sep 2020 12:24:10 +0000 (21:54 +0930)]
png: remove bogus chanlen warning

3 years agoape/ctype.h: add isblank, fix functions (thanks staalmannen)
Ori Bernstein [Sat, 29 Aug 2020 18:09:20 +0000 (11:09 -0700)]
ape/ctype.h: add isblank, fix functions (thanks staalmannen)

Our ctype.h mistakenly ommitted isblank. Add it in.

While we're here, the make the 'isfoo()' functions
are broken: they're offsetting into the array, and
don't work with negative character values.

Sync the function bodies with the macros, and make
them produce correct results.

3 years agowalk(1): fix typo
Alex Musolino [Sat, 29 Aug 2020 08:53:59 +0000 (18:23 +0930)]
walk(1): fix typo

3 years agofaces(1): remove bespoke date parser
Ori Bernstein [Thu, 27 Aug 2020 17:32:02 +0000 (10:32 -0700)]
faces(1): remove bespoke date parser

In addition to being more code, this date parser would
treat local times as local, but anything that wasn't a
local time would get parsed as gmt, due to a quirk of
how tm2sec used to work.

This moves the code to tmparse, and fixes timezone parsing
at the same time.

3 years agowalk(1): clarify how -n argument works (thanks umbraticus)
Ori Bernstein [Thu, 27 Aug 2020 04:17:17 +0000 (21:17 -0700)]
walk(1): clarify how -n argument works (thanks umbraticus)

Make it clear what happens if you omit the ',' when
specifying '-n'.

3 years agotmparse: fix typo
Ori Bernstein [Wed, 26 Aug 2020 19:12:44 +0000 (12:12 -0700)]
tmparse: fix typo

3 years agolibc: tmparse should ignore leading whitespace
Ori Bernstein [Wed, 26 Aug 2020 17:23:00 +0000 (10:23 -0700)]
libc: tmparse should ignore leading whitespace

We almost always want to skip leading whitespace in time
formats, so make tmparse just do it. This fixes upas mbox
parsing, which leaves a leading whitespace at the start of
the date.

3 years agogetwd(2): add reference to chdir(2) in SEE ALSO section
Alex Musolino [Tue, 25 Aug 2020 11:21:38 +0000 (20:51 +0930)]
getwd(2): add reference to chdir(2) in SEE ALSO section

3 years agochdir(2): add reference to getwd(2) in SEE ALSO section
Alex Musolino [Tue, 25 Aug 2020 11:21:24 +0000 (20:51 +0930)]
chdir(2): add reference to getwd(2) in SEE ALSO section

3 years agotm2sec: clear new fields in tm
Ori Bernstein [Mon, 24 Aug 2020 21:47:10 +0000 (14:47 -0700)]
tm2sec: clear new fields in tm

Old users of the time APIs would hand-craft
time structs without first zeroing all the
members. When this got into tmnorm(), we
would try to access the new members, and
things would go off the rails.

This makes tm2sec() clear the new fields
before passing them to the new APIs, so
that the hand-crafted structs remain
valid.

3 years agonusb/lib: use fmtprint for the entire dump to be printed out
Sigrid [Sun, 23 Aug 2020 10:14:32 +0000 (12:14 +0200)]
nusb/lib: use fmtprint for the entire dump to be printed out

3 years agokernel: fix Abind cyclic reference and mounthead leaks (thanks Alex Musolino)
cinap_lenrek [Sun, 23 Aug 2020 03:07:30 +0000 (05:07 +0200)]
kernel: fix Abind cyclic reference and mounthead leaks (thanks Alex Musolino)

The Abind case in namec() needs to cunique() the chan
before attaching the umh mount head pointer onto it.

This is because we cannot give a reference to the mount
head to any of the mh->mount...->to channels, as they
will never go away until the mount head goes away.
This is a cyclic reference.

This could be reproduced with:

@{rfork n; mount -a '#s/boot' /mnt/root; bind /mnt/root /}

Also, fix memory leaks around cunique(), which can
error, leaking the mount head we got from domount().

Move the umh != nil check inside cunique().

3 years agotorrent(1): update url in examples section
Alex Musolino [Fri, 21 Aug 2020 00:36:22 +0000 (10:06 +0930)]
torrent(1): update url in examples section

3 years agoip(3): fix typo in manpage (thanks jstsmthrgk)
Ori Bernstein [Thu, 20 Aug 2020 20:25:37 +0000 (13:25 -0700)]
ip(3): fix typo in manpage (thanks jstsmthrgk)

3 years agolibaml: fix fault when the second operand of comparison cannot be converted
Sigrid [Thu, 20 Aug 2020 06:28:24 +0000 (08:28 +0200)]
libaml: fix fault when the second operand of comparison cannot be converted

3 years agooggdec: give it enough chance to seek from the start, where first seek might be still...
Sigrid [Tue, 18 Aug 2020 14:45:00 +0000 (16:45 +0200)]
oggdec: give it enough chance to seek from the start, where first seek might be still too close to the beginning of the file

3 years agoaudio/oggdec: allow -s 0
Sigrid [Wed, 12 Aug 2020 20:26:06 +0000 (22:26 +0200)]
audio/oggdec: allow -s 0

3 years agoaudio/mp3dec: mad timer duration is all wrong, use samples instead
Sigrid [Wed, 12 Aug 2020 09:42:00 +0000 (11:42 +0200)]
audio/mp3dec: mad timer duration is all wrong, use samples instead

3 years agoaudio/mp3dec: add -s SECONDS option
Sigrid [Wed, 12 Aug 2020 08:43:46 +0000 (10:43 +0200)]
audio/mp3dec: add -s SECONDS option

3 years agoaudio(1): add new -s SECONDS option
Sigrid [Tue, 11 Aug 2020 15:27:11 +0000 (17:27 +0200)]
audio(1): add new -s SECONDS option

3 years agoaudio/oggdec: add -s SECONDS option to seek before decoding
Sigrid [Tue, 11 Aug 2020 15:26:33 +0000 (17:26 +0200)]
audio/oggdec: add -s SECONDS option to seek before decoding

3 years agoaudio/flacdec: add -s SECONDS option to seek before decoding
Sigrid [Tue, 11 Aug 2020 15:25:53 +0000 (17:25 +0200)]
audio/flacdec: add -s SECONDS option to seek before decoding

3 years agotmdate(2): fix typo (thanks mveety)
Ori Bernstein [Tue, 11 Aug 2020 03:33:39 +0000 (20:33 -0700)]
tmdate(2): fix typo (thanks mveety)

sysfata => sysfatal

3 years agostdio.h: correct return type of putc
Ori Bernstein [Tue, 11 Aug 2020 02:36:09 +0000 (19:36 -0700)]
stdio.h: correct return type of putc

The putc macro is specified as returning an int, but our
type conversion rules turned it into a uint. Put in the
appropriate cast to make the type what we want.

3 years agoaux/ms2, aux/na: fix warnings
Ori Bernstein [Tue, 11 Aug 2020 02:35:05 +0000 (19:35 -0700)]
aux/ms2, aux/na: fix warnings

aux/na was comparing the return of putc with <0, when it should
have been comparing against EOF, which is not specified as -ve.

aux/ms2 was zero-extending the mask for the address when it
should have been sign extended.

3 years agoseconds: use new libc date api
Ori Bernstein [Tue, 11 Aug 2020 02:02:09 +0000 (19:02 -0700)]
seconds: use new libc date api

3 years agodate: use new libc date apis.
Ori Bernstein [Tue, 11 Aug 2020 02:01:45 +0000 (19:01 -0700)]
date: use new libc date apis.

3 years agomerge
Ori Bernstein [Tue, 11 Aug 2020 02:00:59 +0000 (19:00 -0700)]
merge

3 years agovmx: does not do well with certain fb widths, so restrict it
Sigrid [Mon, 10 Aug 2020 14:38:26 +0000 (16:38 +0200)]
vmx: does not do well with certain fb widths, so restrict it

3 years agoupas/fs: port date parsing to libc apis
Ori Bernstein [Mon, 10 Aug 2020 02:46:38 +0000 (19:46 -0700)]
upas/fs: port date parsing to libc apis

There was a lot of code in upas/fs to deal with dates.
Now there isn't.