opnsense-src/sys
John Baldwin 44c1914ee6 powerpc_nvram: Fix a bug in the adler32 checksum.
The Adler32 digest consists of two 16-bit words whose values are
calculated modulo 65521 (largest prime < 2^16).  To avoid two division
instructions per byte, this version copies an optimization found in
zlib which defers the modulus until close to the point that the
intermediate sums can overflow 2^32.  (zlib uses NMAX == 5552 for
this, this version uses 5000)

The bug is that in the deferred modulus case, the modulus was
only applied to the high word (and twice at that) but not to
the low word.  The fix is to apply it to both words.

Reviewed by:	jhibbits
Reported by:	Miod Vallat <miod@openbsd.org>
Differential Revision:	https://reviews.freebsd.org/D36798

(cherry picked from commit e0df0dce71)
2022-11-11 10:18:53 -08:00
..
amd64 linux32: binutils as requires %eflags instead of %flags for CFI. 2022-11-11 10:18:53 -08:00
arm xilinx: Fix a typo in a source code comment 2022-11-04 06:06:34 +01:00
arm64 aarch64: Add constants for fields in the PMEVTYPERn_EL0 event registers. 2022-11-10 13:04:49 -08:00
bsm Add aio_writev and aio_readv 2021-01-02 19:57:58 -07:00
cam iscsi: Fetch limits based on a socket rather than assuming global limits. 2022-11-10 13:48:36 -08:00
cddl dtrace: Drop illumos ifdefs for CPU register definitions 2022-10-19 10:15:49 -04:00
compat sysent: regen after ee9bc58183, posix_fadvise in capmode 2022-10-20 09:59:50 -04:00
conf cxgbe: Rename t4_kern_tls.c to t6_kern_tls.c. 2022-11-10 16:35:35 -08:00
contrib zlib crc32: Add prototypes for recently-added static functions. 2022-11-11 10:18:52 -08:00
crypto Fix the IV length in the armv8 AES GCM code 2022-09-21 10:45:52 +01:00
ddb ddb: print the actual syscall name 2022-11-06 10:54:46 -04:00
dev powerpc_nvram: Fix a bug in the adler32 checksum. 2022-11-11 10:18:53 -08:00
dts add overlay for enabling i2c1 on allwinner h3 2022-02-09 11:35:59 +02:00
fs nfs: Fix common typos in source code comments 2022-11-11 05:33:57 +01:00
gdb ddb: use _FLAGS command macros where appropriate 2022-08-11 11:25:53 -03:00
geom Delay GEOM disk_create() until CAM periph probe completes. 2022-08-15 13:37:58 -04:00
gnu bwn: eliminate dead writes in BWN_GPL_PHY 2022-05-12 08:56:04 -04:00
i386 ddb: print the actual syscall name 2022-11-06 10:54:46 -04:00
isa Adjust function definition in isa's pnp.c to avoid clang 15 warning 2022-08-01 20:07:10 +02:00
kern kasan: disable kasan_mark() after a violation 2022-11-02 12:02:24 -05:00
kgssapi State kgssapi dependency on xdr. 2020-09-17 22:29:38 +00:00
libkern qdivrem: Predict division by zero as false. 2022-10-12 17:53:21 +02:00
mips mips busdma: expunge an extra closing brace 2022-07-12 13:47:44 -05:00
modules cxgbe: Rename t4_kern_tls.c to t6_kern_tls.c. 2022-11-10 16:35:35 -08:00
net Remove a write-only variable. 2022-11-10 10:26:22 -08:00
net80211 net8021: Fix a typo in a kernel error message 2022-11-01 07:02:55 +01:00
netgraph netgraph/ng_bridge: add missing array terminator 2022-11-08 09:54:13 +01:00
netinet tcp_bbr(4): Fix a typo in a source code comment 2022-11-11 05:34:33 +01:00
netinet6 in6: Consolidate IN6_ARE_ADDR_EQUAL definitions 2022-11-10 12:03:03 -05:00
netipsec ipsec: replace SECASVAR mtx by rmlock 2022-08-09 15:46:57 +02:00
netpfil ipfilter: Cast uintmax_t values to size_t when adding to a pointer. 2022-11-11 10:18:52 -08:00
netsmb smb_smb_treedisconnect: eliminate write only variable mbp 2022-10-01 22:25:57 -06:00
nfs nfs: skip bootpc when vfs.root.mountfrom is other than nfs 2022-10-05 21:13:06 -03:00
nfsclient nfs: clean up empty lines in .c and .h files 2020-09-01 21:25:39 +00:00
nfsserver nfs: Mark unused statistics variable as reserved 2020-11-18 04:35:49 +00:00
nlm nlm: clean up empty lines in .c and .h files 2020-09-01 22:14:52 +00:00
ofed ibcore: Add support for RDMA/RoCE using VLAN(4) devices. 2022-08-29 14:03:57 +02:00
opencrypto opencrypto: mark INVARIANTS variables as __diagused 2022-08-28 21:03:48 -04:00
powerpc powerpc: slb_alloc_user_cache: fix missing uma_zalloc wait flag 2022-10-05 21:14:29 -03:00
riscv ddb: print the actual syscall name 2022-11-06 10:54:46 -04:00
rpc clnt_vc.c: Replace msleep() with pause() to avoid assert panic 2022-10-17 16:38:39 -07:00
security sysent: Get rid of bogus sys/sysent.h include. 2022-06-17 22:35:31 +03:00
sys Fix LINT build after 368ee2f86a 2022-10-23 19:43:46 -05:00
teken teken: color #3 is yellow not brown - use TC_YELLOW as the name 2022-05-03 14:20:44 -04:00
tests routing: add IPv6 fib validation procedure. 2021-09-07 21:02:58 +00:00
tools firmware: Map '@' in filenames to '_' in symbols. 2022-07-13 09:19:51 -07:00
ufs Fix an incorrectly placed parenthesis. 2022-10-13 08:45:56 -07:00
vm Fix various places which cast a pointer to a vm_paddr_t or vice versa. 2022-11-11 10:18:53 -08:00
x86 Fix various places which cast a pointer to a vm_paddr_t or vice versa. 2022-11-11 10:18:53 -08:00
xdr xdr: clean up empty lines in .c and .h files 2020-09-01 22:13:28 +00:00
xen Create wrapper for Giant taken for newbus 2022-06-21 17:13:20 +02:00
Makefile