Commit Graph

251248 Commits

Author SHA1 Message Date
kre fd38bbe2e4 An initial attempt at implementing LINENO to meet the specs.
Aside from one problem (not too hard to fix if it was ever needed) this version
does about as well as most other shell implementations when expanding
$((LINENO)) and better for ${LINENO} as it retains the "LINENO hack" for the
latter, and that is very accurate.

Unfortunately that means that ${LINENO} and $((LINENO)) do not always produce
the same value when used on the same line (a defect that other shells do not
share - aside from the FreeBSD sh as it is today, where only the LINENO hack
exists and so (like for us before this commit) $((LINENO)) is always either
0, or at least whatever value was last set, perhaps by
	LINENO=${LINENO}
which does actually work ... for that one line...)

This could be corrected by simply removing the LINENO hack (look for the string
LINENO in parser.c) in which case ${LINENO} and $((LINENO)) would give the
same (not perfectly accurate) values, as do most other shells.

POSIX requires that LINENO be set before each command, and this implementation
does that fairly literally - except that we only bother before the commands
which actually expand words (for, case and simple commands).   Unfortunately
this forgot that expansions also occur in redirects, and the other compound
commands can also have redirects, so if a redirect on one of the other compound
commands wants to use the value of $((LINENO)) as a part of a generated file
name, then it will get an incorrect value.  This is the "one problem" above.
(Because the LINENO hack is still enabled, using ${LINENO} works.)

This could be fixed, but as this version of the LINENO implementation is just
for reference purposes (it will be superseded within minutes by a better one)
I won't bother.  However should anyone else decide that this is a better choice
(it is probably a smaller implementation, in terms of code & data space then
the replacement, but also I would expect, slower, and definitely less accurate)
this defect is something to bear in mind, and fix.

This version retains the *BSD historical practice that line numbers in functions
(all functions) count from 1 from the start of the function, and elsewhere,
start from 1 from where the shell started reading the input file/stream in
question.  In an "eval" expression the line number starts at the line of the
"eval" (and then increases if the input is a multi-line string).

Note: this version is not documented (beyond as much as LINENO was before)
hence this slightly longer than usual commit message.
2017-06-07 04:44:17 +00:00
knakahara 2d7472e23b vlan(4) MP-ify. contributed by s-yamaguchi@IIJ, thanks.
XXX Pull-ups needed for netbsd-8 branch
2017-06-07 03:53:11 +00:00
msaitoh 5ea8386aad Fix typo. 2017-06-07 03:32:39 +00:00
msaitoh 6fa1e87bf8 - Add some bit definitions:
- Unidirectional enable
   - Unidirectional ability
   - Extended Next Page
   - Receive Next Page Location Able
   - Received Next Page Storage Location
   - Data Link Layer Classification capability
   - Enable Physical Layer Classification
   - Invalid Class in PD Class
   - PSE Status bit definitions
- Sort registers
- Modify comments.
2017-06-07 03:21:31 +00:00
msaitoh db571ad1db Fix typos. 2017-06-07 03:08:44 +00:00
kre 37406ae4e9 Fix a typo (or rather a remnant of an earlier intent). 2017-06-06 22:38:52 +00:00
jmcneill 91ce610635 Fix a race between ld_sdmmc_start and ld_sdmmc_dobio that could result in
tasks getting lost from the task queue. The symptom of this is a NULL
deref in ld_sdmmc_start since the code assumes that a task will always be
available from the pool.

This changes the code to use pcq(9) instead of a TAILQ to manage the free
task list.
2017-06-06 21:01:07 +00:00
skrll 97d12aea86 Reduce number of ALIGN macros defines and rename to avoid namespace clash 2017-06-06 20:19:04 +00:00
abhinav 1a8ce3a63b Bump date for previous
Fix typo: fileystem -> filesystem
2017-06-06 20:12:54 +00:00
ryo 1a52494ae8 whitespace police 2017-06-06 19:59:10 +00:00
christos a3ddac400c since ln(1) now uses linkat(2) provide a dumb wrapper. 2017-06-06 19:48:42 +00:00
christos 8bbf9e0cc7 - acquire lock
- use c99 loop indexes
- initialize featp
2017-06-06 18:08:23 +00:00
kamil bc0c5fd82b Update the EV_SET() description with newer implementation.
EV_SET(2) is a macro again, that wraps an inline function which is still
new in NetBSD 8.0.

