Commit Graph

251107 Commits

Author SHA1 Message Date
jmcneill 439bf4cce8 If the "frequency" property is not specified, try to use the value in
CNTFRQ. Firmware should have already set this for us.
2017-05-28 00:29:55 +00:00
jmcneill 7780d9ea44 Change first pass from 1 to 0. 2017-05-28 00:28:17 +00:00
bouyer f3e8ca4e98 Add options CAN and pseudo-device canloop to ALL kernel configs.
Add the same commented out to i386/amd64 GENERIC and OLIMEXLIME2 (A20-based).
Also add commented out awincan0 in OLIMEXLIME2.
2017-05-27 22:53:29 +00:00
bouyer ddcfa75974 Update status of bouyer-socketcan 2017-05-27 21:06:26 +00:00
bouyer 1f23490b7e Note can(4) 2017-05-27 21:05:02 +00:00
bouyer 6e4cb2b9ab merge the bouyer-socketcan branch to HEAD.
CAN stands for Controller Area Network, a broadcast network used
in automation and automotive fields. For example, the NMEA2000 standard
developped for marine devices uses a CAN network as the link layer.

This is an implementation of the linux socketcan API:
https://www.kernel.org/doc/Documentation/networking/can.txt
you can also see can(4).

This adds a new socket family (AF_CAN) and protocol (PF_CAN),
as well as the canconfig(8) utility, used to set timing parameter of
CAN hardware. Also inclued is a driver for the CAN controller
found in the allwinner A20 SoC (I tested it with an Olimex lime2 board,
connected with PIC18-based CAN devices).

There is also the canloop(4) pseudo-device, which allows to use
the socketcan API without CAN hardware.

At this time the CANFD part of the linux socketcan API is not implemented.
Error frames are not implemented either. But I could get the cansend and
canreceive utilities from the canutils package to build and run with minimal
changes. tcpudmp(8) can also be used to record frames, which can be
decoded with etherreal.
2017-05-27 21:02:54 +00:00
jmcneill 99b53e88ef tegra_dma_bootstrap is no more 2017-05-27 20:26:44 +00:00
jmcneill a50e96c8f6 GC unused tegra_dma_bootstrap function. 2017-05-27 20:26:27 +00:00
nat e06e7fc1e1 Be even more carefull with devices that support only play back OR capture.
Addresses PR kern/52256.
2017-05-27 13:55:58 +00:00
kre ff906b151f Skip the test of non-posix behaviour if we are deliberately trying
to be posix compatible (POSIXLY_CORRECT is set).
2017-05-27 13:11:50 +00:00
nat 3e954dfe56 Revert to previous as what was the HIRES_BELL option is now the only
choice.

Suggested by jmcneill@.
2017-05-27 12:15:34 +00:00
nat 94002ebae7 The high resolution bell is the only option. The 8 kHz version has been
removed.

Suggested by jmcneill@.
2017-05-27 12:04:44 +00:00
kre 2d8874d9a7 More standard (and saner) implementation of the ! reserved word.
Unless the shell is compiled with the (compilation time) option
BOGUS_NOT_COMMAND (as in CFLAGS+=-DBOGUS_NOT_COMMAND) which it
will not normally be, the ! command (reserved word) will only
be permitted at the start of a pipeline (which includes the
degenerate pipeline with no '|'s in it of course - ie: a simple cmd)
and not in the middle of a pipeline sequence (no "cmd | ! cmd" nonsense.)
If the latter is really required, then "cmd | { ! cmd; }" works as
a standard equivalent.

In POSIX mode, permit only one !  ("! pipeline" is ok. "! ! pipeline" is not).
Again, if needed (and POSIX conformance is wanted) "! { ! pipeline; }"
works as an alternative - and is safer, some shells treat "! ! cmd" as
being identical to "cmd" (this one did until recently.)
2017-05-27 11:19:57 +00:00
nat e3d34f7eb6 Document the HIRES_BELL option. 2017-05-27 11:10:24 +00:00
nat 61f74d0842 The audio bell is now in 16 bit slinear format.
It is possible to use a frequency of 44.1 kHz as apposed to 8 kHz if
you specifiy:

options HIRES_BELL

in your kernel config file.

Changes to the way in which the wave is generated help reducing pops and
ticks in the bell.

The output of the high resolution bell has been tested extensively using
frequency spectographs generated by pkgsrc package audio/audacity.

This addresses PR kern/51784.
2017-05-27 10:54:47 +00:00
nat fad2617ec8 Add missing sc_bytes_count. 2017-05-27 10:43:30 +00:00
nat b38268fc93 Streaming channel is now opened in blocking mode again.
Removal of a hack in sbc_encode now that pad(4) is fixed.
2017-05-27 10:04:57 +00:00
nat 1a9a1dfb7d Rework of previous.
Math for BYTESTOSLEEP and TIMENEXTREAD is now correct.
2017-05-27 10:02:26 +00:00
kre 8df083c104 It turns out that most shells do not do variable value/attribute
inheritance when a variable is declared local, but instead leave
the local var unset (if not given a value) in the function.
Only ash derived shells do inheritance it seems.

So, to compensate for that, and get one step closer to making
"local" part of POSIX, so we can really rely upon it, a compromise
has been suggested, where "local x" is implementation defined
when it comes to this issue, and we add "local -I x" to specify
inheritance, and "local -N x" to specify "not" (something...)
(not inherited, or not set, or whatever you prefer to imagine!)
The option names took a lot of hunting to find something reasonable
that no shell (we know of) had already used for some other purpose...
The I was easy, but 'u' 'U' 'X' ... all in use somewhere.

This implements that (well, semi-) agreement.

