svn commit: r301433 - head/sys/dev/bwn
Author: adrian Date: Sun Jun 5 07:51:36 2016 New Revision: 301433 URL: https://svnweb.freebsd.org/changeset/base/301433 Log: [bwn] complain usefully if a PHY-N PHY is detected with no support is compiled in. Log something other than "error 6" if the attach fails because the GPL PHY-N code isn't included. Modified: head/sys/dev/bwn/if_bwn_phy_n.c Modified: head/sys/dev/bwn/if_bwn_phy_n.c == --- head/sys/dev/bwn/if_bwn_phy_n.c Sun Jun 5 07:45:55 2016 (r301432) +++ head/sys/dev/bwn/if_bwn_phy_n.c Sun Jun 5 07:51:36 2016 (r301433) @@ -101,6 +101,9 @@ bwn_phy_n_attach(struct bwn_mac *mac) #ifdef BWN_GPL_PHY return bwn_nphy_op_allocate(mac); #else + device_printf(mac->mac_sc->sc_dev, + "%s: BWN_GPL_PHY not in kernel config; " + "no PHY-N support\n", __func__); return (ENXIO); #endif } ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301434 - head/sys/dev/bwn
Author: adrian Date: Sun Jun 5 07:55:21 2016 New Revision: 301434 URL: https://svnweb.freebsd.org/changeset/base/301434 Log: [bwn] Enable PHY-LP 5GHz support for the one NIC I have tested it on so far. After perusing the PHY-LP code (don't ask why; honest) I discovered that it /has/ 5GHz support - but it's not ever used. I found one NIC - a BCM4312 w/ pci id 0x4315 - which advertised dual-band PHY-LP support. Turns out it works. Whilst here, move up the support bit logging code so I can use it to debug this. Tested: * BCM4312 (pci id 0x4315); 5GHz STA operation Modified: head/sys/dev/bwn/if_bwn.c Modified: head/sys/dev/bwn/if_bwn.c == --- head/sys/dev/bwn/if_bwn.c Sun Jun 5 07:51:36 2016(r301433) +++ head/sys/dev/bwn/if_bwn.c Sun Jun 5 07:55:21 2016(r301434) @@ -1163,6 +1163,16 @@ bwn_attach_core(struct bwn_mac *mac) have_bg = 1; have_a = 1; } +#if 0 + device_printf(sc->sc_dev, "%s: high=0x%08x, have_a=%d, have_bg=%d," + " deviceid=0x%04x, siba_deviceid=0x%04x\n", + __func__, + high, + have_a, + have_bg, + siba_get_pci_device(sc->sc_dev), + siba_get_chipid(sc->sc_dev)); +#endif } else { device_printf(sc->sc_dev, "%s: not siba; bailing\n", __func__); error = ENXIO; @@ -1183,18 +1193,12 @@ bwn_attach_core(struct bwn_mac *mac) if (error) goto fail; -#if 0 - device_printf(sc->sc_dev, "%s: high=0x%08x, have_a=%d, have_bg=%d," - " deviceid=0x%04x, siba_deviceid=0x%04x\n", - __func__, - high, - have_a, - have_bg, - siba_get_pci_device(sc->sc_dev), - siba_get_chipid(sc->sc_dev)); -#endif - + /* +* This is the whitelist of devices which we "believe" +* the SPROM PHY config from. The rest are "guessed". +*/ if (siba_get_pci_device(sc->sc_dev) != 0x4312 && + siba_get_pci_device(sc->sc_dev) != 0x4315 && siba_get_pci_device(sc->sc_dev) != 0x4319 && siba_get_pci_device(sc->sc_dev) != 0x4324 && siba_get_pci_device(sc->sc_dev) != 0x4328 && ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301435 - head/sys/dev/bwn
Author: adrian Date: Sun Jun 5 07:56:28 2016 New Revision: 301435 URL: https://svnweb.freebsd.org/changeset/base/301435 Log: [bwn] Add missing firmware release calls. This trips me up whenever I'm fooling around with partially supported NICs that fail to fully attach or initialise - the firmware gets loaded and references, but something fails - and the firmware references aren't cleaned up. Modified: head/sys/dev/bwn/if_bwn.c Modified: head/sys/dev/bwn/if_bwn.c == --- head/sys/dev/bwn/if_bwn.c Sun Jun 5 07:55:21 2016(r301434) +++ head/sys/dev/bwn/if_bwn.c Sun Jun 5 07:56:28 2016(r301435) @@ -750,6 +750,7 @@ bwn_detach(device_t dev) if (mac->mac_msi != 0) pci_release_msi(dev); mbufq_drain(&sc->sc_snd); + bwn_release_firmware(mac); BWN_LOCK_DESTROY(sc); return (0); } @@ -1328,6 +1329,7 @@ bwn_attach_core(struct bwn_mac *mac) siba_dev_down(sc->sc_dev, 0); fail: siba_powerdown(sc->sc_dev); + bwn_release_firmware(mac); return (error); } @@ -3930,6 +3932,7 @@ bwn_fw_gets(struct bwn_mac *mac, enum bw } } else if (rev < 11) { device_printf(sc->sc_dev, "no PCM for rev %d\n", rev); + bwn_release_firmware(mac); return (EOPNOTSUPP); } ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r301434 - head/sys/dev/bwn
note: this works on RX only; TX seems to fail right now and I'm not yet sure why. I'll dig into it. Thanks, -adrian On 5 June 2016 at 00:55, Adrian Chadd wrote: > Author: adrian > Date: Sun Jun 5 07:55:21 2016 > New Revision: 301434 > URL: https://svnweb.freebsd.org/changeset/base/301434 > > Log: > [bwn] Enable PHY-LP 5GHz support for the one NIC I have tested it on so far. > > After perusing the PHY-LP code (don't ask why; honest) I discovered that > it /has/ 5GHz support - but it's not ever used. I found one NIC - a > BCM4312 w/ pci id 0x4315 - which advertised dual-band PHY-LP support. > > Turns out it works. > > Whilst here, move up the support bit logging code so I can use it > to debug this. > > Tested: > > * BCM4312 (pci id 0x4315); 5GHz STA operation > > Modified: > head/sys/dev/bwn/if_bwn.c > > Modified: head/sys/dev/bwn/if_bwn.c > == > --- head/sys/dev/bwn/if_bwn.c Sun Jun 5 07:51:36 2016(r301433) > +++ head/sys/dev/bwn/if_bwn.c Sun Jun 5 07:55:21 2016(r301434) > @@ -1163,6 +1163,16 @@ bwn_attach_core(struct bwn_mac *mac) > have_bg = 1; > have_a = 1; > } > +#if 0 > + device_printf(sc->sc_dev, "%s: high=0x%08x, have_a=%d, > have_bg=%d," > + " deviceid=0x%04x, siba_deviceid=0x%04x\n", > + __func__, > + high, > + have_a, > + have_bg, > + siba_get_pci_device(sc->sc_dev), > + siba_get_chipid(sc->sc_dev)); > +#endif > } else { > device_printf(sc->sc_dev, "%s: not siba; bailing\n", > __func__); > error = ENXIO; > @@ -1183,18 +1193,12 @@ bwn_attach_core(struct bwn_mac *mac) > if (error) > goto fail; > > -#if 0 > - device_printf(sc->sc_dev, "%s: high=0x%08x, have_a=%d, have_bg=%d," > - " deviceid=0x%04x, siba_deviceid=0x%04x\n", > - __func__, > - high, > - have_a, > - have_bg, > - siba_get_pci_device(sc->sc_dev), > - siba_get_chipid(sc->sc_dev)); > -#endif > - > + /* > +* This is the whitelist of devices which we "believe" > +* the SPROM PHY config from. The rest are "guessed". > +*/ > if (siba_get_pci_device(sc->sc_dev) != 0x4312 && > + siba_get_pci_device(sc->sc_dev) != 0x4315 && > siba_get_pci_device(sc->sc_dev) != 0x4319 && > siba_get_pci_device(sc->sc_dev) != 0x4324 && > siba_get_pci_device(sc->sc_dev) != 0x4328 && > ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r301414 - head/sys/dev/filemon
On Sat, Jun 04, 2016 at 11:34:51PM +, Bryan Drewery wrote: > Author: bdrewery > Date: Sat Jun 4 23:34:51 2016 > New Revision: 301414 > URL: https://svnweb.freebsd.org/changeset/base/301414 > > Log: > Fix build after r301404. > > X-MFC-With: r301404 > MFC after: 1 week > > Modified: > head/sys/dev/filemon/filemon_wrapper.c > > Modified: head/sys/dev/filemon/filemon_wrapper.c > == > --- head/sys/dev/filemon/filemon_wrapper.cSat Jun 4 21:34:06 2016 > (r301413) > +++ head/sys/dev/filemon/filemon_wrapper.cSat Jun 4 23:34:51 2016 > (r301414) > @@ -39,6 +39,10 @@ __FBSDID("$FreeBSD$"); > > #include "opt_compat.h" > > +#if defined(COMPAT_IA32) || defined(COMPAT_FREEBSD32) || > defined(COMPAT_ARCH32) What are those COMPAT_IA32 and COMPAT_ARCH32 defines ? I cannot find any use or definitions for them except in filemon. Are the symbols remnants of some porting ? > +extern struct sysent freebsd32_sysent[]; > +#endif > + > static eventhandler_tag filemon_exec_tag; > static eventhandler_tag filemon_exit_tag; > static eventhandler_tag filemon_fork_tag; ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301437 - in head: sys/cam/ctl sys/dev/iscsi usr.bin/iscsictl usr.sbin/ctladm usr.sbin/ctld
Author: trasz Date: Sun Jun 5 08:48:37 2016 New Revision: 301437 URL: https://svnweb.freebsd.org/changeset/base/301437 Log: Report negotiated MaxBurstLength and FirstBurstLength in "iscsictl -v" and "ctladm islist -v" outputs. MFC after:1 month Modified: head/sys/cam/ctl/ctl_frontend_iscsi.c head/sys/cam/ctl/ctl_frontend_iscsi.h head/sys/dev/iscsi/iscsi.c head/sys/dev/iscsi/iscsi_ioctl.h head/usr.bin/iscsictl/iscsictl.c head/usr.sbin/ctladm/ctladm.c head/usr.sbin/ctld/ctld.h head/usr.sbin/ctld/kernel.c head/usr.sbin/ctld/login.c Modified: head/sys/cam/ctl/ctl_frontend_iscsi.c == --- head/sys/cam/ctl/ctl_frontend_iscsi.c Sun Jun 5 08:42:33 2016 (r301436) +++ head/sys/cam/ctl/ctl_frontend_iscsi.c Sun Jun 5 08:48:37 2016 (r301437) @@ -1514,6 +1514,7 @@ cfiscsi_ioctl_handoff(struct ctl_iscsi * cs->cs_statsn = cihp->statsn; cs->cs_max_data_segment_length = cihp->max_recv_data_segment_length; cs->cs_max_burst_length = cihp->max_burst_length; + cs->cs_first_burst_length = cihp->first_burst_length; cs->cs_immediate_data = !!cihp->immediate_data; if (cihp->header_digest == CTL_ISCSI_DIGEST_CRC32C) cs->cs_conn->ic_header_crc32c = true; @@ -1652,6 +1653,8 @@ cfiscsi_ioctl_list(struct ctl_iscsi *ci) "%s" "%s" "%zd" + "%zd" + "%zd" "%d" "%d" "%s" @@ -1663,6 +1666,8 @@ cfiscsi_ioctl_list(struct ctl_iscsi *ci) cs->cs_conn->ic_header_crc32c ? "CRC32C" : "None", cs->cs_conn->ic_data_crc32c ? "CRC32C" : "None", cs->cs_max_data_segment_length, + cs->cs_max_burst_length, + cs->cs_first_burst_length, cs->cs_immediate_data, cs->cs_conn->ic_iser, cs->cs_conn->ic_offload); Modified: head/sys/cam/ctl/ctl_frontend_iscsi.h == --- head/sys/cam/ctl/ctl_frontend_iscsi.h Sun Jun 5 08:42:33 2016 (r301436) +++ head/sys/cam/ctl/ctl_frontend_iscsi.h Sun Jun 5 08:48:37 2016 (r301437) @@ -86,6 +86,7 @@ struct cfiscsi_session { boolcs_tasks_aborted; size_t cs_max_data_segment_length; size_t cs_max_burst_length; + size_t cs_first_burst_length; boolcs_immediate_data; charcs_initiator_name[CTL_ISCSI_NAME_LEN]; charcs_initiator_addr[CTL_ISCSI_ADDR_LEN]; Modified: head/sys/dev/iscsi/iscsi.c == --- head/sys/dev/iscsi/iscsi.c Sun Jun 5 08:42:33 2016(r301436) +++ head/sys/dev/iscsi/iscsi.c Sun Jun 5 08:48:37 2016(r301437) @@ -1934,6 +1934,8 @@ iscsi_ioctl_session_list(struct iscsi_so iss.iss_data_digest = ISCSI_DIGEST_NONE; iss.iss_max_data_segment_length = is->is_max_data_segment_length; + iss.iss_max_burst_length = is->is_max_burst_length; + iss.iss_first_burst_length = is->is_first_burst_length; iss.iss_immediate_data = is->is_immediate_data; iss.iss_connected = is->is_connected; Modified: head/sys/dev/iscsi/iscsi_ioctl.h == --- head/sys/dev/iscsi/iscsi_ioctl.hSun Jun 5 08:42:33 2016 (r301436) +++ head/sys/dev/iscsi/iscsi_ioctl.hSun Jun 5 08:48:37 2016 (r301437) @@ -93,7 +93,8 @@ struct iscsi_session_state { int iss_connected; chariss_reason[ISCSI_REASON_LEN]; chariss_offload[ISCSI_OFFLOAD_LEN]; - int iss_spare[2]; + int iss_max_burst_length; + int iss_first_burst_length; }; /* Modified: head/usr.bin/iscsictl/iscsictl.c == --- head/usr.bin/iscsictl/iscsictl.cSun Jun 5 08:42:33 2016 (r301436) +++ head/usr.bin/iscsictl/iscsictl.cSun Jun 5 08:48:37 2016 (r301437) @@ -567,6 +567,10 @@ kernel_list(int iscsi_fd, const struct t "CRC32C" : "None"); xo_emit("{L:/%-18s}{V:dataSegmentLen/%d}\n", "DataSegmentLen:", state->iss_max_data_segment_length); + xo_emit("{L:/%-18s}{V:maxBurstLen/%d}\n", + "MaxBurstLen:", state->iss_max_burst_length); +
svn commit: r301438 - head/usr.sbin/ctladm
Author: trasz Date: Sun Jun 5 08:51:56 2016 New Revision: 301438 URL: https://svnweb.freebsd.org/changeset/base/301438 Log: Remove duplicated semicolons. MFC after:1 month Modified: head/usr.sbin/ctladm/ctladm.c Modified: head/usr.sbin/ctladm/ctladm.c == --- head/usr.sbin/ctladm/ctladm.c Sun Jun 5 08:48:37 2016 (r301437) +++ head/usr.sbin/ctladm/ctladm.c Sun Jun 5 08:51:56 2016 (r301438) @@ -2794,10 +2794,10 @@ struct cctl_islist_conn { char *target_alias; char *header_digest; char *data_digest; - char *max_data_segment_length;; - char *max_burst_length;; - char *first_burst_length;; - char *offload;; + char *max_data_segment_length; + char *max_burst_length; + char *first_burst_length; + char *offload; int immediate_data; int iser; STAILQ_ENTRY(cctl_islist_conn) links; ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301439 - head/contrib/libucl/src
Author: bapt Date: Sun Jun 5 09:38:48 2016 New Revision: 301439 URL: https://svnweb.freebsd.org/changeset/base/301439 Log: Ensure old gcc does not accidently get the attributes it does not know about Modified: head/contrib/libucl/src/mum.h Modified: head/contrib/libucl/src/mum.h == --- head/contrib/libucl/src/mum.h Sun Jun 5 08:51:56 2016 (r301438) +++ head/contrib/libucl/src/mum.h Sun Jun 5 09:38:48 2016 (r301439) @@ -73,7 +73,7 @@ typedef unsigned __int64 uint64_t; #define _MUM_FRESH_GCC #endif -#if defined(__GNUC__) && !defined(__llvm__) +#if defined(__GNUC__) && !defined(__llvm__) && defined(_MUM_FRESH_GCC) #define _MUM_ATTRIBUTE_UNUSED __attribute__((unused)) #define _MUM_OPTIMIZE(opts) __attribute__((__optimize__ (opts))) #define _MUM_TARGET(opts) __attribute__((__target__ (opts))) ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301440 - head/sys/netpfil/ipfw
Author: melifaro Date: Sun Jun 5 10:33:53 2016 New Revision: 301440 URL: https://svnweb.freebsd.org/changeset/base/301440 Log: Fix 4-byte overflow in ipv6_writemask. This bug could cause some IPv6 table prefix delete requests to fail. Obtained from:Yandex LLC Modified: head/sys/netpfil/ipfw/ip_fw_table_algo.c Modified: head/sys/netpfil/ipfw/ip_fw_table_algo.c == --- head/sys/netpfil/ipfw/ip_fw_table_algo.cSun Jun 5 09:38:48 2016 (r301439) +++ head/sys/netpfil/ipfw/ip_fw_table_algo.cSun Jun 5 10:33:53 2016 (r301440) @@ -590,7 +590,8 @@ ipv6_writemask(struct in6_addr *addr6, u for (cp = (uint32_t *)addr6; mask >= 32; mask -= 32) *cp++ = 0x; - *cp = htonl(mask ? ~((1 << (32 - mask)) - 1) : 0); + if (mask > 0) + *cp = htonl(mask ? ~((1 << (32 - mask)) - 1) : 0); } #endif ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301442 - head/contrib/libucl/src
Author: bapt Date: Sun Jun 5 11:56:03 2016 New Revision: 301442 URL: https://svnweb.freebsd.org/changeset/base/301442 Log: Fix build with external gcc Completly disable some extra optimisation for very recent gcc. They would require some updated in the runtime which we do not have yet Modified: head/contrib/libucl/src/mum.h Modified: head/contrib/libucl/src/mum.h == --- head/contrib/libucl/src/mum.h Sun Jun 5 10:48:27 2016 (r301441) +++ head/contrib/libucl/src/mum.h Sun Jun 5 11:56:03 2016 (r301442) @@ -69,9 +69,11 @@ typedef unsigned __int64 uint64_t; #endif #endif +#if 0 #if defined(__GNUC__) && ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 9) || (__GNUC__ > 4)) #define _MUM_FRESH_GCC #endif +#endif #if defined(__GNUC__) && !defined(__llvm__) && defined(_MUM_FRESH_GCC) #define _MUM_ATTRIBUTE_UNUSED __attribute__((unused)) ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r301414 - head/sys/dev/filemon
Konstantin Belousov wrote: > > Modified: head/sys/dev/filemon/filemon_wrapper.c > > > === > > > > +#if defined(COMPAT_IA32) || defined(COMPAT_FREEBSD32) || > > defined(COMPAT_ARCH32) > What are those COMPAT_IA32 and COMPAT_ARCH32 defines ? > I cannot find any use or definitions for them except in filemon. > > Are the symbols remnants of some porting ? I think it was originally written for 7.x but AFAIK it was never built for anything but FreeBSD. It is possible that the original author was thinking of making it portable to other platforms, but separate implementations were done for NetBSD and Linux. ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301448 - head/lib/libc/stdlib
Author: ache Date: Sun Jun 5 15:46:14 2016 New Revision: 301448 URL: https://svnweb.freebsd.org/changeset/base/301448 Log: Reflect error indication according to POSIX and what those functions currently do. Modified: head/lib/libc/stdlib/random.3 Modified: head/lib/libc/stdlib/random.3 == --- head/lib/libc/stdlib/random.3 Sun Jun 5 15:05:53 2016 (r301447) +++ head/lib/libc/stdlib/random.3 Sun Jun 5 15:46:14 2016 (r301448) @@ -174,8 +174,8 @@ If .Fn initstate is called with less than 8 bytes of state information, or if .Fn setstate -detects that the state information has been garbled, error -messages are printed on the standard error output. +detects that the state information has been garbled, +NULL is returned. .Sh SEE ALSO .Xr arc4random 3 , .Xr lrand48 3 , ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301451 - in head/sys: kern sys
Author: skra Date: Sun Jun 5 16:07:57 2016 New Revision: 301451 URL: https://svnweb.freebsd.org/changeset/base/301451 Log: (1) Add a new bus method to get a mapping data for an interrupt. BUS_MAP_INTR() is used to get an interrupt mapping data according to provided hints. The hints could be modified afterwards, but only if mapping data was allocated. This method is intended to be called before BUS_ALLOC_RESOURCE(). An interrupt mapping data describes an interrupt - hardware number, type, configuration, cpu binding, and whatever is needed to setup it. (2) Introduce a method which allows storing of an additional data in struct resource to be available for bus drivers. This method is convenient in two ways: - there is no need to rework existing bus drivers as they can simply be extended to provide an additional data, - there is no need to modify any existing bus methods as struct resource is already passed to them as argument and thus stored data is simply accessible by other bus drivers. For now, implement this method only for INTRNG. This is motivated by needs of modern SOCs where hardware initialization is not straightforward and resources descriptions are complex, opaque for everyone but provider, and may vary from SOC to SOC. Typical situation is that one bus driver can fetch a resource description for its child device, but it's opaque for this driver. Another bus driver knows a provider for this kind of resource and can pass this resource description to it. In fact, something like device IVARS would be perfect for that if implemented generally enough. Unfortunatelly, IVARS are usable only by their owners now. Only owner knows its IVARS layout, thus other bus drivers are not able to use them. Differential Revision:https://reviews.freebsd.org/D6632 Modified: head/sys/kern/bus_if.m head/sys/kern/subr_bus.c head/sys/kern/subr_intr.c head/sys/sys/bus.h head/sys/sys/intr.h Modified: head/sys/kern/bus_if.m == --- head/sys/kern/bus_if.m Sun Jun 5 15:57:32 2016(r301450) +++ head/sys/kern/bus_if.m Sun Jun 5 16:07:57 2016(r301451) @@ -418,6 +418,35 @@ METHOD int release_resource { }; /** + * @brief Map an interrupt + * + * This method is used to get an interrupt mapping data according to provided + * hints. The hints could be modified afterwards, but only if mapping data was + * allocated. This method is intended to be called before BUS_ALLOC_RESOURCE(). + * + * @param _dev the parent device of @p _child + * @param _child the device which is requesting an allocation + * @param _rid a pointer to the resource identifier + * @param _start a pointer to the hint at the start of the resource + * range - pass @c 0 for any start address + * @param _end a pointer to the hint at the end of the resource + * range - pass @c ~0 for any end address + * @param _count a pointer to the hint at the size of resource + * range required - pass @c 1 for any size + * @param _imd a pointer to the interrupt mapping data which was + * allocated + */ +METHOD int map_intr { + device_t_dev; + device_t_child; + int *_rid; + rman_res_t *_start; + rman_res_t *_end; + rman_res_t *_count; + struct intr_map_data **_imd; +} DEFAULT bus_generic_map_intr; + +/** * @brief Install an interrupt handler * * This method is used to associate an interrupt handler function with Modified: head/sys/kern/subr_bus.c == --- head/sys/kern/subr_bus.cSun Jun 5 15:57:32 2016(r301450) +++ head/sys/kern/subr_bus.cSun Jun 5 16:07:57 2016(r301451) @@ -3951,6 +3951,23 @@ bus_generic_new_pass(device_t dev) } /** + * @brief Helper function for implementing BUS_MAP_INTR(). + * + * This simple implementation of BUS_MAP_INTR() simply calls the + * BUS_MAP_INTR() method of the parent of @p dev. + */ +int +bus_generic_map_intr(device_t dev, device_t child, int *rid, rman_res_t *start, +rman_res_t *end, rman_res_t *count, struct intr_map_data **imd) +{ + /* Propagate up the bus hierarchy until someone handles it. */ + if (dev->parent) + return (BUS_MAP_INTR(dev->parent, child, rid, start, end, count, + imd)); + return (EINVAL); +} + +/** * @brief Helper function for implementing BUS_SETUP_INTR(). * * This simple implementation of BUS_SETUP_INTR() simply calls the @@ -4405,6 +4422,41 @@ bus_release_resources(device_t dev, cons } } +#ifdef INTRNG +/** + * @internal + * + * This can be converted to bus method later. (XXX) + */ +static struct intr_map_data * +bus_extend_resource(
svn commit: r301452 - head/bin/sh
Author: jilles Date: Sun Jun 5 16:09:31 2016 New Revision: 301452 URL: https://svnweb.freebsd.org/changeset/base/301452 Log: sh: Improve descriptions in 'ulimit -a' output. The format limits descriptions to 18 characters and is not changed, so the descriptions do not describe the limits exactly. Modified: head/bin/sh/miscbltin.c Modified: head/bin/sh/miscbltin.c == --- head/bin/sh/miscbltin.c Sun Jun 5 16:07:57 2016(r301451) +++ head/bin/sh/miscbltin.c Sun Jun 5 16:09:31 2016(r301452) @@ -406,7 +406,7 @@ static const struct limits limits[] = { { "swap limit", "kbytes", RLIMIT_SWAP,1024, 'w' }, #endif #ifdef RLIMIT_SBSIZE - { "sbsize", "bytes",RLIMIT_SBSIZE, 1, 'b' }, + { "socket buffer size", "bytes",RLIMIT_SBSIZE, 1, 'b' }, #endif #ifdef RLIMIT_NPTS { "pseudo-terminals", (char *)0, RLIMIT_NPTS, 1, 'p' }, @@ -415,7 +415,7 @@ static const struct limits limits[] = { { "kqueues",(char *)0, RLIMIT_KQUEUES,1, 'k' }, #endif #ifdef RLIMIT_UMTXP - { "umtxp", (char *)0, RLIMIT_UMTXP, 1, 'o' }, + { "umtx shared locks", (char *)0, RLIMIT_UMTXP, 1, 'o' }, #endif { (char *) 0, (char *)0, 0, 0, '\0' } }; ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301453 - in head/sys: arm/arm arm64/arm64 dev/fdt dev/gpio dev/iicbus dev/ofw dev/pci dev/vnic kern mips/mips sys
Author: skra Date: Sun Jun 5 16:20:12 2016 New Revision: 301453 URL: https://svnweb.freebsd.org/changeset/base/301453 Log: INTRNG - change the way how an interrupt mapping data are provided to the framework in OFW (FDT) case. This is a follow-up to r301451. Differential Revision:https://reviews.freebsd.org/D6634 Modified: head/sys/arm/arm/nexus.c head/sys/arm64/arm64/gic_v3.c head/sys/arm64/arm64/nexus.c head/sys/dev/fdt/simplebus.c head/sys/dev/gpio/ofw_gpiobus.c head/sys/dev/iicbus/ofw_iicbus.c head/sys/dev/ofw/ofw_bus_subr.c head/sys/dev/ofw/ofw_bus_subr.h head/sys/dev/ofw/ofwbus.c head/sys/dev/pci/pci_host_generic.c head/sys/dev/vnic/mrml_bridge.c head/sys/dev/vnic/thunder_mdio_fdt.c head/sys/kern/subr_intr.c head/sys/mips/mips/nexus.c head/sys/sys/intr.h Modified: head/sys/arm/arm/nexus.c == --- head/sys/arm/arm/nexus.cSun Jun 5 16:09:31 2016(r301452) +++ head/sys/arm/arm/nexus.cSun Jun 5 16:20:12 2016(r301453) @@ -412,6 +412,10 @@ nexus_ofw_map_intr(device_t dev, device_ pcell_t *intr) { +#ifdef INTRNG + return (INTR_IRQ_INVALID); +#else return (intr_fdt_map_irq(iparent, intr, icells)); +#endif } #endif Modified: head/sys/arm64/arm64/gic_v3.c == --- head/sys/arm64/arm64/gic_v3.c Sun Jun 5 16:09:31 2016 (r301452) +++ head/sys/arm64/arm64/gic_v3.c Sun Jun 5 16:20:12 2016 (r301453) @@ -58,6 +58,10 @@ __FBSDID("$FreeBSD$"); #include #include +#ifdef FDT +#include +#endif + #include "pic_if.h" #include "gic_v3_reg.h" Modified: head/sys/arm64/arm64/nexus.c == --- head/sys/arm64/arm64/nexus.cSun Jun 5 16:09:31 2016 (r301452) +++ head/sys/arm64/arm64/nexus.cSun Jun 5 16:20:12 2016 (r301453) @@ -448,7 +448,7 @@ nexus_ofw_map_intr(device_t dev, device_ pcell_t *intr) { #ifdef INTRNG - return (intr_fdt_map_irq(iparent, intr, icells)); + return (INTR_IRQ_INVALID); #else int irq; Modified: head/sys/dev/fdt/simplebus.c == --- head/sys/dev/fdt/simplebus.cSun Jun 5 16:09:31 2016 (r301452) +++ head/sys/dev/fdt/simplebus.cSun Jun 5 16:20:12 2016 (r301453) @@ -251,7 +251,9 @@ simplebus_setup_dinfo(device_t dev, phan resource_list_init(&ndi->rl); ofw_bus_reg_to_rl(dev, node, sc->acells, sc->scells, &ndi->rl); +#ifndef INTRNG ofw_bus_intr_to_rl(dev, node, &ndi->rl, NULL); +#endif return (ndi); } Modified: head/sys/dev/gpio/ofw_gpiobus.c == --- head/sys/dev/gpio/ofw_gpiobus.c Sun Jun 5 16:09:31 2016 (r301452) +++ head/sys/dev/gpio/ofw_gpiobus.c Sun Jun 5 16:20:12 2016 (r301453) @@ -321,11 +321,13 @@ ofw_gpiobus_setup_devinfo(device_t bus, devi->pins[i] = pins[i].pin; } free(pins, M_DEVBUF); +#ifndef INTRNG /* Parse the interrupt resources. */ if (ofw_bus_intr_to_rl(bus, node, &dinfo->opd_dinfo.rl, NULL) != 0) { ofw_gpiobus_destroy_devinfo(bus, dinfo); return (NULL); } +#endif device_set_ivars(child, dinfo); return (dinfo); Modified: head/sys/dev/iicbus/ofw_iicbus.c == --- head/sys/dev/iicbus/ofw_iicbus.cSun Jun 5 16:09:31 2016 (r301452) +++ head/sys/dev/iicbus/ofw_iicbus.cSun Jun 5 16:20:12 2016 (r301453) @@ -187,8 +187,10 @@ ofw_iicbus_attach(device_t dev) childdev = device_add_child(dev, NULL, -1); resource_list_init(&dinfo->opd_dinfo.rl); +#ifndef INTRNG ofw_bus_intr_to_rl(childdev, child, &dinfo->opd_dinfo.rl, NULL); +#endif device_set_ivars(childdev, dinfo); } Modified: head/sys/dev/ofw/ofw_bus_subr.c == --- head/sys/dev/ofw/ofw_bus_subr.c Sun Jun 5 16:09:31 2016 (r301452) +++ head/sys/dev/ofw/ofw_bus_subr.c Sun Jun 5 16:20:12 2016 (r301453) @@ -516,6 +516,7 @@ ofw_bus_find_iparent(phandle_t node) return (iparent); } +#ifndef INTRNG int ofw_bus_intr_to_rl(device_t dev, phandle_t node, struct resource_list *rl, int *rlen) @@ -581,6 +582,78 @@ ofw_bus_intr_to_rl(device_t dev, phandle free(intr, M_OFWPROP); return (err); } +#endif + +int +ofw_bus_intr_by_rid(device_t dev, phandle_t node, int wanted_rid, +phandle_t *producer, int *ncells, pcell_t **cells) +{ + phandle_t iparent
svn commit: r301455 - head/sys/kern
Author: kib Date: Sun Jun 5 16:55:55 2016 New Revision: 301455 URL: https://svnweb.freebsd.org/changeset/base/301455 Log: Use ANSI function definition. Sponsored by: The FreeBSD Foundation Modified: head/sys/kern/kern_proc.c Modified: head/sys/kern/kern_proc.c == --- head/sys/kern/kern_proc.c Sun Jun 5 16:21:53 2016(r301454) +++ head/sys/kern/kern_proc.c Sun Jun 5 16:55:55 2016(r301455) @@ -168,7 +168,7 @@ CTASSERT(sizeof(struct kinfo_proc32) == * Initialize global process hashing structures. */ void -procinit() +procinit(void) { sx_init(&allproc_lock, "allproc"); ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301456 - in head/sys: kern mips/mips sys
Author: kib Date: Sun Jun 5 17:04:03 2016 New Revision: 301456 URL: https://svnweb.freebsd.org/changeset/base/301456 Log: Get rid of struct proc p_sched and struct thread td_sched pointers. p_sched is unused. The struct td_sched is always co-allocated with the struct thread, except for the thread0. Avoid useless indirection, instead calculate td_sched location using simple pointer arithmetic in td_get_sched(9). For thread0, which is statically allocated, create a structure to emulate layout of the dynamic allocation. Reviewed by: jhb (previous version) Sponsored by: The FreeBSD Foundation Differential revision:https://reviews.freebsd.org/D6711 Modified: head/sys/kern/init_main.c head/sys/kern/kern_fork.c head/sys/kern/kern_proc.c head/sys/kern/kern_synch.c head/sys/kern/kern_thread.c head/sys/kern/sched_4bsd.c head/sys/kern/sched_ule.c head/sys/mips/mips/locore.S head/sys/sys/proc.h Modified: head/sys/kern/init_main.c == --- head/sys/kern/init_main.c Sun Jun 5 16:55:55 2016(r301455) +++ head/sys/kern/init_main.c Sun Jun 5 17:04:03 2016(r301456) @@ -99,7 +99,7 @@ void mi_startup(void);/* Should be e static struct session session0; static struct pgrp pgrp0; struct proc proc0; -struct thread thread0 __aligned(16); +struct thread0_storage thread0_st __aligned(16); struct vmspace vmspace0; struct proc *initproc; Modified: head/sys/kern/kern_fork.c == --- head/sys/kern/kern_fork.c Sun Jun 5 16:55:55 2016(r301455) +++ head/sys/kern/kern_fork.c Sun Jun 5 17:04:03 2016(r301456) @@ -1011,7 +1011,7 @@ fork_exit(void (*callout)(void *, struct KASSERT(p->p_state == PRS_NORMAL, ("executing process is still new")); CTR4(KTR_PROC, "fork_exit: new thread %p (td_sched %p, pid %d, %s)", - td, td->td_sched, p->p_pid, td->td_name); + td, td_get_sched(td), p->p_pid, td->td_name); sched_fork_exit(td); /* Modified: head/sys/kern/kern_proc.c == --- head/sys/kern/kern_proc.c Sun Jun 5 16:55:55 2016(r301455) +++ head/sys/kern/kern_proc.c Sun Jun 5 17:04:03 2016(r301456) @@ -237,7 +237,6 @@ proc_init(void *mem, int size, int flags p = (struct proc *)mem; SDT_PROBE3(proc, , init, entry, p, size, flags); - p->p_sched = (struct p_sched *)&p[1]; mtx_init(&p->p_mtx, "process lock", NULL, MTX_DEF | MTX_DUPOK | MTX_NEW); mtx_init(&p->p_slock, "process slock", NULL, MTX_SPIN | MTX_NEW); mtx_init(&p->p_statmtx, "pstatl", NULL, MTX_SPIN | MTX_NEW); Modified: head/sys/kern/kern_synch.c == --- head/sys/kern/kern_synch.c Sun Jun 5 16:55:55 2016(r301455) +++ head/sys/kern/kern_synch.c Sun Jun 5 17:04:03 2016(r301456) @@ -441,7 +441,7 @@ mi_switch(int flags, struct thread *newt PCPU_INC(cnt.v_swtch); PCPU_SET(switchticks, ticks); CTR4(KTR_PROC, "mi_switch: old thread %ld (td_sched %p, pid %ld, %s)", - td->td_tid, td->td_sched, td->td_proc->p_pid, td->td_name); + td->td_tid, td_get_sched(td), td->td_proc->p_pid, td->td_name); #if (KTR_COMPILE & KTR_SCHED) != 0 if (TD_IS_IDLETHREAD(td)) KTR_STATE1(KTR_SCHED, "thread", sched_tdname(td), "idle", @@ -457,7 +457,7 @@ mi_switch(int flags, struct thread *newt "prio:%d", td->td_priority); CTR4(KTR_PROC, "mi_switch: new thread %ld (td_sched %p, pid %ld, %s)", - td->td_tid, td->td_sched, td->td_proc->p_pid, td->td_name); + td->td_tid, td_get_sched(td), td->td_proc->p_pid, td->td_name); /* * If the last thread was exiting, finish cleaning it up. Modified: head/sys/kern/kern_thread.c == --- head/sys/kern/kern_thread.c Sun Jun 5 16:55:55 2016(r301455) +++ head/sys/kern/kern_thread.c Sun Jun 5 17:04:03 2016(r301456) @@ -211,7 +211,6 @@ thread_init(void *mem, int size, int fla td->td_turnstile = turnstile_alloc(); td->td_rlqe = NULL; EVENTHANDLER_INVOKE(thread_init, td); - td->td_sched = (struct td_sched *)&td[1]; umtx_thread_init(td); td->td_kstack = 0; td->td_sel = NULL; Modified: head/sys/kern/sched_4bsd.c == --- head/sys/kern/sched_4bsd.c Sun Jun 5 16:55:55 2016(r301455) +++ head/sys/kern/sched_4bsd.c Sun Jun 5 17:04:03 2016(r301456) @@ -117,7 +117,10 @@ struct td_sched { #defineTHREAD_CAN_SCHED(td, cpu) \ CPU_ISSET((cpu), &(td)-
svn commit: r301457 - head/sys/amd64/amd64
Author: kib Date: Sun Jun 5 17:11:23 2016 New Revision: 301457 URL: https://svnweb.freebsd.org/changeset/base/301457 Log: Avoid spurious EINVAL in amd64 pmap_change_attr(). Do not try to change attributes for DMAP when working on a mapping which is not covered by the DMAP. This was reported on real system where a BAR of a device (NTB) was mapped outside the PCI window. Reported and tested by: mav Reviewed by: jhb, mav Sponsored by: The FreeBSD Foundation MFC after:1 week Differential revision:https://reviews.freebsd.org/D6668 Modified: head/sys/amd64/amd64/pmap.c Modified: head/sys/amd64/amd64/pmap.c == --- head/sys/amd64/amd64/pmap.c Sun Jun 5 17:04:03 2016(r301456) +++ head/sys/amd64/amd64/pmap.c Sun Jun 5 17:11:23 2016(r301457) @@ -6533,7 +6533,7 @@ static int pmap_change_attr_locked(vm_offset_t va, vm_size_t size, int mode) { vm_offset_t base, offset, tmpva; - vm_paddr_t pa_start, pa_end; + vm_paddr_t pa_start, pa_end, pa_end1; pdp_entry_t *pdpe; pd_entry_t *pde; pt_entry_t *pte; @@ -6716,9 +6716,12 @@ pmap_change_attr_locked(vm_offset_t va, tmpva += PAGE_SIZE; } } - if (error == 0 && pa_start != pa_end) - error = pmap_change_attr_locked(PHYS_TO_DMAP(pa_start), - pa_end - pa_start, mode); + if (error == 0 && pa_start != pa_end && pa_start < dmaplimit) { + pa_end1 = MIN(pa_end, dmaplimit); + if (pa_start != pa_end1) + error = pmap_change_attr_locked(PHYS_TO_DMAP(pa_start), + pa_end1 - pa_start, mode); + } /* * Flush CPU caches if required to make sure any data isn't cached that ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301460 - head/sys/dev/filemon
Author: bdrewery Date: Sun Jun 5 18:16:33 2016 New Revision: 301460 URL: https://svnweb.freebsd.org/changeset/base/301460 Log: Cleanup COMPAT_FREEBSD32 support. This is a NOP. The COMPAT_IA32 was renamed in r205014 to COMPAT_FREEBSD32 and COMPAT_ARCH32 does not seem to have existed. Also remove some leftovers from the sysent rework in r301404. Include freebsd32_util.h for the freebsd32_sysent prototype. X-MFC-With: r301404 Reported by: kib MFC after:3 days Sponsored by: EMC / Isilon Storage Division Modified: head/sys/dev/filemon/filemon.c head/sys/dev/filemon/filemon_wrapper.c Modified: head/sys/dev/filemon/filemon.c == --- head/sys/dev/filemon/filemon.c Sun Jun 5 18:11:52 2016 (r301459) +++ head/sys/dev/filemon/filemon.c Sun Jun 5 18:16:33 2016 (r301460) @@ -54,16 +54,12 @@ __FBSDID("$FreeBSD$"); #include "filemon.h" -#if defined(COMPAT_IA32) || defined(COMPAT_FREEBSD32) || defined(COMPAT_ARCH32) +#if defined(COMPAT_FREEBSD32) #include #include - -extern struct sysentvec ia32_freebsd_sysvec; +#include #endif -extern struct sysentvec elf32_freebsd_sysvec; -extern struct sysentvec elf64_freebsd_sysvec; - static d_close_t filemon_close; static d_ioctl_t filemon_ioctl; static d_open_tfilemon_open; Modified: head/sys/dev/filemon/filemon_wrapper.c == --- head/sys/dev/filemon/filemon_wrapper.c Sun Jun 5 18:11:52 2016 (r301459) +++ head/sys/dev/filemon/filemon_wrapper.c Sun Jun 5 18:16:33 2016 (r301460) @@ -39,10 +39,6 @@ __FBSDID("$FreeBSD$"); #include "opt_compat.h" -#if defined(COMPAT_IA32) || defined(COMPAT_FREEBSD32) || defined(COMPAT_ARCH32) -extern struct sysent freebsd32_sysent[]; -#endif - static eventhandler_tag filemon_exec_tag; static eventhandler_tag filemon_exit_tag; static eventhandler_tag filemon_fork_tag; @@ -429,7 +425,7 @@ filemon_wrapper_install(void) sysent[SYS_symlink].sy_call = (sy_call_t *) filemon_wrapper_symlink; sysent[SYS_linkat].sy_call = (sy_call_t *) filemon_wrapper_linkat; -#if defined(COMPAT_IA32) || defined(COMPAT_FREEBSD32) || defined(COMPAT_ARCH32) +#if defined(COMPAT_FREEBSD32) freebsd32_sysent[FREEBSD32_SYS_chdir].sy_call = (sy_call_t *) filemon_wrapper_chdir; freebsd32_sysent[FREEBSD32_SYS_open].sy_call = (sy_call_t *) filemon_wrapper_open; freebsd32_sysent[FREEBSD32_SYS_openat].sy_call = (sy_call_t *) filemon_wrapper_openat; @@ -438,7 +434,7 @@ filemon_wrapper_install(void) freebsd32_sysent[FREEBSD32_SYS_link].sy_call = (sy_call_t *) filemon_wrapper_link; freebsd32_sysent[FREEBSD32_SYS_symlink].sy_call = (sy_call_t *) filemon_wrapper_symlink; freebsd32_sysent[FREEBSD32_SYS_linkat].sy_call = (sy_call_t *) filemon_wrapper_linkat; -#endif /* COMPAT_ARCH32 */ +#endif /* COMPAT_FREEBSD32 */ filemon_exec_tag = EVENTHANDLER_REGISTER(process_exec, filemon_event_process_exec, NULL, EVENTHANDLER_PRI_LAST); @@ -461,7 +457,7 @@ filemon_wrapper_deinstall(void) sysent[SYS_symlink].sy_call = (sy_call_t *)sys_symlink; sysent[SYS_linkat].sy_call = (sy_call_t *)sys_linkat; -#if defined(COMPAT_IA32) || defined(COMPAT_FREEBSD32) || defined(COMPAT_ARCH32) +#if defined(COMPAT_FREEBSD32) freebsd32_sysent[FREEBSD32_SYS_chdir].sy_call = (sy_call_t *)sys_chdir; freebsd32_sysent[FREEBSD32_SYS_open].sy_call = (sy_call_t *)sys_open; freebsd32_sysent[FREEBSD32_SYS_openat].sy_call = (sy_call_t *)sys_openat; @@ -470,7 +466,7 @@ filemon_wrapper_deinstall(void) freebsd32_sysent[FREEBSD32_SYS_link].sy_call = (sy_call_t *)sys_link; freebsd32_sysent[FREEBSD32_SYS_symlink].sy_call = (sy_call_t *)sys_symlink; freebsd32_sysent[FREEBSD32_SYS_linkat].sy_call = (sy_call_t *)sys_linkat; -#endif /* COMPAT_ARCH32 */ +#endif /* COMPAT_FREEBSD32 */ EVENTHANDLER_DEREGISTER(process_exec, filemon_exec_tag); EVENTHANDLER_DEREGISTER(process_exit, filemon_exit_tag); ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r301226 - in head: etc etc/defaults etc/periodic/security etc/rc.d lib lib/libblacklist libexec libexec/blacklistd-helper share/mk tools/build/mk usr.sbin usr.sbin/blacklistctl usr.sbi
> On Jun 2, 2016, at 3:06 PM, Kurt Lidl wrote: > > Author: lidl > Date: Thu Jun 2 19:06:04 2016 > New Revision: 301226 > URL: https://svnweb.freebsd.org/changeset/base/301226 > > Log: > Add basic blacklist build support > [snip] > Modified: head/etc/defaults/rc.conf > == > --- head/etc/defaults/rc.conf Thu Jun 2 18:41:33 2016(r301225) > +++ head/etc/defaults/rc.conf Thu Jun 2 19:06:04 2016(r301226) > @@ -270,6 +270,8 @@ hastd_program="/sbin/hastd" # path to ha > hastd_flags=""# Optional flags to hastd. > ctld_enable="NO" # CAM Target Layer / iSCSI target daemon. > local_unbound_enable="NO" # local caching resolver > +blacklistd_enable="YES" # Run blacklistd daemon (YES/NO). > +blacklistd_flags="" # Optional flags for blacklistd(8). What is the rationale for having this enabled by default? Is any of the services that use it (in their default config) enabled by default? Thanks, Matteo ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301461 - in head/lib/libc: gen locale regex
Author: pfg Date: Sun Jun 5 19:12:52 2016 New Revision: 301461 URL: https://svnweb.freebsd.org/changeset/base/301461 Log: libc/locale: Fix type breakage in __collate_range_cmp(). When collation support was brought in, the second and third arguments in __collate_range_cmp() were changed from int to wchar_t, breaking the ABI. Change them to a "char" type which makes more sense and keeps the ABI compatible. Also introduce __wcollate_range_cmp() which does work with wide characters. This function is used only internally in libc so we don't export it. Use the new function in glob(3), fnmatch(3), and regexec(3). PR: 179721 Suggested by: ache. jilles MFC after:3 weeks (perhaps partial only) Modified: head/lib/libc/gen/fnmatch.c head/lib/libc/gen/glob.c head/lib/libc/locale/collate.h head/lib/libc/locale/collcmp.c head/lib/libc/regex/regcomp.c Modified: head/lib/libc/gen/fnmatch.c == --- head/lib/libc/gen/fnmatch.c Sun Jun 5 18:16:33 2016(r301460) +++ head/lib/libc/gen/fnmatch.c Sun Jun 5 19:12:52 2016(r301461) @@ -296,8 +296,8 @@ rangematch(const char *pattern, wchar_t if (table->__collate_load_error ? c <= test && test <= c2 : - __collate_range_cmp(table, c, test) <= 0 - && __collate_range_cmp(table, test, c2) <= 0 + __wcollate_range_cmp(table, c, test) <= 0 + && __wcollate_range_cmp(table, test, c2) <= 0 ) ok = 1; } else if (c == test) Modified: head/lib/libc/gen/glob.c == --- head/lib/libc/gen/glob.cSun Jun 5 18:16:33 2016(r301460) +++ head/lib/libc/gen/glob.cSun Jun 5 19:12:52 2016(r301461) @@ -832,8 +832,8 @@ match(Char *name, Char *pat, Char *paten if ((*pat & M_MASK) == M_RNG) { if (table->__collate_load_error ? CHAR(c) <= CHAR(k) && CHAR(k) <= CHAR(pat[1]) : - __collate_range_cmp(table, CHAR(c), CHAR(k)) <= 0 - && __collate_range_cmp(table, CHAR(k), CHAR(pat[1])) <= 0 + __wcollate_range_cmp(table, CHAR(c), CHAR(k)) <= 0 + && __wcollate_range_cmp(table, CHAR(k), CHAR(pat[1])) <= 0 ) ok = 1; pat += 2; Modified: head/lib/libc/locale/collate.h == --- head/lib/libc/locale/collate.h Sun Jun 5 18:16:33 2016 (r301460) +++ head/lib/libc/locale/collate.h Sun Jun 5 19:12:52 2016 (r301461) @@ -128,7 +128,8 @@ int __collate_load_tables(const char *); int__collate_equiv_value(locale_t, const wchar_t *, size_t); void _collate_lookup(struct xlocale_collate *,const wchar_t *, int *, int *, int, const int **); -int__collate_range_cmp(struct xlocale_collate *, wchar_t, wchar_t); +int__collate_range_cmp(struct xlocale_collate *, char, char); +int__wcollate_range_cmp(struct xlocale_collate *, wchar_t, wchar_t); size_t _collate_wxfrm(struct xlocale_collate *, const wchar_t *, wchar_t *, size_t); size_t _collate_sxfrm(struct xlocale_collate *, const wchar_t *, char *, Modified: head/lib/libc/locale/collcmp.c == --- head/lib/libc/locale/collcmp.c Sun Jun 5 18:16:33 2016 (r301460) +++ head/lib/libc/locale/collcmp.c Sun Jun 5 19:12:52 2016 (r301461) @@ -41,14 +41,27 @@ __FBSDID("$FreeBSD$"); * Compare two characters using collate */ -int __collate_range_cmp(struct xlocale_collate *table, wchar_t c1, wchar_t c2) +int __collate_range_cmp(struct xlocale_collate *table, char c1, char c2) +{ + char s1[2], s2[2]; + + s1[0] = c1; + s1[1] = '\0'; + s2[0] = c2; + s2[1] = '\0'; + struct _xlocale l = {{0}}; + l.components[XLC_COLLATE] = (struct xlocale_component *)table; + return (strcoll_l(s1, s2, &l)); +} + +int __wcollate_range_cmp(struct xlocale_collate *table, wchar_t c1, wchar_t c2) { wchar_t s1[2], s2[2]; s1[0] = c1; - s1[1] = 0; + s1[1] = L'\0'; s2[0] = c2; - s2[1] = 0; + s2[1] = L'\0'; struct _xlocale l = {{0}}; l.components[XLC_COLLATE] = (struct xlocale_component *)table; return (wcscoll_l(s1, s2, &l)); Modified: head/lib/libc/regex/regcomp.c ===
Re: svn commit: r301461 - in head/lib/libc: gen locale regex
On 05.06.2016 22:12, Pedro F. Giffuni wrote: > --- head/lib/libc/regex/regcomp.c Sun Jun 5 18:16:33 2016 > (r301460) > +++ head/lib/libc/regex/regcomp.c Sun Jun 5 19:12:52 2016 > (r301461) > @@ -821,10 +821,10 @@ p_b_term(struct parse *p, cset *cs) > (void)REQUIRE((uch)start <= (uch)finish, > REG_ERANGE); > CHaddrange(p, cs, start, finish); > } else { > - (void)REQUIRE(__collate_range_cmp(table, start, > finish) <= 0, REG_ERANGE); > + (void)REQUIRE(__wcollate_range_cmp(table, > start, finish) <= 0, REG_ERANGE); > for (i = 0; i <= UCHAR_MAX; i++) { > - if ( __collate_range_cmp(table, > start, i) <= 0 > - && __collate_range_cmp(table, i, > finish) <= 0 > + if ( __wcollate_range_cmp(table, > start, i) <= 0 > + && __wcollate_range_cmp(table, i, > finish) <= 0 > ) > CHadd(p, cs, i); > } > As I already mention in PR, we have broken regcomp after someone adds wchar_t support there. Now regcomp ranges works only for the first 256 wchars of the current locale, notice that loop upper limit: for (i = 0; i <= UCHAR_MAX; i++) { In general, ranges are either broken in regcomp now or are memory eating. We have bitmask only for the first 256 wchars, all other added to the range literally. Imagine what happens if someone specify full Unicode range in regexp. Proper fix will be adding bitmask for the whole Unicode range, and even in that case regcomp attempting to use collation in ranges will be _very_slow_ since needs to check all Unicode chars in its for (i = 0; i <= Max_Unicode_wchar; i++) { loop. Better stop pretending that we are able to do collation support in the ranges, since POSIX cares about its own locale only here: "In the POSIX locale, a range expression represents the set of collating elements that fall between two elements in the collation sequence, inclusive. In other locales, a range expression has unspecified behavior: strictly conforming applications shall not rely on whether the range expression is valid, or on the set of collating elements matched." Until whole Unicode range bitmask will be implemented (if ever), better stop pretending to honor collation order, we just can't do it with wchars now and do what NetBSD/OpenBSD does (using wchar_t) instead. It does not prevent memory eating on big ranges (bitmask is needed, see above), but at least fix the thing that only first 256 wchars are considered. ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r301461 - in head/lib/libc: gen locale regex
On 05.06.2016 22:12, Pedro F. Giffuni wrote: > When collation support was brought in, the second and third > arguments in __collate_range_cmp() were changed from int to > wchar_t, breaking the ABI. Change them to a "char" type which > makes more sense and keeps the ABI compatible. Not only that breaks ABI, but changing strcoll_l() to wcscoll_l() in the __collate_range_cmp() too (now fixed), while this function is visible outside of libc. ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301462 - in head: contrib/bmake contrib/bmake/mk usr.bin/bmake
Author: sjg Date: Sun Jun 5 20:26:16 2016 New Revision: 301462 URL: https://svnweb.freebsd.org/changeset/base/301462 Log: Import bmake-20160604 Performace improvements for meta mode. Modified: head/contrib/bmake/ChangeLog head/contrib/bmake/Makefile head/contrib/bmake/bmake.1 head/contrib/bmake/bmake.cat1 head/contrib/bmake/boot-strap head/contrib/bmake/main.c head/contrib/bmake/make-bootstrap.sh.in head/contrib/bmake/make.1 head/contrib/bmake/make.h head/contrib/bmake/meta.c head/contrib/bmake/mk/ChangeLog head/contrib/bmake/mk/dpadd.mk head/contrib/bmake/mk/install-mk head/contrib/bmake/mk/meta.autodep.mk head/contrib/bmake/mk/meta.stage.mk head/contrib/bmake/nonints.h head/contrib/bmake/var.c head/usr.bin/bmake/Makefile Directory Properties: head/contrib/bmake/ (props changed) Modified: head/contrib/bmake/ChangeLog == --- head/contrib/bmake/ChangeLogSun Jun 5 19:12:52 2016 (r301461) +++ head/contrib/bmake/ChangeLogSun Jun 5 20:26:16 2016 (r301462) @@ -1,3 +1,26 @@ +2016-06-04 Simon J. Gerraty + + * Makefile (_MAKE_VERSION): 20160604 + Merge with NetBSD make, pick up + o meta.c: missing filemon data is only relevant if we read a + meta file. + Also do not return oodate for a missing metafile if gn->path + points to .CURDIR + +2016-06-02 Simon J. Gerraty + + * Makefile (_MAKE_VERSION): 20160602 + Merge with NetBSD make, pick up + o cached_realpath(): avoid hitting filesystem more than necessary. + o meta.c: refactor need_meta decision, add knobs for + missing meta file and filemon data wrt out-of-datedness. + +2016-05-28 Simon J. Gerraty + + * Makefile (_MAKE_VERSION): 20160528 + + * boot-strap, make-bootstrap.sh.in: Makefile now uses _MAKE_VERSION + 2016-05-12 Simon J. Gerraty * Makefile (_MAKE_VERSION): 20160512 Modified: head/contrib/bmake/Makefile == --- head/contrib/bmake/Makefile Sun Jun 5 19:12:52 2016(r301461) +++ head/contrib/bmake/Makefile Sun Jun 5 20:26:16 2016(r301462) @@ -1,7 +1,7 @@ -# $Id: Makefile,v 1.63 2016/05/12 20:34:46 sjg Exp $ +# $Id: Makefile,v 1.66 2016/06/04 22:21:15 sjg Exp $ # Base version on src date -_MAKE_VERSION= 20160512 +_MAKE_VERSION= 20160604 PROG= bmake Modified: head/contrib/bmake/bmake.1 == --- head/contrib/bmake/bmake.1 Sun Jun 5 19:12:52 2016(r301461) +++ head/contrib/bmake/bmake.1 Sun Jun 5 20:26:16 2016(r301462) @@ -1,4 +1,4 @@ -.\"$NetBSD: make.1,v 1.257 2016/05/10 23:45:45 sjg Exp $ +.\"$NetBSD: make.1,v 1.259 2016/06/03 07:07:37 wiz Exp $ .\" .\" Copyright (c) 1990, 1993 .\"The Regents of the University of California. All rights reserved. @@ -29,7 +29,7 @@ .\" .\"from: @(#)make.18.4 (Berkeley) 3/19/94 .\" -.Dd May 10, 2016 +.Dd June 2, 2016 .Dt MAKE 1 .Os .Sh NAME @@ -846,7 +846,7 @@ Can affect the mode that .Nm runs in. It can contain a number of keywords: -.Bl -hang -width ignore-cmd +.Bl -hang -width missing-filemon=bf. .It Pa compat Like .Fl B , @@ -870,6 +870,17 @@ will not create .meta files in This can be overridden by setting .Va bf to a value which represents True. +.It Pa missing-meta= Ar bf +If +.Va bf +is True, then a missing .meta file makes the target out-of-date. +.It Pa missing-filemon= Ar bf +If +.Va bf +is True, then missing filemon data makes the target out-of-date. +.It Pa nofilemon +Do not use +.Xr filemon 4 . .It Pa env For debugging, it can be useful to include the environment in the .meta file. Modified: head/contrib/bmake/bmake.cat1 == --- head/contrib/bmake/bmake.cat1 Sun Jun 5 19:12:52 2016 (r301461) +++ head/contrib/bmake/bmake.cat1 Sun Jun 5 20:26:16 2016 (r301462) @@ -531,37 +531,51 @@ VVAARRIIAABBLLEE AASSSSIIGG mode that bbmmaakkee runs in. It can contain a number of key- words: - _c_o_m_p_a_t Like --BB, puts bbmmaakkee into "compat" mode. + _c_o_m_p_a_t Like --BB, puts bbmmaakkee into "compat" + mode. - _m_e_t_aPuts bbmmaakkee into "meta" mode, where meta files - are created for each target to capture the - command run, the output generated and if - filemon(4) is available, the system calls - which are of interest to bbmm
Re: svn commit: r301172 - head/contrib/blacklist
On Fri, 2016-06-03 at 08:50 +0200, Jan Beich wrote: > Kurt Lidl writes: > > > Author: lidl > > Date: Wed Jun 1 22:04:10 2016 > > New Revision: 301172 > > URL: https://svnweb.freebsd.org/changeset/base/301172 > > > > Log: > > Import NetBSD's blacklist source from vendor tree > > > > This import includes The basic blacklist library and utility > > programs, > > to add a system-wide packet filtering notification mechanism to > > FreeBSD. > > > > The rational behind the daemon was given by Christos Zoulas in a > > presentation at vBSDcon 2015: https://youtu.be/fuuf8G28mjs > > > > Reviewed by: rpaulo > > Approved by: rpaulo > > Obtained from:NetBSD > > Relnotes: YES > > Can you track FreeBSD version in manpages? Maybe ping upstream, so > they > add .Fx as well. > > $ fgrep .Nx contrib/blacklist/**/*.[0-9] > contrib/blacklist/bin/blacklistctl.8:.Nx 7 . > contrib/blacklist/bin/blacklistd.8:.Nx 7 . > contrib/blacklist/bin/blacklistd.conf.5:.Nx 7 . > > $ man blacklistd | col -b | fgrep -A1 HISTORY > HISTORY > blacklistd appeared in NetBSD 7. We don't really need to submit that change to NetBSD. Just change the man page in FreeBSD and hopefully future merges won't remove it. ;-) -- Rui Paulo ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r301462 - in head: contrib/bmake contrib/bmake/mk usr.bin/bmake
On 6/5/16 1:26 PM, Simon J. Gerraty wrote: > Author: sjg > Date: Sun Jun 5 20:26:16 2016 > New Revision: 301462 > URL: https://svnweb.freebsd.org/changeset/base/301462 > > Log: > Import bmake-20160604 > > Performace improvements for meta mode. Thanks! -- Regards, Bryan Drewery ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301464 - head/share/mk
Author: bdrewery Date: Sun Jun 5 21:21:41 2016 New Revision: 301464 URL: https://svnweb.freebsd.org/changeset/base/301464 Log: Import latest meta.stage.mk 1.45 (r301462) Modified: head/share/mk/meta.stage.mk Modified: head/share/mk/meta.stage.mk == --- head/share/mk/meta.stage.mk Sun Jun 5 20:58:07 2016(r301463) +++ head/share/mk/meta.stage.mk Sun Jun 5 21:21:41 2016(r301464) @@ -1,5 +1,5 @@ # $FreeBSD$ -# $Id: meta.stage.mk,v 1.44 2016/03/16 18:21:23 sjg Exp $ +# $Id: meta.stage.mk,v 1.45 2016/05/26 03:59:09 sjg Exp $ # # @(#) Copyright (c) 2011, Simon J. Gerraty # @@ -271,6 +271,8 @@ beforeinstall: .dirdep .NOPATH: ${STAGE_FILES} .if !empty(STAGE_TARGETS) +.NOPATH: ${CLEANFILES} + MK_STALE_STAGED?= no .if ${MK_STALE_STAGED} == "yes" all: stale_staged ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301465 - head
Author: bdrewery Date: Sun Jun 5 23:04:15 2016 New Revision: 301465 URL: https://svnweb.freebsd.org/changeset/base/301465 Log: Fix bmake version upgrade logic to use the new bmake. Otherwise it was only used on the next build. This was a flaw in r295980. MFC after:3 days Sponsored by: EMC / Isilon Storage Division Modified: head/Makefile Modified: head/Makefile == --- head/Makefile Sun Jun 5 21:21:41 2016(r301464) +++ head/Makefile Sun Jun 5 23:04:15 2016(r301465) @@ -170,9 +170,13 @@ HAVE_MAKE= bmake .else HAVE_MAKE= fmake .endif +.if ${HAVE_MAKE} != ${WANT_MAKE} || \ +(defined(WANT_MAKE_VERSION) && ${MAKE_VERSION} < ${WANT_MAKE_VERSION}) +NEED_MAKE_UPGRADE= t +.endif .if exists(${MYMAKE}) SUB_MAKE:= ${MYMAKE} -m ${.CURDIR}/share/mk -.elif ${WANT_MAKE} != ${HAVE_MAKE} +.elif defined(NEED_MAKE_UPGRADE) # It may not exist yet but we may cause it to. # In the case of fmake, upgrade_checks may cause a newer version to be built. SUB_MAKE= `test -x ${MYMAKE} && echo ${MYMAKE} || echo ${MAKE}` \ @@ -313,8 +317,7 @@ kernel: buildkernel installkernel # for building the world. # upgrade_checks: -.if ${HAVE_MAKE} != ${WANT_MAKE} || \ -(defined(WANT_MAKE_VERSION) && ${MAKE_VERSION} < ${WANT_MAKE_VERSION}) +.if defined(NEED_MAKE_UPGRADE) @${_+_}(cd ${.CURDIR} && ${MAKE} ${WANT_MAKE:S,^f,,}) .endif ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301466 - in head: . share/mk tools/build/options
Author: bdrewery Date: Sun Jun 5 23:04:42 2016 New Revision: 301466 URL: https://svnweb.freebsd.org/changeset/base/301466 Log: WITH_META_MODE: Enable bmake's missing meta rebuild feature Modified: head/Makefile head/share/mk/local.meta.sys.mk head/share/mk/sys.mk head/tools/build/options/WITH_META_MODE Modified: head/Makefile == --- head/Makefile Sun Jun 5 23:04:15 2016(r301465) +++ head/Makefile Sun Jun 5 23:04:42 2016(r301466) @@ -162,8 +162,13 @@ _MAKEOBJDIRPREFIX!= /usr/bin/env -i PATH # We cannot blindly use a make which may not be the one we want # so be exlicit - until all choice is removed. WANT_MAKE= bmake +.if !empty(.MAKE.MODE:Mmeta) +# 20160604 - support missing-meta,missing-filemon and performance improvements +WANT_MAKE_VERSION= 20160604 +.else # 20160220 - support .dinclude for FAST_DEPEND. WANT_MAKE_VERSION= 20160220 +.endif MYMAKE= ${MAKEOBJDIRPREFIX}${.CURDIR}/make.${MACHINE}/${WANT_MAKE} .if defined(.PARSEDIR) HAVE_MAKE= bmake Modified: head/share/mk/local.meta.sys.mk == --- head/share/mk/local.meta.sys.mk Sun Jun 5 23:04:15 2016 (r301465) +++ head/share/mk/local.meta.sys.mk Sun Jun 5 23:04:42 2016 (r301466) @@ -278,3 +278,8 @@ CFLAGS+= ${CROSS_TARGET_FLAGS} ACFLAGS+= ${CROSS_TARGET_FLAGS} LDFLAGS+= -Wl,-m -Wl,elf_${MACHINE_ARCH}_fbsd .endif + +META_MODE+=missing-meta=yes +.if empty(META_MODE:Mnofilemon) +META_MODE+=missing-filemon=yes +.endif Modified: head/share/mk/sys.mk == --- head/share/mk/sys.mkSun Jun 5 23:04:15 2016(r301465) +++ head/share/mk/sys.mkSun Jun 5 23:04:42 2016(r301466) @@ -47,6 +47,9 @@ __ENV_ONLY_OPTIONS:= \ .elif ${MK_META_MODE} == "yes" && defined(.MAKEFLAGS) && ${.MAKEFLAGS:M-B} == "" # verbose will show .MAKE.META.PREFIX for each target. META_MODE+=meta verbose +.if !defined(NO_META_MISSING) +META_MODE+=missing-meta=yes +.endif # silent will hide command output if a .meta file is created. .if !defined(NO_SILENT) META_MODE+=silent=yes @@ -57,6 +60,10 @@ META_MODE+= silent=yes .endif META_MODE+= nofilemon .endif +# Require filemon data with bmake +.if empty(META_MODE:Mnofilemon) +META_MODE+= missing-filemon=yes +.endif .endif META_MODE?= normal .export META_MODE Modified: head/tools/build/options/WITH_META_MODE == --- head/tools/build/options/WITH_META_MODE Sun Jun 5 23:04:15 2016 (r301465) +++ head/tools/build/options/WITH_META_MODE Sun Jun 5 23:04:42 2016 (r301466) @@ -19,9 +19,10 @@ The command to execute changes. .It The current working directory changes. .It -The target's meta file is missing, if it had -.Sy .META -as a dependency. +The target's meta file is missing. +.It +The target's meta file is missing filemon data when filemon is loaded +and a previous run did not have it loaded. .It [requires .Xr filemon 4 ] ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301469 - head/targets/pseudo/bootstrap-tools
Author: bdrewery Date: Sun Jun 5 23:05:07 2016 New Revision: 301469 URL: https://svnweb.freebsd.org/changeset/base/301469 Log: DIRDEPS_BUILD: Fix bootstrap-tools not handling CCACHE_DIR properly. CCACHE_DIR needs to be resolved to its full path before processing legacy.meta or meta mode may see the change to the stats file. Sponsored by: EMC / Isilon Storage Division Modified: head/targets/pseudo/bootstrap-tools/Makefile Modified: head/targets/pseudo/bootstrap-tools/Makefile == --- head/targets/pseudo/bootstrap-tools/MakefileSun Jun 5 23:05:04 2016(r301468) +++ head/targets/pseudo/bootstrap-tools/MakefileSun Jun 5 23:05:07 2016(r301469) @@ -84,3 +84,6 @@ BSTCARGS= \ # finally we build toolchain leveraging the above. bootstrap-toolchain: .MAKE cross-tools ${BSTCENV} ${MAKE} -C ${.CURDIR:H:H} ${BSTCARGS} toolchain + +# Ensure CCACHE_DIR is ignored since we are processing .meta files here. +.include ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301470 - head
Author: bdrewery Date: Sun Jun 5 23:05:10 2016 New Revision: 301470 URL: https://svnweb.freebsd.org/changeset/base/301470 Log: Add a MINIMUM_SUPPORTED_OSREL and bump it to 900044. This is actually a revision in the stable/9 branch released as 9.1. The localedef build requires xlocale from this period. Sponsored by: EMC / Isilon Storage Division Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 == --- head/Makefile.inc1 Sun Jun 5 23:05:07 2016(r301469) +++ head/Makefile.inc1 Sun Jun 5 23:05:10 2016(r301470) @@ -431,6 +431,9 @@ PACKAGE=kernel # BOOTSTRAPPING?=0 +# Keep these in sync +MINIMUM_SUPPORTED_OSREL?= 900044 +MINIMUM_SUPPORTED_REL?= 9.1 # Common environment for world related stages CROSSENV+= MAKEOBJDIRPREFIX=${OBJTREE} \ @@ -1512,8 +1515,8 @@ _elftoolchain_libs= lib/libelf lib/libdw .endif legacy: .PHONY -.if ${BOOTSTRAPPING} < 800107 && ${BOOTSTRAPPING} != 0 - @echo "ERROR: Source upgrades from versions prior to 8.0 are not supported."; \ +.if ${BOOTSTRAPPING} < ${MINIMUM_SUPPORTED_OSREL} && ${BOOTSTRAPPING} != 0 + @echo "ERROR: Source upgrades from versions prior to ${MINIMUM_SUPPORTED_REL} are not supported."; \ false .endif .for _tool in tools/build ${_elftoolchain_libs} ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301467 - head/share/mk
Author: bdrewery Date: Sun Jun 5 23:05:01 2016 New Revision: 301467 URL: https://svnweb.freebsd.org/changeset/base/301467 Log: WITH_META_MODE: Avoid host tool timestamps causing a rebuild. Using buildworld, installworld, buildworld. It is expected that nothing should rebuild. However any host tool used could have its timestamp updated. Any library used by dynamic tools could have its timestamp updated. The filemon(4) data in the .meta files captures all reads to these files. This causes the 2nd buildworld to rebuild everything since host tools and files have been updated. Because the build is self-reliant and bootstraps itself, it should be safe to ignore mtime changes on host files used during the build. Host files should only impact the build of legacy, build-tools, bootstrap-tools, cross-tools, but those are already intended to be reproducible from its own bootstrapping. It is possible in a rare case that a bug in a host file does produce a broken build tool. If that happens it will just have to be communicated properly. An alternative solution would be to update the mtime of all files in the object directory after installworld so that the host files are not newer than the object files. That also requires special care for read-only obj directories and special care to not mess with any intended timestamps in the build, such as done for reproducibility. Reported by: many Sponsored by: EMC / Isilon Storage Division Modified: head/share/mk/sys.mk Modified: head/share/mk/sys.mk == --- head/share/mk/sys.mkSun Jun 5 23:04:42 2016(r301466) +++ head/share/mk/sys.mkSun Jun 5 23:05:01 2016(r301467) @@ -68,6 +68,26 @@ META_MODE+= missing-filemon=yes META_MODE?= normal .export META_MODE .MAKE.MODE?= ${META_MODE} +.if !empty(.MAKE.MODE:Mmeta) && !defined(NO_META_IGNORE_HOST) +# Ignore host file changes that will otherwise cause +# buildworld -> installworld -> buildworld to rebuild everything. +# Since the build is self-reliant and bootstraps everything it needs, +# this should not be a real problem for incremental builds. +# Note that these are prefix matching, so /lib matches /libexec. +.MAKE.META.IGNORE_PATHS+= \ + ${__MAKE_SHELL} \ + /bin \ + /lib \ + /rescue \ + /sbin \ + /usr/bin \ + /usr/include \ + /usr/lib \ + /usr/sbin \ + /usr/share \ + +.endif + .if ${MK_AUTO_OBJ} == "yes" # This needs to be done early - before .PATH is computed ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301468 - head/share/mk
Author: bdrewery Date: Sun Jun 5 23:05:04 2016 New Revision: 301468 URL: https://svnweb.freebsd.org/changeset/base/301468 Log: WITH_SYSTEM_COMPILER: Disable with WITH_META_MODE for now. The WITH_META_MODE build is intended to be a working incremental build. It spies on the build command to see if things should be rebuilt if the command changes. If you run buildworld, it builds a cross-compiler, then do installworld and buildworld again it will invoke the WITH_SYSTEM_COMPILER logic. This then adds on -target/--sysroot, etc, and causes rebuilds due to the changed build command even though the compiler used is technically the same revision. Since the incremental build is not cleaning anything by default then there is much less risk to rebuilding the already-existing cross-compiler. Just disable the combined logic and always use and build the cross-compiler. An alternative to this would be to always pass -target/--sysroot. Doing so may occur in the future. Sponsored by: EMC / Isilon Storage Division Modified: head/share/mk/src.opts.mk Modified: head/share/mk/src.opts.mk == --- head/share/mk/src.opts.mk Sun Jun 5 23:05:01 2016(r301467) +++ head/share/mk/src.opts.mk Sun Jun 5 23:05:04 2016(r301468) @@ -352,6 +352,10 @@ MK_ELFTOOLCHAIN_BOOTSTRAP:= no MK_GCC_BOOTSTRAP:= no .endif +.if ${MK_META_MODE} == "yes" +MK_SYSTEM_COMPILER:= no +.endif + .if ${MK_TOOLCHAIN} == "no" MK_BINUTILS:= no MK_CLANG:= no ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301471 - in head: contrib/elftoolchain/brandelf contrib/elftoolchain/elfcopy contrib/elftoolchain/elfdump contrib/elftoolchain/libdwarf contrib/elftoolchain/libelftc contrib/elftoolcha...
Author: bdrewery Date: Sun Jun 5 23:05:14 2016 New Revision: 301471 URL: https://svnweb.freebsd.org/changeset/base/301471 Log: Use the in-tree sys/elf_common.h to build libelftc. This fixes build failures on older releases that lack various definitions such as EM_AARCH64 (which was unfixed before this). Revert all of the recent compatibility changes that worked around this problem. This uses the same method of using the in-tree header as lib/libelf, lib/libdwarf and usr.bin/readelf. Reviewed by: emaste Sponsored by: EMC / Isilon Storage Division Differential Revision:https://reviews.freebsd.org/D6734 Modified: head/contrib/elftoolchain/brandelf/brandelf.c head/contrib/elftoolchain/elfcopy/main.c head/contrib/elftoolchain/elfdump/elfdump.c head/contrib/elftoolchain/libdwarf/libdwarf_reloc.c head/contrib/elftoolchain/libelftc/elftc_reloc_type_str.c head/contrib/elftoolchain/readelf/readelf.c head/lib/libelftc/Makefile Modified: head/contrib/elftoolchain/brandelf/brandelf.c == --- head/contrib/elftoolchain/brandelf/brandelf.c Sun Jun 5 23:05:10 2016(r301470) +++ head/contrib/elftoolchain/brandelf/brandelf.c Sun Jun 5 23:05:14 2016(r301471) @@ -46,11 +46,6 @@ ELFTC_VCSID("$Id: brandelf.c 3440 2016-04-07 14:51:47Z emaste $"); -/* Backwards compatability for older FreeBSD releases. */ -#ifndef ELFOSABI_CLOUDABI -#define ELFOSABI_CLOUDABI 17 -#endif - static int elftype(const char *); static const char *iselftype(int); static void printelftypes(void); Modified: head/contrib/elftoolchain/elfcopy/main.c == --- head/contrib/elftoolchain/elfcopy/main.cSun Jun 5 23:05:10 2016 (r301470) +++ head/contrib/elftoolchain/elfcopy/main.cSun Jun 5 23:05:14 2016 (r301471) @@ -41,11 +41,6 @@ ELFTC_VCSID("$Id: main.c 3446 2016-05-03 01:31:17Z emaste $"); -/* Backwards compatability for older FreeBSD releases. */ -#ifndef ELFOSABI_CLOUDABI -#define ELFOSABI_CLOUDABI 17 -#endif - enum options { ECP_ADD_GNU_DEBUGLINK, Modified: head/contrib/elftoolchain/elfdump/elfdump.c == --- head/contrib/elftoolchain/elfdump/elfdump.c Sun Jun 5 23:05:10 2016 (r301470) +++ head/contrib/elftoolchain/elfdump/elfdump.c Sun Jun 5 23:05:14 2016 (r301471) @@ -52,14 +52,6 @@ ELFTC_VCSID("$Id: elfdump.c 3474 2016-05-17 20:44:53Z emaste $"); -/* Backwards compatability for older FreeBSD releases. */ -#ifndef EM_IAMCU -#define EM_IAMCU 6 -#endif -#ifndef EM_RISCV -#define EM_RISCV 243 -#endif - #if defined(ELFTC_NEED_ELF_NOTE_DEFINITION) #include "native-elf-format.h" #if ELFTC_CLASS == ELFCLASS32 Modified: head/contrib/elftoolchain/libdwarf/libdwarf_reloc.c == --- head/contrib/elftoolchain/libdwarf/libdwarf_reloc.c Sun Jun 5 23:05:10 2016(r301470) +++ head/contrib/elftoolchain/libdwarf/libdwarf_reloc.c Sun Jun 5 23:05:14 2016(r301471) @@ -28,11 +28,6 @@ ELFTC_VCSID("$Id: libdwarf_reloc.c 3198 2015-05-14 18:36:19Z emaste $"); -/* Backwards compatability for older FreeBSD releases. */ -#ifndef EM_IAMCU -#define EM_IAMCU 6 -#endif - Dwarf_Unsigned _dwarf_get_reloc_type(Dwarf_P_Debug dbg, int is64) { Modified: head/contrib/elftoolchain/libelftc/elftc_reloc_type_str.c == --- head/contrib/elftoolchain/libelftc/elftc_reloc_type_str.c Sun Jun 5 23:05:10 2016(r301470) +++ head/contrib/elftoolchain/libelftc/elftc_reloc_type_str.c Sun Jun 5 23:05:14 2016(r301471) @@ -31,14 +31,6 @@ #include #include -/* Backwards compatability for older FreeBSD releases. */ -#ifndef EM_IAMCU -#define EM_IAMCU 6 -#endif -#ifndef EM_RISCV -#define EM_RISCV 243 -#endif - const char * elftc_reloc_type_str(unsigned int mach, unsigned int type) { Modified: head/contrib/elftoolchain/readelf/readelf.c == --- head/contrib/elftoolchain/readelf/readelf.c Sun Jun 5 23:05:10 2016 (r301470) +++ head/contrib/elftoolchain/readelf/readelf.c Sun Jun 5 23:05:14 2016 (r301471) @@ -50,15 +50,6 @@ ELFTC_VCSID("$Id: readelf.c 3469 2016-05-15 23:16:09Z emaste $"); /* Backwards compatability for older FreeBSD releases. */ -#ifndef ELFOSABI_CLOUDABI -#define ELFOSABI_CLOUDABI 17 -#endif -#ifndef EM_IAMCU -#define EM_IAMCU 6 -#endif -#ifndef EM_RISCV -#define EM_RISCV 243 -#endif #ifndefSTB_GNU_UNIQUE #defineSTB_GNU_UNIQUE 10 #endif Modified: head/lib/libelftc/Makefile == --- head/lib/libelftc/Makefile Sun Jun 5 23:05
svn commit: r301472 - head
Author: bdrewery Date: Sun Jun 5 23:05:17 2016 New Revision: 301472 URL: https://svnweb.freebsd.org/changeset/base/301472 Log: Only include bsd.compiler.mk for bmakes that use -m .../share/mk by default. Otherwise they error when trying to include the file, which also has its own dependencies. Sponsored by: EMC / Isilon Storage Division Modified: head/Makefile Modified: head/Makefile == --- head/Makefile Sun Jun 5 23:05:14 2016(r301471) +++ head/Makefile Sun Jun 5 23:05:17 2016(r301472) @@ -103,7 +103,9 @@ # This is included so CC is set to ccache for -V, and COMPILER_TYPE/VERSION # can be cached for sub-makes. +.if ${MAKE_VERSION} >= 20140620 .include +.endif # Note: we use this awkward construct to be compatible with FreeBSD's # old make used in 10.0 and 9.2 and earlier. ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r301172 - head/contrib/blacklist
On 6/1/16 3:04 PM, Kurt Lidl wrote: > Author: lidl > Date: Wed Jun 1 22:04:10 2016 > New Revision: 301172 > URL: https://svnweb.freebsd.org/changeset/base/301172 > > Log: > Import NetBSD's blacklist source from vendor tree no description found for WITHOUT_BLACKLIST, skipping no description found for WITHOUT_BLACKLIST_SUPPORT, skipping Need to add these in tools/build/options, svn commit, svn up, and then run from that directory: ./makeman > ../../../share/man/man5/src.conf.5 Then commit ../../../share/man/man5/src.conf.5 -- Regards, Bryan Drewery ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301473 - head/share/man/man5
Author: bdrewery Date: Sun Jun 5 23:10:05 2016 New Revision: 301473 URL: https://svnweb.freebsd.org/changeset/base/301473 Log: Regenerate Modified: head/share/man/man5/src.conf.5 Modified: head/share/man/man5/src.conf.5 == --- head/share/man/man5/src.conf.5 Sun Jun 5 23:05:17 2016 (r301472) +++ head/share/man/man5/src.conf.5 Sun Jun 5 23:10:05 2016 (r301473) @@ -1,7 +1,7 @@ .\" DO NOT EDIT-- this file is automatically generated. .\" from FreeBSD: head/tools/build/options/makeman 292283 2015-12-15 18:42:30Z bdrewery .\" $FreeBSD$ -.Dd May 24, 2016 +.Dd June 5, 2016 .Dt SRC.CONF 5 .Os .Sh NAME @@ -1062,7 +1062,7 @@ Set to not build utilities for manual pa .Xr manctl 8 , and related support files. .It Va WITH_META_MODE -.\" from FreeBSD: head/tools/build/options/WITH_META_MODE 300630 2016-05-24 23:15:52Z bdrewery +.\" from FreeBSD: head/tools/build/options/WITH_META_MODE 301466 2016-06-05 23:04:42Z bdrewery Creates .Xr make 1 meta files when building, which can provide a reliable incremental build when @@ -1083,9 +1083,10 @@ The command to execute changes. .It The current working directory changes. .It -The target's meta file is missing, if it had -.Sy .META -as a dependency. +The target's meta file is missing. +.It +The target's meta file is missing filemon data when filemon is loaded +and a previous run did not have it loaded. .It [requires .Xr filemon 4 ] ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301474 - head/tools/build/options
Author: bdrewery Date: Sun Jun 5 23:14:06 2016 New Revision: 301474 URL: https://svnweb.freebsd.org/changeset/base/301474 Log: Document WITH_META_MODE enforcing WITHOUT_SYSTEM_COMPILER. makeman doesn't handle this since it would need to enable all non-default options when checking enabling 1 option, which then convolutes what is really affecting each other. Modified: head/tools/build/options/WITH_META_MODE Modified: head/tools/build/options/WITH_META_MODE == --- head/tools/build/options/WITH_META_MODE Sun Jun 5 23:10:05 2016 (r301473) +++ head/tools/build/options/WITH_META_MODE Sun Jun 5 23:14:06 2016 (r301474) @@ -42,3 +42,6 @@ The build operates as it normally would This option originally invoked a different build system but that was renamed to .Va WITH_DIRDEPS_BUILD . +.Pp +Currently this also enforces +.Va WITHOUT_SYSTEM_COMPILER . ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301475 - head/share/man/man5
Author: bdrewery Date: Sun Jun 5 23:16:27 2016 New Revision: 301475 URL: https://svnweb.freebsd.org/changeset/base/301475 Log: Regenerate Modified: head/share/man/man5/src.conf.5 Modified: head/share/man/man5/src.conf.5 == --- head/share/man/man5/src.conf.5 Sun Jun 5 23:14:06 2016 (r301474) +++ head/share/man/man5/src.conf.5 Sun Jun 5 23:16:27 2016 (r301475) @@ -1062,7 +1062,7 @@ Set to not build utilities for manual pa .Xr manctl 8 , and related support files. .It Va WITH_META_MODE -.\" from FreeBSD: head/tools/build/options/WITH_META_MODE 301466 2016-06-05 23:04:42Z bdrewery +.\" from FreeBSD: head/tools/build/options/WITH_META_MODE 301474 2016-06-05 23:14:06Z bdrewery Creates .Xr make 1 meta files when building, which can provide a reliable incremental build when @@ -1107,6 +1107,9 @@ This option originally invoked a differe to .Va WITH_DIRDEPS_BUILD . .Pp +Currently this also enforces +.Va WITHOUT_SYSTEM_COMPILER . +.Pp This must be set in the environment, make command line, or .Pa /etc/src-env.conf , not ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301476 - head/usr.bin/elfcopy
Author: bdrewery Date: Sun Jun 5 23:34:19 2016 New Revision: 301476 URL: https://svnweb.freebsd.org/changeset/base/301476 Log: Use the in-tree sys/elf_common.h This is the same fix as r301471. Modified: head/usr.bin/elfcopy/Makefile Modified: head/usr.bin/elfcopy/Makefile == --- head/usr.bin/elfcopy/Makefile Sun Jun 5 23:16:27 2016 (r301475) +++ head/usr.bin/elfcopy/Makefile Sun Jun 5 23:34:19 2016 (r301476) @@ -30,4 +30,17 @@ MAN= ${PROG}.1 strip.1 LINKS= ${BINDIR}/${PROG} ${BINDIR}/strip +# This same hack is in lib/libelf/Makefile and usr.bin/readelf/Makefile +# We need to link against the correct version of these files. One +# solution is to include ../../sys in the include path. This causes +# problems when a header file in sys depends on a file in another +# part of the tree, e.g. a machine dependent header. +# +SRCS+= sys/elf_common.h +CLEANDIRS= sys +CFLAGS+= -I. +sys/elf_common.h: ${SRCTOP}/sys/${.TARGET} .NOMETA + mkdir -p ${.OBJDIR}/sys + ln -sf ${.ALLSRC} ${.TARGET} + .include ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301477 - head
Author: bdrewery Date: Sun Jun 5 23:56:28 2016 New Revision: 301477 URL: https://svnweb.freebsd.org/changeset/base/301477 Log: legacy: Avoid building/installing headers twice. Sponsored by: EMC / Isilon Storage Division Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 == --- head/Makefile.inc1 Sun Jun 5 23:34:19 2016(r301476) +++ head/Makefile.inc1 Sun Jun 5 23:56:28 2016(r301477) @@ -1524,8 +1524,9 @@ legacy: .PHONY cd ${.CURDIR}/${_tool}; \ ${MAKE} DIRPRFX=${_tool}/ obj; \ ${MAKE} DIRPRFX=${_tool}/ DESTDIR=${MAKEOBJDIRPREFIX}/legacy includes; \ - ${MAKE} DIRPRFX=${_tool}/ all; \ - ${MAKE} DIRPRFX=${_tool}/ DESTDIR=${MAKEOBJDIRPREFIX}/legacy install + ${MAKE} DIRPRFX=${_tool}/ MK_INCLUDES=no all; \ + ${MAKE} DIRPRFX=${_tool}/ MK_INCLUDES=no \ + DESTDIR=${MAKEOBJDIRPREFIX}/legacy install .endfor # ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301478 - head/sys/netinet
Author: gnn Date: Mon Jun 6 00:35:45 2016 New Revision: 301478 URL: https://svnweb.freebsd.org/changeset/base/301478 Log: Add missing constants from RFCs 4443 and 6550 Modified: head/sys/netinet/icmp6.h Modified: head/sys/netinet/icmp6.h == --- head/sys/netinet/icmp6.hSun Jun 5 23:56:28 2016(r301477) +++ head/sys/netinet/icmp6.hMon Jun 6 00:35:45 2016(r301478) @@ -144,6 +144,9 @@ struct icmp6_hdr { #define ICMP6_DST_UNREACH_BEYONDSCOPE 2 /* beyond scope of source address */ #define ICMP6_DST_UNREACH_ADDR 3 /* address unreachable */ #define ICMP6_DST_UNREACH_NOPORT 4 /* port unreachable */ +#define ICMP6_DST_UNREACH_POLICY 5 /* failed ingress/egress policy */ +#define ICMP6_DST_UNREACH_REJECT 6 /* Reject route to destination */ +#define ICMP6_DST_UNREACH_SRCROUTE 7 /* Error in source routing header */ #define ICMP6_TIME_EXCEED_TRANSIT 0 /* ttl==0 in transit */ #define ICMP6_TIME_EXCEED_REASSEMBLY 1 /* ttl==0 in reass */ ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301479 - in head: etc/mtree share/examples
Author: araujo Date: Mon Jun 6 02:43:41 2016 New Revision: 301479 URL: https://svnweb.freebsd.org/changeset/base/301479 Log: Install/Connect ypldap.conf(5) on examples. Modified: head/etc/mtree/BSD.usr.dist head/share/examples/Makefile Modified: head/etc/mtree/BSD.usr.dist == --- head/etc/mtree/BSD.usr.dist Mon Jun 6 00:35:45 2016(r301478) +++ head/etc/mtree/BSD.usr.dist Mon Jun 6 02:43:41 2016(r301479) @@ -425,6 +425,8 @@ .. uefisign .. +ypldap +.. .. firmware .. Modified: head/share/examples/Makefile == --- head/share/examples/MakefileMon Jun 6 00:35:45 2016 (r301478) +++ head/share/examples/MakefileMon Jun 6 02:43:41 2016 (r301479) @@ -37,7 +37,8 @@ LDIRS=BSD_daemon \ ses \ scsi_target \ sunrpc \ - uefisign + uefisign \ + ypldap XFILES=BSD_daemon/FreeBSD.pfa \ BSD_daemon/README \ @@ -192,7 +193,8 @@ XFILES= BSD_daemon/FreeBSD.pfa \ sunrpc/sort/rsort.c \ sunrpc/sort/sort.x \ sunrpc/sort/sort_proc.c \ - uefisign/uefikeys + uefisign/uefikeys \ + ypldap/ypldap.conf BINDIR= ${SHAREDIR}/examples ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301480 - in head/etc: defaults rc.d
Author: araujo Date: Mon Jun 6 03:55:00 2016 New Revision: 301480 URL: https://svnweb.freebsd.org/changeset/base/301480 Log: Add rc.d script for ypldap(8). Added: head/etc/rc.d/ypldap (contents, props changed) Modified: head/etc/defaults/rc.conf Modified: head/etc/defaults/rc.conf == --- head/etc/defaults/rc.conf Mon Jun 6 02:43:41 2016(r301479) +++ head/etc/defaults/rc.conf Mon Jun 6 03:55:00 2016(r301480) @@ -392,6 +392,8 @@ nis_ypxfrd_enable="NO" # Run rpc.ypxfrd nis_ypxfrd_flags=""# Flags to rpc.ypxfrd (if enabled). nis_yppasswdd_enable="NO" # Run rpc.yppasswdd at boot time (or NO). nis_yppasswdd_flags="" # Flags to rpc.yppasswdd (if enabled). +nis_ypldap_enable="NO" # Run ypldap at boot time (or NO). +nis_ypldap_flags=""# Flags to ypldap (if enabled). ### SNMP daemon ### # Be sure to understand the security implications of running SNMP v1/v2 Added: head/etc/rc.d/ypldap == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/etc/rc.d/ypldapMon Jun 6 03:55:00 2016(r301480) @@ -0,0 +1,27 @@ +#!/bin/sh +# +# $FreeBSD$ +# + +# PROVIDE: ypldap +# REQUIRE: ypserv +# BEFORE: DAEMON +# KEYWORD: shutdown + +. /etc/rc.subr + +name="ypldap" +rcvar="nis_ypldap_enable" + +load_rc_config $name + +command="/usr/sbin/${name}" +command_args="${nis_ypldap_flags}" + +start_precmd="ypldap_precmd" + +ypldap_precmd() +{ + force_depend ypserv nis_server || return 1 +} +run_rc_command "$1" ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301481 - head/etc/rc.d
Author: araujo Date: Mon Jun 6 04:13:49 2016 New Revision: 301481 URL: https://svnweb.freebsd.org/changeset/base/301481 Log: Connect ypldap(8) script on Makefile, forgotten on my previous commit r301480. Modified: head/etc/rc.d/Makefile Modified: head/etc/rc.d/Makefile == --- head/etc/rc.d/Makefile Mon Jun 6 03:55:00 2016(r301480) +++ head/etc/rc.d/Makefile Mon Jun 6 04:13:49 2016(r301481) @@ -120,6 +120,7 @@ FILES= DAEMON \ var \ watchdogd \ ypbind \ + ypldap \ yppasswdd \ ypserv \ ypset \ ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301482 - head/usr.sbin/bluetooth/btpand
Author: araujo Date: Mon Jun 6 04:18:56 2016 New Revision: 301482 URL: https://svnweb.freebsd.org/changeset/base/301482 Log: For pointers use NULL instead of 0. Modified: head/usr.sbin/bluetooth/btpand/btpand.c Modified: head/usr.sbin/bluetooth/btpand/btpand.c == --- head/usr.sbin/bluetooth/btpand/btpand.c Mon Jun 6 04:13:49 2016 (r301481) +++ head/usr.sbin/bluetooth/btpand/btpand.c Mon Jun 6 04:18:56 2016 (r301482) @@ -171,7 +171,7 @@ main(int argc, char *argv[]) usage(); if (!bdaddr_any(&remote_bdaddr) && (server_limit != 0 || - control_path != 0 || (service_name != NULL && l2cap_psm != 0))) + control_path != NULL || (service_name != NULL && l2cap_psm != 0))) usage(); /* default options */ ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301483 - in head/sys: conf dev/hyperv/vmbus dev/hyperv/vmbus/amd64 dev/hyperv/vmbus/i386 modules/hyperv/vmbus
Author: sephe Date: Mon Jun 6 05:55:37 2016 New Revision: 301483 URL: https://svnweb.freebsd.org/changeset/base/301483 Log: hyperv: Move machine dependent bits into machine dependent files. MFC after:1 week Sponsored by: Microsoft OSTC Differential Revision:https://reviews.freebsd.org/D6701 Added: head/sys/dev/hyperv/vmbus/amd64/hyperv_machdep.c (contents, props changed) head/sys/dev/hyperv/vmbus/hyperv_machdep.h (contents, props changed) head/sys/dev/hyperv/vmbus/i386/hyperv_machdep.c (contents, props changed) Modified: head/sys/conf/files.amd64 head/sys/conf/files.i386 head/sys/dev/hyperv/vmbus/hyperv.c head/sys/modules/hyperv/vmbus/Makefile Modified: head/sys/conf/files.amd64 == --- head/sys/conf/files.amd64 Mon Jun 6 04:18:56 2016(r301482) +++ head/sys/conf/files.amd64 Mon Jun 6 05:55:37 2016(r301483) @@ -278,6 +278,7 @@ dev/hyperv/vmbus/hyperv.c optionalhy dev/hyperv/vmbus/hyperv_busdma.c optionalhyperv dev/hyperv/vmbus/vmbus.c optionalhyperv dev/hyperv/vmbus/vmbus_et.coptionalhyperv +dev/hyperv/vmbus/amd64/hyperv_machdep.coptional hyperv dev/hyperv/vmbus/amd64/vmbus_vector.S optionalhyperv dev/nfe/if_nfe.c optionalnfe pci dev/ntb/if_ntb/if_ntb.coptionalif_ntb Modified: head/sys/conf/files.i386 == --- head/sys/conf/files.i386Mon Jun 6 04:18:56 2016(r301482) +++ head/sys/conf/files.i386Mon Jun 6 05:55:37 2016(r301483) @@ -253,6 +253,7 @@ dev/hyperv/vmbus/hyperv.c optionalhy dev/hyperv/vmbus/hyperv_busdma.c optionalhyperv dev/hyperv/vmbus/vmbus.c optionalhyperv dev/hyperv/vmbus/vmbus_et.coptionalhyperv +dev/hyperv/vmbus/i386/hyperv_machdep.c optionalhyperv dev/hyperv/vmbus/i386/vmbus_vector.S optionalhyperv dev/ichwd/ichwd.c optional ichwd dev/if_ndis/if_ndis.c optional ndis Added: head/sys/dev/hyperv/vmbus/amd64/hyperv_machdep.c == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dev/hyperv/vmbus/amd64/hyperv_machdep.cMon Jun 6 05:55:37 2016(r301483) @@ -0,0 +1,43 @@ +/*- + * Copyright (c) 2016 Microsoft Corp. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice unmodified, this list of conditions, and the following + *disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include + +uint64_t +hypercall_md(volatile void *hc_addr, uint64_t in_val, +uint64_t in_paddr, uint64_t out_paddr) +{ + uint64_t status; + + __asm__ __volatile__ ("mov %0, %%r8" : : "r" (out_paddr): "r8"); + __asm__ __volatile__ ("call *%3" : "=a" (status) : + "c" (in_val), "d" (in_paddr), "m" (hc_addr)); + return (status); +} Modified: head/sys/dev/hyperv/vmbus/hyperv.c == --- head/sys/dev/hyperv/vmbus/hyperv.c Mon Jun 6 04:18:56 2016 (r301482) +++ head/sys/dev/hyperv/vmbus/hyperv.c Mon Jun 6 05:55:37 2016 (r301483) @@ -45,6 +45,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include @@ -104,40 +105,17 @@ hyperv_get_timecount(struct timecounter * @brief I
Re: svn commit: r301217 - in head/sys: net netinet netinet6
06.06.2016, 04:40, "George Neville-Neil" : > On 4 Jun 2016, at 15:05, Alexander V. Chernikov wrote: > >> 02.06.2016, 20:51, "George V. Neville-Neil" : >>> Author: gnn >>> Date: Thu Jun 2 17:51:29 2016 >>> New Revision: 301217 >>> URL: https://svnweb.freebsd.org/changeset/base/301217 >>> >>> Log: >>> This change re-adds L2 caching for TCP and UDP, as originally >>> added in D4306 >>> but removed due to other changes in the system. Restore the >>> llentry pointer >>> to the "struct route", and use it to cache the L2 lookup (ARP or >>> ND6) as >>> appropriate. >> >> I have several comments regarding this commit. >> >> 1 Architecturally, there was quite a lot of efforts to eliminate >> layering violation between lltable and other places in network stack. >> It ended by committing D4102, which allowed both to cleanup lower >> level, provide abstract “prepend” framework which could be used to >> provide cached data to _otuput() functions. >> This change brings these violations back in a really invasive way. >> >> Additionally, implementing L2 PCB caching at the other subsystem >> expense is really a bad idea. >> If one wants caching in some subsystem, it should be implemented in >> that subsystem not polluting other things. >> Current implementation permits this by filling in “ro_prepend” / >> ro_plen fields. >> >> In general, this change looks more like a local hack and not like the >> code that should be included in the tree. >> >> 2 There was no benchmarks proving the effectiveness of this change. >> (For example, it is not obvious if it could significantly improve TCP >> since we still have per-session TCP wlock + (typically) per-ring >> mutex, so removing lltable rock might not help things here). Given >> that the patch complicates existing code, there should be adequate >> benefits to consider whether this change is worth implementing. >> >> 3 The “network” group was not included to the review despite the >> fact that most of the changes were related to the L2 layer which is >> not “transport”, so some people might have missed this review. >> >> 4 This change DOES NOT WORK. really. >> (which raises questions on both review and benchmarking process). >> >> The reason is that “plle” argument is filled only in “heavy” >> lltable lookup functions (e.g. when we don’t have neighbour >> adjacency). 99.9% of the time arpresolve/nd6_resolve() returns the >> result w/o calling their heavy versions, and the returned “plle” >> is NULL. >> >> This can be easily verified by calling something like >> dtrace -n 'fbt:kernel:ether_output:entry /arg3!=NULL&&((struct route >> *)arg3)->ro_lle != NULL/ { stack(); }' >> >> Given that, I kindly ask you to backout this change. > > Hi, > > I'm going to limit the scope of this reply to just you, me and Mike > Karels, from whom this originated. No, please keep the discussion open. The decision on having that particular L2 caching implementation (and L2 caching in general) is quite important, so it would be great if all technical arguments were saved so other people can (now or later) understand the decision details. Thanks for understanding. > > Best, > George ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r301484 - head/sys/dev/hyperv/vmbus
Author: sephe Date: Mon Jun 6 06:18:18 2016 New Revision: 301484 URL: https://svnweb.freebsd.org/changeset/base/301484 Log: hyperv/vmbus: Define type for channel messages. And fix message processing; only channel messages are supported. MFC after:1 week Sponsored by: Microsoft OSTC Differential Revision:https://reviews.freebsd.org/D6706 Modified: head/sys/dev/hyperv/vmbus/hv_connection.c head/sys/dev/hyperv/vmbus/vmbus.c head/sys/dev/hyperv/vmbus/vmbus_reg.h Modified: head/sys/dev/hyperv/vmbus/hv_connection.c == --- head/sys/dev/hyperv/vmbus/hv_connection.c Mon Jun 6 05:55:37 2016 (r301483) +++ head/sys/dev/hyperv/vmbus/hv_connection.c Mon Jun 6 06:18:18 2016 (r301484) @@ -373,8 +373,8 @@ int hv_vmbus_post_message(void *buffer, * insufficient resources. 20 times should suffice in practice. */ for (retries = 0; retries < 20; retries++) { - ret = hv_vmbus_post_msg_via_msg_ipc(connId, 1, buffer, - bufferLen); + ret = hv_vmbus_post_msg_via_msg_ipc(connId, + VMBUS_MSGTYPE_CHANNEL, buffer, bufferLen); if (ret == HV_STATUS_SUCCESS) return (0); Modified: head/sys/dev/hyperv/vmbus/vmbus.c == --- head/sys/dev/hyperv/vmbus/vmbus.c Mon Jun 6 05:55:37 2016 (r301483) +++ head/sys/dev/hyperv/vmbus/vmbus.c Mon Jun 6 06:18:18 2016 (r301484) @@ -85,8 +85,13 @@ vmbus_msg_task(void *xsc, int pending __ hv_vmbus_channel_msg_header *hdr; hv_vmbus_channel_msg_type msg_type; - if (msg->msg_type == VMBUS_MSGTYPE_NONE) - break; /* no message */ + if (msg->msg_type == VMBUS_MSGTYPE_NONE) { + /* No message */ + break; + } else if (msg->msg_type != VMBUS_MSGTYPE_CHANNEL) { + /* Not a channel message */ + goto handled; + } /* XXX: update messageHandler interface */ hdr = __DEVOLATILE(hv_vmbus_channel_msg_header *, Modified: head/sys/dev/hyperv/vmbus/vmbus_reg.h == --- head/sys/dev/hyperv/vmbus/vmbus_reg.h Mon Jun 6 05:55:37 2016 (r301483) +++ head/sys/dev/hyperv/vmbus/vmbus_reg.h Mon Jun 6 06:18:18 2016 (r301484) @@ -49,6 +49,7 @@ struct vmbus_message { CTASSERT(sizeof(struct vmbus_message) == VMBUS_MSG_SIZE); #define VMBUS_MSGTYPE_NONE 0 +#define VMBUS_MSGTYPE_CHANNEL 1 #define VMBUS_MSGTYPE_TIMER_EXPIRED0x8010 #define VMBUS_MSGFLAG_PENDING 0x01 ___ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"