Sponsored by <The NetBSD Foundation>
2017-06-06 17:01:59 +00:00
macallan 471068c972 SMU config goo 2017-06-06 15:58:59 +00:00
macallan 8ff9ad3262 SMU support, from Phileas Fogg 2017-06-06 15:58:17 +00:00
skrll a6ce035c71 Document current dtc/libfdt status (even if it is a mess) 2017-06-06 12:56:42 +00:00
jmcneill e2e89c4db3 Allow 'console=fb' to act as a shortcut on vexpress for
'stdout-path=/smb@08000000/motherboard/iofpga@3,00000000/clcd@1f0000'
2017-06-06 09:56:57 +00:00
jmcneill 98ec040ad9 Initialize boot_args before bootstrap for the benefit of platform code. 2017-06-06 09:56:00 +00:00
skrll e846b19637 Disable dtc/libfdt for now 2017-06-06 08:21:53 +00:00
skrll 03dcb730d4 Add libfdt 2017-06-06 07:45:39 +00:00
nat aaa8c67e4e Style change. 2017-06-06 07:32:41 +00:00
nat 59a3cdc9c9 pad blocksize 1024 -> 8192. Helps when sleeping in rate limiter. 2017-06-06 07:31:40 +00:00
nat 153aad6495 Simplification of rate limiter. It now works uni/multiprocessor. 2017-06-06 07:29:35 +00:00
nat 77e338f6c3 sc_bytes_count needs to be set in pad_audio_open not pad_open. 2017-06-06 07:27:15 +00:00
nat 518307b9ac Express BYTESTOSLEEP as an 64 bit integer.
Use BYTESTOSLEEP in expresson of BYTES_PER_SEC.
2017-06-06 07:18:38 +00:00
mbalmer 92375b0ab6 Fix a typo, i366 -> i386.
From PR misc/52274.
2017-06-06 07:13:06 +00:00
msaitoh 7ac7b3f845 Regen. 2017-06-06 05:39:28 +00:00
msaitoh 65539b5973 - Change VMware's 0x0770 from "Virtual USB" to "Virtual EHCI"
- Add VMware's 0x0774(UHCI) and 0x0778(xHCI)
2017-06-06 05:39:06 +00:00
msaitoh 0b02239177 Add missing RCS Id. 2017-06-06 04:56:12 +00:00
knakahara 2c01b23ab6 apply the same fix as crypto.c:r1.83 for crypto_dispatch to crypto_kdispatch. 2017-06-06 04:11:41 +00:00
knakahara 239ae8baa7 avoid crp_q reordering as hardware interrupts.
crypto_{,k}invoke() can be called with holding crp_q_mtx now.
2017-06-06 01:51:39 +00:00
knakahara 15bd7242d4 add locking notes. 2017-06-06 01:48:33 +00:00
knakahara 3fe5189186 restructure locks(2/2): crypto_q_mtx can be adaptive now. 2017-06-06 01:47:23 +00:00
knakahara bd79c5ac85 restructure locks(1/2): make relation between lock and data explicit.
+ crypto_drv_mtx protects
      -  whole crypto_drivers
    + crypto_drivers[i].cc_lock (new) protects
      - crypto_drivers[i] itself
      - member of crypto_drivers[i]
    + crypto_q_mtx protects
      - crp_q
      - crp_kq
    + crypto_ret_q_mtx protects
      - crp_ret_q
      - crp_ret_kq
      - crypto_exit_flag

I will add locking note later.
2017-06-06 01:45:57 +00:00
jmcneill b4f7190f81 Add support for stdout-path= kernel cmdline option to override the
console device specified in the FDT.
2017-06-06 00:28:05 +00:00
jmcneill eb1baa31be Allow plfb to be the console device 2017-06-06 00:26:59 +00:00
jmcneill 800afc3c4c Attach kbd slot to console 2017-06-06 00:26:16 +00:00
jmcneill 63d24fecc6 Fix spelling of WS_DEFAULT_FG and WS_KERNEL_FG options. 2017-06-06 00:25:48 +00:00
christos 85cf7cedea No need to set dtc twice. 2017-06-05 23:55:43 +00:00
christos 5b3fb03fcc add DTC 2017-06-05 23:44:27 +00:00
christos 7f85e44d1f Add dtc 2017-06-05 23:44:08 +00:00
christos 3634c48306 add MKDTC 2017-06-05 23:41:52 +00:00
christos 484e2f7c2e Add dtc 2017-06-05 23:24:29 +00:00
christos 74d52999c0 tools build glue. 2017-06-05 22:44:40 +00:00
sevan f5be6335dc Improve wording.
Bump date.

ok christos
2017-06-05 21:34:58 +00:00
abhinav 062266a272 Undo the previous
While it fixed the problem of trailing spaces, but if the probe specifier
contained leading spaces, it would brake dtrace. The proper fix would be
to skip the leading spaces in the string as well.

However, it would result in a bigger diff for a very small benefit. While
a new import of dtrace is impending, it's better not to have this change.

Discussed with christos.
2017-06-05 21:19:32 +00:00
skrll 922be9d3d3 Clean out some #if 0'ed or //'ed code 2017-06-05 20:02:11 +00:00
christos 496baf8250 remove the conflict. 2017-06-05 19:17:59 +00:00
christos 461d2d6a4c Add build glue (from skrll) 2017-06-05 18:59:43 +00:00
christos f8d365c3eb Make this compatible with byacc 2017-06-05 18:59:21 +00:00