While here, add "local -x" (which many other shells already have)
which causes the local variable to be made exported.  Not a lot
of gain in that (since "export x" can always be done immediately
after "local x") but it is very cheap to add and allows more other
scripts to work with out shell.

Note that while 'local x="${x}"' always works to specify inheritance
(while making the shell work harder), "local x; unset x" does not
always work to specify the alternative, as some shells have
"re-interpreted" unset of a local variable to mean something that
would best be described as "unlocal" instead - ie: after the unset
you might be back with the variable from the outer scope, rather
than with an unset local variable.

Also add "unset -x" to allow unsetting a variable without removing
any exported status it has.

There are gazillions of other options that are not supported here!
2017-05-27 06:32:12 +00:00
joerg 5bdaea99ff Use MACHINE_ARCH for the sparc check. 2017-05-26 22:56:50 +00:00
joerg 47fb074ea2 Fix argument order. 2017-05-26 22:50:35 +00:00
jmcneill da90d24c20 Recognize Cortex-A57 FPU, GIC, and Generic Timer. 2017-05-26 21:17:46 +00:00
jmcneill b0a72e63a8 Match nvidia,tegra210-pcie compat string. 2017-05-26 20:14:17 +00:00
jmcneill e97f463c20 Match nvidia,tegra210-ictlr compat string. 2017-05-26 20:08:02 +00:00
jmcneill bea84bfd88 Adjust a comment that refers to Tegra124; this code can be used on more
than one Tegra SoC.
2017-05-26 20:04:56 +00:00
jmcneill b75e6d101d Don't try to use memory above 4GB PA. 2017-05-26 18:58:55 +00:00
jmcneill 08b7e80d58 Handle reg values beyond 4GB for platforms with 32-bit bus_addr_t.
fdtbus_get_reg will do a range check and return ERANGE if addr+size
exceeds 4GB.

Add fdtbus_get_reg64 to allow for fetching raw values w/o range check.
2017-05-26 18:56:27 +00:00
hauke 01510a9c7f Enable carp packets early during boot, to avoid gratuitous failovers.
Okayed by christos@
2017-05-26 15:40:27 +00:00
riastradh c921bd9b79 Check VOP_INACTIVE contract with a judicious assert. 2017-05-26 14:40:09 +00:00
riastradh 51e152b5ce Clarify comment. 2017-05-26 14:39:20 +00:00
riastradh 93562e3f53 Eliminate crusty debugging sludge.
We have a mostly sane vnode lifecycle now.  If this needs debugging,
it should be done once at the call site of VOP_RECLAIM.
2017-05-26 14:34:19 +00:00
riastradh 5f4bcc542d Welcome to 7.99.74, courtesy assertable VOP_RECLAIM. 2017-05-26 14:22:53 +00:00
riastradh f4ad397b3e regen 2017-05-26 14:21:54 +00:00
riastradh 7f7aad09bd Make VOP_RECLAIM do the last unlock of the vnode.
VOP_RECLAIM naturally has exclusive access to the vnode, so having it
locked on entry is not strictly necessary -- but it means if there
are any final operations that must be done on the vnode, such as
ffs_update, requiring exclusive access to it, we can now kassert that
the vnode is locked in those operations.

We can't just have the caller release the last lock because some file
systems don't use genfs_lock, and require the vnode to remain valid
for VOP_UNLOCK to work, notably unionfs.
2017-05-26 14:20:59 +00:00
martin 4629a84de8 Add t_strcoll 2017-05-26 11:16:18 +00:00
msaitoh 7bf1852420 Add missing {ixgbe,ixv}_stop() in the detach function. Without this change,
shutdown won't finish or panic on heay traffic.
2017-05-26 09:17:32 +00:00
martin 2e49ec1546 Fix typo 2017-05-26 09:02:33 +00:00
msaitoh eccb5e67a7 Count Bad SFD (Start Frame Delimiter). X550 and newer have this register. 2017-05-26 08:36:41 +00:00
ozaki-r cafb33e1cd Replace "cmp" of function names to "match" and make their return value consistent
Function names with cmp are expected to return the order of two comparees
like memcmp and strcmp. The functions in question just answer if matched
or not, so don't use cmp and use match instead.

Consistently return 1 on matched and 0 otherwise.
2017-05-26 08:26:22 +00:00
ozaki-r 956d492de9 Make key_cmpspidx_exactly and key_cmpspidx_withmask static 2017-05-26 08:10:46 +00:00
ozaki-r b27d2b947a Comment out unused key_freesp_so and key_freeso 2017-05-26 08:09:44 +00:00
wiz 6ef78dfd8c New sentence, new line. Punctuation fixes. 2017-05-26 08:09:08 +00:00
ozaki-r c216b3be17 Simplify; we can assume the arguments are always non-NULL 2017-05-26 08:00:15 +00:00
msaitoh 493fc8cfd3 Clear all event counters when SIOCZIFDATA(ifconfig -z) is called. 2017-05-26 07:42:15 +00:00
skrll 04fbf2287d Whitespace 2017-05-26 06:41:42 +00:00
skrll 194ed3d72f Remove incorrect __diagused 2017-05-26 06:40:47 +00:00
skrll a49520abfd Use the define name PMAP_HWPAGEWALKER and not PMAP_TLB_HWPAGEWALKER 2017-05-26 06:38:56 +00:00
pgoyette 964c578f8a Add new t_strcol test to the sets list - hopefully fix the build 2017-05-26 05:33:27 +00:00
knakahara fdea45ce5f update opencrypto(9) 2017-05-26 02:30:24 +00:00
perseant 4e3374a73f Add simple expect-fail test case for strcoll(3) 2017-05-26 01:24:19 +00:00