Commit Graph

278253 Commits

Author SHA1 Message Date
rillig
e8699354fb cgram(6): use standard cursor keys, use standard shuffle algorithm
The previous shuffle algorithm asked for 100 random numbers, on average.
The new algorithm asks exactly for 26 random numbers.

Curses predefines numeric constants for keys, and there is no apparent
reason not to use these standard keys for cursor movement.
2020-07-02 19:11:01 +00:00
roy
95af55eb59 dhcpcd: Fix SMALL build 2020-07-02 17:15:00 +00:00
rillig
ebbfad8f2d make(1): fix unnecessary evaluation of variables in :@var@ modifier 2020-07-02 16:52:34 +00:00
rillig
fcdc2c38f9 make(1): fix unnecessary evaluation for :S :C := modifiers 2020-07-02 16:46:57 +00:00
rillig
935e957525 make(1): demonstrate some more cases for unintended evaluation 2020-07-02 16:37:56 +00:00
rillig
ac48a45be5 make(1): clean up code in var.c
- remove redundant parentheses in return statements
- add missing space after comma
- remove some redundant parentheses around comparisons
- use hexadecimal numbers for bit mask constants
- remove Var_GetTail and Var_GetHead, which had been unused for 19 years
2020-07-02 16:14:50 +00:00
rillig
91643e7541 make(1): remove useless parameter from Var_Set
The enum corresponding to this int parameter is only defined in var.c,
which makes it impractical for the outside to set this parameter to
anything but 0.

On x86_64, this reduces the size of the resulting executable by 5 kB.
2020-07-02 15:47:38 +00:00
rillig
3b9ed0c6b7 make(1): use enum instead of #define for VarPattern flags 2020-07-02 15:26:21 +00:00
rillig
e42ab321d5 make(1): add more type safety for enums
There are several types of flags for variables, and these cannot be
mixed.  To prevent accidental typos, these are defined in separate enum
types.  Clang warns about direct assignments between distinct types, but
not about mixing distinct types in binary expressions like A | B.  GCC
does not warn at all.
2020-07-02 15:14:38 +00:00
lukem
46b85cbbd3 kyua-cli: convert auto_ptr to unique_ptr
Update kyua-cli to C++11 and use unique_ptr instead of auto_ptr,
(with std::move() where appropriate), to avoid deprecated warning by g++ 8.

(I didn't change some of the code that could arguably be refactored
to use unique_ptr or shared_ptr instead of raw pointers
and therefore remove the special case destructor handling).
2020-07-02 14:04:00 +00:00
roy
6ae10ac187 Note import of dhcpcd-9.1.3 2020-07-02 14:02:04 +00:00
roy
2fc7a081d2 Sync 2020-07-02 13:59:19 +00:00
roy
a43a146444 Update to dhcpcd-9.1.3 with the following changes:
* inet6: Add support for reporting Mobile IPv6 RA's
 * inet6: Report RA Proxy flag if set
 * BSD: Allow non NetBSD and OpenBSD to set IN6_IFF_AUTOCONF
 * privsep: Don't handle any signals meant for the main process
 * eloop: Try and survive a signal storm
 * dhcpcd: Add an option to poll the interface carrier state
 * script: Make visible some link level parameters to lease dumping
 * inet6: Don't regen temp addresses we didn't add
 * privsep: Don't limit file writes if logging to a file
 * DHCP6: Fix lease timings with nodelay option
2020-07-02 13:57:40 +00:00
lukem
e60d5634a2 lutok: auto_ptr replaced; remove build workaround 2020-07-02 13:56:10 +00:00
lukem
8665e60721 lutok: use unique_ptr not auto_ptr 2020-07-02 13:54:19 +00:00
rin
c9e3efd544 Add support of ptrace(2) for COMPAT_NETBSD32.
Now, GDB for arm32 is usable for debugging 32bit applications.

OK ryo@
2020-07-02 13:04:46 +00:00
rillig
f5d9ab301a make(1): fix unnecessary evaluation of :M and :N modifiers 2020-07-02 13:04:09 +00:00
rin
ed24610792 pmap_procwr(): sync icache even if p != curproc. This fixes applications
like GDB for arm32, that rewrite text of other process.

Thanks to ryo@ for discussion.
2020-07-02 13:01:11 +00:00
rin
864ad9df8e Set uvmexp.ncolors appropriately, which is required for some CPU
models with VIPT icache.

Otherwise, alias in virtual address results in inconsistent results,
at least for applications that rewrite text of other process, e.g.,
GDB for arm32.

Also, this hopefully fixes other unexpected failures due to alias.

Confirmed that there's no observable regression in performance;
difference in ``time make -j8'' for GENERIC64 kernel on BCM2837
with and without setting uvmexp.ncolors is within 0.1%.

Thanks to ryo@ for discussion.
2020-07-02 12:59:31 +00:00
macallan
b7d8551aa7 add $NetBSD: 2020-07-02 12:47:19 +00:00
macallan
14909839c0 proplib API catchup 2020-07-02 12:45:27 +00:00
rillig
4f4f969a98 make(1): demonstrate another unintended variable evaluation 2020-07-02 12:37:18 +00:00
rillig
b8b3ace20a make(1): fix edge case for evaluating unnecessary conditions 2020-07-02 12:34:30 +00:00
martin
b83e3fc8ed Initialize ci_kfpu_spl earlier for secondary CPUs. From riastradh 2020-07-02 11:49:48 +00:00
jmcneill
336dbb3e65 Add ddb "mach reset" command for Arm ports. 2020-07-02 11:10:47 +00:00
jdolecek
8c4f01a8e3 fix incomplete gnu/ deletion - PR misc/55444 by Jim Bernard 2020-07-02 11:08:55 +00:00
rillig
84868c179c make(1): demonstrate another unnecessary condition evaluation 2020-07-02 10:36:58 +00:00
rin
4db2f9236b Fix typo; PMAP_OEA64_BRIDGE not PMAP_OEA_BRIDGE.
Tested on Power Mac G5.
2020-07-02 10:28:11 +00:00
jmcneill
891b1559b6 Document OBJMACHINE_ARCH 2020-07-02 10:22:28 +00:00
rillig
947fa718d0 make(1): document the actual cause for "recursive variable"
That wrong error message had nothing to do with the .for loop, it was
only caused because the .for loop uses the :U modifier internally.
2020-07-02 09:44:51 +00:00
lukem
2c4fb72252 loader.efi doesn't have source
(Untested fix)
2020-07-02 09:07:24 +00:00
msaitoh
4af81626f6 prop_data_data_nocopy -> prop_data_value 2020-07-02 09:02:04 +00:00
lukem
08fb4e9235 Makefile.minirootkmod don't have SRCS 2020-07-02 08:48:10 +00:00
rin
4acff240b3 Remove pointless cast; dp is already uint32_t *.
No functional changes intended.
2020-07-02 07:49:44 +00:00
rin
8f480339f5 Correct SRCS; bsdstart.S not bsdstart.s.
Fix build with bsd.dep.mk rev 1.87, which requires more strict
filename matching.

Found by martin.
2020-07-01 23:37:10 +00:00
sjg
767817a641 Fix parsing of nested variables during .for loop
Recent change to cond.c to avoid eval of unnecessary
terms had side effect on constructs like:

.for s in 1 2
.if defined(MAN$s) && !empty(MAN$s)
MAN+= ${MAN$s}
.endif
.endfor

resulting in MAN being flagged as recursive.

When Var_Parse encounters a variable within a variable name
we want to force it to be expanded.
But given the way get_mpt_arg calls Var_Parse we need to check
whether we actually started parsing a variable yet.
2020-07-01 18:02:26 +00:00
jdolecek
87e5223f68 revert, not working 2020-07-01 17:57:14 +00:00
jdolecek
2cd6ed210c ignore interrupt when not expecting one, particularly don't invoke
the irqack in this case

seems cmdide doesn't honour WDCTL_IDS when executing polled commands,
and there is a race where the irqack call interferes with polled
command and causes a lockup

reported by Martin Husemann
2020-07-01 15:10:01 +00:00
jruoho
4704e28c3f Add basic checks for magic symlink(7)'s. These include a case for PR lib/55361,
although it seems that realpath(3) has bigger problems with these symlinks.
2020-07-01 13:49:26 +00:00
sborrill
ce6ed78858 When using show subcommand, display node ID (nid) in hexadecimal to match
the HD audio documentation. Diverge slightly by using 0xXX instead of XXh
format for consistency with the list subcommand.
2020-07-01 12:19:45 +00:00
riastradh
341c574011 Pass the requisite -msse options for i386. 2020-07-01 09:58:29 +00:00
lukem
7115637964 Fix addition of C++ .cc source to SRCS
Fix assumption that all of the source files are .c, as some are .cc.

Not tested, based on similar change to
  external/gpl3/gcc/usr.bin/cc1plus/Makefile
2020-07-01 08:25:44 +00:00
ryo
1b74214774 show clidr_el1 and ctr_el0. 2020-07-01 08:03:10 +00:00
ryo
697eec1bf5 add workaround for Neoverse N1 erratum 1542419 2020-07-01 08:02:13 +00:00
ryo
0c7bdc13f0 - On some systems with a different cache line size (and DIC,IDC) per CPU, trap "mrs Xt,ctr_el0" instruction
to return the minimum cache line size of the system to userland.
- add CLIDR_EL1 and CTR_EL0 to struct aarch64_sysctl_cpu_id.

On most systems, cache line size is the same for all CPUs, so this mechanism won't be required.
Rather, this is primarily for errata support, which will be committed later.
2020-07-01 08:01:07 +00:00
ryo
561087550e Switch the Icache sync operation to the necessary and sufficient one according to the CTR_EL0.DIC and CTR_EL0.IDC flags.
If CTR_EL0.DIC=1, Icache invalidation is not required.
If CTR_EL0.IDC=1, Dcache clean before Icache invalidation is not required.
CLIDR_EL1.LoC is 0, or CLIDR_EL1.LoUIS and CLIDR_EL1.LoUU are 0, Dcache clean is not required as well.

SEE ALSO ARMARM, "CTR_EL0 Cache Type Register", and "CLIDR_EL1 Cache Level ID Register"
2020-07-01 07:59:16 +00:00
lukem
b252a0e204 use ggc-none.c not ggc-none.o in SRCS
not tested, based on similar change to
 external/gpl3/gcc/usr.bin/lto-wrapper/Makefile
2020-07-01 07:54:24 +00:00
lukem
1defdf0961 bsd.dep.mk: fix "make tags" (again)
[repeat revision 1.85]

Fix "make tags" to actually build a tags file:
- Use !commands() instead of !target(), so that the rule actually works
- Write to ${.OBJDIR}/tags for read-only source (don't know why ${.TARGET}
  isn't sufficient).
- Only match *.[cly] from ${.ALLSRCS} - just excluding *.h causes failures
  because of ${targ}: subdir-${targ} in bsd.subdir.mk.

Thanks to uwe@ for assistance.
2020-07-01 07:38:29 +00:00
jruoho
55abcd082f Add basic checks for a64l(3), l64a(3), and l64a_r(3). 2020-07-01 07:16:37 +00:00
martin
bf0d51809d Forbid gcc to whine about intended format truncation 2020-07-01 06:31:18 +00:00