sync with OpenBSD -current
This commit is contained in:
parent
b321f55ead
commit
302c0be22f
43 changed files with 456 additions and 132 deletions
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: aes.c,v 1.3 2024/03/30 05:14:12 joshua Exp $ */
|
/* $OpenBSD: aes.c,v 1.4 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
/* ====================================================================
|
/* ====================================================================
|
||||||
* Copyright (c) 2002-2006 The OpenSSL Project. All rights reserved.
|
* Copyright (c) 2002-2006 The OpenSSL Project. All rights reserved.
|
||||||
*
|
*
|
||||||
|
@ -55,6 +55,8 @@
|
||||||
#include <openssl/bio.h>
|
#include <openssl/bio.h>
|
||||||
#include <openssl/modes.h>
|
#include <openssl/modes.h>
|
||||||
|
|
||||||
|
#include "crypto_arch.h"
|
||||||
|
|
||||||
static const unsigned char aes_wrap_default_iv[] = {
|
static const unsigned char aes_wrap_default_iv[] = {
|
||||||
0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6,
|
0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6, 0xA6,
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: aes_core.c,v 1.23 2024/03/30 05:14:12 joshua Exp $ */
|
/* $OpenBSD: aes_core.c,v 1.24 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
/**
|
/**
|
||||||
* rijndael-alg-fst.c
|
* rijndael-alg-fst.c
|
||||||
*
|
*
|
||||||
|
@ -35,6 +35,7 @@
|
||||||
#include <openssl/aes.h>
|
#include <openssl/aes.h>
|
||||||
|
|
||||||
#include "aes_local.h"
|
#include "aes_local.h"
|
||||||
|
#include "crypto_arch.h"
|
||||||
#include "crypto_internal.h"
|
#include "crypto_internal.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
21
lib/libcrypto/arch/aarch64/crypto_arch.h
Normal file
21
lib/libcrypto/arch/aarch64/crypto_arch.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#endif
|
21
lib/libcrypto/arch/alpha/crypto_arch.h
Normal file
21
lib/libcrypto/arch/alpha/crypto_arch.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,4 +1,4 @@
|
||||||
# $OpenBSD: Makefile.inc,v 1.28 2024/06/04 15:14:45 deraadt Exp $
|
# $OpenBSD: Makefile.inc,v 1.29 2024/08/11 13:02:39 jsing Exp $
|
||||||
|
|
||||||
# amd64-specific libcrypto build rules
|
# amd64-specific libcrypto build rules
|
||||||
|
|
||||||
|
@ -13,11 +13,6 @@ SSLASM+= aes bsaes-x86_64
|
||||||
CFLAGS+= -DVPAES_ASM
|
CFLAGS+= -DVPAES_ASM
|
||||||
SSLASM+= aes vpaes-x86_64
|
SSLASM+= aes vpaes-x86_64
|
||||||
SSLASM+= aes aesni-x86_64
|
SSLASM+= aes aesni-x86_64
|
||||||
CFLAGS+= -DHAVE_AES_CBC_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_DECRYPT_INTERNAL
|
|
||||||
# bn
|
# bn
|
||||||
CFLAGS+= -DOPENSSL_IA32_SSE2
|
CFLAGS+= -DOPENSSL_IA32_SSE2
|
||||||
CFLAGS+= -DRSA_ASM
|
CFLAGS+= -DRSA_ASM
|
||||||
|
@ -48,8 +43,6 @@ SSLASM+= md5 md5-x86_64
|
||||||
CFLAGS+= -DGHASH_ASM
|
CFLAGS+= -DGHASH_ASM
|
||||||
SSLASM+= modes ghash-x86_64
|
SSLASM+= modes ghash-x86_64
|
||||||
# rc4
|
# rc4
|
||||||
CFLAGS+= -DHAVE_RC4_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_RC4_SET_KEY_INTERNAL
|
|
||||||
SSLASM+= rc4 rc4-x86_64
|
SSLASM+= rc4 rc4-x86_64
|
||||||
# ripemd
|
# ripemd
|
||||||
# sha
|
# sha
|
||||||
|
|
34
lib/libcrypto/arch/amd64/crypto_arch.h
Normal file
34
lib/libcrypto/arch/amd64/crypto_arch.h
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ASM
|
||||||
|
|
||||||
|
#define HAVE_AES_CBC_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_DECRYPT_INTERNAL
|
||||||
|
|
||||||
|
#define HAVE_RC4_INTERNAL
|
||||||
|
#define HAVE_RC4_SET_KEY_INTERNAL
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
|
@ -5,10 +5,6 @@
|
||||||
# aes
|
# aes
|
||||||
CFLAGS+= -DAES_ASM
|
CFLAGS+= -DAES_ASM
|
||||||
SSLASM+= aes aes-armv4
|
SSLASM+= aes aes-armv4
|
||||||
CFLAGS+= -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_DECRYPT_INTERNAL
|
|
||||||
# bn
|
# bn
|
||||||
CFLAGS+= -DOPENSSL_BN_ASM_MONT
|
CFLAGS+= -DOPENSSL_BN_ASM_MONT
|
||||||
SSLASM+= bn armv4-mont
|
SSLASM+= bn armv4-mont
|
||||||
|
|
30
lib/libcrypto/arch/arm/crypto_arch.h
Normal file
30
lib/libcrypto/arch/arm/crypto_arch.h
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ASM
|
||||||
|
|
||||||
|
#define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_DECRYPT_INTERNAL
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,12 +1,10 @@
|
||||||
# $OpenBSD: Makefile.inc,v 1.24 2024/03/29 11:00:57 jsing Exp $
|
# $OpenBSD: Makefile.inc,v 1.25 2024/08/11 13:02:39 jsing Exp $
|
||||||
|
|
||||||
# hppa-specific libcrypto build rules
|
# hppa-specific libcrypto build rules
|
||||||
|
|
||||||
# aes
|
# aes
|
||||||
CFLAGS+= -DAES_ASM
|
CFLAGS+= -DAES_ASM
|
||||||
SSLASM+= aes aes-parisc aes-parisc
|
SSLASM+= aes aes-parisc aes-parisc
|
||||||
CFLAGS+= -DHAVE_AES_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_DECRYPT_INTERNAL
|
|
||||||
# bn
|
# bn
|
||||||
SSLASM+= bn parisc-mont parisc-mont
|
SSLASM+= bn parisc-mont parisc-mont
|
||||||
CFLAGS+= -DOPENSSL_BN_ASM_MONT -DBN_DIV2W
|
CFLAGS+= -DOPENSSL_BN_ASM_MONT -DBN_DIV2W
|
||||||
|
|
28
lib/libcrypto/arch/hppa/crypto_arch.h
Normal file
28
lib/libcrypto/arch/hppa/crypto_arch.h
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ASM
|
||||||
|
|
||||||
|
#define HAVE_AES_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_DECRYPT_INTERNAL
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,4 +1,4 @@
|
||||||
# $OpenBSD: Makefile.inc,v 1.24 2024/03/29 11:00:57 jsing Exp $
|
# $OpenBSD: Makefile.inc,v 1.25 2024/08/11 13:02:39 jsing Exp $
|
||||||
|
|
||||||
# i386-specific libcrypto build rules
|
# i386-specific libcrypto build rules
|
||||||
|
|
||||||
|
@ -11,11 +11,6 @@ SSLASM+= aes aes-586
|
||||||
CFLAGS+= -DVPAES_ASM
|
CFLAGS+= -DVPAES_ASM
|
||||||
SSLASM+= aes vpaes-x86
|
SSLASM+= aes vpaes-x86
|
||||||
SSLASM+= aes aesni-x86
|
SSLASM+= aes aesni-x86
|
||||||
CFLAGS+= -DHAVE_AES_CBC_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_DECRYPT_INTERNAL
|
|
||||||
# bn
|
# bn
|
||||||
CFLAGS+= -DOPENSSL_IA32_SSE2
|
CFLAGS+= -DOPENSSL_IA32_SSE2
|
||||||
SSLASM+= bn bn-586
|
SSLASM+= bn bn-586
|
||||||
|
@ -29,8 +24,6 @@ SSLASM+= md5 md5-586
|
||||||
CFLAGS+= -DGHASH_ASM
|
CFLAGS+= -DGHASH_ASM
|
||||||
SSLASM+= modes ghash-x86
|
SSLASM+= modes ghash-x86
|
||||||
# rc4
|
# rc4
|
||||||
CFLAGS+= -DHAVE_RC4_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_RC4_SET_KEY_INTERNAL
|
|
||||||
SSLASM+= rc4 rc4-586
|
SSLASM+= rc4 rc4-586
|
||||||
# sha
|
# sha
|
||||||
CFLAGS+= -DSHA1_ASM
|
CFLAGS+= -DSHA1_ASM
|
||||||
|
|
34
lib/libcrypto/arch/i386/crypto_arch.h
Normal file
34
lib/libcrypto/arch/i386/crypto_arch.h
Normal file
|
@ -0,0 +1,34 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ASM
|
||||||
|
|
||||||
|
#define HAVE_AES_CBC_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_DECRYPT_INTERNAL
|
||||||
|
|
||||||
|
#define HAVE_RC4_INTERNAL
|
||||||
|
#define HAVE_RC4_SET_KEY_INTERNAL
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
21
lib/libcrypto/arch/m88k/crypto_arch.h
Normal file
21
lib/libcrypto/arch/m88k/crypto_arch.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,14 +1,10 @@
|
||||||
# $OpenBSD: Makefile.inc,v 1.17 2024/03/29 11:00:57 jsing Exp $
|
# $OpenBSD: Makefile.inc,v 1.18 2024/08/11 13:02:39 jsing Exp $
|
||||||
|
|
||||||
# mips64-specific libcrypto build rules
|
# mips64-specific libcrypto build rules
|
||||||
|
|
||||||
# aes
|
# aes
|
||||||
CFLAGS+= -DAES_ASM
|
CFLAGS+= -DAES_ASM
|
||||||
SSLASM+= aes aes-mips aes-mips
|
SSLASM+= aes aes-mips aes-mips
|
||||||
CFLAGS+= -DHAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_DECRYPT_INTERNAL
|
|
||||||
# bn
|
# bn
|
||||||
SSLASM+= bn mips bn-mips
|
SSLASM+= bn mips bn-mips
|
||||||
SSLASM+= bn mips-mont mips-mont
|
SSLASM+= bn mips-mont mips-mont
|
||||||
|
|
30
lib/libcrypto/arch/mips64/crypto_arch.h
Normal file
30
lib/libcrypto/arch/mips64/crypto_arch.h
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ASM
|
||||||
|
|
||||||
|
#define HAVE_AES_SET_ENCRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_SET_DECRYPT_KEY_INTERNAL
|
||||||
|
#define HAVE_AES_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_DECRYPT_INTERNAL
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
21
lib/libcrypto/arch/powerpc/crypto_arch.h
Normal file
21
lib/libcrypto/arch/powerpc/crypto_arch.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#endif
|
21
lib/libcrypto/arch/powerpc64/crypto_arch.h
Normal file
21
lib/libcrypto/arch/powerpc64/crypto_arch.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#endif
|
21
lib/libcrypto/arch/riscv64/crypto_arch.h
Normal file
21
lib/libcrypto/arch/riscv64/crypto_arch.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#endif
|
21
lib/libcrypto/arch/sh/crypto_arch.h
Normal file
21
lib/libcrypto/arch/sh/crypto_arch.h
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,12 +1,10 @@
|
||||||
# $OpenBSD: Makefile.inc,v 1.18 2024/03/29 11:00:57 jsing Exp $
|
# $OpenBSD: Makefile.inc,v 1.19 2024/08/11 13:02:39 jsing Exp $
|
||||||
|
|
||||||
# sparc64-specific libcrypto build rules
|
# sparc64-specific libcrypto build rules
|
||||||
|
|
||||||
# aes
|
# aes
|
||||||
CFLAGS+= -DAES_ASM
|
CFLAGS+= -DAES_ASM
|
||||||
SSLASM+= aes aes-sparcv9 aes-sparcv9
|
SSLASM+= aes aes-sparcv9 aes-sparcv9
|
||||||
CFLAGS+= -DHAVE_AES_ENCRYPT_INTERNAL
|
|
||||||
CFLAGS+= -DHAVE_AES_DECRYPT_INTERNAL
|
|
||||||
# bn
|
# bn
|
||||||
# modes
|
# modes
|
||||||
CFLAGS+= -DGHASH_ASM
|
CFLAGS+= -DGHASH_ASM
|
||||||
|
|
28
lib/libcrypto/arch/sparc64/crypto_arch.h
Normal file
28
lib/libcrypto/arch/sparc64/crypto_arch.h
Normal file
|
@ -0,0 +1,28 @@
|
||||||
|
/* $OpenBSD: crypto_arch.h,v 1.1 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
|
/*
|
||||||
|
* Copyright (c) 2024 Joel Sing <jsing@openbsd.org>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*/
|
||||||
|
|
||||||
|
#ifndef HEADER_CRYPTO_ARCH_H
|
||||||
|
#define HEADER_CRYPTO_ARCH_H
|
||||||
|
|
||||||
|
#ifndef OPENSSL_NO_ASM
|
||||||
|
|
||||||
|
#define HAVE_AES_ENCRYPT_INTERNAL
|
||||||
|
#define HAVE_AES_DECRYPT_INTERNAL
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: crypto_internal.h,v 1.10 2024/04/17 14:43:37 jsing Exp $ */
|
/* $OpenBSD: crypto_internal.h,v 1.11 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2023 Joel Sing <jsing@openbsd.org>
|
* Copyright (c) 2023 Joel Sing <jsing@openbsd.org>
|
||||||
*
|
*
|
||||||
|
@ -20,6 +20,8 @@
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
|
#include "crypto_arch.h"
|
||||||
|
|
||||||
#ifndef HEADER_CRYPTO_INTERNAL_H
|
#ifndef HEADER_CRYPTO_INTERNAL_H
|
||||||
#define HEADER_CRYPTO_INTERNAL_H
|
#define HEADER_CRYPTO_INTERNAL_H
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: rc4.c,v 1.11 2024/03/28 12:11:26 jsing Exp $ */
|
/* $OpenBSD: rc4.c,v 1.12 2024/08/11 13:02:39 jsing Exp $ */
|
||||||
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
|
/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
|
@ -60,6 +60,8 @@
|
||||||
|
|
||||||
#include <openssl/rc4.h>
|
#include <openssl/rc4.h>
|
||||||
|
|
||||||
|
#include "crypto_arch.h"
|
||||||
|
|
||||||
/* RC4 as implemented from a posting from
|
/* RC4 as implemented from a posting from
|
||||||
* Newsgroups: sci.crypt
|
* Newsgroups: sci.crypt
|
||||||
* From: sterndark@netcom.com (David Sterndark)
|
* From: sterndark@netcom.com (David Sterndark)
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
# $OpenBSD: Makefile,v 1.84 2024/07/13 18:33:18 tb Exp $
|
# $OpenBSD: Makefile,v 1.85 2024/08/11 13:04:46 jsing Exp $
|
||||||
|
|
||||||
.include <bsd.own.mk>
|
.include <bsd.own.mk>
|
||||||
.ifndef NOMAN
|
.ifndef NOMAN
|
||||||
|
@ -24,6 +24,7 @@ CFLAGS+= -DTLS13_DEBUG
|
||||||
.endif
|
.endif
|
||||||
CFLAGS+= -I${.CURDIR}
|
CFLAGS+= -I${.CURDIR}
|
||||||
CFLAGS+= -I${.CURDIR}/../libcrypto
|
CFLAGS+= -I${.CURDIR}/../libcrypto
|
||||||
|
CFLAGS+= -I${.CURDIR}/../libcrypto/arch/${MACHINE_CPU}
|
||||||
CFLAGS+= -I${.CURDIR}/../libcrypto/hidden
|
CFLAGS+= -I${.CURDIR}/../libcrypto/hidden
|
||||||
CFLAGS+= -I${.CURDIR}/../libcrypto/bio
|
CFLAGS+= -I${.CURDIR}/../libcrypto/bio
|
||||||
CFLAGS+= -I${.CURDIR}/hidden
|
CFLAGS+= -I${.CURDIR}/hidden
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
# $OpenBSD: Makefile,v 1.1 2024/04/25 14:27:29 jsing Exp $
|
# $OpenBSD: Makefile,v 1.2 2024/08/11 13:05:43 jsing Exp $
|
||||||
|
|
||||||
PROG = crypto_test
|
PROG = crypto_test
|
||||||
|
|
||||||
|
@ -8,5 +8,6 @@ LDFLAGS+= -lcrypto
|
||||||
CFLAGS+= -DLIBRESSL_INTERNAL
|
CFLAGS+= -DLIBRESSL_INTERNAL
|
||||||
CFLAGS+= -Wall -Wundef -Werror
|
CFLAGS+= -Wall -Wundef -Werror
|
||||||
CFLAGS+= -I${.CURDIR}/../../../../lib/libcrypto
|
CFLAGS+= -I${.CURDIR}/../../../../lib/libcrypto
|
||||||
|
CFLAGS+= -I${.CURDIR}/../../../../lib/libcrypto/arch/${MACHINE_CPU}
|
||||||
|
|
||||||
.include <bsd.regress.mk>
|
.include <bsd.regress.mk>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
.\" $OpenBSD: dhcpleased.8,v 1.6 2023/03/02 17:09:52 jmc Exp $
|
.\" $OpenBSD: dhcpleased.8,v 1.7 2024/08/11 06:07:37 jmc Exp $
|
||||||
.\"
|
.\"
|
||||||
.\" Copyright (c) 2021 Florian Obser <florian@openbsd.org>
|
.\" Copyright (c) 2021 Florian Obser <florian@openbsd.org>
|
||||||
.\"
|
.\"
|
||||||
|
@ -14,7 +14,7 @@
|
||||||
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
.\"
|
.\"
|
||||||
.Dd $Mdocdate: March 2 2023 $
|
.Dd $Mdocdate: August 11 2024 $
|
||||||
.Dt DHCPLEASED 8
|
.Dt DHCPLEASED 8
|
||||||
.Os
|
.Os
|
||||||
.Sh NAME
|
.Sh NAME
|
||||||
|
@ -28,11 +28,16 @@
|
||||||
.Sh DESCRIPTION
|
.Sh DESCRIPTION
|
||||||
.Nm
|
.Nm
|
||||||
is a dynamic host configuration protocol (DHCP) daemon for clients.
|
is a dynamic host configuration protocol (DHCP) daemon for clients.
|
||||||
It requests IP configuration information from for example those offered by
|
If an interface has the
|
||||||
.Xr dhcpd 8 ,
|
|
||||||
on interfaces with the
|
|
||||||
.Sy AUTOCONF4
|
.Sy AUTOCONF4
|
||||||
flag set.
|
flag set
|
||||||
|
(auto configuration is enabled),
|
||||||
|
.Nm
|
||||||
|
sends requests for IP configuration information from a DHCP server,
|
||||||
|
such as
|
||||||
|
.Xr dhcpd 8 ,
|
||||||
|
and uses that information to configure the relevant interface.
|
||||||
|
.Pp
|
||||||
See
|
See
|
||||||
.Xr hostname.if 5
|
.Xr hostname.if 5
|
||||||
and
|
and
|
||||||
|
@ -41,9 +46,8 @@ on how to enable auto configuration on an interface.
|
||||||
.Pp
|
.Pp
|
||||||
.Nm
|
.Nm
|
||||||
monitors network interface states (interface going up or down,
|
monitors network interface states (interface going up or down,
|
||||||
auto configuration enabled or disabled etc.) and sends requests
|
auto configuration enabled or disabled, etc.) and sends requests
|
||||||
when necessary.
|
when necessary.
|
||||||
.Pp
|
|
||||||
A running
|
A running
|
||||||
.Nm
|
.Nm
|
||||||
can be controlled with the
|
can be controlled with the
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
.\" $OpenBSD: slaacd.8,v 1.12 2023/03/02 17:09:54 jmc Exp $
|
.\" $OpenBSD: slaacd.8,v 1.13 2024/08/11 06:07:37 jmc Exp $
|
||||||
.\"
|
.\"
|
||||||
.\" Copyright (c) 2017 Florian Obser <florian@openbsd.org>
|
.\" Copyright (c) 2017 Florian Obser <florian@openbsd.org>
|
||||||
.\" Copyright (c) 2016 Kenneth R Westerback <kwesterback@gmail.com>
|
.\" Copyright (c) 2016 Kenneth R Westerback <kwesterback@gmail.com>
|
||||||
|
@ -15,7 +15,7 @@
|
||||||
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
.\"
|
.\"
|
||||||
.Dd $Mdocdate: March 2 2023 $
|
.Dd $Mdocdate: August 11 2024 $
|
||||||
.Dt SLAACD 8
|
.Dt SLAACD 8
|
||||||
.Os
|
.Os
|
||||||
.Sh NAME
|
.Sh NAME
|
||||||
|
@ -28,15 +28,16 @@
|
||||||
.Sh DESCRIPTION
|
.Sh DESCRIPTION
|
||||||
.Nm
|
.Nm
|
||||||
is a stateless address autoconfiguration (SLAAC) daemon for clients.
|
is a stateless address autoconfiguration (SLAAC) daemon for clients.
|
||||||
It listens for IPv6 router advertisement messages,
|
If an interface has the
|
||||||
for example those sent by
|
|
||||||
.Xr rad 8 ,
|
|
||||||
on interfaces with the
|
|
||||||
.Sy AUTOCONF6
|
.Sy AUTOCONF6
|
||||||
flag set.
|
flag set
|
||||||
|
(auto configuration is enabled),
|
||||||
.Nm
|
.Nm
|
||||||
derives IPv6 addresses and default routes from received router
|
regularly sends out requests for IPv6 router advertisement messages,
|
||||||
advertisements and installs them in the kernel.
|
such as those sent by
|
||||||
|
.Xr rad 8 ,
|
||||||
|
and uses those messages to configure the relevant interface.
|
||||||
|
.Pp
|
||||||
See
|
See
|
||||||
.Xr hostname.if 5
|
.Xr hostname.if 5
|
||||||
and
|
and
|
||||||
|
@ -44,10 +45,9 @@ and
|
||||||
on how to enable auto configuration on an interface.
|
on how to enable auto configuration on an interface.
|
||||||
.Pp
|
.Pp
|
||||||
.Nm
|
.Nm
|
||||||
monitors network interface states (interface going up or down,
|
monitors network interface states
|
||||||
auto configuration enabled or disabled etc.) and sends router solicitations
|
(interface going up or down, auto configuration enabled or disabled, etc.)\&
|
||||||
when necessary.
|
and sends router solicitations when necessary.
|
||||||
.Pp
|
|
||||||
A running
|
A running
|
||||||
.Nm
|
.Nm
|
||||||
can be controlled with the
|
can be controlled with the
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
.\" $OpenBSD: dwxe.4,v 1.3 2022/03/21 14:56:16 miod Exp $
|
.\" $OpenBSD: dwxe.4,v 1.4 2024/08/11 08:25:12 dtucker Exp $
|
||||||
.\"
|
.\"
|
||||||
.\" Copyright (c) 2016 Mark Kettenis <kettenis@openbsd.org>
|
.\" Copyright (c) 2016 Mark Kettenis <kettenis@openbsd.org>
|
||||||
.\"
|
.\"
|
||||||
|
@ -14,7 +14,7 @@
|
||||||
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
.\"
|
.\"
|
||||||
.Dd $Mdocdate: March 21 2022 $
|
.Dd $Mdocdate: August 11 2024 $
|
||||||
.Dt DWXE 4
|
.Dt DWXE 4
|
||||||
.Os
|
.Os
|
||||||
.Sh NAME
|
.Sh NAME
|
||||||
|
@ -28,7 +28,7 @@ The
|
||||||
.Nm
|
.Nm
|
||||||
driver provides support for various Ethernet controllers based on the
|
driver provides support for various Ethernet controllers based on the
|
||||||
Allwinner EMAC.
|
Allwinner EMAC.
|
||||||
These controllers are found on the Allwinner H3/H5/A64 SoCs.
|
These controllers are found on the Allwinner A64/H3/H5/H6/H616 SoCs.
|
||||||
.Pp
|
.Pp
|
||||||
The
|
The
|
||||||
.Nm
|
.Nm
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
.\" $OpenBSD: timeout.9,v 1.58 2024/08/05 23:52:03 dlg Exp $
|
.\" $OpenBSD: timeout.9,v 1.59 2024/08/11 00:50:38 dlg Exp $
|
||||||
.\"
|
.\"
|
||||||
.\" Copyright (c) 2000 Artur Grabowski <art@openbsd.org>
|
.\" Copyright (c) 2000 Artur Grabowski <art@openbsd.org>
|
||||||
.\" Copyright (c) 2021, 2022 Scott Cheloha <cheloha@openbsd.org>
|
.\" Copyright (c) 2021, 2022 Scott Cheloha <cheloha@openbsd.org>
|
||||||
|
@ -24,7 +24,7 @@
|
||||||
.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||||
.\" ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
.\" ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
.\"
|
.\"
|
||||||
.Dd $Mdocdate: August 5 2024 $
|
.Dd $Mdocdate: August 11 2024 $
|
||||||
.Dt TIMEOUT_SET 9
|
.Dt TIMEOUT_SET 9
|
||||||
.Os
|
.Os
|
||||||
.Sh NAME
|
.Sh NAME
|
||||||
|
@ -83,12 +83,12 @@
|
||||||
.Ft int
|
.Ft int
|
||||||
.Fo timeout_add_msec
|
.Fo timeout_add_msec
|
||||||
.Fa "struct timeout *to"
|
.Fa "struct timeout *to"
|
||||||
.Fa "int msecs"
|
.Fa "uint64_t msecs"
|
||||||
.Fc
|
.Fc
|
||||||
.Ft int
|
.Ft int
|
||||||
.Fo timeout_add_usec
|
.Fo timeout_add_usec
|
||||||
.Fa "struct timeout *to"
|
.Fa "struct timeout *to"
|
||||||
.Fa "int usecs"
|
.Fa "uint64_t usecs"
|
||||||
.Fc
|
.Fc
|
||||||
.Ft int
|
.Ft int
|
||||||
.Fo timeout_add_nsec
|
.Fo timeout_add_nsec
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: acpi.c,v 1.436 2024/07/30 19:47:06 mglocker Exp $ */
|
/* $OpenBSD: acpi.c,v 1.437 2024/08/10 23:28:17 deraadt Exp $ */
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com>
|
* Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com>
|
||||||
* Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org>
|
* Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org>
|
||||||
|
@ -2591,8 +2591,6 @@ acpi_resume_pm(struct acpi_softc *sc, int fromstate)
|
||||||
acpi_disable_allgpes(sc);
|
acpi_disable_allgpes(sc);
|
||||||
acpi_enable_rungpes(sc);
|
acpi_enable_rungpes(sc);
|
||||||
|
|
||||||
acpi_indicator(sc, ACPI_SST_WAKING);
|
|
||||||
|
|
||||||
/* 2nd resume AML step: _WAK(fromstate) */
|
/* 2nd resume AML step: _WAK(fromstate) */
|
||||||
aml_node_setval(sc, sc->sc_wak, fromstate);
|
aml_node_setval(sc, sc->sc_wak, fromstate);
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: acpi_x86.c,v 1.25 2024/08/08 07:02:38 kettenis Exp $ */
|
/* $OpenBSD: acpi_x86.c,v 1.29 2024/08/11 17:30:28 deraadt Exp $ */
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com>
|
* Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com>
|
||||||
* Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org>
|
* Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org>
|
||||||
|
@ -80,7 +80,6 @@ sleep_setstate(void *v)
|
||||||
if (aml_node_setval(sc, sc->sc_pts, sc->sc_state) != 0)
|
if (aml_node_setval(sc, sc->sc_pts, sc->sc_state) != 0)
|
||||||
return (EINVAL);
|
return (EINVAL);
|
||||||
}
|
}
|
||||||
acpi_indicator(sc, ACPI_SST_WAKING); /* blink */
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -126,6 +125,7 @@ gosleep(void *v)
|
||||||
if (sc->sc_pmc_resume)
|
if (sc->sc_pmc_resume)
|
||||||
sc->sc_pmc_resume(sc->sc_pmc_cookie);
|
sc->sc_pmc_resume(sc->sc_pmc_cookie);
|
||||||
|
|
||||||
|
acpi_indicator(sc, ACPI_SST_WAKING); /* blink */
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -143,7 +143,6 @@ sleep_resume(void *v)
|
||||||
if (aml_node_setval(sc, sc->sc_tts, ACPI_STATE_S0) != 0)
|
if (aml_node_setval(sc, sc->sc_tts, ACPI_STATE_S0) != 0)
|
||||||
return (EINVAL);
|
return (EINVAL);
|
||||||
}
|
}
|
||||||
acpi_indicator(sc, ACPI_SST_WAKING); /* blink */
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2080,7 +2080,6 @@ inteldrm_doswitch(void *v)
|
||||||
{
|
{
|
||||||
struct inteldrm_softc *dev_priv = v;
|
struct inteldrm_softc *dev_priv = v;
|
||||||
struct rasops_info *ri = &dev_priv->ro;
|
struct rasops_info *ri = &dev_priv->ro;
|
||||||
struct drm_device *dev = &dev_priv->drm;
|
|
||||||
|
|
||||||
rasops_show_screen(ri, dev_priv->switchcookie, 0, NULL, NULL);
|
rasops_show_screen(ri, dev_priv->switchcookie, 0, NULL, NULL);
|
||||||
intel_fbdev_restore_mode(dev_priv);
|
intel_fbdev_restore_mode(dev_priv);
|
||||||
|
@ -2094,7 +2093,6 @@ inteldrm_enter_ddb(void *v, void *cookie)
|
||||||
{
|
{
|
||||||
struct inteldrm_softc *dev_priv = v;
|
struct inteldrm_softc *dev_priv = v;
|
||||||
struct rasops_info *ri = &dev_priv->ro;
|
struct rasops_info *ri = &dev_priv->ro;
|
||||||
struct drm_device *dev = &dev_priv->drm;
|
|
||||||
|
|
||||||
if (cookie == ri->ri_active)
|
if (cookie == ri->ri_active)
|
||||||
return;
|
return;
|
||||||
|
@ -2252,11 +2250,9 @@ inteldrm_attach(struct device *parent, struct device *self, void *aux)
|
||||||
struct drm_device *dev;
|
struct drm_device *dev;
|
||||||
struct pci_attach_args *pa = aux;
|
struct pci_attach_args *pa = aux;
|
||||||
const struct pci_device_id *id;
|
const struct pci_device_id *id;
|
||||||
struct intel_device_info *info, *device_info;
|
struct intel_device_info *info;
|
||||||
struct intel_runtime_info *runtime;
|
|
||||||
extern int vga_console_attached;
|
extern int vga_console_attached;
|
||||||
int mmio_bar, mmio_size, mmio_type;
|
int mmio_bar, mmio_size, mmio_type;
|
||||||
int ret;
|
|
||||||
|
|
||||||
dev_priv->pa = pa;
|
dev_priv->pa = pa;
|
||||||
dev_priv->pc = pa->pa_pc;
|
dev_priv->pc = pa->pa_pc;
|
||||||
|
@ -2309,8 +2305,10 @@ inteldrm_attach(struct device *parent, struct device *self, void *aux)
|
||||||
|
|
||||||
/* uc_expand_default_options() with no GuC submission */
|
/* uc_expand_default_options() with no GuC submission */
|
||||||
if (GRAPHICS_VER(dev_priv) >= 12 &&
|
if (GRAPHICS_VER(dev_priv) >= 12 &&
|
||||||
!IS_TIGERLAKE(dev_priv) && !IS_ROCKETLAKE(dev_priv) &&
|
(INTEL_INFO(dev_priv)->platform != INTEL_TIGERLAKE) &&
|
||||||
!IS_XEHPSDV(dev_priv) && !IS_PONTEVECCHIO(dev_priv))
|
(INTEL_INFO(dev_priv)->platform != INTEL_ROCKETLAKE) &&
|
||||||
|
(INTEL_INFO(dev_priv)->platform != INTEL_XEHPSDV) &&
|
||||||
|
(INTEL_INFO(dev_priv)->platform != INTEL_PONTEVECCHIO))
|
||||||
dev_priv->params.enable_guc = ENABLE_GUC_LOAD_HUC;
|
dev_priv->params.enable_guc = ENABLE_GUC_LOAD_HUC;
|
||||||
|
|
||||||
mmio_bar = (GRAPHICS_VER(dev_priv) == 2) ? 0x14 : 0x10;
|
mmio_bar = (GRAPHICS_VER(dev_priv) == 2) ? 0x14 : 0x10;
|
||||||
|
@ -2394,8 +2392,10 @@ inteldrm_attach(struct device *parent, struct device *self, void *aux)
|
||||||
void
|
void
|
||||||
inteldrm_forcedetach(struct inteldrm_softc *dev_priv)
|
inteldrm_forcedetach(struct inteldrm_softc *dev_priv)
|
||||||
{
|
{
|
||||||
|
#ifdef notyet
|
||||||
struct pci_softc *psc = (struct pci_softc *)dev_priv->sc_dev.dv_parent;
|
struct pci_softc *psc = (struct pci_softc *)dev_priv->sc_dev.dv_parent;
|
||||||
pcitag_t tag = dev_priv->tag;
|
pcitag_t tag = dev_priv->tag;
|
||||||
|
#endif
|
||||||
extern int vga_console_attached;
|
extern int vga_console_attached;
|
||||||
|
|
||||||
if (dev_priv->primary) {
|
if (dev_priv->primary) {
|
||||||
|
@ -2420,7 +2420,6 @@ inteldrm_attachhook(struct device *self)
|
||||||
struct rasops_info *ri = &dev_priv->ro;
|
struct rasops_info *ri = &dev_priv->ro;
|
||||||
struct wsemuldisplaydev_attach_args aa;
|
struct wsemuldisplaydev_attach_args aa;
|
||||||
const struct pci_device_id *id = dev_priv->id;
|
const struct pci_device_id *id = dev_priv->id;
|
||||||
struct drm_device *dev = &dev_priv->drm;
|
|
||||||
int orientation_quirk;
|
int orientation_quirk;
|
||||||
|
|
||||||
if (inteldrm_refcnt == 0) {
|
if (inteldrm_refcnt == 0) {
|
||||||
|
@ -2629,7 +2628,6 @@ inteldrm_firmware_backlight(struct inteldrm_softc *dev_priv,
|
||||||
void
|
void
|
||||||
inteldrm_init_backlight(struct inteldrm_softc *dev_priv)
|
inteldrm_init_backlight(struct inteldrm_softc *dev_priv)
|
||||||
{
|
{
|
||||||
struct drm_device *dev = &dev_priv->drm;
|
|
||||||
struct wsdisplay_param dp;
|
struct wsdisplay_param dp;
|
||||||
|
|
||||||
dp.param = WSDISPLAYIO_PARAM_BRIGHTNESS;
|
dp.param = WSDISPLAYIO_PARAM_BRIGHTNESS;
|
||||||
|
|
|
@ -10,6 +10,7 @@
|
||||||
struct resource {
|
struct resource {
|
||||||
u_long start;
|
u_long start;
|
||||||
u_long end;
|
u_long end;
|
||||||
|
const char *name;
|
||||||
};
|
};
|
||||||
|
|
||||||
static inline resource_size_t
|
static inline resource_size_t
|
||||||
|
@ -22,6 +23,7 @@ resource_size(const struct resource *r)
|
||||||
(struct resource) { \
|
(struct resource) { \
|
||||||
.start = (_start), \
|
.start = (_start), \
|
||||||
.end = (_start) + (_size) - 1, \
|
.end = (_start) + (_size) - 1, \
|
||||||
|
.name = NULL, \
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: if_igc.c,v 1.26 2024/08/08 14:58:49 jan Exp $ */
|
/* $OpenBSD: if_igc.c,v 1.27 2024/08/11 01:02:10 dlg Exp $ */
|
||||||
/*-
|
/*-
|
||||||
* SPDX-License-Identifier: BSD-2-Clause
|
* SPDX-License-Identifier: BSD-2-Clause
|
||||||
*
|
*
|
||||||
|
@ -202,6 +202,7 @@ igc_attach(struct device *parent, struct device *self, void *aux)
|
||||||
/* Determine hardware and mac info */
|
/* Determine hardware and mac info */
|
||||||
igc_identify_hardware(sc);
|
igc_identify_hardware(sc);
|
||||||
|
|
||||||
|
sc->rx_mbuf_sz = MCLBYTES;
|
||||||
sc->num_tx_desc = IGC_DEFAULT_TXD;
|
sc->num_tx_desc = IGC_DEFAULT_TXD;
|
||||||
sc->num_rx_desc = IGC_DEFAULT_RXD;
|
sc->num_rx_desc = IGC_DEFAULT_RXD;
|
||||||
|
|
||||||
|
@ -881,7 +882,6 @@ igc_init(void *arg)
|
||||||
}
|
}
|
||||||
igc_initialize_transmit_unit(sc);
|
igc_initialize_transmit_unit(sc);
|
||||||
|
|
||||||
sc->rx_mbuf_sz = MCLBYTES;
|
|
||||||
/* Prepare receive descriptors and buffers. */
|
/* Prepare receive descriptors and buffers. */
|
||||||
if (igc_setup_receive_structures(sc)) {
|
if (igc_setup_receive_structures(sc)) {
|
||||||
printf("%s: Could not setup receive structures\n",
|
printf("%s: Could not setup receive structures\n",
|
||||||
|
@ -1232,7 +1232,7 @@ igc_rxrinfo(struct igc_softc *sc, struct if_rxrinfo *ifri)
|
||||||
|
|
||||||
for (i = 0; i < sc->sc_nqueues; i++) {
|
for (i = 0; i < sc->sc_nqueues; i++) {
|
||||||
rxr = &sc->rx_rings[i];
|
rxr = &sc->rx_rings[i];
|
||||||
ifr[n].ifr_size = MCLBYTES;
|
ifr[n].ifr_size = sc->rx_mbuf_sz;
|
||||||
snprintf(ifr[n].ifr_name, sizeof(ifr[n].ifr_name), "%d", i);
|
snprintf(ifr[n].ifr_name, sizeof(ifr[n].ifr_name), "%d", i);
|
||||||
ifr[n].ifr_info = rxr->rx_ring;
|
ifr[n].ifr_info = rxr->rx_ring;
|
||||||
n++;
|
n++;
|
||||||
|
@ -1673,11 +1673,11 @@ igc_get_buf(struct igc_rxring *rxr, int i)
|
||||||
return ENOBUFS;
|
return ENOBUFS;
|
||||||
}
|
}
|
||||||
|
|
||||||
m = MCLGETL(NULL, M_DONTWAIT, sc->rx_mbuf_sz);
|
m = MCLGETL(NULL, M_DONTWAIT, sc->rx_mbuf_sz + ETHER_ALIGN);
|
||||||
if (!m)
|
if (!m)
|
||||||
return ENOBUFS;
|
return ENOBUFS;
|
||||||
|
|
||||||
m->m_data += (m->m_ext.ext_size - sc->rx_mbuf_sz);
|
m->m_data += ETHER_ALIGN;
|
||||||
m->m_len = m->m_pkthdr.len = sc->rx_mbuf_sz;
|
m->m_len = m->m_pkthdr.len = sc->rx_mbuf_sz;
|
||||||
|
|
||||||
error = bus_dmamap_load_mbuf(rxr->rxdma.dma_tag, rxbuf->map, m,
|
error = bus_dmamap_load_mbuf(rxr->rxdma.dma_tag, rxbuf->map, m,
|
||||||
|
@ -2159,7 +2159,7 @@ igc_allocate_receive_buffers(struct igc_rxring *rxr)
|
||||||
rxbuf = rxr->rx_buffers;
|
rxbuf = rxr->rx_buffers;
|
||||||
for (i = 0; i < sc->num_rx_desc; i++, rxbuf++) {
|
for (i = 0; i < sc->num_rx_desc; i++, rxbuf++) {
|
||||||
error = bus_dmamap_create(rxr->rxdma.dma_tag,
|
error = bus_dmamap_create(rxr->rxdma.dma_tag,
|
||||||
MAX_JUMBO_FRAME_SIZE, IGC_MAX_SCATTER, MCLBYTES, 0,
|
sc->rx_mbuf_sz, 1, sc->rx_mbuf_sz, 0,
|
||||||
BUS_DMA_NOWAIT, &rxbuf->map);
|
BUS_DMA_NOWAIT, &rxbuf->map);
|
||||||
if (error) {
|
if (error) {
|
||||||
printf("%s: Unable to create RX DMA map\n",
|
printf("%s: Unable to create RX DMA map\n",
|
||||||
|
@ -2223,7 +2223,8 @@ igc_setup_receive_ring(struct igc_rxring *rxr)
|
||||||
rxr->next_to_check = 0;
|
rxr->next_to_check = 0;
|
||||||
rxr->last_desc_filled = sc->num_rx_desc - 1;
|
rxr->last_desc_filled = sc->num_rx_desc - 1;
|
||||||
|
|
||||||
if_rxr_init(&rxr->rx_ring, 2 * ((ifp->if_hardmtu / MCLBYTES) + 1),
|
if_rxr_init(&rxr->rx_ring,
|
||||||
|
2 * howmany(ifp->if_hardmtu, sc->rx_mbuf_sz) + 1,
|
||||||
sc->num_rx_desc - 1);
|
sc->num_rx_desc - 1);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: kern_exit.c,v 1.230 2024/08/06 18:41:20 claudio Exp $ */
|
/* $OpenBSD: kern_exit.c,v 1.231 2024/08/11 15:10:53 mvs Exp $ */
|
||||||
/* $NetBSD: kern_exit.c,v 1.39 1996/04/22 01:38:25 christos Exp $ */
|
/* $NetBSD: kern_exit.c,v 1.39 1996/04/22 01:38:25 christos Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -151,6 +151,9 @@ exit1(struct proc *p, int xexit, int xsig, int flags)
|
||||||
PS_ISPWAIT);
|
PS_ISPWAIT);
|
||||||
wakeup(pr->ps_pptr);
|
wakeup(pr->ps_pptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Wait for concurrent `allprocess' loops */
|
||||||
|
refcnt_finalize(&pr->ps_refcnt, "psdtor");
|
||||||
}
|
}
|
||||||
|
|
||||||
/* unlink ourselves from the active threads */
|
/* unlink ourselves from the active threads */
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: kern_fork.c,v 1.261 2024/08/06 08:44:54 claudio Exp $ */
|
/* $OpenBSD: kern_fork.c,v 1.262 2024/08/11 15:10:53 mvs Exp $ */
|
||||||
/* $NetBSD: kern_fork.c,v 1.29 1996/02/09 18:59:34 christos Exp $ */
|
/* $NetBSD: kern_fork.c,v 1.29 1996/02/09 18:59:34 christos Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -178,6 +178,8 @@ thread_new(struct proc *parent, vaddr_t uaddr)
|
||||||
void
|
void
|
||||||
process_initialize(struct process *pr, struct proc *p)
|
process_initialize(struct process *pr, struct proc *p)
|
||||||
{
|
{
|
||||||
|
refcnt_init(&pr->ps_refcnt);
|
||||||
|
|
||||||
/* initialize the thread links */
|
/* initialize the thread links */
|
||||||
pr->ps_mainproc = p;
|
pr->ps_mainproc = p;
|
||||||
TAILQ_INIT(&pr->ps_threads);
|
TAILQ_INIT(&pr->ps_threads);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: kern_sysctl.c,v 1.436 2024/08/08 15:02:36 bluhm Exp $ */
|
/* $OpenBSD: kern_sysctl.c,v 1.437 2024/08/11 15:10:53 mvs Exp $ */
|
||||||
/* $NetBSD: kern_sysctl.c,v 1.17 1996/05/20 17:49:05 mrg Exp $ */
|
/* $NetBSD: kern_sysctl.c,v 1.17 1996/05/20 17:49:05 mrg Exp $ */
|
||||||
|
|
||||||
/*-
|
/*-
|
||||||
|
@ -1686,6 +1686,9 @@ sysctl_file(int *name, u_int namelen, char *where, size_t *sizep,
|
||||||
/* not the pid we are looking for */
|
/* not the pid we are looking for */
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
refcnt_take(&pr->ps_refcnt);
|
||||||
|
|
||||||
matched = 1;
|
matched = 1;
|
||||||
fdp = pr->ps_fd;
|
fdp = pr->ps_fd;
|
||||||
if (pr->ps_textvp)
|
if (pr->ps_textvp)
|
||||||
|
@ -1702,6 +1705,9 @@ sysctl_file(int *name, u_int namelen, char *where, size_t *sizep,
|
||||||
FILLIT(fp, fdp, i, NULL, pr);
|
FILLIT(fp, fdp, i, NULL, pr);
|
||||||
FRELE(fp, p);
|
FRELE(fp, p);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
refcnt_rele_wake(&pr->ps_refcnt);
|
||||||
|
|
||||||
/* pid is unique, stop searching */
|
/* pid is unique, stop searching */
|
||||||
if (arg >= 0)
|
if (arg >= 0)
|
||||||
break;
|
break;
|
||||||
|
@ -1721,6 +1727,9 @@ sysctl_file(int *name, u_int namelen, char *where, size_t *sizep,
|
||||||
/* not the uid we are looking for */
|
/* not the uid we are looking for */
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
refcnt_take(&pr->ps_refcnt);
|
||||||
|
|
||||||
fdp = pr->ps_fd;
|
fdp = pr->ps_fd;
|
||||||
if (fdp->fd_cdir)
|
if (fdp->fd_cdir)
|
||||||
FILLIT(NULL, NULL, KERN_FILE_CDIR, fdp->fd_cdir, pr);
|
FILLIT(NULL, NULL, KERN_FILE_CDIR, fdp->fd_cdir, pr);
|
||||||
|
@ -1734,6 +1743,8 @@ sysctl_file(int *name, u_int namelen, char *where, size_t *sizep,
|
||||||
FILLIT(fp, fdp, i, NULL, pr);
|
FILLIT(fp, fdp, i, NULL, pr);
|
||||||
FRELE(fp, p);
|
FRELE(fp, p);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
refcnt_rele_wake(&pr->ps_refcnt);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: kern_timeout.c,v 1.98 2024/08/05 23:51:11 dlg Exp $ */
|
/* $OpenBSD: kern_timeout.c,v 1.99 2024/08/11 00:49:34 dlg Exp $ */
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2001 Thomas Nordin <nordin@openbsd.org>
|
* Copyright (c) 2001 Thomas Nordin <nordin@openbsd.org>
|
||||||
* Copyright (c) 2000-2001 Artur Grabowski <art@openbsd.org>
|
* Copyright (c) 2000-2001 Artur Grabowski <art@openbsd.org>
|
||||||
|
@ -332,18 +332,25 @@ timeout_add(struct timeout *new, int to_ticks)
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline int
|
||||||
|
timeout_add_ticks(struct timeout *to, uint64_t to_ticks, int notzero)
|
||||||
|
{
|
||||||
|
if (to_ticks > INT_MAX)
|
||||||
|
to_ticks = INT_MAX;
|
||||||
|
else if (to_ticks == 0 && notzero)
|
||||||
|
to_ticks = 1;
|
||||||
|
|
||||||
|
return timeout_add(to, (int)to_ticks);
|
||||||
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
timeout_add_tv(struct timeout *to, const struct timeval *tv)
|
timeout_add_tv(struct timeout *to, const struct timeval *tv)
|
||||||
{
|
{
|
||||||
uint64_t to_ticks;
|
uint64_t to_ticks;
|
||||||
|
|
||||||
to_ticks = (uint64_t)hz * tv->tv_sec + tv->tv_usec / tick;
|
to_ticks = (uint64_t)hz * tv->tv_sec + tv->tv_usec / tick;
|
||||||
if (to_ticks > INT_MAX)
|
|
||||||
to_ticks = INT_MAX;
|
|
||||||
if (to_ticks == 0 && tv->tv_usec > 0)
|
|
||||||
to_ticks = 1;
|
|
||||||
|
|
||||||
return timeout_add(to, (int)to_ticks);
|
return timeout_add_ticks(to, to_ticks, tv->tv_usec > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
|
@ -352,37 +359,28 @@ timeout_add_sec(struct timeout *to, int secs)
|
||||||
uint64_t to_ticks;
|
uint64_t to_ticks;
|
||||||
|
|
||||||
to_ticks = (uint64_t)hz * secs;
|
to_ticks = (uint64_t)hz * secs;
|
||||||
if (to_ticks > INT_MAX)
|
|
||||||
to_ticks = INT_MAX;
|
|
||||||
if (to_ticks == 0)
|
|
||||||
to_ticks = 1;
|
|
||||||
|
|
||||||
return timeout_add(to, (int)to_ticks);
|
return timeout_add_ticks(to, to_ticks, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
timeout_add_msec(struct timeout *to, int msecs)
|
timeout_add_msec(struct timeout *to, uint64_t msecs)
|
||||||
{
|
{
|
||||||
uint64_t to_ticks;
|
uint64_t to_ticks;
|
||||||
|
|
||||||
to_ticks = (uint64_t)msecs * 1000 / tick;
|
to_ticks = msecs * 1000 / tick;
|
||||||
if (to_ticks > INT_MAX)
|
|
||||||
to_ticks = INT_MAX;
|
|
||||||
if (to_ticks == 0 && msecs > 0)
|
|
||||||
to_ticks = 1;
|
|
||||||
|
|
||||||
return timeout_add(to, (int)to_ticks);
|
return timeout_add_ticks(to, to_ticks, msecs > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
timeout_add_usec(struct timeout *to, int usecs)
|
timeout_add_usec(struct timeout *to, uint64_t usecs)
|
||||||
{
|
{
|
||||||
int to_ticks = usecs / tick;
|
uint64_t to_ticks;
|
||||||
|
|
||||||
if (to_ticks == 0 && usecs > 0)
|
to_ticks = usecs / tick;
|
||||||
to_ticks = 1;
|
|
||||||
|
|
||||||
return timeout_add(to, to_ticks);
|
return timeout_add_ticks(to, to_ticks, usecs > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
|
@ -391,12 +389,8 @@ timeout_add_nsec(struct timeout *to, uint64_t nsecs)
|
||||||
uint64_t to_ticks;
|
uint64_t to_ticks;
|
||||||
|
|
||||||
to_ticks = nsecs / (tick * 1000);
|
to_ticks = nsecs / (tick * 1000);
|
||||||
if (to_ticks > INT_MAX)
|
|
||||||
to_ticks = INT_MAX;
|
|
||||||
if (to_ticks == 0 && nsecs > 0)
|
|
||||||
to_ticks = 1;
|
|
||||||
|
|
||||||
return timeout_add(to, (int)to_ticks);
|
return timeout_add_ticks(to, to_ticks, nsecs > 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: uipc_socket.c,v 1.342 2024/08/06 20:14:56 mvs Exp $ */
|
/* $OpenBSD: uipc_socket.c,v 1.343 2024/08/11 00:19:00 jsg Exp $ */
|
||||||
/* $NetBSD: uipc_socket.c,v 1.21 1996/02/04 02:17:52 christos Exp $ */
|
/* $NetBSD: uipc_socket.c,v 1.21 1996/02/04 02:17:52 christos Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1581,7 +1581,7 @@ sotask(void *arg)
|
||||||
int sockstream = (so->so_proto->pr_flags & PR_WANTRCVD);
|
int sockstream = (so->so_proto->pr_flags & PR_WANTRCVD);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* sblock() on `so_rcv' protects sockets from beind unspliced
|
* sblock() on `so_rcv' protects sockets from being unspliced
|
||||||
* for UDP case. TCP sockets still rely on solock().
|
* for UDP case. TCP sockets still rely on solock().
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: proc.h,v 1.367 2024/08/06 08:44:54 claudio Exp $ */
|
/* $OpenBSD: proc.h,v 1.369 2024/08/11 21:07:05 mvs Exp $ */
|
||||||
/* $NetBSD: proc.h,v 1.44 1996/04/22 01:23:21 christos Exp $ */
|
/* $NetBSD: proc.h,v 1.44 1996/04/22 01:23:21 christos Exp $ */
|
||||||
|
|
||||||
/*-
|
/*-
|
||||||
|
@ -50,6 +50,7 @@
|
||||||
#include <sys/resource.h> /* For struct rusage */
|
#include <sys/resource.h> /* For struct rusage */
|
||||||
#include <sys/rwlock.h> /* For struct rwlock */
|
#include <sys/rwlock.h> /* For struct rwlock */
|
||||||
#include <sys/sigio.h> /* For struct sigio */
|
#include <sys/sigio.h> /* For struct sigio */
|
||||||
|
#include <sys/refcnt.h> /* For struct refcnt */
|
||||||
|
|
||||||
#ifdef _KERNEL
|
#ifdef _KERNEL
|
||||||
#include <sys/atomic.h>
|
#include <sys/atomic.h>
|
||||||
|
@ -142,6 +143,8 @@ struct pinsyscall {
|
||||||
* T itimer_mtx
|
* T itimer_mtx
|
||||||
*/
|
*/
|
||||||
struct process {
|
struct process {
|
||||||
|
struct refcnt ps_refcnt;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ps_mainproc is the original thread in the process.
|
* ps_mainproc is the original thread in the process.
|
||||||
* It's only still special for the handling of
|
* It's only still special for the handling of
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: timeout.h,v 1.49 2024/08/05 23:51:11 dlg Exp $ */
|
/* $OpenBSD: timeout.h,v 1.50 2024/08/11 00:49:34 dlg Exp $ */
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2000-2001 Artur Grabowski <art@openbsd.org>
|
* Copyright (c) 2000-2001 Artur Grabowski <art@openbsd.org>
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
|
@ -108,8 +108,8 @@ void timeout_set_proc(struct timeout *, void (*)(void *), void *);
|
||||||
int timeout_add(struct timeout *, int);
|
int timeout_add(struct timeout *, int);
|
||||||
int timeout_add_tv(struct timeout *, const struct timeval *);
|
int timeout_add_tv(struct timeout *, const struct timeval *);
|
||||||
int timeout_add_sec(struct timeout *, int);
|
int timeout_add_sec(struct timeout *, int);
|
||||||
int timeout_add_msec(struct timeout *, int);
|
int timeout_add_msec(struct timeout *, uint64_t);
|
||||||
int timeout_add_usec(struct timeout *, int);
|
int timeout_add_usec(struct timeout *, uint64_t);
|
||||||
int timeout_add_nsec(struct timeout *, uint64_t);
|
int timeout_add_nsec(struct timeout *, uint64_t);
|
||||||
|
|
||||||
int timeout_abs_ts(struct timeout *, const struct timespec *);
|
int timeout_abs_ts(struct timeout *, const struct timespec *);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
.\" $OpenBSD: awk.1,v 1.69 2024/07/30 13:55:11 jmc Exp $
|
.\" $OpenBSD: awk.1,v 1.70 2024/08/11 18:24:43 schwarze Exp $
|
||||||
.\"
|
.\"
|
||||||
.\" Copyright (C) Lucent Technologies 1997
|
.\" Copyright (C) Lucent Technologies 1997
|
||||||
.\" All Rights Reserved
|
.\" All Rights Reserved
|
||||||
|
@ -22,7 +22,7 @@
|
||||||
.\" ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
|
.\" ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
|
||||||
.\" THIS SOFTWARE.
|
.\" THIS SOFTWARE.
|
||||||
.\"
|
.\"
|
||||||
.Dd $Mdocdate: July 30 2024 $
|
.Dd $Mdocdate: August 11 2024 $
|
||||||
.Dt AWK 1
|
.Dt AWK 1
|
||||||
.Os
|
.Os
|
||||||
.Sh NAME
|
.Sh NAME
|
||||||
|
@ -1041,11 +1041,6 @@ and
|
||||||
.Fn srand
|
.Fn srand
|
||||||
has been changed to support non-deterministic random numbers.
|
has been changed to support non-deterministic random numbers.
|
||||||
.Pp
|
.Pp
|
||||||
In
|
|
||||||
.Ev LC_CTYPE Ns Li =POSIX
|
|
||||||
mode, treating non-ASCII input bytes as non-letter characters rather
|
|
||||||
than as input encoding errors intentionally violates the specification.
|
|
||||||
.Pp
|
|
||||||
The flags
|
The flags
|
||||||
.Op Fl \&dV ,
|
.Op Fl \&dV ,
|
||||||
.Op Fl -csv ,
|
.Op Fl -csv ,
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
/* $OpenBSD: rpcinfo.c,v 1.16 2023/03/08 04:43:12 guenther Exp $ */
|
/* $OpenBSD: rpcinfo.c,v 1.17 2024/08/11 11:56:08 florian Exp $ */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2010, Oracle America, Inc.
|
* Copyright (c) 2010, Oracle America, Inc.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue