Commit Graph

286116 Commits

Author SHA1 Message Date
rillig
09aa491484 tests/indent: demonstrate another bug in nested blocks 2021-03-08 20:55:34 +00:00
jkoshy
c5261b8388 Update libelf's manual pages to upstream revision [r3928]. 2021-03-08 20:55:06 +00:00
christos
447d94bacb remove ip{,6}_id.c 2021-03-08 20:43:22 +00:00
rillig
68856268b8 indent: inline macro for backslash
No functional change.
2021-03-08 20:20:11 +00:00
rillig
37bc0e6731 indent: convert big macros to functions
Each of these buffers is only modified in a single file.  This makes it
unnecessary to declare the macros in the global header.
2021-03-08 20:15:42 +00:00
rillig
548d705b04 tests/indent: add test for output line counting 2021-03-08 20:12:04 +00:00
christos
34a0a9590c welcome to 9.99.81, ip_randomid() signature change. 2021-03-08 20:02:47 +00:00
christos
fd63f5967c reinstate a simple version of ip_randomid() 2021-03-08 20:01:54 +00:00
rillig
6383459232 tests/indent: allow golden stderr file, improve filenames, clean up code
When indent runs in filter mode, it may output messages to stderr.
Allow tests with non-empty expected stderr.

In the ATF output, the filename 'output_file.parsed' was not helpful for
casual readers of diff output since they expect the filenames to be
meaningful.  Embed the name of the test case in that filename.

Fix quoting of the shell variables.

Remove the repetition of the regular expression to clean up the test
files.
2021-03-08 20:01:16 +00:00
christos
72d8d6c36a Appease new lint enum errors 2021-03-08 19:38:10 +00:00
rillig
849f856bf6 indent: make it easy to compile indent in debug mode 2021-03-08 19:21:41 +00:00
rillig
4526c76528 indent: fix printing of uninitialized 'token' in debug output 2021-03-08 19:06:48 +00:00
christos
0b3745dbe8 no need for ip6_id.c... 2021-03-08 18:22:16 +00:00
christos
2f7bd7704b Remove the unused "addin" argument (it was always 0) and go back using
a random iss by default (instead of rfc1948)
2021-03-08 18:17:27 +00:00
christos
aa44bcfbff remove now unused pseudo-random ip id code. 2021-03-08 18:03:25 +00:00
christos
fa908c0b8c Add some randomness to the iss offset 2021-03-08 17:54:43 +00:00
christos
a07b5793ea Use a random IPv4 ID because the shuffling algorithm used before could expose
information (Amit Klein)
2021-03-08 17:54:23 +00:00
christos
32fcdf5a4e Don't increment the iss sequence on each connection because it exposes
information (Amit Klein)
2021-03-08 17:53:20 +00:00
christos
47d63e29e1 give names to the enums so we can cast by name for lint 2021-03-08 17:34:30 +00:00
christos
e24596a734 cast to the proper enums for lint 2021-03-08 17:34:10 +00:00
isaki
50ac27503a Remove incorrect byte and word conversions from fpu_explode.
The correct operation here is arithmetic right shift, but nobody calls it.
2021-03-08 14:37:55 +00:00
mlelstv
d09bf9dfa7 Add comments for 2711 local peripherals 2021-03-08 14:27:45 +00:00
mlelstv
a1cd4d2a6b Move interrupt register definitions to driver. 2021-03-08 14:22:42 +00:00
mlelstv
229485571b Undocumented register to multiplex emmc2 pins to legacy sdhc 2021-03-08 13:59:29 +00:00
mlelstv
fd9b697d9c Add some firmware support functions and define more properties
- framebuffer
- power management
- vchiq init
- RPI4 USB firmware support
2021-03-08 13:53:08 +00:00
mlelstv
24287f23e1 RPI4 PCIe driver, based on pcihost_fdt.c 2021-03-08 13:49:01 +00:00
mlelstv
ba4ea317ac Interrupt no longer needs kernel lock. 2021-03-08 13:15:06 +00:00
mlelstv
089deafcbb Compute CRC for all segments of a multi-buffer packet.
Add interrupt mitigation for transmit and receive.
Use separate transmit lock.
Fix some error paths.
2021-03-08 13:14:44 +00:00
msaitoh
e1035e4cdb Use no_jmbuf evcnt for the failure case of ixgbe_getjcl(). 2021-03-08 07:10:45 +00:00
mlelstv
658992b280 Add bluetooth also to 32bit kernel. 2021-03-08 06:31:42 +00:00
mlelstv
3f227289ed early console for pico-pi-imx7 2021-03-08 06:27:06 +00:00
mlelstv
222bc718db always re-read status register in the loop. 2021-03-08 06:23:31 +00:00
rillig
73071b8322 indent: fix handling of '//' end-of-line comments 2021-03-07 22:11:01 +00:00
christos
b7a595bc61 fix missing chars 2021-03-07 20:54:41 +00:00
rillig
b65a14572e indent: sprinkle a few const
No functional change.
2021-03-07 20:52:11 +00:00
rillig
ec2de7a28a indent: remove redundant parentheses around return value
No functional change.
2021-03-07 20:47:13 +00:00
rillig
17efe8f8c3 lint: move keyword 'continue' over to the other control flow keywords
No functional change since neither rw_jump nor rw_inline_or_restrict is
mentioned in any switch statement, and lint didn't find any other
suspicious enum operations.
2021-03-07 20:40:18 +00:00
rillig
a3d348a576 indent: use named constants for the different types of keywords
This reduces the magic numbers in the code.  Most of these had their
designated constant name written in a nearby comment anyway.

