CVS commit: src/sys/miscfs/procfs
Module Name:src Committed By: christos Date: Mon Jan 10 23:16:05 UTC 2022 Modified Files: src/sys/miscfs/procfs: procfs_vnops.c Log Message: use a single nc variable. To generate a diff of this commit: cvs rdiff -u -r1.221 -r1.222 src/sys/miscfs/procfs/procfs_vnops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/miscfs/procfs/procfs_vnops.c diff -u src/sys/miscfs/procfs/procfs_vnops.c:1.221 src/sys/miscfs/procfs/procfs_vnops.c:1.222 --- src/sys/miscfs/procfs/procfs_vnops.c:1.221 Mon Jan 10 17:26:14 2022 +++ src/sys/miscfs/procfs/procfs_vnops.c Mon Jan 10 18:16:05 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: procfs_vnops.c,v 1.221 2022/01/10 22:26:14 christos Exp $ */ +/* $NetBSD: procfs_vnops.c,v 1.222 2022/01/10 23:16:05 christos Exp $ */ /*- * Copyright (c) 2006, 2007, 2008, 2020 The NetBSD Foundation, Inc. @@ -105,7 +105,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: procfs_vnops.c,v 1.221 2022/01/10 22:26:14 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: procfs_vnops.c,v 1.222 2022/01/10 23:16:05 christos Exp $"); #include #include @@ -1289,6 +1289,7 @@ procfs_readdir(void *v) struct procfs_root_readdir_ctx ctx; struct lwp *l; int nfd; + int nc = 0; vp = ap->a_vp; pfs = VTOPFS(vp); @@ -1356,7 +1357,7 @@ procfs_readdir(void *v) case PFSfd: { struct proc *p; file_t *fp; - int lim, nc = 0; + int lim; if ((error = procfs_proc_lock(vp->v_mount, pfs->pfs_pid, , ESRCH)) != 0) @@ -1421,7 +1422,6 @@ procfs_readdir(void *v) } case PFStask: { struct proc *p; - int nc = 0; if ((error = procfs_proc_lock(vp->v_mount, pfs->pfs_pid, , ESRCH)) != 0) @@ -1476,7 +1476,6 @@ procfs_readdir(void *v) case PFSroot: { struct proc *p; - int nc = 0; if (ap->a_ncookies) { /*
CVS commit: src/sys/miscfs/procfs
Module Name:src Committed By: christos Date: Mon Jan 10 23:16:05 UTC 2022 Modified Files: src/sys/miscfs/procfs: procfs_vnops.c Log Message: use a single nc variable. To generate a diff of this commit: cvs rdiff -u -r1.221 -r1.222 src/sys/miscfs/procfs/procfs_vnops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/miscfs/procfs
Module Name:src Committed By: christos Date: Mon Jan 10 22:26:14 UTC 2022 Modified Files: src/sys/miscfs/procfs: procfs_vnops.c Log Message: Fix locking in the error path (from RVP). Centralize unlock code. To generate a diff of this commit: cvs rdiff -u -r1.220 -r1.221 src/sys/miscfs/procfs/procfs_vnops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/miscfs/procfs/procfs_vnops.c diff -u src/sys/miscfs/procfs/procfs_vnops.c:1.220 src/sys/miscfs/procfs/procfs_vnops.c:1.221 --- src/sys/miscfs/procfs/procfs_vnops.c:1.220 Wed Dec 8 15:11:54 2021 +++ src/sys/miscfs/procfs/procfs_vnops.c Mon Jan 10 17:26:14 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: procfs_vnops.c,v 1.220 2021/12/08 20:11:54 andvar Exp $ */ +/* $NetBSD: procfs_vnops.c,v 1.221 2022/01/10 22:26:14 christos Exp $ */ /*- * Copyright (c) 2006, 2007, 2008, 2020 The NetBSD Foundation, Inc. @@ -105,7 +105,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: procfs_vnops.c,v 1.220 2021/12/08 20:11:54 andvar Exp $"); +__KERNEL_RCSID(0, "$NetBSD: procfs_vnops.c,v 1.221 2022/01/10 22:26:14 christos Exp $"); #include #include @@ -1399,10 +1399,8 @@ procfs_readdir(void *v) *cookies++ = i + 1; nc++; } - if (error) { - ncookies = nc; - break; - } + if (error) + goto out; for (; uio->uio_resid >= UIO_MX && i < nfd; i++) { /* check the descriptor exists */ if ((fp = fd_getfile2(p, i - 2)) == NULL) @@ -1419,9 +1417,7 @@ procfs_readdir(void *v) *cookies++ = i + 1; nc++; } - ncookies = nc; - procfs_proc_unlock(p); - break; + goto out; } case PFStask: { struct proc *p; @@ -1453,10 +1449,8 @@ procfs_readdir(void *v) *cookies++ = i + 1; nc++; } - if (error) { - ncookies = nc; - break; - } + if (error) + goto out; for (; uio->uio_resid >= UIO_MX && i < nfd; i++) { /* check the descriptor exists */ d.d_fileno = PROCFS_FILENO(pfs->pfs_pid, PFStask, @@ -1470,9 +1464,7 @@ procfs_readdir(void *v) *cookies++ = i + 1; nc++; } - ncookies = nc; - procfs_proc_unlock(p); - break; + goto out; } /* @@ -1575,7 +1567,7 @@ procfs_readdir(void *v) if (cookies) *cookies++ = i + 1; } - +out: ncookies = nc; procfs_proc_unlock(p); break;
CVS commit: src/sys/miscfs/procfs
Module Name:src Committed By: christos Date: Mon Jan 10 22:26:14 UTC 2022 Modified Files: src/sys/miscfs/procfs: procfs_vnops.c Log Message: Fix locking in the error path (from RVP). Centralize unlock code. To generate a diff of this commit: cvs rdiff -u -r1.220 -r1.221 src/sys/miscfs/procfs/procfs_vnops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/usr.sbin/sysinst
Module Name:src Committed By: nia Date: Mon Jan 10 22:14:01 UTC 2022 Modified Files: src/usr.sbin/sysinst: net.c Log Message: sysinst(8): Avoid asking Wi-Fi questions about non-Wi-Fi devices. To generate a diff of this commit: cvs rdiff -u -r1.37 -r1.38 src/usr.sbin/sysinst/net.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/sysinst/net.c diff -u src/usr.sbin/sysinst/net.c:1.37 src/usr.sbin/sysinst/net.c:1.38 --- src/usr.sbin/sysinst/net.c:1.37 Mon Jan 10 12:17:48 2022 +++ src/usr.sbin/sysinst/net.c Mon Jan 10 22:14:01 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: net.c,v 1.37 2022/01/10 12:17:48 nia Exp $ */ +/* $NetBSD: net.c,v 1.38 2022/01/10 22:14:01 nia Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -47,6 +47,7 @@ #include #include #include +#include #include #include @@ -1137,6 +1138,23 @@ config_wlan(char *inter) { FILE *wpa_conf = NULL; char wpa_cmd[256]; + int sock; + struct ifreq ifr = {0}; + struct ieee80211_nwid nwid = {0}; + + strlcpy(ifr.ifr_name, inter, sizeof(ifr.ifr_name)); + ifr.ifr_data = + + sock = socket(PF_INET, SOCK_DGRAM, 0); + if (sock == -1) + return 0; + + /* skip non-WLAN devices */ + if (ioctl(sock, SIOCG80211NWID, ) == -1) { + close(sock); + return 0; + } + close(sock); if (!file_mode_match(WPA_SUPPLICANT, S_IFREG)) return 0;
CVS commit: src/usr.sbin/sysinst
Module Name:src Committed By: nia Date: Mon Jan 10 22:14:01 UTC 2022 Modified Files: src/usr.sbin/sysinst: net.c Log Message: sysinst(8): Avoid asking Wi-Fi questions about non-Wi-Fi devices. To generate a diff of this commit: cvs rdiff -u -r1.37 -r1.38 src/usr.sbin/sysinst/net.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/usr.bin/make
Module Name:src Committed By: rillig Date: Mon Jan 10 20:32:29 UTC 2022 Modified Files: src/usr.bin/make: main.c src/usr.bin/make/unit-tests: directive-export-impl.exp var-op-shell.exp var-op-shell.mk varmod-assign-shell.exp varmod-assign-shell.mk varmod-shell.exp varmod-shell.mk varmod-sun-shell.exp varmod-sun-shell.mk varname-empty.exp Log Message: make: add debug logging for capturing the output of external commands This applies to all 4 situations in which the output of an external command is used for modifying a variable or an expression: * the assignment operator '!=' * the assignment modifier '::!=' * the SUN shell modifier ':sh' * the other shell modifier ':!cmd!' Previously, only the shell modifier ':!cmd!' had debug logging. Suggested by Christoph Badura. To generate a diff of this commit: cvs rdiff -u -r1.568 -r1.569 src/usr.bin/make/main.c cvs rdiff -u -r1.15 -r1.16 \ src/usr.bin/make/unit-tests/directive-export-impl.exp cvs rdiff -u -r1.4 -r1.5 src/usr.bin/make/unit-tests/var-op-shell.exp cvs rdiff -u -r1.5 -r1.6 src/usr.bin/make/unit-tests/var-op-shell.mk cvs rdiff -u -r1.2 -r1.3 src/usr.bin/make/unit-tests/varmod-assign-shell.exp cvs rdiff -u -r1.3 -r1.4 src/usr.bin/make/unit-tests/varmod-assign-shell.mk \ src/usr.bin/make/unit-tests/varmod-shell.exp cvs rdiff -u -r1.6 -r1.7 src/usr.bin/make/unit-tests/varmod-shell.mk cvs rdiff -u -r1.1 -r1.2 src/usr.bin/make/unit-tests/varmod-sun-shell.exp \ src/usr.bin/make/unit-tests/varmod-sun-shell.mk cvs rdiff -u -r1.17 -r1.18 src/usr.bin/make/unit-tests/varname-empty.exp Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.bin/make/main.c diff -u src/usr.bin/make/main.c:1.568 src/usr.bin/make/main.c:1.569 --- src/usr.bin/make/main.c:1.568 Sun Jan 9 18:49:28 2022 +++ src/usr.bin/make/main.c Mon Jan 10 20:32:28 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: main.c,v 1.568 2022/01/09 18:49:28 rillig Exp $ */ +/* $NetBSD: main.c,v 1.569 2022/01/10 20:32:28 rillig Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1993 @@ -111,7 +111,7 @@ #include "trace.h" /* "@(#)main.c 8.3 (Berkeley) 3/19/94" */ -MAKE_RCSID("$NetBSD: main.c,v 1.568 2022/01/09 18:49:28 rillig Exp $"); +MAKE_RCSID("$NetBSD: main.c,v 1.569 2022/01/10 20:32:28 rillig Exp $"); #if defined(MAKE_NATIVE) && !defined(lint) __COPYRIGHT("@(#) Copyright (c) 1988, 1989, 1990, 1993 " "The Regents of the University of California. " @@ -1720,6 +1720,7 @@ Cmd_Exec(const char *cmd, char **error) args[1] = "-c"; args[2] = cmd; args[3] = NULL; + DEBUG1(VAR, "Capturing the output of command \"%s\"\n", cmd); if (pipe(pipefds) == -1) { *error = str_concat3( Index: src/usr.bin/make/unit-tests/directive-export-impl.exp diff -u src/usr.bin/make/unit-tests/directive-export-impl.exp:1.15 src/usr.bin/make/unit-tests/directive-export-impl.exp:1.16 --- src/usr.bin/make/unit-tests/directive-export-impl.exp:1.15 Tue Dec 28 15:49:00 2021 +++ src/usr.bin/make/unit-tests/directive-export-impl.exp Mon Jan 10 20:32:29 2022 @@ -14,6 +14,7 @@ CondParser_Eval: ${:!echo "\$UT_VAR"!} ! Var_Parse: ${:!echo "\$UT_VAR"!} != "<>" (eval-defined) Evaluating modifier ${:!...} on value "" (eval-defined, undefined) Modifier part: "echo "$UT_VAR"" +Capturing the output of command "echo "$UT_VAR"" Var_Parse: ${.MAKE.EXPORTED:O:u} (eval) Evaluating modifier ${.MAKE.EXPORTED:O} on value "UT_VAR" Result of ${.MAKE.EXPORTED:O} is "UT_VAR" @@ -37,6 +38,7 @@ CondParser_Eval: ${:!echo "\$UT_VAR"!} ! Var_Parse: ${:!echo "\$UT_VAR"!} != "" (eval-defined) Evaluating modifier ${:!...} on value "" (eval-defined, undefined) Modifier part: "echo "$UT_VAR"" +Capturing the output of command "echo "$UT_VAR"" Var_Parse: ${.MAKE.EXPORTED:O:u} (eval) Evaluating modifier ${.MAKE.EXPORTED:O} on value "UT_VAR" Result of ${.MAKE.EXPORTED:O} is "UT_VAR" Index: src/usr.bin/make/unit-tests/var-op-shell.exp diff -u src/usr.bin/make/unit-tests/var-op-shell.exp:1.4 src/usr.bin/make/unit-tests/var-op-shell.exp:1.5 --- src/usr.bin/make/unit-tests/var-op-shell.exp:1.4 Sun Jan 9 18:22:31 2022 +++ src/usr.bin/make/unit-tests/var-op-shell.exp Mon Jan 10 20:32:29 2022 @@ -4,4 +4,8 @@ make: "var-op-shell.mk" line 59: warning /bin/no/such/command: not found make: "var-op-shell.mk" line 65: warning: "/bin/no/such/command" returned non-zero status stderr +Capturing the output of command "echo ''" +Global: OUTPUT = +Global: .MAKEFLAGS = -r -k -d v -d +Global: .MAKEFLAGS = -r -k -d v -d 0 exit status 0 Index: src/usr.bin/make/unit-tests/var-op-shell.mk diff -u src/usr.bin/make/unit-tests/var-op-shell.mk:1.5 src/usr.bin/make/unit-tests/var-op-shell.mk:1.6 --- src/usr.bin/make/unit-tests/var-op-shell.mk:1.5 Sun Jan 9 18:22:31 2022 +++ src/usr.bin/make/unit-tests/var-op-shell.mk Mon Jan 10 20:32:29 2022 @@ -1,4 +1,4 @@ -# $NetBSD: var-op-shell.mk,v 1.5
CVS commit: src/usr.bin/make
Module Name:src Committed By: rillig Date: Mon Jan 10 20:32:29 UTC 2022 Modified Files: src/usr.bin/make: main.c src/usr.bin/make/unit-tests: directive-export-impl.exp var-op-shell.exp var-op-shell.mk varmod-assign-shell.exp varmod-assign-shell.mk varmod-shell.exp varmod-shell.mk varmod-sun-shell.exp varmod-sun-shell.mk varname-empty.exp Log Message: make: add debug logging for capturing the output of external commands This applies to all 4 situations in which the output of an external command is used for modifying a variable or an expression: * the assignment operator '!=' * the assignment modifier '::!=' * the SUN shell modifier ':sh' * the other shell modifier ':!cmd!' Previously, only the shell modifier ':!cmd!' had debug logging. Suggested by Christoph Badura. To generate a diff of this commit: cvs rdiff -u -r1.568 -r1.569 src/usr.bin/make/main.c cvs rdiff -u -r1.15 -r1.16 \ src/usr.bin/make/unit-tests/directive-export-impl.exp cvs rdiff -u -r1.4 -r1.5 src/usr.bin/make/unit-tests/var-op-shell.exp cvs rdiff -u -r1.5 -r1.6 src/usr.bin/make/unit-tests/var-op-shell.mk cvs rdiff -u -r1.2 -r1.3 src/usr.bin/make/unit-tests/varmod-assign-shell.exp cvs rdiff -u -r1.3 -r1.4 src/usr.bin/make/unit-tests/varmod-assign-shell.mk \ src/usr.bin/make/unit-tests/varmod-shell.exp cvs rdiff -u -r1.6 -r1.7 src/usr.bin/make/unit-tests/varmod-shell.mk cvs rdiff -u -r1.1 -r1.2 src/usr.bin/make/unit-tests/varmod-sun-shell.exp \ src/usr.bin/make/unit-tests/varmod-sun-shell.mk cvs rdiff -u -r1.17 -r1.18 src/usr.bin/make/unit-tests/varname-empty.exp Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/arch/sparc64
Module Name:src Committed By: palle Date: Mon Jan 10 20:14:54 UTC 2022 Modified Files: src/sys/arch/sparc64/include: sparc64.h src/sys/arch/sparc64/sparc64: ofw_machdep.c Log Message: sun4v: add function to retrieve hypervisor api version To generate a diff of this commit: cvs rdiff -u -r1.14 -r1.15 src/sys/arch/sparc64/include/sparc64.h cvs rdiff -u -r1.47 -r1.48 src/sys/arch/sparc64/sparc64/ofw_machdep.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/sparc64/include/sparc64.h diff -u src/sys/arch/sparc64/include/sparc64.h:1.14 src/sys/arch/sparc64/include/sparc64.h:1.15 --- src/sys/arch/sparc64/include/sparc64.h:1.14 Sat Jul 3 19:18:55 2021 +++ src/sys/arch/sparc64/include/sparc64.h Mon Jan 10 20:14:54 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: sparc64.h,v 1.14 2021/07/03 19:18:55 palle Exp $ */ +/* $NetBSD: sparc64.h,v 1.15 2022/01/10 20:14:54 palle Exp $ */ /* * Copyright (C) 1996 Wolfgang Solfrank. @@ -60,6 +60,7 @@ bool prom_has_stop_other(void); void prom_startcpu(u_int, void *, u_long); int prom_startcpu_by_cpuid(u_int, void *, u_long arg); uint64_t prom_set_sun4v_api_version(uint64_t, uint64_t, uint64_t, uint64_t *); +uint64_t prom_get_sun4v_api_version(uint64_t, uint64_t *, uint64_t *); void prom_sun4v_soft_state_supported(void); #endif /* _MACHINE_SPARC64_H_ */ Index: src/sys/arch/sparc64/sparc64/ofw_machdep.c diff -u src/sys/arch/sparc64/sparc64/ofw_machdep.c:1.47 src/sys/arch/sparc64/sparc64/ofw_machdep.c:1.48 --- src/sys/arch/sparc64/sparc64/ofw_machdep.c:1.47 Sat Jul 3 19:18:55 2021 +++ src/sys/arch/sparc64/sparc64/ofw_machdep.c Mon Jan 10 20:14:54 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: ofw_machdep.c,v 1.47 2021/07/03 19:18:55 palle Exp $ */ +/* $NetBSD: ofw_machdep.c,v 1.48 2022/01/10 20:14:54 palle Exp $ */ /* * Copyright (C) 1996 Wolfgang Solfrank. @@ -34,7 +34,7 @@ #include "opt_multiprocessor.h" #include -__KERNEL_RCSID(0, "$NetBSD: ofw_machdep.c,v 1.47 2021/07/03 19:18:55 palle Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ofw_machdep.c,v 1.48 2022/01/10 20:14:54 palle Exp $"); #include #include @@ -676,7 +676,35 @@ prom_set_sun4v_api_version(uint64_t api_ *supported_minor = args.supported_minor; return (uint64_t)args.status; } +#if 1 +uint64_t +prom_get_sun4v_api_version(uint64_t api_group, uint64_t* major, uint64_t* minor) +{ + static struct { + cell_t name; + cell_t nargs; + cell_t nreturns; + cell_t api_group; + cell_t status; + cell_t major; + cell_t minor; + } args; + args.name = ADR2CELL("SUNW,get-sun4v-api-version"); + args.nargs = 1; + args.nreturns = 3; + args.api_group = api_group; + args.status = -1; + args.major = -1; + args.minor = -1; + + openfirmware(); + + *major = args.major; + *minor = args.minor; + return (uint64_t)args.status; +} +#endif void prom_sun4v_soft_state_supported(void) {
CVS commit: src/sys/arch/sparc64
Module Name:src Committed By: palle Date: Mon Jan 10 20:14:54 UTC 2022 Modified Files: src/sys/arch/sparc64/include: sparc64.h src/sys/arch/sparc64/sparc64: ofw_machdep.c Log Message: sun4v: add function to retrieve hypervisor api version To generate a diff of this commit: cvs rdiff -u -r1.14 -r1.15 src/sys/arch/sparc64/include/sparc64.h cvs rdiff -u -r1.47 -r1.48 src/sys/arch/sparc64/sparc64/ofw_machdep.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/lib/libkvm
Module Name:src Committed By: christos Date: Mon Jan 10 20:04:01 UTC 2022 Modified Files: src/lib/libkvm: kvm_proc.c Log Message: read the ps arguments from the correct place. To generate a diff of this commit: cvs rdiff -u -r1.96 -r1.97 src/lib/libkvm/kvm_proc.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libkvm/kvm_proc.c diff -u src/lib/libkvm/kvm_proc.c:1.96 src/lib/libkvm/kvm_proc.c:1.97 --- src/lib/libkvm/kvm_proc.c:1.96 Mon Jan 10 14:51:30 2022 +++ src/lib/libkvm/kvm_proc.c Mon Jan 10 15:04:01 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: kvm_proc.c,v 1.96 2022/01/10 19:51:30 christos Exp $ */ +/* $NetBSD: kvm_proc.c,v 1.97 2022/01/10 20:04:01 christos Exp $ */ /*- * Copyright (c) 1998 The NetBSD Foundation, Inc. @@ -67,7 +67,7 @@ #if 0 static char sccsid[] = "@(#)kvm_proc.c 8.3 (Berkeley) 9/23/93"; #else -__RCSID("$NetBSD: kvm_proc.c,v 1.96 2022/01/10 19:51:30 christos Exp $"); +__RCSID("$NetBSD: kvm_proc.c,v 1.97 2022/01/10 20:04:01 christos Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -118,6 +118,7 @@ __RCSID("$NetBSD: kvm_proc.c,v 1.96 2022 struct miniproc { struct vmspace *p_vmspace; char p_stat; + vaddr_t p_psstrp; struct proc *p_paddr; pid_t p_pid; }; @@ -131,6 +132,7 @@ struct miniproc { (p)->p_pid = (kp)->p_pid; \ (p)->p_paddr = NULL; \ (p)->p_vmspace = (kp)->p_vmspace; \ + (p)->p_psstrp = (kp)->p_psstrp; \ } while (/*CONSTCOND*/0); #define KPTOMINI(kp, p) \ @@ -1057,7 +1059,6 @@ proc_verify(kvm_t *kd, u_long kernp, con (kernproc.p_stat != SZOMB || p->p_stat == SZOMB)); } -extern struct ps_strings *__ps_strings; static char ** kvm_doargv(kvm_t *kd, const struct miniproc *p, int nchr, void (*info)(struct ps_strings *, u_long *, int *)) @@ -1072,8 +1073,7 @@ kvm_doargv(kvm_t *kd, const struct minip */ if (p->p_stat == SZOMB) return (NULL); - /* XXX: this is broken for ASLR: we need to read p->p_psstr instead */ - cnt = (int)kvm_ureadm(kd, p, (u_long)(intptr_t)__ps_strings, + cnt = (int)kvm_ureadm(kd, p, p->p_psstrp, (void *), sizeof(arginfo)); if (cnt != sizeof(arginfo)) return (NULL);
CVS commit: src/lib/libkvm
Module Name:src Committed By: christos Date: Mon Jan 10 20:04:01 UTC 2022 Modified Files: src/lib/libkvm: kvm_proc.c Log Message: read the ps arguments from the correct place. To generate a diff of this commit: cvs rdiff -u -r1.96 -r1.97 src/lib/libkvm/kvm_proc.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/lib/libkvm
Module Name:src Committed By: christos Date: Mon Jan 10 19:51:30 UTC 2022 Modified Files: src/lib/libkvm: kvm.c kvm_aarch64.c kvm_alpha.c kvm_arm.c kvm_hppa.c kvm_i386.c kvm_m68k.c kvm_mips.c kvm_or1k.c kvm_powerpc.c kvm_powerpc64.c kvm_private.h kvm_proc.c kvm_riscv.c kvm_sh3.c kvm_sparc.c kvm_sparc64.c kvm_vax.c kvm_x86_64.c Log Message: Get rid of usrstack/USRSTACK. Document that the old version of getargv is broken because of ASLR. To generate a diff of this commit: cvs rdiff -u -r1.109 -r1.110 src/lib/libkvm/kvm.c cvs rdiff -u -r1.10 -r1.11 src/lib/libkvm/kvm_aarch64.c cvs rdiff -u -r1.27 -r1.28 src/lib/libkvm/kvm_alpha.c cvs rdiff -u -r1.6 -r1.7 src/lib/libkvm/kvm_arm.c \ src/lib/libkvm/kvm_powerpc64.c cvs rdiff -u -r1.7 -r1.8 src/lib/libkvm/kvm_hppa.c cvs rdiff -u -r1.31 -r1.32 src/lib/libkvm/kvm_i386.c cvs rdiff -u -r1.19 -r1.20 src/lib/libkvm/kvm_m68k.c cvs rdiff -u -r1.22 -r1.23 src/lib/libkvm/kvm_mips.c cvs rdiff -u -r1.1 -r1.2 src/lib/libkvm/kvm_or1k.c src/lib/libkvm/kvm_riscv.c cvs rdiff -u -r1.13 -r1.14 src/lib/libkvm/kvm_powerpc.c cvs rdiff -u -r1.21 -r1.22 src/lib/libkvm/kvm_private.h cvs rdiff -u -r1.95 -r1.96 src/lib/libkvm/kvm_proc.c cvs rdiff -u -r1.9 -r1.10 src/lib/libkvm/kvm_sh3.c cvs rdiff -u -r1.35 -r1.36 src/lib/libkvm/kvm_sparc.c cvs rdiff -u -r1.17 -r1.18 src/lib/libkvm/kvm_sparc64.c cvs rdiff -u -r1.20 -r1.21 src/lib/libkvm/kvm_vax.c cvs rdiff -u -r1.12 -r1.13 src/lib/libkvm/kvm_x86_64.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/lib/libkvm/kvm.c diff -u src/lib/libkvm/kvm.c:1.109 src/lib/libkvm/kvm.c:1.110 --- src/lib/libkvm/kvm.c:1.109 Sat May 2 10:31:13 2020 +++ src/lib/libkvm/kvm.c Mon Jan 10 14:51:30 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: kvm.c,v 1.109 2020/05/02 14:31:13 christos Exp $ */ +/* $NetBSD: kvm.c,v 1.110 2022/01/10 19:51:30 christos Exp $ */ /*- * Copyright (c) 1989, 1992, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)kvm.c 8.2 (Berkeley) 2/13/94"; #else -__RCSID("$NetBSD: kvm.c,v 1.109 2020/05/02 14:31:13 christos Exp $"); +__RCSID("$NetBSD: kvm.c,v 1.110 2022/01/10 19:51:30 christos Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -289,7 +289,7 @@ _kvm_open(kvm_t *kd, const char *uf, con /* * Call the MD open hook. This sets: - * usrstack, min_uva, max_uva + * min_uva, max_uva */ if (_kvm_mdopen(kd)) { _kvm_err(kd, kd->program, "md init failed"); Index: src/lib/libkvm/kvm_aarch64.c diff -u src/lib/libkvm/kvm_aarch64.c:1.10 src/lib/libkvm/kvm_aarch64.c:1.11 --- src/lib/libkvm/kvm_aarch64.c:1.10 Tue Nov 10 14:14:11 2020 +++ src/lib/libkvm/kvm_aarch64.c Mon Jan 10 14:51:30 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: kvm_aarch64.c,v 1.10 2020/11/10 19:14:11 skrll Exp $ */ +/* $NetBSD: kvm_aarch64.c,v 1.11 2022/01/10 19:51:30 christos Exp $ */ /*- * Copyright (c) 2014, 2018 The NetBSD Foundation, Inc. @@ -49,7 +49,7 @@ #include "kvm_private.h" -__RCSID("$NetBSD: kvm_aarch64.c,v 1.10 2020/11/10 19:14:11 skrll Exp $"); +__RCSID("$NetBSD: kvm_aarch64.c,v 1.11 2022/01/10 19:51:30 christos Exp $"); /*ARGSUSED*/ void @@ -197,7 +197,6 @@ int _kvm_mdopen(kvm_t *kd) { - kd->usrstack = USRSTACK; kd->min_uva = VM_MIN_ADDRESS; kd->max_uva = VM_MAXUSER_ADDRESS; Index: src/lib/libkvm/kvm_alpha.c diff -u src/lib/libkvm/kvm_alpha.c:1.27 src/lib/libkvm/kvm_alpha.c:1.28 --- src/lib/libkvm/kvm_alpha.c:1.27 Wed Feb 19 15:21:22 2014 +++ src/lib/libkvm/kvm_alpha.c Mon Jan 10 14:51:30 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: kvm_alpha.c,v 1.27 2014/02/19 20:21:22 dsl Exp $ */ +/* $NetBSD: kvm_alpha.c,v 1.28 2022/01/10 19:51:30 christos Exp $ */ /* * Copyright (c) 1994, 1995 Carnegie-Mellon University. @@ -50,7 +50,7 @@ #include "kvm_private.h" -__RCSID("$NetBSD: kvm_alpha.c,v 1.27 2014/02/19 20:21:22 dsl Exp $"); +__RCSID("$NetBSD: kvm_alpha.c,v 1.28 2022/01/10 19:51:30 christos Exp $"); /*ARGSUSED*/ void @@ -186,7 +186,6 @@ int _kvm_mdopen(kvm_t *kd) { - kd->usrstack = USRSTACK; kd->min_uva = VM_MIN_ADDRESS; kd->max_uva = VM_MAXUSER_ADDRESS; Index: src/lib/libkvm/kvm_arm.c diff -u src/lib/libkvm/kvm_arm.c:1.6 src/lib/libkvm/kvm_arm.c:1.7 --- src/lib/libkvm/kvm_arm.c:1.6 Mon Sep 20 19:23:16 2010 +++ src/lib/libkvm/kvm_arm.c Mon Jan 10 14:51:30 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: kvm_arm.c,v 1.6 2010/09/20 23:23:16 jym Exp $ */ +/* $NetBSD: kvm_arm.c,v 1.7 2022/01/10 19:51:30 christos Exp $ */ /*- * Copyright (C) 1996 Wolfgang Solfrank. @@ -39,7 +39,7 @@ #include #if defined(LIBC_SCCS) && !defined(lint) -__RCSID("$NetBSD: kvm_arm.c,v 1.6 2010/09/20 23:23:16 jym Exp $"); +__RCSID("$NetBSD: kvm_arm.c,v 1.7 2022/01/10 19:51:30 christos Exp $"); #endif/* LIBC_SCCS and not lint */ #include @@ -194,13 +194,11 @@ _kvm_mdopen(kvm_t * kd) extern struct ps_strings *__ps_strings; #if 0/* XXX - These vary across arm machines... */ -
CVS commit: src/lib/libkvm
Module Name:src Committed By: christos Date: Mon Jan 10 19:51:30 UTC 2022 Modified Files: src/lib/libkvm: kvm.c kvm_aarch64.c kvm_alpha.c kvm_arm.c kvm_hppa.c kvm_i386.c kvm_m68k.c kvm_mips.c kvm_or1k.c kvm_powerpc.c kvm_powerpc64.c kvm_private.h kvm_proc.c kvm_riscv.c kvm_sh3.c kvm_sparc.c kvm_sparc64.c kvm_vax.c kvm_x86_64.c Log Message: Get rid of usrstack/USRSTACK. Document that the old version of getargv is broken because of ASLR. To generate a diff of this commit: cvs rdiff -u -r1.109 -r1.110 src/lib/libkvm/kvm.c cvs rdiff -u -r1.10 -r1.11 src/lib/libkvm/kvm_aarch64.c cvs rdiff -u -r1.27 -r1.28 src/lib/libkvm/kvm_alpha.c cvs rdiff -u -r1.6 -r1.7 src/lib/libkvm/kvm_arm.c \ src/lib/libkvm/kvm_powerpc64.c cvs rdiff -u -r1.7 -r1.8 src/lib/libkvm/kvm_hppa.c cvs rdiff -u -r1.31 -r1.32 src/lib/libkvm/kvm_i386.c cvs rdiff -u -r1.19 -r1.20 src/lib/libkvm/kvm_m68k.c cvs rdiff -u -r1.22 -r1.23 src/lib/libkvm/kvm_mips.c cvs rdiff -u -r1.1 -r1.2 src/lib/libkvm/kvm_or1k.c src/lib/libkvm/kvm_riscv.c cvs rdiff -u -r1.13 -r1.14 src/lib/libkvm/kvm_powerpc.c cvs rdiff -u -r1.21 -r1.22 src/lib/libkvm/kvm_private.h cvs rdiff -u -r1.95 -r1.96 src/lib/libkvm/kvm_proc.c cvs rdiff -u -r1.9 -r1.10 src/lib/libkvm/kvm_sh3.c cvs rdiff -u -r1.35 -r1.36 src/lib/libkvm/kvm_sparc.c cvs rdiff -u -r1.17 -r1.18 src/lib/libkvm/kvm_sparc64.c cvs rdiff -u -r1.20 -r1.21 src/lib/libkvm/kvm_vax.c cvs rdiff -u -r1.12 -r1.13 src/lib/libkvm/kvm_x86_64.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 19:23:00 UTC 2022 Modified Files: src/distrib/sets/lists/base: md.evbmips Log Message: Add sysinst message catalogs To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/distrib/sets/lists/base/md.evbmips Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/base/md.evbmips diff -u src/distrib/sets/lists/base/md.evbmips:1.4 src/distrib/sets/lists/base/md.evbmips:1.5 --- src/distrib/sets/lists/base/md.evbmips:1.4 Fri Jul 24 12:07:09 2020 +++ src/distrib/sets/lists/base/md.evbmips Mon Jan 10 19:23:00 2022 @@ -1,4 +1,4 @@ -# $NetBSD: md.evbmips,v 1.4 2020/07/24 12:07:09 jmcneill Exp $ +# $NetBSD: md.evbmips,v 1.5 2022/01/10 19:23:00 martin Exp $ ./usr/mdec/sbmipsbase-sysutil-bin ./usr/mdec/sbmips/bootbase-sysutil-bin ./usr/mdec/sbmips/bootxx_cd9660 base-sysutil-bin @@ -6,3 +6,8 @@ ./usr/mdec/sbmips/bootxx_lfs base-sysutil-bin ./usr/mdec/sbmips/netboot base-sysutil-bin ./usr/sbin/ofctlbase-sysutil-bin +./usr/share/sysinst/catalog/sysinstmsgs.de base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.es base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.fr base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.pl base-util-share +
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 19:23:00 UTC 2022 Modified Files: src/distrib/sets/lists/base: md.evbmips Log Message: Add sysinst message catalogs To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5 src/distrib/sets/lists/base/md.evbmips Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/sys/uvm
Module Name:src Committed By: christos Date: Mon Jan 10 18:04:20 UTC 2022 Modified Files: src/sys/uvm: uvm_unix.c Log Message: Use p->p_stackbase instead of USRSTACK because the stackbase can move because of ASLR. To generate a diff of this commit: cvs rdiff -u -r1.50 -r1.51 src/sys/uvm/uvm_unix.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/uvm/uvm_unix.c diff -u src/sys/uvm/uvm_unix.c:1.50 src/sys/uvm/uvm_unix.c:1.51 --- src/sys/uvm/uvm_unix.c:1.50 Sat Jan 6 11:41:24 2018 +++ src/sys/uvm/uvm_unix.c Mon Jan 10 13:04:20 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: uvm_unix.c,v 1.50 2018/01/06 16:41:24 kamil Exp $ */ +/* $NetBSD: uvm_unix.c,v 1.51 2022/01/10 18:04:20 christos Exp $ */ /* * Copyright (c) 1997 Charles D. Cranor and Washington University. @@ -45,7 +45,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uvm_unix.c,v 1.50 2018/01/06 16:41:24 kamil Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uvm_unix.c,v 1.51 2022/01/10 18:04:20 christos Exp $"); #include "opt_pax.h" @@ -150,9 +150,9 @@ uvm_grow(struct proc *p, vaddr_t sp) * For common case of already allocated (from trap). */ #ifdef __MACHINE_STACK_GROWS_UP - if (sp < USRSTACK + ctob(vm->vm_ssize)) + if (sp < p->p_stackbase + ctob(vm->vm_ssize)) #else - if (sp >= USRSTACK - ctob(vm->vm_ssize)) + if (sp >= p->p_stackbase - ctob(vm->vm_ssize)) #endif return (1); @@ -160,9 +160,9 @@ uvm_grow(struct proc *p, vaddr_t sp) * Really need to check vs limit and increment stack size if ok. */ #ifdef __MACHINE_STACK_GROWS_UP - nss = btoc(sp - USRSTACK); + nss = btoc(sp - p->p_stackbase); #else - nss = btoc(USRSTACK - sp); + nss = btoc(p->p_stackbase - sp); #endif if (nss > btoc(p->p_rlimit[RLIMIT_STACK].rlim_cur)) return (0);
CVS commit: src/sys/uvm
Module Name:src Committed By: christos Date: Mon Jan 10 18:04:20 UTC 2022 Modified Files: src/sys/uvm: uvm_unix.c Log Message: Use p->p_stackbase instead of USRSTACK because the stackbase can move because of ASLR. To generate a diff of this commit: cvs rdiff -u -r1.50 -r1.51 src/sys/uvm/uvm_unix.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 17:50:18 UTC 2022 Modified Files: src/distrib/sets/lists/base: md.acorn32 md.atari md.cats Log Message: Add sysinst catalogs to a few more md lists To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/distrib/sets/lists/base/md.acorn32 cvs rdiff -u -r1.55 -r1.56 src/distrib/sets/lists/base/md.atari cvs rdiff -u -r1.8 -r1.9 src/distrib/sets/lists/base/md.cats Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/base/md.acorn32 diff -u src/distrib/sets/lists/base/md.acorn32:1.13 src/distrib/sets/lists/base/md.acorn32:1.14 --- src/distrib/sets/lists/base/md.acorn32:1.13 Thu May 2 03:56:38 2013 +++ src/distrib/sets/lists/base/md.acorn32 Mon Jan 10 17:50:18 2022 @@ -1,2 +1,6 @@ -# $NetBSD: md.acorn32,v 1.13 2013/05/02 03:56:38 matt Exp $ +# $NetBSD: md.acorn32,v 1.14 2022/01/10 17:50:18 martin Exp $ ./dev/beep base-obsolete obsolete +./usr/share/sysinst/catalog/sysinstmsgs.de base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.es base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.fr base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.pl base-util-share Index: src/distrib/sets/lists/base/md.atari diff -u src/distrib/sets/lists/base/md.atari:1.55 src/distrib/sets/lists/base/md.atari:1.56 --- src/distrib/sets/lists/base/md.atari:1.55 Sun Mar 4 03:14:51 2018 +++ src/distrib/sets/lists/base/md.atari Mon Jan 10 17:50:18 2022 @@ -1,4 +1,4 @@ -# $NetBSD: md.atari,v 1.55 2018/03/04 03:14:51 tsutsui Exp $ +# $NetBSD: md.atari,v 1.56 2022/01/10 17:50:18 martin Exp $ ./sbin/ahdilabelbase-sysutil-root ./sbin/binpatch base-sysutil-root ./sbin/edahdi base-sysutil-root @@ -29,3 +29,4 @@ ./usr/share/keymaps/atari/fr.map base-sys-share ./usr/share/keymaps/atari/uk.map base-sys-share ./usr/share/keymaps/atari/us.map base-sys-share +./usr/share/sysinst/catalog/sysinstmsgs.de base-util-share Index: src/distrib/sets/lists/base/md.cats diff -u src/distrib/sets/lists/base/md.cats:1.8 src/distrib/sets/lists/base/md.cats:1.9 --- src/distrib/sets/lists/base/md.cats:1.8 Wed Aug 6 12:15:01 2014 +++ src/distrib/sets/lists/base/md.cats Mon Jan 10 17:50:18 2022 @@ -1,2 +1,6 @@ -# $NetBSD: md.cats,v 1.8 2014/08/06 12:15:01 martin Exp $ +# $NetBSD: md.cats,v 1.9 2022/01/10 17:50:18 martin Exp $ ./dev/pms0 base-obsolete obsolete +./usr/share/sysinst/catalog/sysinstmsgs.de base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.es base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.fr base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.pl base-util-share
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 17:50:18 UTC 2022 Modified Files: src/distrib/sets/lists/base: md.acorn32 md.atari md.cats Log Message: Add sysinst catalogs to a few more md lists To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/distrib/sets/lists/base/md.acorn32 cvs rdiff -u -r1.55 -r1.56 src/distrib/sets/lists/base/md.atari cvs rdiff -u -r1.8 -r1.9 src/distrib/sets/lists/base/md.cats Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 15:31:38 UTC 2022 Modified Files: src/distrib/sets/lists/base: md.evbarm Log Message: Add sysinst catalog files To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/distrib/sets/lists/base/md.evbarm Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 15:31:38 UTC 2022 Modified Files: src/distrib/sets/lists/base: md.evbarm Log Message: Add sysinst catalog files To generate a diff of this commit: cvs rdiff -u -r1.20 -r1.21 src/distrib/sets/lists/base/md.evbarm Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/base/md.evbarm diff -u src/distrib/sets/lists/base/md.evbarm:1.20 src/distrib/sets/lists/base/md.evbarm:1.21 --- src/distrib/sets/lists/base/md.evbarm:1.20 Tue Feb 9 11:57:20 2021 +++ src/distrib/sets/lists/base/md.evbarm Mon Jan 10 15:31:38 2022 @@ -1,4 +1,4 @@ -# $NetBSD: md.evbarm,v 1.20 2021/02/09 11:57:20 yamt Exp $ +# $NetBSD: md.evbarm,v 1.21 2022/01/10 15:31:38 martin Exp $ ./libdata/firmware/if_bwfm/brcmfmac43143-sdio.bin base-firmware-root firmware ./libdata/firmware/if_bwfm/brcmfmac43241b0-sdio.bin base-firmware-root firmware ./libdata/firmware/if_bwfm/brcmfmac43241b4-sdio.bin base-firmware-root firmware @@ -29,3 +29,7 @@ ./libdata/firmware/if_bwfm/brcmfmac4354-sdio.bin base-firmware-root firmware ./libdata/firmware/if_bwfm/brcmfmac4356-sdio.bin base-firmware-root firmware ./libdata/firmware/if_bwfm/brcmfmac4373-sdio.bin base-firmware-root firmware +./usr/share/sysinst/catalog/sysinstmsgs.de base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.es base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.fr base-util-share +./usr/share/sysinst/catalog/sysinstmsgs.pl base-util-share
CVS commit: src/usr.sbin/sysinst
Module Name:src Committed By: nia Date: Mon Jan 10 12:17:48 UTC 2022 Modified Files: src/usr.sbin/sysinst: msg.mi.de msg.mi.en msg.mi.es msg.mi.fr msg.mi.pl net.c Log Message: sysinst(8): Add initial support for connecting to Wi-Fi networks by spawning wpa_supplicant. Reviewed by martin. To generate a diff of this commit: cvs rdiff -u -r1.34 -r1.35 src/usr.sbin/sysinst/msg.mi.de cvs rdiff -u -r1.36 -r1.37 src/usr.sbin/sysinst/msg.mi.en \ src/usr.sbin/sysinst/msg.mi.pl src/usr.sbin/sysinst/net.c cvs rdiff -u -r1.30 -r1.31 src/usr.sbin/sysinst/msg.mi.es cvs rdiff -u -r1.35 -r1.36 src/usr.sbin/sysinst/msg.mi.fr Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/usr.sbin/sysinst/msg.mi.de diff -u src/usr.sbin/sysinst/msg.mi.de:1.34 src/usr.sbin/sysinst/msg.mi.de:1.35 --- src/usr.sbin/sysinst/msg.mi.de:1.34 Sat Sep 25 08:54:31 2021 +++ src/usr.sbin/sysinst/msg.mi.de Mon Jan 10 12:17:48 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: msg.mi.de,v 1.34 2021/09/25 08:54:31 maya Exp $ */ +/* $NetBSD: msg.mi.de,v 1.35 2022/01/10 12:17:48 nia Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -641,6 +641,12 @@ message net_defroute message net_media {Art der Netzwerkverbindung} +message net_ssid +{WLAN-SSID?} + +message net_passphrase +{WLAN-Passwort?} + message netok {Nachfolgend sehen Sie die aktuellen Netzwerkeinstellungen. Index: src/usr.sbin/sysinst/msg.mi.en diff -u src/usr.sbin/sysinst/msg.mi.en:1.36 src/usr.sbin/sysinst/msg.mi.en:1.37 --- src/usr.sbin/sysinst/msg.mi.en:1.36 Sat Sep 25 08:54:31 2021 +++ src/usr.sbin/sysinst/msg.mi.en Mon Jan 10 12:17:48 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: msg.mi.en,v 1.36 2021/09/25 08:54:31 maya Exp $ */ +/* $NetBSD: msg.mi.en,v 1.37 2022/01/10 12:17:48 nia Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -616,6 +616,12 @@ message net_defroute message net_media {Network media type} +message net_ssid +{Wi-Fi SSID?} + +message net_passphrase +{Wi-Fi passphrase?} + message netok {The following are the values you entered. Index: src/usr.sbin/sysinst/msg.mi.pl diff -u src/usr.sbin/sysinst/msg.mi.pl:1.36 src/usr.sbin/sysinst/msg.mi.pl:1.37 --- src/usr.sbin/sysinst/msg.mi.pl:1.36 Sat Sep 25 08:54:31 2021 +++ src/usr.sbin/sysinst/msg.mi.pl Mon Jan 10 12:17:48 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: msg.mi.pl,v 1.36 2021/09/25 08:54:31 maya Exp $ */ +/* $NetBSD: msg.mi.pl,v 1.37 2022/01/10 12:17:48 nia Exp $ */ /* Based on english version: */ /* NetBSD: msg.mi.pl,v 1.36 2004/04/17 18:55:35 atatat Exp */ @@ -611,6 +611,12 @@ message net_defroute message net_media {Typ interfejsu sieciowego} +message net_ssid +{Wi-Fi SSID?} + +message net_passphrase +{Wi-Fi passphrase?} + message netok {Ponizej sa wartosci, ktore wprowadziles. Index: src/usr.sbin/sysinst/net.c diff -u src/usr.sbin/sysinst/net.c:1.36 src/usr.sbin/sysinst/net.c:1.37 --- src/usr.sbin/sysinst/net.c:1.36 Sun Jan 31 22:45:46 2021 +++ src/usr.sbin/sysinst/net.c Mon Jan 10 12:17:48 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: net.c,v 1.36 2021/01/31 22:45:46 rillig Exp $ */ +/* $NetBSD: net.c,v 1.37 2022/01/10 12:17:48 nia Exp $ */ /* * Copyright 1997 Piermont Information Systems Inc. @@ -79,6 +79,8 @@ static char net_mask[SSTRSIZE]; char net_namesvr[STRSIZE]; static char net_defroute[STRSIZE]; static char net_media[STRSIZE]; +static char net_ssid[STRSIZE]; +static char net_passphrase[STRSIZE]; static char sl_flags[STRSIZE]; static int net_dhcpconf; #define DHCPCONF_IPADDR 0x01 @@ -100,8 +102,11 @@ static char *url_encode (char *dst, cons static void write_etc_hosts(FILE *f); #define DHCPCD "/sbin/dhcpcd" +#define WPA_SUPPLICANT "/usr/sbin/wpa_supplicant" #include +static int config_eth_medium(char *); static int config_dhcp(char *); +static int config_wlan(char *); #ifdef INET6 static int is_v6kernel (void); @@ -562,45 +567,8 @@ again: /* domain and host */ msg_display(MSG_netinfo); - /* ethernet medium */ - for (;;) { - msg_prompt_add(MSG_net_media, net_media, net_media, - sizeof net_media); - - /* - * ifconfig does not allow media specifiers on - * IFM_MANUAL interfaces. Our UI gives no way - * to set an option back - * to null-string if it gets accidentally set. - * Check for plausible alternatives. - */ - if (strcmp(net_media, "") == 0 || - strcmp(net_media, "default") == 0 || - strcmp(net_media, "") == 0 || - strcmp(net_media, "manual") == 0 || - strcmp(net_media, "") == 0 || - strcmp(net_media, "none") == 0 || - strcmp(net_media, " ") == 0) { -*net_media = '\0'; - } - - if (*net_media == '\0') -break; - /* - * We must set the media type here - to give dhcp - * a chance - */ - if (run_program(0, "/sbin/ifconfig %s media %s", -net_dev, net_media) == 0) -break; - /* Failed to set - output the supported
CVS commit: src/usr.sbin/sysinst
Module Name:src Committed By: nia Date: Mon Jan 10 12:17:48 UTC 2022 Modified Files: src/usr.sbin/sysinst: msg.mi.de msg.mi.en msg.mi.es msg.mi.fr msg.mi.pl net.c Log Message: sysinst(8): Add initial support for connecting to Wi-Fi networks by spawning wpa_supplicant. Reviewed by martin. To generate a diff of this commit: cvs rdiff -u -r1.34 -r1.35 src/usr.sbin/sysinst/msg.mi.de cvs rdiff -u -r1.36 -r1.37 src/usr.sbin/sysinst/msg.mi.en \ src/usr.sbin/sysinst/msg.mi.pl src/usr.sbin/sysinst/net.c cvs rdiff -u -r1.30 -r1.31 src/usr.sbin/sysinst/msg.mi.es cvs rdiff -u -r1.35 -r1.36 src/usr.sbin/sysinst/msg.mi.fr Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 10:02:30 UTC 2022 Modified Files: src/distrib/sets/lists/base: mi Log Message: "Unobsolete" the sysinst message catalogs, now that we install them again. To generate a diff of this commit: cvs rdiff -u -r1.1286 -r1.1287 src/distrib/sets/lists/base/mi Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/base/mi diff -u src/distrib/sets/lists/base/mi:1.1286 src/distrib/sets/lists/base/mi:1.1287 --- src/distrib/sets/lists/base/mi:1.1286 Tue Dec 7 17:39:53 2021 +++ src/distrib/sets/lists/base/mi Mon Jan 10 10:02:30 2022 @@ -1,4 +1,4 @@ -# $NetBSD: mi,v 1.1286 2021/12/07 17:39:53 brad Exp $ +# $NetBSD: mi,v 1.1287 2022/01/10 10:02:30 martin Exp $ # # Note: Don't delete entries from here - mark them as "obsolete" instead, # unless otherwise stated below. @@ -5156,10 +5156,6 @@ ./usr/share/sushi/util/scripting/func base-obsolete obsolete ./usr/share/sysinstbase-util-share ./usr/share/sysinst/catalog base-util-share -./usr/share/sysinst/catalog/sysinstmsgs.de base-obsolete obsolete -./usr/share/sysinst/catalog/sysinstmsgs.es base-obsolete obsolete -./usr/share/sysinst/catalog/sysinstmsgs.fr base-obsolete obsolete -./usr/share/sysinst/catalog/sysinstmsgs.pl base-obsolete obsolete ./usr/share/tabsetbase-util-share ./usr/share/tabset/3101base-util-share share ./usr/share/tabset/9837base-util-share share
CVS commit: src/distrib/sets/lists/base
Module Name:src Committed By: martin Date: Mon Jan 10 10:02:30 UTC 2022 Modified Files: src/distrib/sets/lists/base: mi Log Message: "Unobsolete" the sysinst message catalogs, now that we install them again. To generate a diff of this commit: cvs rdiff -u -r1.1286 -r1.1287 src/distrib/sets/lists/base/mi Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.