Re: svn commit: r290809 - in stable: 10/share/man/man9 10/sys/dev/pci 9/share/man/man9 9/sys/dev/pci
This commit breaks installworld. Index: share/man/man9/Makefile === --- share/man/man9/Makefile (revision 290818) +++ share/man/man9/Makefile (working copy) @@ -1032,7 +1032,7 @@ pci.9 pci_write_config.9 \ pci.9 pcie_adjust_config.9 \ pci.9 pcie_read_config.9 \ - pci.9 pcie_write_config.9 \ + pci.9 pcie_write_config.9 MLINKS+=pfil.9 pfil_add_hook.9 \ pfil.9 pfil_hook_get.9 \ pfil.9 pfil_remove_hook.9 Dne 14.11.2015 v 2:06 John Baldwin napsal(a): > Author: jhb > Date: Sat Nov 14 01:06:45 2015 > New Revision: 290809 > URL: https://svnweb.freebsd.org/changeset/base/290809 > > Log: > MFC 290414,290415: > Additional PCI helper functions. > > 290414: > Add helper routines for PCI device drivers to read, write, and modify > PCI-Express capability registers (that is, PCI config registers in the > standard PCI config space belonging to the PCI-Express capability > register set). > > Note that all of the current PCI-e registers are either 16 or 32-bits, > so only widths of 2 or 4 bytes are supported. > > 290415: > Add a new helper function for PCI devices to locate the upstream > PCI-express root port of a given PCI device. > > Modified: > stable/10/share/man/man9/Makefile > stable/10/share/man/man9/pci.9 > stable/10/sys/dev/pci/pci.c > stable/10/sys/dev/pci/pcivar.h > Directory Properties: > stable/10/ (props changed) > > Changes in other areas also in this revision: > Modified: > stable/9/share/man/man9/Makefile > stable/9/share/man/man9/pci.9 > stable/9/sys/dev/pci/pci.c > stable/9/sys/dev/pci/pcivar.h > Directory Properties: > stable/9/share/man/man9/ (props changed) > stable/9/sys/ (props changed) > stable/9/sys/dev/ (props changed) > > Modified: stable/10/share/man/man9/Makefile > == > --- stable/10/share/man/man9/Makefile Sat Nov 14 00:04:42 2015 > (r290808) > +++ stable/10/share/man/man9/Makefile Sat Nov 14 01:06:45 2015 > (r290809) > @@ -1014,6 +1014,7 @@ MLINKS+=pci.9 pci_alloc_msi.9 \ > pci.9 pci_find_device.9 \ > pci.9 pci_find_extcap.9 \ > pci.9 pci_find_htcap.9 \ > + pci.9 pci_find_pcie_root_port.9 \ > pci.9 pci_get_max_read_req.9 \ > pci.9 pci_get_powerstate.9 \ > pci.9 pci_get_vpd_ident.9 \ > @@ -1028,7 +1029,10 @@ MLINKS+=pci.9 pci_alloc_msi.9 \ > pci.9 pci_save_state.9 \ > pci.9 pci_set_powerstate.9 \ > pci.9 pci_set_max_read_req.9 \ > - pci.9 pci_write_config.9 > + pci.9 pci_write_config.9 \ > + pci.9 pcie_adjust_config.9 \ > + pci.9 pcie_read_config.9 \ > + pci.9 pcie_write_config.9 \ > MLINKS+=pfil.9 pfil_add_hook.9 \ > pfil.9 pfil_hook_get.9 \ > pfil.9 pfil_remove_hook.9 > > Modified: stable/10/share/man/man9/pci.9 > == > --- stable/10/share/man/man9/pci.9Sat Nov 14 00:04:42 2015 > (r290808) > +++ stable/10/share/man/man9/pci.9Sat Nov 14 01:06:45 2015 > (r290809) > @@ -25,7 +25,7 @@ > .\" > .\" $FreeBSD$ > .\" > -.Dd March 5, 2012 > +.Dd November 5, 2015 > .Dt PCI 9 > .Os > .Sh NAME > @@ -42,6 +42,7 @@ > .Nm pci_find_device , > .Nm pci_find_extcap , > .Nm pci_find_htcap , > +.Nm pci_find_pcie_root_port , > .Nm pci_get_max_read_req , > .Nm pci_get_powerstate , > .Nm pci_get_vpd_ident , > @@ -56,7 +57,10 @@ > .Nm pci_save_state , > .Nm pci_set_max_read_req , > .Nm pci_set_powerstate , > -.Nm pci_write_config > +.Nm pci_write_config , > +.Nm pcie_adjust_config , > +.Nm pcie_read_config , > +.Nm pcie_write_config > .Nd PCI bus interface > .Sh SYNOPSIS > .In sys/bus.h > @@ -86,6 +90,8 @@ > .Fn pci_find_extcap "device_t dev" "int capability" "int *capreg" > .Ft int > .Fn pci_find_htcap "device_t dev" "int capability" "int *capreg" > +.Ft device_t > +.Fn pci_find_pcie_root_port "device_t dev" > .Ft int > .Fn pci_get_max_read_req "device_t dev" > .Ft int > @@ -116,6 +122,18 @@ > .Fn pci_set_powerstate "device_t dev" "int state" > .Ft void > .Fn pci_write_config "device_t dev" "int reg" "uint32_t val" "int width" > +.Ft uint32_t > +.Fo pcie_adjust_config > +.Fa "device_t dev" > +.Fa "int reg" > +.Fa "uint32_t mask" > +.Fa "uint32_t val" > +.Fa "int width" > +.Fc > +.Ft uint32_t > +.Fn pcie_read_config "device_t dev" "int reg" "int width" > +.Ft void > +.Fn pcie_write_config "device_t dev" "int reg" "uint32_t val" "int width" > .Sh DESCRIPTION > The > .Nm > @@ -152,6 +170,48 @@ with > .Fa width > specifying the size of the access. > .Pp > +The > +.Fn pcie_adjust_config > +function is used to modify the value of a register in the PCI-express > +capability register set of device > +.Fa dev . > +The offset > +.Fa reg > +specifies a relative offset in the register set with > +.Fa width > +specifying the
svn commit: r290853 - stable/10/usr.sbin/rtadvd
Author: delphij Date: Sun Nov 15 07:10:02 2015 New Revision: 290853 URL: https://svnweb.freebsd.org/changeset/base/290853 Log: MFC r290173: Use strlcpy(). Modified: stable/10/usr.sbin/rtadvd/if.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.sbin/rtadvd/if.c == --- stable/10/usr.sbin/rtadvd/if.c Sun Nov 15 06:38:38 2015 (r290852) +++ stable/10/usr.sbin/rtadvd/if.c Sun Nov 15 07:10:02 2015 (r290853) @@ -359,8 +359,7 @@ update_persist_ifinfo(struct ifilist_hea ELM_MALLOC(ifi, exit(1)); ifi->ifi_ifindex = 0; - strncpy(ifi->ifi_ifname, ifname, sizeof(ifi->ifi_ifname)-1); - ifi->ifi_ifname[sizeof(ifi->ifi_ifname)-1] = '\0'; + strlcpy(ifi->ifi_ifname, ifname, sizeof(ifi->ifi_ifname)); ifi->ifi_rainfo = NULL; ifi->ifi_state = IFI_STATE_UNCONFIGURED; TAILQ_INSERT_TAIL(ifi_head, ifi, ifi_next); ___ svn-src-stable-10@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10 To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"
svn commit: r290854 - stable/10/usr.sbin/pw
Author: delphij Date: Sun Nov 15 07:14:17 2015 New Revision: 290854 URL: https://svnweb.freebsd.org/changeset/base/290854 Log: MFC r290174: In pw_userlock, set 'name' to NULL when we encounter an all number string because it is also used as an indicator of whether a name or an UID is being used and we may have undefined results as 'name' may contain uninitialized stack contents. Modified: stable/10/usr.sbin/pw/pw_user.c Directory Properties: stable/10/ (props changed) Modified: stable/10/usr.sbin/pw/pw_user.c == --- stable/10/usr.sbin/pw/pw_user.c Sun Nov 15 07:10:02 2015 (r290853) +++ stable/10/usr.sbin/pw/pw_user.c Sun Nov 15 07:14:17 2015 (r290854) @@ -280,9 +280,10 @@ pw_userlock(char *arg1, int mode) if (arg1 == NULL) errx(EX_DATAERR, "username or id required"); - if (arg1[strspn(arg1, "0123456789")] == '\0') + if (arg1[strspn(arg1, "0123456789")] == '\0') { id = pw_checkid(arg1, UID_MAX); - else + name = NULL; + } else name = arg1; pwd = (name != NULL) ? GETPWNAM(pw_checkname(name, 0)) : GETPWUID(id); ___ svn-src-stable-10@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10 To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"
Re: svn commit: r290014 - in stable/10: lib/libthr/arch/amd64 lib/libthr/arch/i386 libexec/rtld-elf/amd64 libexec/rtld-elf/i386 share/mk
On 26 Oct 2015, at 16:21, Eric van Gyzenwrote: > > One counter-argument to this change is that most applications already > use SIMD, and the number of applications and amount of SIMD usage > are only increasing. Note that SSE and SIMD are not the same thing. The x86-64 ABI uses SSE registers for floating point arguments, so even a purely scalar application that uses floating point will end up faulting in the SSE state. This is not the case on IA32, where x87 registers are used (though when compiling for i686, SSE is used by default because register allocation for x87 is a huge pain). I believe that the no-sse option for clang is ABI-preserving, so will not actually disable all SSE unless you also specify -msoft-float. I don’t think that libthr uses floating point anywhere, but libc does and you only need to call one function that takes a floating point argument in between context switches to lose this gain on x86-64. With this change, we’re making the compiler emit less efficient code, on the assumption that nothing will touch the fpu in the quantum before the next context switch. I’d really like to see the set of applications that you benchmarked the change with on x86-64 to reach the conclusion that this is a net win overall. Or, to put it another way: How many applications are multithreaded but don’t use any floating point code? David ___ svn-src-stable-10@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10 To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"
svn commit: r290826 - stable/10/share/man/man9
Author: bdrewery Date: Sat Nov 14 17:30:52 2015 New Revision: 290826 URL: https://svnweb.freebsd.org/changeset/base/290826 Log: MFC r290428: remove \, it confuses things. Modified: stable/10/share/man/man9/Makefile Directory Properties: stable/10/ (props changed) Modified: stable/10/share/man/man9/Makefile == --- stable/10/share/man/man9/Makefile Sat Nov 14 17:21:17 2015 (r290825) +++ stable/10/share/man/man9/Makefile Sat Nov 14 17:30:52 2015 (r290826) @@ -1032,7 +1032,7 @@ MLINKS+=pci.9 pci_alloc_msi.9 \ pci.9 pci_write_config.9 \ pci.9 pcie_adjust_config.9 \ pci.9 pcie_read_config.9 \ - pci.9 pcie_write_config.9 \ + pci.9 pcie_write_config.9 MLINKS+=pfil.9 pfil_add_hook.9 \ pfil.9 pfil_hook_get.9 \ pfil.9 pfil_remove_hook.9 ___ svn-src-stable-10@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10 To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"
Re: svn commit: r290809 - in stable: 10/share/man/man9 10/sys/dev/pci 9/share/man/man9 9/sys/dev/pci
On 11/14/2015 12:25 AM, Michal Meloun wrote: > This commit breaks installworld. Fixed. > > Index: share/man/man9/Makefile > === > --- share/man/man9/Makefile (revision 290818) > +++ share/man/man9/Makefile (working copy) > @@ -1032,7 +1032,7 @@ > pci.9 pci_write_config.9 \ > pci.9 pcie_adjust_config.9 \ > pci.9 pcie_read_config.9 \ > - pci.9 pcie_write_config.9 \ > + pci.9 pcie_write_config.9 > MLINKS+=pfil.9 pfil_add_hook.9 \ > pfil.9 pfil_hook_get.9 \ > pfil.9 pfil_remove_hook.9 > > > Dne 14.11.2015 v 2:06 John Baldwin napsal(a): >> Author: jhb >> Date: Sat Nov 14 01:06:45 2015 >> New Revision: 290809 >> URL: https://svnweb.freebsd.org/changeset/base/290809 >> >> Log: >> MFC 290414,290415: >> Additional PCI helper functions. >> -- Regards, Bryan Drewery signature.asc Description: OpenPGP digital signature