CVS commit: src/sys/arch/riscv/riscv
Module Name:src Committed By: kamil Date: Mon Dec 5 07:24:16 UTC 2016 Modified Files: src/sys/arch/riscv/riscv: locore.S Log Message: Fix cpu_switchto(9) prototype in a comment To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/arch/riscv/riscv/locore.S 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/riscv/riscv/locore.S diff -u src/sys/arch/riscv/riscv/locore.S:1.5 src/sys/arch/riscv/riscv/locore.S:1.6 --- src/sys/arch/riscv/riscv/locore.S:1.5 Tue Mar 31 11:53:13 2015 +++ src/sys/arch/riscv/riscv/locore.S Mon Dec 5 07:24:16 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: locore.S,v 1.5 2015/03/31 11:53:13 matt Exp $ */ +/* $NetBSD: locore.S,v 1.6 2016/12/05 07:24:16 kamil Exp $ */ /*- * Copyright (c) 2014 The NetBSD Foundation, Inc. * All rights reserved. @@ -156,7 +156,7 @@ ENTRY_NP(start) END(start) // -// struct lwp *cpu_switch(struct lwp *oldl, struct lwp *newl, bool returning); +// struct lwp *cpu_switchto(struct lwp *oldl, struct lwp *newl, bool returning); // ENTRY_NP(cpu_switchto) addi sp, sp, -TF_LEN // allocate trapframe
CVS commit: src/tests/kernel
Module Name:src Committed By: kamil Date: Mon Dec 5 07:18:10 UTC 2016 Modified Files: src/tests/kernel: t_ptrace_wait.c Log Message: Mark again lwpinfo2 with expected failure in t_ptrace_wait{,3,4,6,id,pid} Only failure lwpinfo1 was addressed, not lwpinfo2. PR kern/51685 Sponsored by To generate a diff of this commit: cvs rdiff -u -r1.39 -r1.40 src/tests/kernel/t_ptrace_wait.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/tests/kernel/t_ptrace_wait.c diff -u src/tests/kernel/t_ptrace_wait.c:1.39 src/tests/kernel/t_ptrace_wait.c:1.40 --- src/tests/kernel/t_ptrace_wait.c:1.39 Sun Dec 4 23:48:02 2016 +++ src/tests/kernel/t_ptrace_wait.c Mon Dec 5 07:18:10 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: t_ptrace_wait.c,v 1.39 2016/12/04 23:48:02 kamil Exp $ */ +/* $NetBSD: t_ptrace_wait.c,v 1.40 2016/12/05 07:18:10 kamil Exp $ */ /*- * Copyright (c) 2016 The NetBSD Foundation, Inc. @@ -27,7 +27,7 @@ */ #include -__RCSID("$NetBSD: t_ptrace_wait.c,v 1.39 2016/12/04 23:48:02 kamil Exp $"); +__RCSID("$NetBSD: t_ptrace_wait.c,v 1.40 2016/12/05 07:18:10 kamil Exp $"); #include #include @@ -4709,6 +4709,12 @@ ATF_TC_BODY(lwpinfo2, tc) #endif struct ptrace_lwpinfo info = {0}; + /* + * ptrace(2): Signal does not set PL_EVENT_SIGNAL inOB + * (struct ptrace_lwpinfo.)pl_event + */ + atf_tc_expect_fail("PR kern/51685"); + printf("Spawn tracee\n"); ATF_REQUIRE(pipe(fds_totracee) == 0); tracee = atf_utils_fork();
CVS commit: src/sys/arch/x86/include
Module Name:src Committed By: msaitoh Date: Mon Dec 5 03:59:47 UTC 2016 Modified Files: src/sys/arch/x86/include: specialreg.h Log Message: Fix CPUID_SEF_FLAGS. Octal value has no 8. To generate a diff of this commit: cvs rdiff -u -r1.89 -r1.90 src/sys/arch/x86/include/specialreg.h 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/x86/include/specialreg.h diff -u src/sys/arch/x86/include/specialreg.h:1.89 src/sys/arch/x86/include/specialreg.h:1.90 --- src/sys/arch/x86/include/specialreg.h:1.89 Fri Aug 19 18:53:29 2016 +++ src/sys/arch/x86/include/specialreg.h Mon Dec 5 03:59:47 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: specialreg.h,v 1.89 2016/08/19 18:53:29 maxv Exp $ */ +/* $NetBSD: specialreg.h,v 1.90 2016/12/05 03:59:47 msaitoh Exp $ */ /*- * Copyright (c) 1991 The Regents of the University of California. @@ -354,9 +354,9 @@ "\11" "BMI2" "\12" "ERMS" "\13" "INVPCID" "\14" "RTM" \ "\15" "QM" "\16" "FPUCSDS" "\17" "MPX" "\20" "PQE" \ "\21" "AVX512F" "\22" "AVX512DQ" "\23" "RDSEED" "\24" "ADX" \ - "\25" "SMAP" "\28" "CLFLUSHOPT" \ + "\25" "SMAP" "\30" "CLFLUSHOPT" \ "\32" "PT" "\33" "AVX512PF" "\34" "AVX512ER" \ - "\35" "AVX512CD""\36" "SHA" "\37" "AVX512BW" "\38" "AVX512VL" + "\35" "AVX512CD""\36" "SHA" "\37" "AVX512BW" "\40" "AVX512VL" /* %ecx */ #define CPUID_SEF_PREFETCHWT1 __BIT(0)
CVS commit: src/tests/kernel
Module Name:src Committed By: kamil Date: Sun Dec 4 23:48:02 UTC 2016 Modified Files: src/tests/kernel: t_ptrace_wait.c Log Message: lwpinfo1 and lwpinfo2 in t_ptrace_wait{,3,4,6,id,pid} no longer fails Remove atf_tc_expect_fail() linked with PR kern/51685. Issue fixed by Christsos Zoulas in src/sys/kern/kern_sig.c r. 1.331 Sponsored by To generate a diff of this commit: cvs rdiff -u -r1.38 -r1.39 src/tests/kernel/t_ptrace_wait.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/tests/kernel/t_ptrace_wait.c diff -u src/tests/kernel/t_ptrace_wait.c:1.38 src/tests/kernel/t_ptrace_wait.c:1.39 --- src/tests/kernel/t_ptrace_wait.c:1.38 Sat Dec 3 07:23:08 2016 +++ src/tests/kernel/t_ptrace_wait.c Sun Dec 4 23:48:02 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: t_ptrace_wait.c,v 1.38 2016/12/03 07:23:08 kamil Exp $ */ +/* $NetBSD: t_ptrace_wait.c,v 1.39 2016/12/04 23:48:02 kamil Exp $ */ /*- * Copyright (c) 2016 The NetBSD Foundation, Inc. @@ -27,7 +27,7 @@ */ #include -__RCSID("$NetBSD: t_ptrace_wait.c,v 1.38 2016/12/03 07:23:08 kamil Exp $"); +__RCSID("$NetBSD: t_ptrace_wait.c,v 1.39 2016/12/04 23:48:02 kamil Exp $"); #include #include @@ -4637,12 +4637,6 @@ ATF_TC_BODY(lwpinfo1, tc) #endif struct ptrace_lwpinfo info = {0}; - /* - * ptrace(2): Signal does not set PL_EVENT_SIGNAL in - * (struct ptrace_lwpinfo.)pl_event - */ - atf_tc_expect_fail("PR kern/51685"); - printf("Before forking process PID=%d\n", getpid()); child = atf_utils_fork(); if (child == 0) { @@ -4715,12 +4709,6 @@ ATF_TC_BODY(lwpinfo2, tc) #endif struct ptrace_lwpinfo info = {0}; - /* - * ptrace(2): Signal does not set PL_EVENT_SIGNAL in - * (struct ptrace_lwpinfo.)pl_event - */ - atf_tc_expect_fail("PR kern/51685"); - printf("Spawn tracee\n"); ATF_REQUIRE(pipe(fds_totracee) == 0); tracee = atf_utils_fork();
CVS commit: src/external/gpl3/binutils
Module Name:src Committed By: christos Date: Sun Dec 4 18:43:07 UTC 2016 Modified Files: src/external/gpl3/binutils/lib/libbfd/arch/sh3eb: bfd.h bfdver.h config.h src/external/gpl3/binutils/lib/libbfd/arch/sh3el: bfd.h bfdver.h config.h src/external/gpl3/binutils/lib/libopcodes/arch/sh3eb: config.h src/external/gpl3/binutils/lib/libopcodes/arch/sh3el: config.h src/external/gpl3/binutils/usr.bin/common/arch/sh3eb: config.h defs.mk src/external/gpl3/binutils/usr.bin/common/arch/sh3el: config.h defs.mk src/external/gpl3/binutils/usr.bin/gas/arch/sh3eb: config.h src/external/gpl3/binutils/usr.bin/gas/arch/sh3el: config.h src/external/gpl3/binutils/usr.bin/gprof/arch/sh3eb: gconfig.h src/external/gpl3/binutils/usr.bin/gprof/arch/sh3el: gconfig.h src/external/gpl3/binutils/usr.bin/ld/arch/sh3eb: config.h src/external/gpl3/binutils/usr.bin/ld/arch/sh3el: config.h Log Message: Regen sh3 To generate a diff of this commit: cvs rdiff -u -r1.6 -r1.7 \ src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/bfd.h cvs rdiff -u -r1.9 -r1.10 \ src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/bfdver.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/config.h cvs rdiff -u -r1.6 -r1.7 \ src/external/gpl3/binutils/lib/libbfd/arch/sh3el/bfd.h cvs rdiff -u -r1.9 -r1.10 \ src/external/gpl3/binutils/lib/libbfd/arch/sh3el/bfdver.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/lib/libbfd/arch/sh3el/config.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/lib/libopcodes/arch/sh3eb/config.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/lib/libopcodes/arch/sh3el/config.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/common/arch/sh3eb/config.h cvs rdiff -u -r1.7 -r1.8 \ src/external/gpl3/binutils/usr.bin/common/arch/sh3eb/defs.mk cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/common/arch/sh3el/config.h cvs rdiff -u -r1.7 -r1.8 \ src/external/gpl3/binutils/usr.bin/common/arch/sh3el/defs.mk cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/gas/arch/sh3eb/config.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/gas/arch/sh3el/config.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/gprof/arch/sh3eb/gconfig.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/gprof/arch/sh3el/gconfig.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/ld/arch/sh3eb/config.h cvs rdiff -u -r1.5 -r1.6 \ src/external/gpl3/binutils/usr.bin/ld/arch/sh3el/config.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/bfd.h diff -u src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/bfd.h:1.6 src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/bfd.h:1.7 --- src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/bfd.h:1.6 Fri Jan 29 12:30:23 2016 +++ src/external/gpl3/binutils/lib/libbfd/arch/sh3eb/bfd.h Sun Dec 4 13:43:07 2016 @@ -11,7 +11,7 @@ /* Main header file for the bfd library -- portable access to object files. - Copyright (C) 1990-2015 Free Software Foundation, Inc. + Copyright (C) 1990-2016 Free Software Foundation, Inc. Contributed by Cygnus Support. @@ -522,7 +522,6 @@ extern void warn_deprecated (const char #define bfd_get_file_flags(abfd) ((abfd)->flags) #define bfd_applicable_file_flags(abfd) ((abfd)->xvec->object_flags) #define bfd_applicable_section_flags(abfd) ((abfd)->xvec->section_flags) -#define bfd_my_archive(abfd) ((abfd)->my_archive) #define bfd_has_map(abfd) ((abfd)->has_armap) #define bfd_is_thin_archive(abfd) ((abfd)->is_thin_archive) @@ -914,6 +913,9 @@ extern bfd_boolean bfd_elf32_arm_get_bfd extern bfd_boolean bfd_elf32_arm_add_glue_sections_to_bfd (bfd *, struct bfd_link_info *); +extern void bfd_elf32_arm_keep_private_stub_output_sections + (struct bfd_link_info *); + /* ELF ARM mapping symbol support. */ #define BFD_ARM_SPECIAL_SYM_TYPE_MAP (1 << 0) #define BFD_ARM_SPECIAL_SYM_TYPE_TAG (1 << 1) @@ -945,7 +947,8 @@ extern void elf32_arm_next_input_section (struct bfd_link_info *, struct bfd_section *); extern bfd_boolean elf32_arm_size_stubs (bfd *, bfd *, struct bfd_link_info *, bfd_signed_vma, - struct bfd_section * (*) (const char *, struct bfd_section *, unsigned int), + struct bfd_section * (*) (const char *, struct bfd_section *, + struct bfd_section *, unsigned int), void (*) (void)); extern bfd_boolean elf32_arm_build_stubs (struct bfd_link_info *); @@ -958,13 +961,6 @@ extern bfd_boolean elf32_arm_fix_exidx_c extern bfd_boolean elf32_tic6x_fix_exidx_coverage (struct bfd_section **, unsigned int, struct bfd_link_info *, bfd_boolean); -/* PowerPC @tls opcode transform/validate. */ -extern unsigned
CVS commit: src/sys/external/bsd/dwc2
Module Name:src Committed By: skrll Date: Sun Dec 4 16:59:49 UTC 2016 Modified Files: src/sys/external/bsd/dwc2: dwc2.c Log Message: Add a missing usb_syncmem(... BUS_DMASYNC_PRE{READ,WRITE}) for the transfer buffer To generate a diff of this commit: cvs rdiff -u -r1.44 -r1.45 src/sys/external/bsd/dwc2/dwc2.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/external/bsd/dwc2/dwc2.c diff -u src/sys/external/bsd/dwc2/dwc2.c:1.44 src/sys/external/bsd/dwc2/dwc2.c:1.45 --- src/sys/external/bsd/dwc2/dwc2.c:1.44 Sun Aug 14 14:42:22 2016 +++ src/sys/external/bsd/dwc2/dwc2.c Sun Dec 4 16:59:49 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: dwc2.c,v 1.44 2016/08/14 14:42:22 skrll Exp $ */ +/* $NetBSD: dwc2.c,v 1.45 2016/12/04 16:59:49 skrll Exp $ */ /*- * Copyright (c) 2013 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: dwc2.c,v 1.44 2016/08/14 14:42:22 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: dwc2.c,v 1.45 2016/12/04 16:59:49 skrll Exp $"); #include "opt_usb.h" @@ -1012,6 +1012,10 @@ dwc2_device_start(struct usbd_xfer *xfer dwc2_urb->usbdma = >ux_dmabuf; dwc2_urb->buf = KERNADDR(dwc2_urb->usbdma, 0); dwc2_urb->dma = DMAADDR(dwc2_urb->usbdma, 0); + + usb_syncmem(>ux_dmabuf, 0, len, + dir == UE_DIR_IN ? + BUS_DMASYNC_PREREAD : BUS_DMASYNC_PREWRITE); } dwc2_urb->length = len; dwc2_urb->flags = flags;
CVS commit: src/sys/kern
Module Name:src Committed By: christos Date: Sun Dec 4 16:40:44 UTC 2016 Modified Files: src/sys/kern: kern_sig.c Log Message: PR/51685: Kamil Rytarowski: Fill sigcontext info in kpsignal2 so that the debugger/core-dump signal info gets filled in in all code paths (including the lwp_kill one). To generate a diff of this commit: cvs rdiff -u -r1.330 -r1.331 src/sys/kern/kern_sig.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/kern/kern_sig.c diff -u src/sys/kern/kern_sig.c:1.330 src/sys/kern/kern_sig.c:1.331 --- src/sys/kern/kern_sig.c:1.330 Tue Sep 13 03:39:45 2016 +++ src/sys/kern/kern_sig.c Sun Dec 4 11:40:43 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: kern_sig.c,v 1.330 2016/09/13 07:39:45 martin Exp $ */ +/* $NetBSD: kern_sig.c,v 1.331 2016/12/04 16:40:43 christos Exp $ */ /*- * Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc. @@ -70,7 +70,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: kern_sig.c,v 1.330 2016/09/13 07:39:45 martin Exp $"); +__KERNEL_RCSID(0, "$NetBSD: kern_sig.c,v 1.331 2016/12/04 16:40:43 christos Exp $"); #include "opt_ptrace.h" #include "opt_dtrace.h" @@ -923,10 +923,6 @@ trapsignal(struct lwp *l, ksiginfo_t *ks mask, ksi); } } else { - /* XXX for core dump/debugger */ - p->p_sigctx.ps_lwp = l->l_lid; - p->p_sigctx.ps_signo = ksi->ksi_signo; - p->p_sigctx.ps_code = ksi->ksi_trap; kpsignal2(p, ksi); mutex_exit(p->p_lock); mutex_exit(proc_lock); @@ -1242,6 +1238,11 @@ kpsignal2(struct proc *p, ksiginfo_t *ks if (p->p_stat != SACTIVE && p->p_stat != SSTOP) return 0; + /* XXX for core dump/debugger */ + p->p_sigctx.ps_lwp = ksi->ksi_lid; + p->p_sigctx.ps_signo = ksi->ksi_signo; + p->p_sigctx.ps_code = ksi->ksi_trap; + /* * Notify any interested parties of the signal. */
CVS commit: src/distrib/sets/lists/xdebug
Module Name:src Committed By: martin Date: Sun Dec 4 13:37:45 UTC 2016 Modified Files: src/distrib/sets/lists/xdebug: md.sparc64 Log Message: Fix debug entry for glint driver (no longer obsolete with 1.18) To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/distrib/sets/lists/xdebug/md.sparc64 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/xdebug/md.sparc64 diff -u src/distrib/sets/lists/xdebug/md.sparc64:1.9 src/distrib/sets/lists/xdebug/md.sparc64:1.10 --- src/distrib/sets/lists/xdebug/md.sparc64:1.9 Sat Sep 24 21:57:38 2016 +++ src/distrib/sets/lists/xdebug/md.sparc64 Sun Dec 4 13:37:45 2016 @@ -1,4 +1,4 @@ -# $NetBSD: md.sparc64,v 1.9 2016/09/24 21:57:38 mrg Exp $ +# $NetBSD: md.sparc64,v 1.10 2016/12/04 13:37:45 martin Exp $ ./usr/X11R7/lib/modules/extensions/libcfb32_g.a -unknown- obsolete ./usr/X11R7/lib/modules/extensions/libcfb_g.a -unknown- obsolete ./usr/X11R7/lib/modules/extensions/libdbe_g.a -unknown- debuglib,xorg,obsolete @@ -53,8 +53,7 @@ ./usr/libdata/debug/usr/X11R7/lib/modules/drivers/ag10e_drv.so.0.debug -unknown- xorg,debug,xorg_server_ver=110 ./usr/libdata/debug/usr/X11R7/lib/modules/drivers/ag10e_drv.so.0.debug -unknown- xorg,debug,xorg_server_ver=118,obsolete ./usr/libdata/debug/usr/X11R7/lib/modules/drivers/ati_drv.so.6.debug -unknown- xorg,debug -./usr/libdata/debug/usr/X11R7/lib/modules/drivers/glint_drv.so.1.debug -unknown- xorg,debug,xorg_server_ver=110 -./usr/libdata/debug/usr/X11R7/lib/modules/drivers/glint_drv.so.1.debug -unknown- xorg,debug,xorg_server_ver=118,obsolete +./usr/libdata/debug/usr/X11R7/lib/modules/drivers/glint_drv.so.1.debug -unknown- xorg,debug ./usr/libdata/debug/usr/X11R7/lib/modules/drivers/kbd_drv.so.1.debug -unknown- xorg,debug ./usr/libdata/debug/usr/X11R7/lib/modules/drivers/libag10e_drv.so.0.debug obsolete xorg,obsolete ./usr/libdata/debug/usr/X11R7/lib/modules/drivers/libati_drv.so.6.debug obsolete xorg,obsolete
CVS commit: src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sun Dec 4 11:47:29 UTC 2016 Modified Files: src/sys/dev/usb: if_axe.c Log Message: Fix a -Werror=sign-compare To generate a diff of this commit: cvs rdiff -u -r1.77 -r1.78 src/sys/dev/usb/if_axe.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/dev/usb/if_axe.c diff -u src/sys/dev/usb/if_axe.c:1.77 src/sys/dev/usb/if_axe.c:1.78 --- src/sys/dev/usb/if_axe.c:1.77 Sun Dec 4 10:08:26 2016 +++ src/sys/dev/usb/if_axe.c Sun Dec 4 11:47:29 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: if_axe.c,v 1.77 2016/12/04 10:08:26 skrll Exp $ */ +/* $NetBSD: if_axe.c,v 1.78 2016/12/04 11:47:29 skrll Exp $ */ /* $OpenBSD: if_axe.c,v 1.137 2016/04/13 11:03:37 mpi Exp $ */ /* @@ -87,7 +87,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.77 2016/12/04 10:08:26 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.78 2016/12/04 11:47:29 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -1307,7 +1307,7 @@ axe_rxeof(struct usbd_xfer *xfer, void * * of 4. */ pktlen = AXE_CSUM_RXBYTES(csum_hdr.len); - int len = sizeof(csum_hdr) + pktlen; + u_int len = sizeof(csum_hdr) + pktlen; len = (len + 3) & ~3; if (total_len < len) { DPRINTFN(20, "total_len %#x < len %#x",
CVS commit: src/doc
Module Name:src Committed By: maya Date: Sun Dec 4 11:40:01 UTC 2016 Modified Files: src/doc: CHANGES Log Message: Note new axe(4) chipset support. To generate a diff of this commit: cvs rdiff -u -r1.2214 -r1.2215 src/doc/CHANGES Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/doc/CHANGES diff -u src/doc/CHANGES:1.2214 src/doc/CHANGES:1.2215 --- src/doc/CHANGES:1.2214 Sat Dec 3 19:15:27 2016 +++ src/doc/CHANGES Sun Dec 4 11:40:01 2016 @@ -1,4 +1,4 @@ -# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.2214 $> +# LIST OF CHANGES FROM LAST RELEASE: <$Revision: 1.2215 $> # # # [Note: This file does not mention every change made to the NetBSD source tree. @@ -401,3 +401,5 @@ Changes from NetBSD 7.0 to NetBSD 8.0: zoneinfo: Import tzdata2016j. [kre 20161124] luna68k: Preliminary support for LUNA's HD647180X I/O processor (a.k.a. XP). [tsutsui 20161203] + axe(4): added support for AX88772A and AX88772B chipsets (from + FreeBSD) [skrll 20161204]
CVS commit: src/share/man/man4
Module Name:src Committed By: skrll Date: Sun Dec 4 11:31:55 UTC 2016 Modified Files: src/share/man/man4: axe.4 Log Message: Note all chipsets supported. Bump date. To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/share/man/man4/axe.4 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/share/man/man4/axe.4 diff -u src/share/man/man4/axe.4:1.8 src/share/man/man4/axe.4:1.9 --- src/share/man/man4/axe.4:1.8 Wed Jun 23 21:03:16 2010 +++ src/share/man/man4/axe.4 Sun Dec 4 11:31:55 2016 @@ -1,4 +1,4 @@ -.\" $NetBSD: axe.4,v 1.8 2010/06/23 21:03:16 wiz Exp $ +.\" $NetBSD: axe.4,v 1.9 2016/12/04 11:31:55 skrll Exp $ .\" .\" Copyright (c) 2003-2004 The NetBSD Foundation, Inc. .\" All rights reserved. @@ -60,7 +60,7 @@ .\" $FreeBSD: /repoman/r/ncvs/src/share/man/man4/axe.4,v 1.3 2003/05/29 21:28:35 ru Exp $ .\" $OpenBSD: axe.4,v 1.37 2009/11/08 20:25:29 jasper Exp $ .\" -.Dd June 23, 2010 +.Dd December 4, 2016 .Dt AXE 4 .Os .Sh NAME @@ -110,8 +110,8 @@ The .Nm driver provides support for USB .Tn Ethernet -adapters based on the ASIX Electronics AX88172, AX88178, and AX88772 -USB 2.0 chipsets. +adapters based on the ASIX Electronics AX88172, AX88178, AX88772, AX88772A, +AX88772B USB 2.0 chipsets. .Pp The chip contains a 10/100 .Tn Ethernet
CVS commit: xsrc/external/mit/xf86-video-glint/dist/src
Module Name:xsrc Committed By: martin Date: Sun Dec 4 10:58:12 UTC 2016 Modified Files: xsrc/external/mit/xf86-video-glint/dist/src: pm2_accel.c Log Message: Remove duplicate function To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 \ xsrc/external/mit/xf86-video-glint/dist/src/pm2_accel.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: xsrc/external/mit/xf86-video-glint/dist/src/pm2_accel.c diff -u xsrc/external/mit/xf86-video-glint/dist/src/pm2_accel.c:1.3 xsrc/external/mit/xf86-video-glint/dist/src/pm2_accel.c:1.4 --- xsrc/external/mit/xf86-video-glint/dist/src/pm2_accel.c:1.3 Fri Dec 2 22:58:26 2016 +++ xsrc/external/mit/xf86-video-glint/dist/src/pm2_accel.c Sun Dec 4 10:58:12 2016 @@ -141,107 +141,6 @@ static void Permedia2PolySegmentThinSoli # define STIPPLE_SWAP 0 #endif -void -Permedia2InitializeEngine(ScrnInfoPtr pScrn) -{ -GLINTPtr pGlint = GLINTPTR(pScrn); - -/* Initialize the Accelerator Engine to defaults */ - -TRACE_ENTER("Permedia2InitializeEngine"); - -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, ScissorMode); -GLINT_SLOW_WRITE_REG(UNIT_ENABLE, FBWriteMode); -GLINT_SLOW_WRITE_REG(0, dXSub); -GLINT_SLOW_WRITE_REG(GWIN_DisableLBUpdate, GLINTWindow); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, DitherMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, AlphaBlendMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, ColorDDAMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, TextureColorMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, TextureAddressMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, PMTextureReadMode); -GLINT_SLOW_WRITE_REG(pGlint->pprod, LBReadMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, AlphaBlendMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, TexelLUTMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, YUVMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, DepthMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, RouterMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, FogMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, AntialiasMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, AlphaTestMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, StencilMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, AreaStippleMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, LogicalOpMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, DepthMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, StatisticMode); -GLINT_SLOW_WRITE_REG(0x400, FilterMode); -GLINT_SLOW_WRITE_REG(0x, FBHardwareWriteMask); -GLINT_SLOW_WRITE_REG(0x, FBSoftwareWriteMask); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, RasterizerMode); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, GLINTDepth); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, FBSourceOffset); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, FBPixelOffset); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, LBSourceOffset); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, WindowOrigin); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, FBWindowBase); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, FBSourceBase); -GLINT_SLOW_WRITE_REG(UNIT_DISABLE, LBWindowBase); - -#if X_BYTE_ORDER == X_BIG_ENDIAN -pGlint->RasterizerSwap = 1; -#else -pGlint->RasterizerSwap = 0; -#endif - -switch (pScrn->bitsPerPixel) { - case 8: - pGlint->PixelWidth = 0x0; /* 8 Bits */ - pGlint->TexMapFormat = pGlint->pprod; -#if X_BYTE_ORDER == X_BIG_ENDIAN - pGlint->RasterizerSwap |= 3<<15; /* Swap host data */ -#endif - break; - case 16: - pGlint->PixelWidth = 0x1; /* 16 Bits */ - pGlint->TexMapFormat = pGlint->pprod | 1<<19; -#if X_BYTE_ORDER == X_BIG_ENDIAN - pGlint->RasterizerSwap |= 2<<15; /* Swap host data */ -#endif - break; - case 24: - pGlint->PixelWidth = 0x4; /* 24 Bits */ - pGlint->TexMapFormat = pGlint->pprod | 2<<19; - break; - case 32: - pGlint->PixelWidth = 0x2; /* 32 Bits */ - pGlint->TexMapFormat = pGlint->pprod | 2<<19; - break; -} -pGlint->ClippingOn = FALSE; -pGlint->startxdom = 0; -pGlint->startxsub = 0; -pGlint->starty = 0; -pGlint->count = 0; -pGlint->dy = 1<<16; -pGlint->dxdom = 0; -pGlint->x = 0; -pGlint->y = 0; -pGlint->h = 0; -pGlint->w = 0; -pGlint->ROP = 0xFF; -GLINT_SLOW_WRITE_REG(pGlint->PixelWidth, FBReadPixel); -GLINT_SLOW_WRITE_REG(pGlint->TexMapFormat, PMTextureMapFormat); -GLINT_SLOW_WRITE_REG(0, RectangleSize); -GLINT_SLOW_WRITE_REG(0, RectangleOrigin); -GLINT_SLOW_WRITE_REG(0, dXDom); -GLINT_SLOW_WRITE_REG(1<<16, dY); -GLINT_SLOW_WRITE_REG(0, StartXDom); -GLINT_SLOW_WRITE_REG(0, StartXSub); -GLINT_SLOW_WRITE_REG(0, StartY); -GLINT_SLOW_WRITE_REG(0, GLINTCount); - -TRACE_EXIT("Permedia2InitializeEngine"); -} #endif Bool
CVS commit: src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sun Dec 4 10:12:35 UTC 2016 Modified Files: src/sys/dev/usb: emdtv.c if_athn_usb.c if_aue.c if_urndisreg.h if_urtw.c if_urtwn.c ohci.c uberry.c ubsa.c ucom.c udl.c udsbr.c uhci.c uhidev.c uipad.c uirdavar.h uplcom.c urio.c usb_quirks.c usb_subr.c usbdi.c uscanner.c usscanner.c Log Message: Whitespace To generate a diff of this commit: cvs rdiff -u -r1.11 -r1.12 src/sys/dev/usb/emdtv.c src/sys/dev/usb/uberry.c cvs rdiff -u -r1.13 -r1.14 src/sys/dev/usb/if_athn_usb.c cvs rdiff -u -r1.138 -r1.139 src/sys/dev/usb/if_aue.c cvs rdiff -u -r1.2 -r1.3 src/sys/dev/usb/if_urndisreg.h cvs rdiff -u -r1.12 -r1.13 src/sys/dev/usb/if_urtw.c cvs rdiff -u -r1.51 -r1.52 src/sys/dev/usb/if_urtwn.c cvs rdiff -u -r1.264 -r1.265 src/sys/dev/usb/ohci.c cvs rdiff -u -r1.33 -r1.34 src/sys/dev/usb/ubsa.c cvs rdiff -u -r1.116 -r1.117 src/sys/dev/usb/ucom.c cvs rdiff -u -r1.18 -r1.19 src/sys/dev/usb/udl.c cvs rdiff -u -r1.25 -r1.26 src/sys/dev/usb/udsbr.c cvs rdiff -u -r1.273 -r1.274 src/sys/dev/usb/uhci.c cvs rdiff -u -r1.68 -r1.69 src/sys/dev/usb/uhidev.c cvs rdiff -u -r1.3 -r1.4 src/sys/dev/usb/uipad.c cvs rdiff -u -r1.6 -r1.7 src/sys/dev/usb/uirdavar.h cvs rdiff -u -r1.79 -r1.80 src/sys/dev/usb/uplcom.c \ src/sys/dev/usb/uscanner.c cvs rdiff -u -r1.45 -r1.46 src/sys/dev/usb/urio.c cvs rdiff -u -r1.85 -r1.86 src/sys/dev/usb/usb_quirks.c cvs rdiff -u -r1.216 -r1.217 src/sys/dev/usb/usb_subr.c cvs rdiff -u -r1.171 -r1.172 src/sys/dev/usb/usbdi.c cvs rdiff -u -r1.41 -r1.42 src/sys/dev/usb/usscanner.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/dev/usb/emdtv.c diff -u src/sys/dev/usb/emdtv.c:1.11 src/sys/dev/usb/emdtv.c:1.12 --- src/sys/dev/usb/emdtv.c:1.11 Sat Apr 23 10:15:31 2016 +++ src/sys/dev/usb/emdtv.c Sun Dec 4 10:12:35 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: emdtv.c,v 1.11 2016/04/23 10:15:31 skrll Exp $ */ +/* $NetBSD: emdtv.c,v 1.12 2016/12/04 10:12:35 skrll Exp $ */ /*- * Copyright (c) 2008, 2011 Jared D. McNeill@@ -27,7 +27,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: emdtv.c,v 1.11 2016/04/23 10:15:31 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: emdtv.c,v 1.12 2016/12/04 10:12:35 skrll Exp $"); #include #include @@ -162,7 +162,7 @@ emdtv_detach(device_t self, int flags) emdtv_dtv_detach(sc, flags); if (sc->sc_iface != NULL) { - status = usbd_set_interface(sc->sc_iface, 0); + status = usbd_set_interface(sc->sc_iface, 0); if (status != USBD_NORMAL_COMPLETION) aprint_error_dev(sc->sc_dev, "couldn't stop stream: %s\n", usbd_errstr(status)); @@ -383,7 +383,7 @@ emdtv_gpio_ctl(struct emdtv_softc *sc, e if (sc->sc_board->eb_manual_gpio == false) { val = eeprom_offset + gpioreg; - emdtv_write_1(sc, 0x03, 0xa0, val); + emdtv_write_1(sc, 0x03, 0xa0, val); gpio_value = emdtv_read_1(sc, 0x02, 0xa0); } else { const struct emdtv_gpio_regs *r = >eb_gpio_regs; Index: src/sys/dev/usb/uberry.c diff -u src/sys/dev/usb/uberry.c:1.11 src/sys/dev/usb/uberry.c:1.12 --- src/sys/dev/usb/uberry.c:1.11 Fri Nov 25 12:56:29 2016 +++ src/sys/dev/usb/uberry.c Sun Dec 4 10:12:35 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: uberry.c,v 1.11 2016/11/25 12:56:29 skrll Exp $ */ +/* $NetBSD: uberry.c,v 1.12 2016/12/04 10:12:35 skrll Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -37,7 +37,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: uberry.c,v 1.11 2016/11/25 12:56:29 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: uberry.c,v 1.12 2016/12/04 10:12:35 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_usb.h" @@ -73,7 +73,7 @@ int uberrydebug = 0; #endif struct uberry_softc { - device_t sc_dev; + device_t sc_dev; struct usbd_device * sc_udev; }; @@ -103,15 +103,15 @@ uberry_cmd(struct uberry_softc *sc, uint { usb_device_request_t req; usbd_status err; - + DPRINTF(("berry cmd type=%x, number=%x, value=%d, index=%d, len=%d\n", requestType, reqno, value, index, length)); req.bmRequestType = requestType; req.bRequest = reqno; -USETW(req.wValue, value); +USETW(req.wValue, value); USETW(req.wIndex, index); USETW(req.wLength, length); - + if ((err = usbd_do_request(sc->sc_udev, , data)) != 0) aprint_error_dev(sc->sc_dev, "sending command failed %d\n", err); @@ -156,7 +156,7 @@ uberry_dual_mode(struct uberry_softc *sc } -int +int uberry_match(device_t parent, cfdata_t match, void *aux) { struct usb_attach_arg *uaa = aux; @@ -166,7 +166,7 @@ uberry_match(device_t parent, cfdata_t m UMATCH_VENDOR_PRODUCT : UMATCH_NONE); } -void +void uberry_attach(device_t parent, device_t self, void *aux) { struct uberry_softc *sc = device_private(self); @@ -199,7 +199,7 @@ uberry_attach(device_t parent, device_t return; } -int +int
CVS commit: src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sun Dec 4 10:08:26 UTC 2016 Modified Files: src/sys/dev/usb: if_axe.c Log Message: Whitespace To generate a diff of this commit: cvs rdiff -u -r1.76 -r1.77 src/sys/dev/usb/if_axe.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/dev/usb/if_axe.c diff -u src/sys/dev/usb/if_axe.c:1.76 src/sys/dev/usb/if_axe.c:1.77 --- src/sys/dev/usb/if_axe.c:1.76 Sun Dec 4 10:07:06 2016 +++ src/sys/dev/usb/if_axe.c Sun Dec 4 10:08:26 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: if_axe.c,v 1.76 2016/12/04 10:07:06 skrll Exp $ */ +/* $NetBSD: if_axe.c,v 1.77 2016/12/04 10:08:26 skrll Exp $ */ /* $OpenBSD: if_axe.c,v 1.137 2016/04/13 11:03:37 mpi Exp $ */ /* @@ -87,7 +87,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.76 2016/12/04 10:07:06 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.77 2016/12/04 10:08:26 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -209,7 +209,7 @@ static const struct axe_type axe_devs[] { { USB_VENDOR_IODATA, USB_PRODUCT_IODATA_ETGUS2 }, AX178 }, { { USB_VENDOR_JVC, USB_PRODUCT_JVC_MP_PRX1}, 0 }, { { USB_VENDOR_LENOVO, USB_PRODUCT_LENOVO_ETHERNET }, AX772B }, - { { USB_VENDOR_LINKSYS, USB_PRODUCT_LINKSYS_HG20F9}, AX772B }, + { { USB_VENDOR_LINKSYS, USB_PRODUCT_LINKSYS_HG20F9}, AX772B }, { { USB_VENDOR_LINKSYS2, USB_PRODUCT_LINKSYS2_USB200M}, 0 }, { { USB_VENDOR_LINKSYS4, USB_PRODUCT_LINKSYS4_USB1000 }, AX178 }, { { USB_VENDOR_LOGITEC, USB_PRODUCT_LOGITEC_LAN_GTJU2}, AX178 }, @@ -325,7 +325,7 @@ axe_cmd(struct axe_softc *sc, int cmd, i static int axe_miibus_readreg_locked(device_t dev, int phy, int reg) { - AXEHIST_FUNC(); AXEHIST_CALLED(); + AXEHIST_FUNC(); AXEHIST_CALLED(); struct axe_softc *sc = device_private(dev); usbd_status err; uint16_t val;
CVS commit: src/sys/dev/usb
Module Name:src Committed By: skrll Date: Sun Dec 4 10:07:06 UTC 2016 Modified Files: src/sys/dev/usb: if_axe.c if_axereg.h Log Message: Sync with FreeBSD/OpenBSD and add support for 88772B devices. While I'm here convert to USB_DEBUG To generate a diff of this commit: cvs rdiff -u -r1.75 -r1.76 src/sys/dev/usb/if_axe.c cvs rdiff -u -r1.18 -r1.19 src/sys/dev/usb/if_axereg.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/usb/if_axe.c diff -u src/sys/dev/usb/if_axe.c:1.75 src/sys/dev/usb/if_axe.c:1.76 --- src/sys/dev/usb/if_axe.c:1.75 Fri Nov 25 12:56:29 2016 +++ src/sys/dev/usb/if_axe.c Sun Dec 4 10:07:06 2016 @@ -1,5 +1,5 @@ -/* $NetBSD: if_axe.c,v 1.75 2016/11/25 12:56:29 skrll Exp $ */ -/* $OpenBSD: if_axe.c,v 1.96 2010/01/09 05:33:08 jsg Exp $ */ +/* $NetBSD: if_axe.c,v 1.76 2016/12/04 10:07:06 skrll Exp $ */ +/* $OpenBSD: if_axe.c,v 1.137 2016/04/13 11:03:37 mpi Exp $ */ /* * Copyright (c) 2005, 2006, 2007 Jonathan Gray@@ -50,14 +50,8 @@ */ /* - * ASIX Electronics AX88172 USB 2.0 ethernet driver. Used in the - * LinkSys USB200M and various other adapters. - * - * Manuals available from: - * http://www.asix.com.tw/datasheet/mac/Ax88172.PDF - * Note: you need the manual for the AX88170 chip (USB 1.x ethernet - * controller) to find the definitions for the RX control register. - * http://www.asix.com.tw/datasheet/mac/Ax88170.PDF + * ASIX Electronics AX88172/AX88178/AX88778 USB 2.0 ethernet driver. + * Used in the LinkSys USB200M and various other adapters. * * Written by Bill Paul * Senior Engineer @@ -77,19 +71,23 @@ * to send any packets. * * Note that this device appears to only support loading the station - * address via autoload from the EEPROM (i.e. there's no way to manaully + * address via autoload from the EEPROM (i.e. there's no way to manually * set it). * * (Adam Weinberger wanted me to name this driver if_gir.c.) */ /* - * Ported to OpenBSD 3/28/2004 by Greg Taleck - * with bits and pieces from the aue and url drivers. + * Ax88178 and Ax88772 support backported from the OpenBSD driver. + * 2007/02/12, J.R. Oldroyd, f...@opal.com + * + * Manual here: + * http://www.asix.com.tw/FrootAttach/datasheet/AX88178_datasheet_Rev10.pdf + * http://www.asix.com.tw/FrootAttach/datasheet/AX88772_datasheet_Rev10.pdf */ #include -__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.75 2016/11/25 12:56:29 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1.76 2016/12/04 10:07:06 skrll Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -120,6 +118,7 @@ __KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1 #include #include +#include #include #include #include @@ -127,14 +126,62 @@ __KERNEL_RCSID(0, "$NetBSD: if_axe.c,v 1 #include -#ifdef AXE_DEBUG -#define DPRINTF(x) do { if (axedebug) printf x; } while (0) -#define DPRINTFN(n,x) do { if (axedebug >= (n)) printf x; } while (0) -int axedebug = 0; +/* + * AXE_178_MAX_FRAME_BURST + * max frame burst size for Ax88178 and Ax88772 + * 0 2048 bytes + * 1 4096 bytes + * 2 8192 bytes + * 3 16384 bytes + * use the largest your system can handle without USB stalling. + * + * NB: 88772 parts appear to generate lots of input errors with + * a 2K rx buffer and 8K is only slightly faster than 4K on an + * EHCI port on a T42 so change at your own risk. + */ +#define AXE_178_MAX_FRAME_BURST 1 + + +#ifdef USB_DEBUG +#ifndef AXE_DEBUG +#define axedebug 0 #else -#define DPRINTF(x) -#define DPRINTFN(n,x) -#endif +static int axedebug = 20; + +SYSCTL_SETUP(sysctl_hw_axe_setup, "sysctl hw.axe setup") +{ + int err; + const struct sysctlnode *rnode; + const struct sysctlnode *cnode; + + err = sysctl_createv(clog, 0, NULL, , + CTLFLAG_PERMANENT, CTLTYPE_NODE, "axe", + SYSCTL_DESCR("axe global controls"), + NULL, 0, NULL, 0, CTL_HW, CTL_CREATE, CTL_EOL); + + if (err) + goto fail; + + /* control debugging printfs */ + err = sysctl_createv(clog, 0, , , + CTLFLAG_PERMANENT|CTLFLAG_READWRITE, CTLTYPE_INT, + "debug", SYSCTL_DESCR("Enable debugging output"), + NULL, 0, , sizeof(axedebug), CTL_CREATE, CTL_EOL); + if (err) + goto fail; + + return; +fail: + aprint_error("%s: sysctl_createv failed (err = %d)\n", __func__, err); +} + +#endif /* AXE_DEBUG */ +#endif /* USB_DEBUG */ + +#define DPRINTF(FMT,A,B,C,D) USBHIST_LOGN(axedebug,1,FMT,A,B,C,D) +#define DPRINTFN(N,FMT,A,B,C,D) USBHIST_LOGN(axedebug,N,FMT,A,B,C,D) +#define AXEHIST_FUNC() USBHIST_FUNC() +#define AXEHIST_CALLED(name) USBHIST_CALLED(axedebug) /* * Various supported device vendors/products. @@ -146,22 +193,23 @@ static const struct axe_type axe_devs[] { { USB_VENDOR_ASIX, USB_PRODUCT_ASIX_AX88172}, 0 }, { { USB_VENDOR_ASIX, USB_PRODUCT_ASIX_AX88772}, AX772 }, { { USB_VENDOR_ASIX, USB_PRODUCT_ASIX_AX88772A}, AX772 }, - { { USB_VENDOR_ASIX,
CVS commit: src/sys/arch/i386/stand/lib
Module Name:src Committed By: maxv Date: Sun Dec 4 08:21:08 UTC 2016 Modified Files: src/sys/arch/i386/stand/lib: biosmem.S biosmemps2.S biosmemx.S exec.c multiboot.S startprog.S Log Message: KNF and explain a few things To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/arch/i386/stand/lib/biosmem.S \ src/sys/arch/i386/stand/lib/biosmemx.S cvs rdiff -u -r1.6 -r1.7 src/sys/arch/i386/stand/lib/biosmemps2.S cvs rdiff -u -r1.61 -r1.62 src/sys/arch/i386/stand/lib/exec.c cvs rdiff -u -r1.1 -r1.2 src/sys/arch/i386/stand/lib/multiboot.S cvs rdiff -u -r1.3 -r1.4 src/sys/arch/i386/stand/lib/startprog.S 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/i386/stand/lib/biosmem.S diff -u src/sys/arch/i386/stand/lib/biosmem.S:1.9 src/sys/arch/i386/stand/lib/biosmem.S:1.10 --- src/sys/arch/i386/stand/lib/biosmem.S:1.9 Thu Jun 16 13:27:59 2011 +++ src/sys/arch/i386/stand/lib/biosmem.S Sun Dec 4 08:21:08 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: biosmem.S,v 1.9 2011/06/16 13:27:59 joerg Exp $ */ +/* $NetBSD: biosmem.S,v 1.10 2016/12/04 08:21:08 maxv Exp $ */ /* * Copyright (c) 1996 @@ -36,8 +36,9 @@ .text -/* get mem below 1M, in kByte */ - +/* + * Get mem below 1M, in kByte. + */ ENTRY(getbasemem) pusha @@ -45,18 +46,19 @@ ENTRY(getbasemem) .code16 int $0x12 - # zero-extend 16-bit result to 32 bits. - movzwl %ax, %eax + /* Zero-extend 16-bit result to 32 bits */ + movzwl %ax,%eax calll _C_LABEL(real_to_prot) .code32 - movl %eax, 28(%esp) + movl %eax,28(%esp) popa ret -/* get mem above 1M, in kByte */ - +/* + * Get mem above 1M, in kByte. + */ ENTRY(getextmem1) pusha @@ -66,13 +68,13 @@ ENTRY(getextmem1) movb $0x88,%ah int $0x15 - # zero-extend 16-bit result to 32 bits. - movzwl %ax, %eax + /* Zero-extend 16-bit result to 32 bits */ + movzwl %ax,%eax calll _C_LABEL(real_to_prot) .code32 - movl %eax, 28(%esp) + movl %eax,28(%esp) popa ret Index: src/sys/arch/i386/stand/lib/biosmemx.S diff -u src/sys/arch/i386/stand/lib/biosmemx.S:1.9 src/sys/arch/i386/stand/lib/biosmemx.S:1.10 --- src/sys/arch/i386/stand/lib/biosmemx.S:1.9 Tue Oct 14 14:18:11 2008 +++ src/sys/arch/i386/stand/lib/biosmemx.S Sun Dec 4 08:21:08 2016 @@ -1,4 +1,4 @@ -/* $NetBSD: biosmemx.S,v 1.9 2008/10/14 14:18:11 ad Exp $ */ +/* $NetBSD: biosmemx.S,v 1.10 2016/12/04 08:21:08 maxv Exp $ */ /* * Copyright (c) 1997, 1999 @@ -30,11 +30,13 @@ .text -/* int getextmem2(int buffer[2]) - return: 0=OK, -1=error - buffer[0]: extmem kBytes below 16M (max 15M/1024) - buffer[1]: extmem above 16M, in 64k units -*/ +/* + * int getextmem2(int buffer[2]) + * + * return: 0=OK, -1=error + * buffer[0]: extmem kBytes below 16M (max 15M/1024) + * buffer[1]: extmem above 16M, in 64k units + */ ENTRY(getextmem2) pushl %ebp movl %esp,%ebp @@ -47,16 +49,16 @@ ENTRY(getextmem2) call _C_LABEL(prot_to_real) .code16 - xorl %ebx, %ebx - movl $0xe801, %eax + xorl %ebx,%ebx + movl $0xe801,%eax int $0x15 pushf - movw %si, %ax - orw %si, %bx + movw %si,%ax + orw %si,%bx jz 1f /* if zero use configured values */ - movw %cx, %ax /* k below 16M (max 0x3c00 = 15MB) */ - movw %dx, %bx /* 64k above 16M */ + movw %cx,%ax /* k below 16M (max 0x3c00 = 15MB) */ + movw %dx,%bx /* 64k above 16M */ 1: popf setc %bl @@ -64,13 +66,13 @@ ENTRY(getextmem2) calll _C_LABEL(real_to_prot) .code32 - movl 8(%ebp), %edi - xorl %eax, %eax - movw %cx, %ax + movl 8(%ebp),%edi + xorl %eax,%eax + movw %cx,%ax stosl - movw %dx, %ax + movw %dx,%ax stosl - movb %bl, %al + movb %bl,%al cbw pop %edi @@ -81,12 +83,14 @@ ENTRY(getextmem2) popl %ebp ret -/* int getmementry(int *iterator, buffer[5]) - return: 0=ok, else error - buffer[0]: start of memory chunk - buffer[2]: length (bytes) - buffer[4]: type -*/ +/* + * int getmementry(int *iterator, int buffer[5]) + * + * return: 0=ok, else error + * buffer[0]: start of memory chunk + * buffer[2]: length (bytes) + * buffer[4]: type + */ ENTRY(getmementry) pushl %ebp movl %esp,%ebp @@ -96,24 +100,24 @@ ENTRY(getmementry) push %esi push %edi - movl 8(%ebp), %eax - movl 0(%eax), %ebx /* index */ - movl $20, %ecx /* Buffer size */ - movl $0x534d4150, %edx /* "SMAP" */ - movl 12(%ebp), %edi /* buffer address */ + movl 8(%ebp),%eax + movl 0(%eax),%ebx /* index */ + movl $20,%ecx /* Buffer size */ + movl $0x534d4150,%edx /* "SMAP" */ + movl 12(%ebp),%edi /* buffer address */ call _C_LABEL(prot_to_real) .code16 push %di - shrl $4, %edi - mov %ds, %ax - add %di, %ax - mov %ax, %es + shrl $4,%edi + mov %ds,%ax + add %di,%ax + mov %ax,%es pop %di - and $0xf, %di /* buffer addres now in ES:DI */ + and $0xf,%di /* buffer addres now in ES:DI */ - movl $0xe820, %eax /* Some BIOS check EAX value */ + movl $0xe820,%eax /* Some BIOS check EAX value */ int $0x15 setc %cl @@