The one instance where arithmetic was performed on this new enum type
(in indent.c) was a bit tricky to understand.

The combination rw_continue_or_inline_or_restrict looks strange, the
'continue' should intuitively belong to the other control flow keywords
in rw_break_or_goto_or_return.

No functional change.
2021-03-07 20:30:48 +00:00
rillig
36dd5d7651 lint: do not allow assignment-expression for constant-expression
It's a funny idea to do something like 'case a = 13:', but since any
compiler will reject this code, there is no point in lint supporting it.

No functional change since everywhere the grammar allows a constant
expression, there is no ambiguity where an assignment could be
interpreted differently.
2021-03-07 20:06:48 +00:00
rillig
53af70edc9 lint: rename grammar rule 'constant'
C99 6.4.4 already defines a grammar rule named 'constant' for an number
literal or an enum constant, so don't use that name for something else.

No functional change.
2021-03-07 19:57:46 +00:00
rillig
4c83646ad2 lint: align names of C grammar rules with C99
No functional change.
2021-03-07 19:46:18 +00:00
rillig
7bd1775519 lint: in strict C mode, warn about initialization with '[a ... b]'
https://gcc.gnu.org/onlinedocs/gcc/Case-Ranges.html
2021-03-07 19:42:54 +00:00
rillig
8c49e96e03 lint: fix off-by-one error in 'case 3...5'
According to the GCC documentation[1], the high end of the range is
inclusive as well, which makes sense since otherwise there would be no
way of specifying a range that includes the maximum representable
number.

Since the range is not used at all in the code, none of the tests could
possibly fail.

[1] https://gcc.gnu.org/onlinedocs/gcc/Case-Ranges.html

No functional change.
2021-03-07 18:02:45 +00:00
rillig
26903e6b19 lint: inline 'case 3...5' in grammar
There was no point in having a separate grammar rule for the '3...' part
of a range expression, it just made the code more complicated than
necessary.

No functional change.
2021-03-07 17:57:52 +00:00
rillig
f4d1bba78c lint: in the name of an array type, list the dimension first
before: array of unsigned int[4]
now:    array[4] of unsigned int

Listing the array dimension first keeps it in contact with the keyword
'array'.  This reduces confusion, especially for nested arrays.
2021-03-07 17:12:41 +00:00
rillig
05f8f43dfd tests/lint: demonstrate wrong warning for array subscript
Seen in usr.bin/indent/lexi.c.
2021-03-07 16:40:20 +00:00
nia
18c61bbc00 G12 2021-03-07 16:25:06 +00:00
christos
ee3785118f add TRAP_SIGDEBUG support to mips. 2021-03-07 15:10:05 +00:00
christos
d54a6e0c5d Add blocklist support to libwrap which enables all programs using libwrap
to block access from hosts we deny. (libwrap support from Greg A. Woods)
2021-03-07 15:09:12 +00:00
christos
ee87d87fd0 Amend missed messages:
netinet6: Pick IPv6 fragment ids uniformly at random.

Expected number of packets before collision is ~2^16, about the same
as we get for IPv4 with alternating disjoint random cycles.  Keep it
simple unless we determine we really need something much better for
IPv6 than what IPv4 can achieve anyway.

netinet6: Rip out now-unused IPv6 fragment id logic.

(from riastradh)
2021-03-07 15:03:32 +00:00