openbsd
10 years agodocument that sendsyslog saves the day
deraadt [Wed, 23 Jul 2014 05:57:36 +0000 (05:57 +0000)]
document that sendsyslog saves the day

10 years agoCheck the return value of the UI functions (including UI_new() which return
miod [Wed, 23 Jul 2014 04:44:56 +0000 (04:44 +0000)]
Check the return value of the UI functions (including UI_new() which return
value is happily dereferenced without checking it for being non-NULL).

ok beck@

10 years agodocument mallocarray like malloc throughout the page. better describe
dlg [Wed, 23 Jul 2014 02:30:12 +0000 (02:30 +0000)]
document mallocarray like malloc throughout the page. better describe
what M_CANFAIL means for each.

motivation and initial diff from doug hogan

10 years agosync
deraadt [Wed, 23 Jul 2014 00:18:22 +0000 (00:18 +0000)]
sync

10 years agoAdd $OpenBSD tag to make syncs easier
dtucker [Tue, 22 Jul 2014 23:57:40 +0000 (23:57 +0000)]
Add $OpenBSD tag to make syncs easier

10 years agoRegenerate test keys with certs signed with ed25519 instead of ecdsa.
dtucker [Tue, 22 Jul 2014 23:35:38 +0000 (23:35 +0000)]
Regenerate test keys with certs signed with ed25519 instead of ecdsa.
These can be used in -portable on platforms that don't support ECDSA.

10 years agoSign test certs with ed25519 instead of ecdsa so that they'll work in
dtucker [Tue, 22 Jul 2014 23:23:22 +0000 (23:23 +0000)]
Sign test certs with ed25519 instead of ecdsa so that they'll work in
-portable on platforms that don't have ECDSA in their OpenSSL.  ok djm

10 years agoSecurity fix:
schwarze [Tue, 22 Jul 2014 22:41:29 +0000 (22:41 +0000)]
Security fix:
The function print_encode() is used both for plain text
and for quoted attribute values.
Escape the '"' character such that malicious manuals cannot pull off
XSS attacks using malformed .Lk, .Mt, .%U, and .UR macros (and maybe
others) to trigger the latter case.
In the former case, escaping does no harm.
Issue found by Sebastien Marie <semarie-openbsd at latrappe dot fr>.

10 years agoadjust -C algorithm to be more aggressive in scaling up.
tedu [Tue, 22 Jul 2014 22:09:36 +0000 (22:09 +0000)]
adjust -C algorithm to be more aggressive in scaling up.
works better for me, and others as well.

10 years agoadd 5.7 firmware key
sthen [Tue, 22 Jul 2014 22:05:46 +0000 (22:05 +0000)]
add 5.7 firmware key

10 years agoAdd a link to pcexio(4) man page. Now 'man 4 pcexio' works fine on
aoyama [Tue, 22 Jul 2014 22:01:10 +0000 (22:01 +0000)]
Add a link to pcexio(4) man page.  Now 'man 4 pcexio' works fine on
luna88k.

ok miod@

10 years agoThe last poison change is awesome, it is triggering use after free bugs.
deraadt [Tue, 22 Jul 2014 21:41:09 +0000 (21:41 +0000)]
The last poison change is awesome, it is triggering use after free bugs.
Some of them aren't too difficult to find and fix, but others are turning
out to be deeply hidden.  The timing is poor -- disable this for now.
We need to revisit this right after tree unlock.

10 years agoRevert revisions 1.88-1.94 but keep recent relevant changes.
ajacoutot [Tue, 22 Jul 2014 21:01:58 +0000 (21:01 +0000)]
Revert revisions 1.88-1.94 but keep recent relevant changes.
The `+' sign was added by mistake thinking it was doing something else.

ok schwarze@

10 years agosome minor fixes;
jmc [Tue, 22 Jul 2014 19:03:21 +0000 (19:03 +0000)]
some minor fixes;

10 years agoTypo.
ajacoutot [Tue, 22 Jul 2014 18:31:16 +0000 (18:31 +0000)]
Typo.

no ok needed miod@ guenther@

10 years agoFSTAB -> _PATH_FSTAB, the latter is deprecated.
jca [Tue, 22 Jul 2014 18:28:40 +0000 (18:28 +0000)]
FSTAB -> _PATH_FSTAB, the latter is deprecated.
From natano@bitrig, ok deraadt@

10 years agoSecurity fix to prevent XSS attacks:
schwarze [Tue, 22 Jul 2014 18:14:05 +0000 (18:14 +0000)]
Security fix to prevent XSS attacks:
Restrict the character set of strings passed into html_alloc(),
in particular architecture names that come from the QUERY_STRING,
but also SCRIPT_NAME and manpath.conf content for additional safety,
and bail out safely on violations.
Issue reported by Sebastien Marie <semarie-openbsd at latrappe dot fr>.

10 years agoNow that DES_random_key() can be trusted, use it to generate DES keys in the
miod [Tue, 22 Jul 2014 18:10:48 +0000 (18:10 +0000)]
Now that DES_random_key() can be trusted, use it to generate DES keys in the
EVP_CTRL_RAND_KEY method handlers, rather than generating a random odd key and
not even checking it against the weak keys list.

ok beck@

10 years agoIn DES_random_key(), force the generated key to the odd parity before checking
miod [Tue, 22 Jul 2014 18:09:20 +0000 (18:09 +0000)]
In DES_random_key(), force the generated key to the odd parity before checking
it is not one of the weak and semi-weak keys.

Even though the probability of generating a weak key with incorrect parity is
abysmally small, there is no reason to be correct (although, if you're in a
need for fresh DES keys nowadays, you should seriously consider switching to
a stronger symmetric cipher algorithm).

ok beck@

10 years agouse NULL instead of (foo *)0; Kent R. Spillner
deraadt [Tue, 22 Jul 2014 18:03:03 +0000 (18:03 +0000)]
use NULL instead of (foo *)0; Kent R. Spillner

10 years agosync
deraadt [Tue, 22 Jul 2014 17:57:35 +0000 (17:57 +0000)]
sync

10 years agoThere is no httpctl yet.
reyk [Tue, 22 Jul 2014 17:54:43 +0000 (17:54 +0000)]
There is no httpctl yet.

Found by jturner

10 years agofloating ,
deraadt [Tue, 22 Jul 2014 17:49:58 +0000 (17:49 +0000)]
floating ,

10 years agoEnable httpd(8) in the builds to get more testing, feedback and
reyk [Tue, 22 Jul 2014 17:37:15 +0000 (17:37 +0000)]
Enable httpd(8) in the builds to get more testing, feedback and
improvements.  It is not "finished" but serves static files.

ok deraadt@

10 years ago- remove unneeded header
jasper [Tue, 22 Jul 2014 17:26:03 +0000 (17:26 +0000)]
- remove unneeded header
- move a declaration before code
- sync with wd.c -r1.101 from may 2011 and pass dk_openmask to setdisklabel

10 years agoRepair two deep targets mistakenly called as afterinstall, rather
deraadt [Tue, 22 Jul 2014 17:05:45 +0000 (17:05 +0000)]
Repair two deep targets mistakenly called as afterinstall, rather
than distribution. These would modify files in /etc, part of the base
set, but still... that makes it harder to discern their sets placement.

10 years agouse a better style of sh code around aperture
deraadt [Tue, 22 Jul 2014 17:01:33 +0000 (17:01 +0000)]
use a better style of sh code around aperture

10 years agoAdd initial httpd.conf(5) example for httpd(8)
reyk [Tue, 22 Jul 2014 16:58:21 +0000 (16:58 +0000)]
Add initial httpd.conf(5) example for httpd(8)

Requested by deraadt@

10 years agoremove unneccessary casts; Kent R. Spillner
deraadt [Tue, 22 Jul 2014 16:51:00 +0000 (16:51 +0000)]
remove unneccessary casts; Kent R. Spillner

10 years agobetter warning for 8bit cards
jasper [Tue, 22 Jul 2014 14:52:35 +0000 (14:52 +0000)]
better warning for 8bit cards

10 years ago- use DL_SECTOBLK() instead of handrolling the same functionality
jasper [Tue, 22 Jul 2014 14:49:49 +0000 (14:49 +0000)]
- use DL_SECTOBLK() instead of handrolling the same functionality
- octcfsize() returns daddr_t, so calculate the return value in a daddr_t

10 years agoSwitch to MI functions disk_{gone,openpart,closepart} instead of handrolling
jasper [Tue, 22 Jul 2014 14:45:34 +0000 (14:45 +0000)]
Switch to MI functions disk_{gone,openpart,closepart} instead of handrolling
the same functionality.

10 years agoUse MI rasops_cmap, instead of MD-defined ANSI colormap.
aoyama [Tue, 22 Jul 2014 13:39:16 +0000 (13:39 +0000)]
Use MI rasops_cmap, instead of MD-defined ANSI colormap.

Note about workaround for 8bpp frame buffer:

Current LUNA wscons touches only first 4 planes (plane #0-#3), but
other program (e.g. mlterm-fb) can use all 8 planes on an 8bpp frame
buffer.  When such program exits, it may not clear all planes, so
there may be some visible garbage data on the other 4 planes (plane
#4-#7) when we use default 256 rasops_cmap directly.

We should manage all 8 planes on LUNA, but that will be too much
overhead for 16 colors wscons.  So, by repeating 16 colors in 256
colormap, we can ignore the values on the other 4 planes.

ok miod@

10 years agoFewer <netinet/in_systm.h>
mpi [Tue, 22 Jul 2014 13:12:11 +0000 (13:12 +0000)]
Fewer <netinet/in_systm.h>

10 years agoFewer <netinet/in_systm.h> !
mpi [Tue, 22 Jul 2014 11:06:09 +0000 (11:06 +0000)]
Fewer <netinet/in_systm.h> !

10 years ago<netinet/in_systm.h> is no longer needed.
mpi [Tue, 22 Jul 2014 10:35:34 +0000 (10:35 +0000)]
<netinet/in_systm.h> is no longer needed.

10 years agotab->space; consistent with the other sysctl values.
ajacoutot [Tue, 22 Jul 2014 10:03:56 +0000 (10:03 +0000)]
tab->space; consistent with the other sysctl values.

10 years agoDrop quotes and mention that 3 and not 2 variables can be overridden.
ajacoutot [Tue, 22 Jul 2014 08:48:07 +0000 (08:48 +0000)]
Drop quotes and mention that 3 and not 2 variables can be overridden.

ok robert@

10 years agoTweak after recebt rc.securelevel change.
ajacoutot [Tue, 22 Jul 2014 07:38:52 +0000 (07:38 +0000)]
Tweak after recebt rc.securelevel change.

10 years agouse ansi style function declarations
jsg [Tue, 22 Jul 2014 07:30:24 +0000 (07:30 +0000)]
use ansi style function declarations
with suggestions from and ok guenther@

10 years agoConvert from <sys/endian.h> to the shiney new <endian.h>
guenther [Tue, 22 Jul 2014 07:13:42 +0000 (07:13 +0000)]
Convert from <sys/endian.h> to the shiney new <endian.h>

ok dtucker@, who also confirmed that -portable handles this already

10 years agoHandle failure of NETSCAPE_SPKI_b64_encode() and don't leak memory
guenther [Tue, 22 Jul 2014 06:55:22 +0000 (06:55 +0000)]
Handle failure of NETSCAPE_SPKI_b64_encode() and don't leak memory
when BIO_new_{file,fp}() fails.

inspired by a diff from logan@  ok miod@

10 years agoUse Cm instead of Li for 'MASK:'
guenther [Tue, 22 Jul 2014 06:47:13 +0000 (06:47 +0000)]
Use Cm instead of Li for 'MASK:'
(Overlooked among jmc@'s other suggestions)

10 years agoDrop the "... during install" comments; they were missing in several
ajacoutot [Tue, 22 Jul 2014 06:45:31 +0000 (06:45 +0000)]
Drop the "... during install" comments; they were missing in several
places and it makes things simpler: no need to check for file existence.

discussed with and ok deraadt@ rpe@

10 years agoRewrite the description of the string_mask config file option to match
guenther [Tue, 22 Jul 2014 06:28:10 +0000 (06:28 +0000)]
Rewrite the description of the string_mask config file option to match
reality, and reformatting to be readable.

formatting and wording suggestions miod@ jmc@

10 years agooops, duplicate
deraadt [Tue, 22 Jul 2014 04:53:59 +0000 (04:53 +0000)]
oops, duplicate

10 years agoneed dev/pci/vga_pcivar.h
deraadt [Tue, 22 Jul 2014 04:44:09 +0000 (04:44 +0000)]
need dev/pci/vga_pcivar.h

10 years agoThe aperture needed test should be in vgafb as well as vga@pci.
jsg [Tue, 22 Jul 2014 04:42:51 +0000 (04:42 +0000)]
The aperture needed test should be in vgafb as well as vga@pci.
Problem noticed/fix tested by sebastia@ on macppc.
sparc64 problems in earlier diff pointed out by deraadt@
'looks good' kettenis@ 'commit' deraadt@

10 years agoCorrect the initializer for tunnconf_default_pptp
guenther [Tue, 22 Jul 2014 02:58:32 +0000 (02:58 +0000)]
Correct the initializer for tunnconf_default_pptp

ok yasuoka@

10 years agoKill a bunch more BUF_strdup's - these are converted to have a check for
beck [Tue, 22 Jul 2014 02:21:20 +0000 (02:21 +0000)]
Kill a bunch more BUF_strdup's - these are converted to have a check for
NULL before an intrinsic strdup.
ok miod@

10 years agoHandle msgbuf_write() returning EAGAIN.
yasuoka [Tue, 22 Jul 2014 02:02:59 +0000 (02:02 +0000)]
Handle msgbuf_write() returning EAGAIN.

from krw

10 years agochange the test for still-open Unix domain sockets to be robust against
djm [Tue, 22 Jul 2014 01:32:12 +0000 (01:32 +0000)]
change the test for still-open Unix domain sockets to be robust against
nc implementations that produce error messages. from -portable

10 years agoPrevent spam from key_load_private_pem during hostbased auth. ok djm@
dtucker [Tue, 22 Jul 2014 01:18:50 +0000 (01:18 +0000)]
Prevent spam from key_load_private_pem during hostbased auth.  ok djm@

10 years agobetter match proposed syscall api
bcook [Tue, 22 Jul 2014 01:15:58 +0000 (01:15 +0000)]
better match proposed syscall api

10 years agoboot(9): Reduce diffs between hppa & hppa64 (& others)
uebayasi [Tue, 22 Jul 2014 01:04:04 +0000 (01:04 +0000)]
boot(9): Reduce diffs between hppa & hppa64 (& others)

10 years agosync
deraadt [Tue, 22 Jul 2014 01:01:37 +0000 (01:01 +0000)]
sync

10 years agoPull in all the parts. Let's face the facts -- .PATH from other
deraadt [Tue, 22 Jul 2014 00:41:19 +0000 (00:41 +0000)]
Pull in all the parts.  Let's face the facts --  .PATH from other
parts of the tree is PAINFUL for basically everyone upstream, not
just for us in our own tree.

10 years agoprotect sysctl path with SYS__sysctl instead; from enh@google, ok bcook
deraadt [Mon, 21 Jul 2014 23:34:54 +0000 (23:34 +0000)]
protect sysctl path with SYS__sysctl instead; from enh@google, ok bcook

10 years agoAdd pthread_sigmask() and raise() to the list of async signal safe
matthew [Mon, 21 Jul 2014 23:05:12 +0000 (23:05 +0000)]
Add pthread_sigmask() and raise() to the list of async signal safe
functions, per POSIX Issue 7

ok deraadt

10 years agofix a minibug reported by kristaps@:
schwarze [Mon, 21 Jul 2014 22:32:55 +0000 (22:32 +0000)]
fix a minibug reported by kristaps@:
preserve manpath and arch in .Xr links

10 years ago- whitespace cleanups (trailing whitespace, indentation)
jasper [Mon, 21 Jul 2014 21:07:34 +0000 (21:07 +0000)]
- whitespace cleanups (trailing whitespace, indentation)
- minor code shuffling and rename a variable to reduce diff with wd.c

no binary change

10 years agoRevert the up/down wheel emulation for now, there will be a better way
nicm [Mon, 21 Jul 2014 20:45:35 +0000 (20:45 +0000)]
Revert the up/down wheel emulation for now, there will be a better way
to do this along later for those who want it.

10 years agoBring back net.inet6.icmp6.rediraccept for rtsol. Pointed out by
naddy [Mon, 21 Jul 2014 20:43:00 +0000 (20:43 +0000)]
Bring back net.inet6.icmp6.rediraccept for rtsol.  Pointed out by
bluhm@ three days ago, oops.

10 years agonet.inet6.ip6.accept_rtadv is gone
naddy [Mon, 21 Jul 2014 20:39:59 +0000 (20:39 +0000)]
net.inet6.ip6.accept_rtadv is gone

10 years agoSince net.inet6.ip6.accept_rtadv is gone, the installer shouldn't
naddy [Mon, 21 Jul 2014 20:34:14 +0000 (20:34 +0000)]
Since net.inet6.ip6.accept_rtadv is gone, the installer shouldn't
set it.  Provisionally drop net.inet6.icmp6.rediraccept, too.

10 years agoUse explicit_bzero() instead of memset() on buffers going out of scope.
guenther [Mon, 21 Jul 2014 20:19:47 +0000 (20:19 +0000)]
Use explicit_bzero() instead of memset() on buffers going out of scope.
Also, zero the SHA256 context.

suggested by "eric" in a comment on an opensslrampage.org post
ok miod@ deraadt@

10 years agodon't try to be clever and name the _PATH_CP exec "mv", since this
deraadt [Mon, 21 Jul 2014 19:55:33 +0000 (19:55 +0000)]
don't try to be clever and name the _PATH_CP exec "mv", since this
breaks the instbin argv[0] mechanism
found by landry, ok guenther

10 years agouse getlist() instead of hand-rolled equivalent, no functional change;
schwarze [Mon, 21 Jul 2014 19:51:32 +0000 (19:51 +0000)]
use getlist() instead of hand-rolled equivalent, no functional change;
diff from Kent R. Spillner <kspillner at acm org>;
no objections came up when showing this diff on tech@

10 years agocast from void * before math; enh@google
deraadt [Mon, 21 Jul 2014 19:15:56 +0000 (19:15 +0000)]
cast from void * before math; enh@google

10 years agomissing newline
deraadt [Mon, 21 Jul 2014 18:13:12 +0000 (18:13 +0000)]
missing newline

10 years agoFix typo: s/lstate/lstat/
matthew [Mon, 21 Jul 2014 17:40:06 +0000 (17:40 +0000)]
Fix typo: s/lstate/lstat/

10 years agoboot(9): Reduce annoying style diffs
uebayasi [Mon, 21 Jul 2014 17:25:47 +0000 (17:25 +0000)]
boot(9): Reduce annoying style diffs

- Always use either: ((x & RB_XXX) != 0) or ((x & RB_XXX) == 0) in boolean
  context (mostly if (x), or x ? y : z)
  - prom_halt() in alpha is confirmed to take int as boolean

Converted by coccinelle.  No functional change intended.

10 years agoKristaps points out that the current HTTP/1.1 draft standard (RFC
schwarze [Mon, 21 Jul 2014 15:44:22 +0000 (15:44 +0000)]
Kristaps points out that the current HTTP/1.1 draft standard (RFC
2616) requires the Location: response-header field to be an absolute
URI (14.30), and only the most recent proposed standard (RFC 7231),
which is barely a month old, allows a relative Location: (7.1.2).
While most modern browsers appear to support relative Location:
headers, some may not, and it's maybe a bit early to rely on relative
Location: headers.

I'm not going back to the HTTP_HOST or SERVER_NAME CGI variables,
though.  While some CGI programs certainly require those, in which
case both the CGI programmer and the web server admin have to be
very careful to keep the system secure and reliable, man.cgi(8)
does not really need them.  We always know at compile time which
domain we are running for, and for man.cgi(8), security and reliability
are definitely much more important than flexibility.  So make HTTP_HOST
a compile-time definition for now.

10 years ago5.7 packages key
naddy [Mon, 21 Jul 2014 12:33:58 +0000 (12:33 +0000)]
5.7 packages key

10 years agolockf is entirely useless and it was a mistake to change to it, go back
nicm [Mon, 21 Jul 2014 10:52:48 +0000 (10:52 +0000)]
lockf is entirely useless and it was a mistake to change to it, go back
to using flock which actually works sensibly. Also always retry the lock
to fix a potential race, and add some extra logging.

10 years agoDrop explicit support for F13-F20 and change to match the xterm terminfo
nicm [Mon, 21 Jul 2014 10:25:48 +0000 (10:25 +0000)]
Drop explicit support for F13-F20 and change to match the xterm terminfo
entry:

        F13-F24 are S-F1 to S-F12
        F25-F36 are C-F1 to C-F12
        F37-F48 are C-S-F1 to C-S-F12
        F49-F60 are M-F1 to M-F12
and     F61-F63 are M-S-F1 to M-S-F3

This should be no difference for applications inside tmux, but means
that any key binding for F13 will need to be replaced by S-F1 and so on.

10 years agofix some wrong comments and a bit of KNF
mlarkin [Mon, 21 Jul 2014 01:57:55 +0000 (01:57 +0000)]
fix some wrong comments and a bit of KNF

10 years agoprintf(9) and friends don't support the <number>$ flags, so gcc's
guenther [Mon, 21 Jul 2014 01:53:12 +0000 (01:53 +0000)]
printf(9) and friends don't support the <number>$ flags, so gcc's
kprintf attribute shouldn't accept them.

ok martynas@

10 years agoSwitch from <sys/endian.h> or <machine/endian.h> to the new,
guenther [Mon, 21 Jul 2014 01:51:10 +0000 (01:51 +0000)]
Switch from <sys/endian.h> or <machine/endian.h> to the new,
being-standardized <endian.h>

ok deraadt@ millert@ beck@

10 years agosync
deraadt [Mon, 21 Jul 2014 00:11:24 +0000 (00:11 +0000)]
sync

10 years ago5.7 base key
deraadt [Mon, 21 Jul 2014 00:10:21 +0000 (00:10 +0000)]
5.7 base key

10 years agoProvide correct guidance on which header to use in the comments
guenther [Sun, 20 Jul 2014 21:41:54 +0000 (21:41 +0000)]
Provide correct guidance on which header to use in the comments

10 years agoMove more OS-specific functionality to arc4random.h headers.
bcook [Sun, 20 Jul 2014 20:51:13 +0000 (20:51 +0000)]
Move more OS-specific functionality to arc4random.h headers.

Move <sys/mman.h> and raise(SIGKILL) calls to OS-specific headers.
On OpenBSD, move thread_private.h as well to arc4random.h.
On Windows, use TerminateProcess on getentropy failure.

ok deraadt@

10 years agoFixed typo in error message.
tobias [Sun, 20 Jul 2014 20:27:19 +0000 (20:27 +0000)]
Fixed typo in error message.

okay deraadt@

10 years agoask about lid
deraadt [Sun, 20 Jul 2014 20:12:41 +0000 (20:12 +0000)]
ask about lid

10 years agoif we think this is a laptop (wsdisplay.....) ask a lidsuspend
deraadt [Sun, 20 Jul 2014 20:08:44 +0000 (20:08 +0000)]
if we think this is a laptop (wsdisplay.....) ask a lidsuspend
question.  Let's see who whines.

10 years agolook up correct dev_t. This matters for the case where a device is
deraadt [Sun, 20 Jul 2014 19:47:53 +0000 (19:47 +0000)]
look up correct dev_t.  This matters for the case where a device is
underlying softraid.
ok mlarkin

10 years agoMerge cmd.c from zboot into boot, dropping "clear" command while at it.
tobias [Sun, 20 Jul 2014 19:33:54 +0000 (19:33 +0000)]
Merge cmd.c from zboot into boot, dropping "clear" command while at it.

With input from deraadt@

okay jasper@, uebayashi@

10 years agoA HTTP connection may have multiple requests with content. Allow
bluhm [Sun, 20 Jul 2014 19:18:31 +0000 (19:18 +0000)]
A HTTP connection may have multiple requests with content.  Allow
to specify an array of md5 hashes in the test arguments and check
all of them in the client and server log files.  So test that relayd
does not modify the http body.

10 years agoRB_MINIROOT is never checked by anything, so stop setting it.
deraadt [Sun, 20 Jul 2014 18:24:34 +0000 (18:24 +0000)]
RB_MINIROOT is never checked by anything, so stop setting it.

10 years agomatch on vga1 or vgafb0, well, let's just call it vga.* for now
deraadt [Sun, 20 Jul 2014 18:13:22 +0000 (18:13 +0000)]
match on vga1 or vgafb0, well, let's just call it vga.* for now

10 years agospacing glitches
deraadt [Sun, 20 Jul 2014 18:10:15 +0000 (18:10 +0000)]
spacing glitches

10 years agoSupport hibernating to softraid crypto volumes.
mlarkin [Sun, 20 Jul 2014 18:05:21 +0000 (18:05 +0000)]
Support hibernating to softraid crypto volumes.

much help and ok from deraadt@

10 years agoFix tcpdump(8) display of logical link control data in IEEE802 frames.
stsp [Sun, 20 Jul 2014 17:52:34 +0000 (17:52 +0000)]
Fix tcpdump(8) display of logical link control data in IEEE802 frames.
The frame subtype field is in the first byte of frame control but tcpdump(8)
was looking at the second byte to determine if this is a data frame.
Patch by Nathanael Rensen, thanks!

10 years agoinitial win32 ARC4_LOCK/UNLOCK implementation.
bcook [Sun, 20 Jul 2014 16:59:31 +0000 (16:59 +0000)]
initial win32 ARC4_LOCK/UNLOCK implementation.

It may make sense to later replace this with a Critical Section later.
ok guenther@

10 years agoSkip reading bits from a region marked as "Preserve" if all bits will be
kettenis [Sun, 20 Jul 2014 12:20:38 +0000 (12:20 +0000)]
Skip reading bits from a region marked as "Preserve" if all bits will be
modified.  Some Sony and Asus laptops don't like this; the read seems to
trigger an unwanted SMI that makes the machine hang.  Diagnosed by mpi@

ok mpi@

10 years agoEliminate silly call() routine that fakes up internal calls as if
guenther [Sun, 20 Jul 2014 12:08:55 +0000 (12:08 +0000)]
Eliminate silly call() routine that fakes up internal calls as if
the user typed in undocumented arguments by splitting two functions
and doing normal (shock!) C calls.

Move extern declarations to externs.h
Eliminate another function cast

10 years agoAlways allocate bwi(4) ring descriptors below the 1GB boundary to give 30bit
stsp [Sun, 20 Jul 2014 11:59:12 +0000 (11:59 +0000)]
Always allocate bwi(4) ring descriptors below the 1GB boundary to give 30bit
devices a chance to work. Use bounce buffers for mbufs on 30bit devices.

This fixes "intr fatal TX/RX" errors that render the internal wifi on many
macppc machines unusable. However, packet loss problems remain. In my testing
the device works fine sometimes, but experiences packet loss rates of up
to 80% at other times. Still, this is a step forward.

Helpful hints from claudio@ and dlg@
Tested on macppc by mpi@ and myself
"go ahead" kettenis@, ok mpi@

10 years agoIn bwi(4), don't declare an interrupt as unhandled in case the PHY TX error
stsp [Sun, 20 Jul 2014 11:57:49 +0000 (11:57 +0000)]
In bwi(4), don't declare an interrupt as unhandled in case the PHY TX error
bit is set. This interrupt condition is handled by resetting the device.
ok mpi@ as part of a larger diff

10 years agoMake bwi_dma_mbuf_create() use the correct loop counter in error case.
stsp [Sun, 20 Jul 2014 11:57:05 +0000 (11:57 +0000)]
Make bwi_dma_mbuf_create() use the correct loop counter in error case.
Bug inherited from DragonFly BSD.
ok mpi@ as part of a larger diff.