Re: svn commit: r322942 - head/sys/kern
Hi Conrad, [ Context: I don't understand anything about CPU topologies! ] 2017-08-27 7:14 GMT+02:00 Conrad Meyer : > + while (top->cg_children == 1) { > + top = &top->cg_child[0]; > + top->cg_parent = NULL; > + } This only removes layers from the top if they only have a single child. Question: is it possible/likely to have CPU topologies where one of the middle layers only has one child? If so, would it make sense to use tree traversal here to do the flattening? -- Ed Schouten Nuxi, 's-Hertogenbosch, the Netherlands KvK-nr.: 62051717 ___ 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: r322947 - head/sys/dev/ppc
Author: kib Date: Sun Aug 27 11:37:07 2017 New Revision: 322947 URL: https://svnweb.freebsd.org/changeset/base/322947 Log: Add PCI Id for MosChip MCS9900. Submitted by: Robert Clausecker PR: 214670 MFC after:1 week Modified: head/sys/dev/ppc/ppc_pci.c Modified: head/sys/dev/ppc/ppc_pci.c == --- head/sys/dev/ppc/ppc_pci.c Sun Aug 27 11:27:27 2017(r322946) +++ head/sys/dev/ppc/ppc_pci.c Sun Aug 27 11:37:07 2017(r322947) @@ -91,6 +91,7 @@ static struct pci_id pci_ids[] = { { 0xc1101415, "Oxford Semiconductor OXPCIe952 Parallel port", 0x10 }, { 0x98059710, "NetMos NM9805 1284 Printer port", 0x10 }, { 0x98659710, "MosChip MCS9865 1284 Printer port", 0x10 }, + { 0x99009710, "MosChip MCS9900 PCIe to Peripheral Controller", 0x10 }, { 0x99019710, "MosChip MCS9901 PCIe to Peripheral Controller", 0x10 }, { 0x } }; ___ 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: r322948 - head/sys/geom
Author: kib Date: Sun Aug 27 12:24:25 2017 New Revision: 322948 URL: https://svnweb.freebsd.org/changeset/base/322948 Log: Let g_access() log the actual error number. Submitted by: Fabian Keil PR: 221855 MFC after:1 week Modified: head/sys/geom/geom_subr.c Modified: head/sys/geom/geom_subr.c == --- head/sys/geom/geom_subr.c Sun Aug 27 11:37:07 2017(r322947) +++ head/sys/geom/geom_subr.c Sun Aug 27 12:24:25 2017(r322948) @@ -918,8 +918,8 @@ g_access(struct g_consumer *cp, int dcr, int dcw, int return (EPERM); /* If we try to open more but provider is error'ed: fail */ else if ((dcr > 0 || dcw > 0 || dce > 0) && pp->error != 0) { - printf("%s(%d): provider %s has error\n", - __func__, __LINE__, pp->name); + printf("%s(%d): provider %s has error %d set\n", + __func__, __LINE__, pp->name, pp->error); return (pp->error); } ___ 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: r322949 - in head/sys/dev/rtwn: rtl8188e rtl8192c
Author: avos Date: Sun Aug 27 12:44:56 2017 New Revision: 322949 URL: https://svnweb.freebsd.org/changeset/base/322949 Log: rtwn(4): change type for Tx power values (RTL8192C / RTL8188EU). Tx power values can easily fit into uint8_t + only 8 bits are written to registers; values may overflow only in case if ROM contains malformed data (but limit is checked anyway). Tested with RTL8188CUS, dev.rtwn.1.debug=0x2000 (no changes). Modified: head/sys/dev/rtwn/rtl8188e/r88e.h head/sys/dev/rtwn/rtl8188e/r88e_chan.c head/sys/dev/rtwn/rtl8192c/r92c.h head/sys/dev/rtwn/rtl8192c/r92c_chan.c head/sys/dev/rtwn/rtl8192c/r92c_var.h Modified: head/sys/dev/rtwn/rtl8188e/r88e.h == --- head/sys/dev/rtwn/rtl8188e/r88e.h Sun Aug 27 12:24:25 2017 (r322948) +++ head/sys/dev/rtwn/rtl8188e/r88e.h Sun Aug 27 12:44:56 2017 (r322949) @@ -49,7 +49,7 @@ uint8_t r88e_temp_read(struct rtwn_softc *); /* r88e_chan.c */ void r88e_get_txpower(struct rtwn_softc *, int, - struct ieee80211_channel *, uint16_t[]); + struct ieee80211_channel *, uint8_t[]); void r88e_set_bw20(struct rtwn_softc *, uint8_t); void r88e_set_gain(struct rtwn_softc *, uint8_t); Modified: head/sys/dev/rtwn/rtl8188e/r88e_chan.c == --- head/sys/dev/rtwn/rtl8188e/r88e_chan.c Sun Aug 27 12:24:25 2017 (r322948) +++ head/sys/dev/rtwn/rtl8188e/r88e_chan.c Sun Aug 27 12:44:56 2017 (r322949) @@ -85,7 +85,7 @@ r88e_get_power_group(struct rtwn_softc *sc, struct iee void r88e_get_txpower(struct rtwn_softc *sc, int chain, -struct ieee80211_channel *c, uint16_t power[RTWN_RIDX_COUNT]) +struct ieee80211_channel *c, uint8_t power[RTWN_RIDX_COUNT]) { struct r92c_softc *rs = sc->sc_priv; const struct rtwn_r88e_txpwr *rt = rs->rs_txpwr; Modified: head/sys/dev/rtwn/rtl8192c/r92c.h == --- head/sys/dev/rtwn/rtl8192c/r92c.h Sun Aug 27 12:24:25 2017 (r322948) +++ head/sys/dev/rtwn/rtl8192c/r92c.h Sun Aug 27 12:44:56 2017 (r322949) @@ -55,7 +55,7 @@ uint8_t r92c_temp_read(struct rtwn_softc *); /* r92c_chan.c */ void r92c_get_txpower(struct rtwn_softc *, int, - struct ieee80211_channel *, uint16_t[]); + struct ieee80211_channel *, uint8_t[]); void r92c_set_bw20(struct rtwn_softc *, uint8_t); void r92c_set_chan(struct rtwn_softc *, struct ieee80211_channel *); void r92c_set_gain(struct rtwn_softc *, uint8_t); Modified: head/sys/dev/rtwn/rtl8192c/r92c_chan.c == --- head/sys/dev/rtwn/rtl8192c/r92c_chan.c Sun Aug 27 12:24:25 2017 (r322948) +++ head/sys/dev/rtwn/rtl8192c/r92c_chan.c Sun Aug 27 12:44:56 2017 (r322949) @@ -82,7 +82,7 @@ r92c_get_power_group(struct rtwn_softc *sc, struct iee /* XXX recheck */ void r92c_get_txpower(struct rtwn_softc *sc, int chain, -struct ieee80211_channel *c, uint16_t power[RTWN_RIDX_COUNT]) +struct ieee80211_channel *c, uint8_t power[RTWN_RIDX_COUNT]) { struct r92c_softc *rs = sc->sc_priv; struct rtwn_r92c_txpwr *rt = rs->rs_txpwr; @@ -158,7 +158,7 @@ r92c_get_txpower(struct rtwn_softc *sc, int chain, static void r92c_write_txpower(struct rtwn_softc *sc, int chain, -uint16_t power[RTWN_RIDX_COUNT]) +uint8_t power[RTWN_RIDX_COUNT]) { uint32_t reg; @@ -221,7 +221,7 @@ r92c_write_txpower(struct rtwn_softc *sc, int chain, static void r92c_set_txpower(struct rtwn_softc *sc, struct ieee80211_channel *c) { - uint16_t power[RTWN_RIDX_COUNT]; + uint8_t power[RTWN_RIDX_COUNT]; int i; for (i = 0; i < sc->ntxchains; i++) { Modified: head/sys/dev/rtwn/rtl8192c/r92c_var.h == --- head/sys/dev/rtwn/rtl8192c/r92c_var.h Sun Aug 27 12:24:25 2017 (r322948) +++ head/sys/dev/rtwn/rtl8192c/r92c_var.h Sun Aug 27 12:44:56 2017 (r322949) @@ -53,7 +53,7 @@ struct r92c_softc { void(*rs_set_bw20)(struct rtwn_softc *, uint8_t); void(*rs_get_txpower)(struct rtwn_softc *, int, - struct ieee80211_channel *, uint16_t[]); + struct ieee80211_channel *, uint8_t[]); void(*rs_set_gain)(struct rtwn_softc *, uint8_t); void(*rs_tx_enable_ampdu)(void *, int); void(*rs_tx_setup_hwseq)(void *); ___ 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: r322950 - in head/sys/dev/rtwn: rtl8192c rtl8192e
Author: avos Date: Sun Aug 27 13:02:51 2017 New Revision: 322950 URL: https://svnweb.freebsd.org/changeset/base/322950 Log: rtwn(4): deduplicate r92c_write_txpower(). Modified: head/sys/dev/rtwn/rtl8192c/r92c.h head/sys/dev/rtwn/rtl8192c/r92c_chan.c head/sys/dev/rtwn/rtl8192e/r92e_chan.c Modified: head/sys/dev/rtwn/rtl8192c/r92c.h == --- head/sys/dev/rtwn/rtl8192c/r92c.h Sun Aug 27 12:44:56 2017 (r322949) +++ head/sys/dev/rtwn/rtl8192c/r92c.h Sun Aug 27 13:02:51 2017 (r322950) @@ -56,6 +56,8 @@ uint8_t r92c_temp_read(struct rtwn_softc *); /* r92c_chan.c */ void r92c_get_txpower(struct rtwn_softc *, int, struct ieee80211_channel *, uint8_t[]); +void r92c_write_txpower(struct rtwn_softc *, int, + uint8_t power[]); void r92c_set_bw20(struct rtwn_softc *, uint8_t); void r92c_set_chan(struct rtwn_softc *, struct ieee80211_channel *); void r92c_set_gain(struct rtwn_softc *, uint8_t); Modified: head/sys/dev/rtwn/rtl8192c/r92c_chan.c == --- head/sys/dev/rtwn/rtl8192c/r92c_chan.c Sun Aug 27 12:44:56 2017 (r322949) +++ head/sys/dev/rtwn/rtl8192c/r92c_chan.c Sun Aug 27 13:02:51 2017 (r322950) @@ -156,7 +156,7 @@ r92c_get_txpower(struct rtwn_softc *sc, int chain, } } -static void +void r92c_write_txpower(struct rtwn_softc *sc, int chain, uint8_t power[RTWN_RIDX_COUNT]) { Modified: head/sys/dev/rtwn/rtl8192e/r92e_chan.c == --- head/sys/dev/rtwn/rtl8192e/r92e_chan.c Sun Aug 27 12:44:56 2017 (r322949) +++ head/sys/dev/rtwn/rtl8192e/r92e_chan.c Sun Aug 27 13:02:51 2017 (r322950) @@ -57,6 +57,8 @@ __FBSDID("$FreeBSD$"); #include #include +#include + #include #include #include @@ -144,70 +146,7 @@ r92e_get_txpower(struct rtwn_softc *sc, int chain, str #endif } - static void -r92e_write_txpower(struct rtwn_softc *sc, int chain, -uint8_t power[RTWN_RIDX_COUNT]) -{ - uint32_t reg; - - /* Write per-CCK rate Tx power. */ - if (chain == 0) { - reg = rtwn_bb_read(sc, R92C_TXAGC_A_CCK1_MCS32); - reg = RW(reg, R92C_TXAGC_A_CCK1, power[RTWN_RIDX_CCK1]); - rtwn_bb_write(sc, R92C_TXAGC_A_CCK1_MCS32, reg); - reg = rtwn_bb_read(sc, R92C_TXAGC_B_CCK11_A_CCK2_11); - reg = RW(reg, R92C_TXAGC_A_CCK2, power[RTWN_RIDX_CCK2]); - reg = RW(reg, R92C_TXAGC_A_CCK55, power[RTWN_RIDX_CCK55]); - reg = RW(reg, R92C_TXAGC_A_CCK11, power[RTWN_RIDX_CCK11]); - rtwn_bb_write(sc, R92C_TXAGC_B_CCK11_A_CCK2_11, reg); - } else { - reg = rtwn_bb_read(sc, R92C_TXAGC_B_CCK1_55_MCS32); - reg = RW(reg, R92C_TXAGC_B_CCK1, power[RTWN_RIDX_CCK1]); - reg = RW(reg, R92C_TXAGC_B_CCK2, power[RTWN_RIDX_CCK2]); - reg = RW(reg, R92C_TXAGC_B_CCK55, power[RTWN_RIDX_CCK55]); - rtwn_bb_write(sc, R92C_TXAGC_B_CCK1_55_MCS32, reg); - reg = rtwn_bb_read(sc, R92C_TXAGC_B_CCK11_A_CCK2_11); - reg = RW(reg, R92C_TXAGC_B_CCK11, power[RTWN_RIDX_CCK11]); - rtwn_bb_write(sc, R92C_TXAGC_B_CCK11_A_CCK2_11, reg); - } - /* Write per-OFDM rate Tx power. */ - rtwn_bb_write(sc, R92C_TXAGC_RATE18_06(chain), - SM(R92C_TXAGC_RATE06, power[RTWN_RIDX_OFDM6]) | - SM(R92C_TXAGC_RATE09, power[RTWN_RIDX_OFDM9]) | - SM(R92C_TXAGC_RATE12, power[RTWN_RIDX_OFDM12]) | - SM(R92C_TXAGC_RATE18, power[RTWN_RIDX_OFDM18])); - rtwn_bb_write(sc, R92C_TXAGC_RATE54_24(chain), - SM(R92C_TXAGC_RATE24, power[RTWN_RIDX_OFDM24]) | - SM(R92C_TXAGC_RATE36, power[RTWN_RIDX_OFDM36]) | - SM(R92C_TXAGC_RATE48, power[RTWN_RIDX_OFDM48]) | - SM(R92C_TXAGC_RATE54, power[RTWN_RIDX_OFDM54])); - /* Write per-MCS Tx power. */ - rtwn_bb_write(sc, R92C_TXAGC_MCS03_MCS00(chain), - SM(R92C_TXAGC_MCS00, power[RTWN_RIDX_MCS(0)]) | - SM(R92C_TXAGC_MCS01, power[RTWN_RIDX_MCS(1)]) | - SM(R92C_TXAGC_MCS02, power[RTWN_RIDX_MCS(2)]) | - SM(R92C_TXAGC_MCS03, power[RTWN_RIDX_MCS(3)])); - rtwn_bb_write(sc, R92C_TXAGC_MCS07_MCS04(chain), - SM(R92C_TXAGC_MCS04, power[RTWN_RIDX_MCS(4)]) | - SM(R92C_TXAGC_MCS05, power[RTWN_RIDX_MCS(5)]) | - SM(R92C_TXAGC_MCS06, power[RTWN_RIDX_MCS(6)]) | - SM(R92C_TXAGC_MCS07, power[RTWN_RIDX_MCS(7)])); - if (sc->ntxchains >= 2) { - rtwn_bb_write(sc, R92C_TXAGC_MCS11_MCS08(chain), - SM(R92C_TXAGC_MCS08, power[RTWN_RIDX_MCS(8)]) | - SM(R92C_TXAGC_MCS09, power[RTWN_RIDX_MCS(9)]) | - SM(R92C_TXAGC_MCS10, power[R
Re: svn commit: r322942 - head/sys/kern
On Sun, Aug 27, 2017 at 1:18 AM, Ed Schouten wrote: > Hi Conrad, > > [ Context: I don't understand anything about CPU topologies! ] > > 2017-08-27 7:14 GMT+02:00 Conrad Meyer : >> + while (top->cg_children == 1) { >> + top = &top->cg_child[0]; >> + top->cg_parent = NULL; >> + } > > This only removes layers from the top if they only have a single > child. Question: is it possible/likely to have CPU topologies where > one of the middle layers only has one child? If so, would it make > sense to use tree traversal here to do the flattening? Hi Ed, It is probably possible for middle layers to have a single child, and your proposal is a good one. This is just the canned patch from Jeff I already had lying around :-). Best, Conrad ___ 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: r322951 - head
Author: ngie Date: Sun Aug 27 16:15:37 2017 New Revision: 322951 URL: https://svnweb.freebsd.org/changeset/base/322951 Log: Respect MK_TCSH with build-tools and native-xtools This helps reduce the WORLDTMP footprint slightly. Based on a patch I submitted 5 years ago to GNATS. PR: 174051 MFC after:2 weeks Relnotes: yes (anyone who cross-builds with MK_TCSH=yes will run into build failures if the host doesn't have tcsh(1)) Reminded by: Fabian Keil Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 == --- head/Makefile.inc1 Sun Aug 27 13:02:51 2017(r322950) +++ head/Makefile.inc1 Sun Aug 27 16:15:37 2017(r322951) @@ -1984,8 +1984,12 @@ _gcc_tools= gnu/usr.bin/cc/cc_tools _rescue=rescue/rescue .endif +.if ${MK_TCSH} != "no" +_tcsh=bin/csh +.endif + .for _tool in \ -bin/csh \ +${_tcsh} \ bin/sh \ ${LOCAL_TOOL_DIRS} \ lib/ncurses/ncurses \ @@ -2143,7 +2147,7 @@ native-xtools: .PHONY bin/cat \ bin/chmod \ bin/cp \ -bin/csh \ +${_tcsh} \ bin/echo \ bin/expr \ bin/hostname \ ___ 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: r322952 - head/share/mk
Author: ngie Date: Sun Aug 27 16:46:51 2017 New Revision: 322952 URL: https://svnweb.freebsd.org/changeset/base/322952 Log: Try and rebase the bsd.lib.mk changes after ^/head@r322824 was merged in Unfortunately the snippet's now broken -- need to get the matching expressions to work properly. Modified: head/share/mk/bsd.lib.mk Modified: head/share/mk/bsd.lib.mk == --- head/share/mk/bsd.lib.mkSun Aug 27 16:15:37 2017(r322951) +++ head/share/mk/bsd.lib.mkSun Aug 27 16:46:51 2017(r322952) @@ -76,6 +76,13 @@ CTFFLAGS+= -g .include +.if ${MK_COVERAGE} != "no" && (!empty(CFLAGS:M-g*) || !empty(CXXFLAGS:M-g*)) +_COV_FLAG= --coverage +CFLAGS+= ${_COV_FLAG} +CXXFLAGS+= ${_COV_FLAG} +.error "foo" +.endif + # prefer .s to a .c, add .po, remove stuff not used in the BSD libraries # .pico used for PIC object files .SUFFIXES: .out .o .bc .ll .po .pico .S .asm .s .c .cc .cpp .cxx .C .f .y .l .ln @@ -95,14 +102,14 @@ PO_FLAG=-pg ${CTFCONVERT_CMD} .c.pico: - ${CC} ${PICFLAG} -DPIC ${SHARED_CFLAGS} ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET} + ${CC} ${PICFLAG} -DPIC ${PO_CFLAGS} ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET} ${CTFCONVERT_CMD} .cc.po .C.po .cpp.po .cxx.po: ${CXX} ${PO_FLAG} ${STATIC_CXXFLAGS} ${PO_CXXFLAGS} -c ${.IMPSRC} -o ${.TARGET} .cc.pico .C.pico .cpp.pico .cxx.pico: - ${CXX} ${PICFLAG} -DPIC ${SHARED_CXXFLAGS} ${CXXFLAGS} -c ${.IMPSRC} -o ${.TARGET} + ${CXX} ${PICFLAG} -DPIC ${PO_CXXFLAGS} ${CXXFLAGS} -c ${.IMPSRC} -o ${.TARGET} .f.po: ${FC} -pg ${FFLAGS} -o ${.TARGET} -c ${.IMPSRC} @@ -142,6 +149,12 @@ _SHLIBDIR:=${SHLIBDIR} .if defined(SHLIB_NAME) .if ${MK_DEBUG_FILES} != "no" SHLIB_NAME_FULL=${SHLIB_NAME}.full +.if ${MK_COVERAGE} != "no" +COVERAGEFILEDIR=${COVERAGEDIR}${_SHLIBDIR} +.if !exists(${DESTDIR}${COVERAGEFILEDIR}) +COVERAGEMKDIR= +.endif +.endif # Use ${DEBUGDIR} for base system debug files, else .debug subdirectory .if ${_SHLIBDIR} == "/boot" ||\ ${SHLIBDIR:C%/lib(/.*)?$%/lib%} == "/lib" ||\ @@ -221,6 +234,9 @@ CLEANFILES+=${SOBJS} .if defined(SHLIB_NAME) _LIBS+=${SHLIB_NAME} +.if !empty(_COV_FLAG) +SOLINKOPTS+= ${_COV_FLAG} +.endif SOLINKOPTS+= -shared -Wl,-x .if defined(LD_FATAL_WARNINGS) && ${LD_FATAL_WARNINGS} == "no" SOLINKOPTS+= -Wl,--no-fatal-warnings @@ -360,6 +376,14 @@ _libinstall: ${_INSTALLFLAGS} ${_SHLINSTALLFLAGS} \ ${SHLIB_NAME} ${DESTDIR}${_SHLIBDIR}/ .if ${MK_DEBUG_FILES} != "no" +.if ${MK_COVERAGE} != "no" +.if defined(COVERAGEMKDIR) + ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},coverage} -d ${DESTDIR}${COVERAGEFILEDIR}/ +.endif + ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},coverage} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ + ${_INSTALLFLAGS} \ + ${SHLIB_NAME}.full ${DESTDIR}${COVERAGEFILEDIR}/${SHLIB_NAME} +.endif .if defined(DEBUGMKDIR) ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},debug} -d ${DESTDIR}${DEBUGFILEDIR}/ .endif @@ -411,6 +435,11 @@ _libinstall: .if !defined(LIBRARIES_ONLY) .include +.if defined(_COV_FLAG) +COV_OBJS= ${OBJS} +COV_SRCS= ${SRCS:M*.[c|cc|cpp|cxx|C]} +.include +.endif .include .include .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"
Re: svn commit: r322952 - head/share/mk
This appears to be breaking the build: -- >>> stage 1.1: legacy release compatibility shims -- ===> tools/build (obj,includes,all,install) make[5]: "/home/cem/head.svn/share/mk/bsd.lib.mk" line 79: Malformed conditional (${MK_COVERAGE} != "no" && (!empty(CFLAGS:M-g*) || !empty(CXXFLAGS:M-g*))) make[5]: Fatal errors encountered -- cannot continue make[5]: stopped in /home/cem/head.svn/tools/build On Sun, Aug 27, 2017 at 9:46 AM, Ngie Cooper wrote: > Author: ngie > Date: Sun Aug 27 16:46:51 2017 > New Revision: 322952 > URL: https://svnweb.freebsd.org/changeset/base/322952 > > Log: > Try and rebase the bsd.lib.mk changes after ^/head@r322824 was merged in > > Unfortunately the snippet's now broken -- need to get the matching > expressions to > work properly. > > Modified: > head/share/mk/bsd.lib.mk > > Modified: head/share/mk/bsd.lib.mk > == > --- head/share/mk/bsd.lib.mkSun Aug 27 16:15:37 2017(r322951) > +++ head/share/mk/bsd.lib.mkSun Aug 27 16:46:51 2017(r322952) > @@ -76,6 +76,13 @@ CTFFLAGS+= -g > > .include > > +.if ${MK_COVERAGE} != "no" && (!empty(CFLAGS:M-g*) || !empty(CXXFLAGS:M-g*)) > +_COV_FLAG= --coverage > +CFLAGS+= ${_COV_FLAG} > +CXXFLAGS+= ${_COV_FLAG} > +.error "foo" > +.endif > + > # prefer .s to a .c, add .po, remove stuff not used in the BSD libraries > # .pico used for PIC object files > .SUFFIXES: .out .o .bc .ll .po .pico .S .asm .s .c .cc .cpp .cxx .C .f .y .l > .ln > @@ -95,14 +102,14 @@ PO_FLAG=-pg > ${CTFCONVERT_CMD} > > .c.pico: > - ${CC} ${PICFLAG} -DPIC ${SHARED_CFLAGS} ${CFLAGS} -c ${.IMPSRC} -o > ${.TARGET} > + ${CC} ${PICFLAG} -DPIC ${PO_CFLAGS} ${CFLAGS} -c ${.IMPSRC} -o > ${.TARGET} > ${CTFCONVERT_CMD} > > .cc.po .C.po .cpp.po .cxx.po: > ${CXX} ${PO_FLAG} ${STATIC_CXXFLAGS} ${PO_CXXFLAGS} -c ${.IMPSRC} -o > ${.TARGET} > > .cc.pico .C.pico .cpp.pico .cxx.pico: > - ${CXX} ${PICFLAG} -DPIC ${SHARED_CXXFLAGS} ${CXXFLAGS} -c ${.IMPSRC} > -o ${.TARGET} > + ${CXX} ${PICFLAG} -DPIC ${PO_CXXFLAGS} ${CXXFLAGS} -c ${.IMPSRC} -o > ${.TARGET} > > .f.po: > ${FC} -pg ${FFLAGS} -o ${.TARGET} -c ${.IMPSRC} > @@ -142,6 +149,12 @@ _SHLIBDIR:=${SHLIBDIR} > .if defined(SHLIB_NAME) > .if ${MK_DEBUG_FILES} != "no" > SHLIB_NAME_FULL=${SHLIB_NAME}.full > +.if ${MK_COVERAGE} != "no" > +COVERAGEFILEDIR=${COVERAGEDIR}${_SHLIBDIR} > +.if !exists(${DESTDIR}${COVERAGEFILEDIR}) > +COVERAGEMKDIR= > +.endif > +.endif > # Use ${DEBUGDIR} for base system debug files, else .debug subdirectory > .if ${_SHLIBDIR} == "/boot" ||\ > ${SHLIBDIR:C%/lib(/.*)?$%/lib%} == "/lib" ||\ > @@ -221,6 +234,9 @@ CLEANFILES+=${SOBJS} > .if defined(SHLIB_NAME) > _LIBS+=${SHLIB_NAME} > > +.if !empty(_COV_FLAG) > +SOLINKOPTS+= ${_COV_FLAG} > +.endif > SOLINKOPTS+= -shared -Wl,-x > .if defined(LD_FATAL_WARNINGS) && ${LD_FATAL_WARNINGS} == "no" > SOLINKOPTS+= -Wl,--no-fatal-warnings > @@ -360,6 +376,14 @@ _libinstall: > ${_INSTALLFLAGS} ${_SHLINSTALLFLAGS} \ > ${SHLIB_NAME} ${DESTDIR}${_SHLIBDIR}/ > .if ${MK_DEBUG_FILES} != "no" > +.if ${MK_COVERAGE} != "no" > +.if defined(COVERAGEMKDIR) > + ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},coverage} -d > ${DESTDIR}${COVERAGEFILEDIR}/ > +.endif > + ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},coverage} -o ${LIBOWN} -g > ${LIBGRP} -m ${LIBMODE} \ > + ${_INSTALLFLAGS} \ > + ${SHLIB_NAME}.full ${DESTDIR}${COVERAGEFILEDIR}/${SHLIB_NAME} > +.endif > .if defined(DEBUGMKDIR) > ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},debug} -d > ${DESTDIR}${DEBUGFILEDIR}/ > .endif > @@ -411,6 +435,11 @@ _libinstall: > > .if !defined(LIBRARIES_ONLY) > .include > +.if defined(_COV_FLAG) > +COV_OBJS= ${OBJS} > +COV_SRCS= ${SRCS:M*.[c|cc|cpp|cxx|C]} > +.include > +.endif > .include > .include > .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"
Re: svn commit: r322952 - head/share/mk
> On Aug 27, 2017, at 09:57, Conrad Meyer wrote: > > This appears to be breaking the build: > > -- stage 1.1: legacy release compatibility shims > -- > ===> tools/build (obj,includes,all,install) > make[5]: "/home/cem/head.svn/share/mk/bsd.lib.mk" line 79: Malformed > conditional (${MK_COVERAGE} != "no" && (!empty(CFLAGS:M-g*) || > !empty(CXXFLAGS:M-g*))) > make[5]: Fatal errors encountered -- cannot continue > make[5]: stopped in /home/cem/head.svn/tools/build The svn switch didn’t complete successfully — great. I’ll fix this shortly. -Ngie signature.asc Description: Message signed with OpenPGP using GPGMail
svn commit: r322953 - head/share/mk
Author: ngie Date: Sun Aug 27 17:08:08 2017 New Revision: 322953 URL: https://svnweb.freebsd.org/changeset/base/322953 Log: Revert change (r322952) that was not yet destined for ^/head This unbreaks the build. This happened because of a botched "svn switch". Reported by: cem Modified: head/share/mk/bsd.lib.mk Modified: head/share/mk/bsd.lib.mk == --- head/share/mk/bsd.lib.mkSun Aug 27 16:46:51 2017(r322952) +++ head/share/mk/bsd.lib.mkSun Aug 27 17:08:08 2017(r322953) @@ -76,13 +76,6 @@ CTFFLAGS+= -g .include -.if ${MK_COVERAGE} != "no" && (!empty(CFLAGS:M-g*) || !empty(CXXFLAGS:M-g*)) -_COV_FLAG= --coverage -CFLAGS+= ${_COV_FLAG} -CXXFLAGS+= ${_COV_FLAG} -.error "foo" -.endif - # prefer .s to a .c, add .po, remove stuff not used in the BSD libraries # .pico used for PIC object files .SUFFIXES: .out .o .bc .ll .po .pico .S .asm .s .c .cc .cpp .cxx .C .f .y .l .ln @@ -102,14 +95,14 @@ PO_FLAG=-pg ${CTFCONVERT_CMD} .c.pico: - ${CC} ${PICFLAG} -DPIC ${PO_CFLAGS} ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET} + ${CC} ${PICFLAG} -DPIC ${SHARED_CFLAGS} ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET} ${CTFCONVERT_CMD} .cc.po .C.po .cpp.po .cxx.po: ${CXX} ${PO_FLAG} ${STATIC_CXXFLAGS} ${PO_CXXFLAGS} -c ${.IMPSRC} -o ${.TARGET} .cc.pico .C.pico .cpp.pico .cxx.pico: - ${CXX} ${PICFLAG} -DPIC ${PO_CXXFLAGS} ${CXXFLAGS} -c ${.IMPSRC} -o ${.TARGET} + ${CXX} ${PICFLAG} -DPIC ${SHARED_CXXFLAGS} ${CXXFLAGS} -c ${.IMPSRC} -o ${.TARGET} .f.po: ${FC} -pg ${FFLAGS} -o ${.TARGET} -c ${.IMPSRC} @@ -149,12 +142,6 @@ _SHLIBDIR:=${SHLIBDIR} .if defined(SHLIB_NAME) .if ${MK_DEBUG_FILES} != "no" SHLIB_NAME_FULL=${SHLIB_NAME}.full -.if ${MK_COVERAGE} != "no" -COVERAGEFILEDIR=${COVERAGEDIR}${_SHLIBDIR} -.if !exists(${DESTDIR}${COVERAGEFILEDIR}) -COVERAGEMKDIR= -.endif -.endif # Use ${DEBUGDIR} for base system debug files, else .debug subdirectory .if ${_SHLIBDIR} == "/boot" ||\ ${SHLIBDIR:C%/lib(/.*)?$%/lib%} == "/lib" ||\ @@ -234,9 +221,6 @@ CLEANFILES+=${SOBJS} .if defined(SHLIB_NAME) _LIBS+=${SHLIB_NAME} -.if !empty(_COV_FLAG) -SOLINKOPTS+= ${_COV_FLAG} -.endif SOLINKOPTS+= -shared -Wl,-x .if defined(LD_FATAL_WARNINGS) && ${LD_FATAL_WARNINGS} == "no" SOLINKOPTS+= -Wl,--no-fatal-warnings @@ -376,14 +360,6 @@ _libinstall: ${_INSTALLFLAGS} ${_SHLINSTALLFLAGS} \ ${SHLIB_NAME} ${DESTDIR}${_SHLIBDIR}/ .if ${MK_DEBUG_FILES} != "no" -.if ${MK_COVERAGE} != "no" -.if defined(COVERAGEMKDIR) - ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},coverage} -d ${DESTDIR}${COVERAGEFILEDIR}/ -.endif - ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},coverage} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ - ${_INSTALLFLAGS} \ - ${SHLIB_NAME}.full ${DESTDIR}${COVERAGEFILEDIR}/${SHLIB_NAME} -.endif .if defined(DEBUGMKDIR) ${INSTALL} ${TAG_ARGS:D${TAG_ARGS},debug} -d ${DESTDIR}${DEBUGFILEDIR}/ .endif @@ -435,11 +411,6 @@ _libinstall: .if !defined(LIBRARIES_ONLY) .include -.if defined(_COV_FLAG) -COV_OBJS= ${OBJS} -COV_SRCS= ${SRCS:M*.[c|cc|cpp|cxx|C]} -.include -.endif .include .include .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: r322954 - head/sys/kern
Author: cem Date: Sun Aug 27 17:12:30 2017 New Revision: 322954 URL: https://svnweb.freebsd.org/changeset/base/322954 Log: Enhance debugibility of sysctl leaf re-use warnings Print the full conflicting oid path, and include the function name in the warning so it is clear that the warnings are sysctl-related. PR: 221853 Submitted by: Fabian Keil (earlier version) Sponsored by: Dell EMC Isilon Modified: head/sys/kern/kern_sysctl.c Modified: head/sys/kern/kern_sysctl.c == --- head/sys/kern/kern_sysctl.c Sun Aug 27 17:08:08 2017(r322953) +++ head/sys/kern/kern_sysctl.c Sun Aug 27 17:12:30 2017(r322954) @@ -323,6 +323,91 @@ sysctl_load_tunable_by_oid_locked(struct sysctl_oid *o freeenv(penv); } +static int +sbuf_printf_drain(void *arg __unused, const char *data, int len) +{ + + return (printf("%.*s", len, data)); +} + +/* + * Locate the path to a given oid. Returns the length of the resulting path, + * or -1 if the oid was not found. nodes must have room for CTL_MAXNAME + * elements and be NULL initialized. + */ +static int +sysctl_search_oid(struct sysctl_oid **nodes, struct sysctl_oid *needle) +{ + int indx; + + SYSCTL_ASSERT_LOCKED(); + indx = 0; + while (indx < CTL_MAXNAME && indx >= 0) { + if (nodes[indx] == NULL && indx == 0) + nodes[indx] = SLIST_FIRST(&sysctl__children); + else if (nodes[indx] == NULL) + nodes[indx] = SLIST_FIRST(&nodes[indx - 1]->oid_children); + else + nodes[indx] = SLIST_NEXT(nodes[indx], oid_link); + + if (nodes[indx] == needle) + return (indx + 1); + + if (nodes[indx] == NULL) { + indx--; + continue; + } + + if ((nodes[indx]->oid_kind & CTLTYPE) == CTLTYPE_NODE) { + indx++; + continue; + } + } + return (-1); +} + +static void +sysctl_warn_reuse(const char *func, struct sysctl_oid *leaf) +{ + struct sysctl_oid *nodes[CTL_MAXNAME]; + char buf[128]; + struct sbuf sb; + int rc, i; + + (void)sbuf_new(&sb, buf, sizeof(buf), SBUF_FIXEDLEN | SBUF_INCLUDENUL); + sbuf_set_drain(&sb, sbuf_printf_drain, NULL); + + sbuf_printf(&sb, "%s: can't re-use a leaf (", __func__); + + memset(nodes, 0, sizeof(nodes)); + rc = sysctl_search_oid(nodes, leaf); + if (rc > 0) { + for (i = 0; i < rc; i++) + sbuf_printf(&sb, "%s%.*s", nodes[i]->oid_name, + i != (rc - 1), "."); + } else { + sbuf_printf(&sb, "%s", leaf->oid_name); + } + sbuf_printf(&sb, ")!\n"); + + (void)sbuf_finish(&sb); +} + +#ifdef SYSCTL_DEBUG +static int +sysctl_reuse_test(SYSCTL_HANDLER_ARGS) +{ + struct rm_priotracker tracker; + + SYSCTL_RLOCK(&tracker); + sysctl_warn_reuse(__func__, oidp); + SYSCTL_RUNLOCK(&tracker); + return (0); +} +SYSCTL_PROC(_sysctl, 0, reuse_test, CTLTYPE_STRING|CTLFLAG_RD|CTLFLAG_MPSAFE, + 0, 0, sysctl_reuse_test, "-", ""); +#endif + void sysctl_register_oid(struct sysctl_oid *oidp) { @@ -343,7 +428,7 @@ sysctl_register_oid(struct sysctl_oid *oidp) p->oid_refcnt++; return; } else { - printf("can't re-use a leaf (%s)!\n", p->oid_name); + sysctl_warn_reuse(__func__, p); return; } } @@ -715,8 +800,8 @@ sysctl_add_oid(struct sysctl_ctx_list *clist, struct s SYSCTL_WUNLOCK(); return (oidp); } else { + sysctl_warn_reuse(__func__, oidp); SYSCTL_WUNLOCK(); - printf("can't re-use a leaf (%s)!\n", name); return (NULL); } } ___ 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: r322957 - head/sys/net80211
Author: avos Date: Sun Aug 27 22:13:03 2017 New Revision: 322957 URL: https://svnweb.freebsd.org/changeset/base/322957 Log: net80211: fix a typo (premable -> preamble). Modified: head/sys/net80211/ieee80211_output.c Modified: head/sys/net80211/ieee80211_output.c == --- head/sys/net80211/ieee80211_output.cSun Aug 27 21:36:44 2017 (r322956) +++ head/sys/net80211/ieee80211_output.cSun Aug 27 22:13:03 2017 (r322957) @@ -2500,7 +2500,7 @@ ieee80211_send_mgmt(struct ieee80211_node *ni, int typ capinfo |= IEEE80211_CAPINFO_PRIVACY; /* * NB: Some 11a AP's reject the request when -* short premable is set. +* short preamble is set. */ if ((ic->ic_flags & IEEE80211_F_SHPREAMBLE) && IEEE80211_IS_CHAN_2GHZ(ic->ic_curchan)) ___ 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: r322959 - head/usr.bin/truss
Author: jhb Date: Mon Aug 28 02:42:20 2017 New Revision: 322959 URL: https://svnweb.freebsd.org/changeset/base/322959 Log: Decode extra signal information for caught signals. Decode fields from the siginfo_t stored in the PT_LWPINFO structure when a signal is caught by a traced process. This includes the signal code (si_code) as well as additional members such as si_addr, si_pid, etc. Modified: head/usr.bin/truss/setup.c Modified: head/usr.bin/truss/setup.c == --- head/usr.bin/truss/setup.c Mon Aug 28 00:05:24 2017(r322958) +++ head/usr.bin/truss/setup.c Mon Aug 28 02:42:20 2017(r322959) @@ -585,8 +585,62 @@ report_new_child(struct trussinfo *info) } static void -report_signal(struct trussinfo *info, siginfo_t *si) +decode_siginfo(FILE *fp, siginfo_t *si) { + const char *str; + + fprintf(fp, " code="); + str = sysdecode_sigcode(si->si_signo, si->si_code); + if (str == NULL) + fprintf(fp, "%d", si->si_code); + else + fprintf(fp, "%s", str); + switch (si->si_code) { + case SI_NOINFO: + break; + case SI_QUEUE: + fprintf(fp, " value=%p", si->si_value.sival_ptr); + /* FALLTHROUGH */ + case SI_USER: + case SI_LWP: + fprintf(fp, " pid=%jd uid=%jd", (intmax_t)si->si_pid, + (intmax_t)si->si_uid); + break; + case SI_TIMER: + fprintf(fp, " value=%p", si->si_value.sival_ptr); + fprintf(fp, " timerid=%d", si->si_timerid); + fprintf(fp, " overrun=%d", si->si_overrun); + if (si->si_errno != 0) + fprintf(fp, " errno=%d", si->si_errno); + break; + case SI_ASYNCIO: + fprintf(fp, " value=%p", si->si_value.sival_ptr); + break; + case SI_MESGQ: + fprintf(fp, " value=%p", si->si_value.sival_ptr); + fprintf(fp, " mqd=%d", si->si_mqd); + break; + default: + switch (si->si_signo) { + case SIGILL: + case SIGFPE: + case SIGSEGV: + case SIGBUS: + fprintf(fp, " trapno=%d", si->si_trapno); + fprintf(fp, " addr=%p", si->si_addr); + break; + case SIGCHLD: + fprintf(fp, " pid=%jd uid=%jd", (intmax_t)si->si_pid, + (intmax_t)si->si_uid); + fprintf(fp, " status=%d", si->si_status); + break; + } + } +} + +static void +report_signal(struct trussinfo *info, siginfo_t *si, struct ptrace_lwpinfo *pl) +{ struct threadinfo *t; const char *signame; @@ -596,7 +650,11 @@ report_signal(struct trussinfo *info, siginfo_t *si) signame = sysdecode_signal(si->si_status); if (signame == NULL) signame = "?"; - fprintf(info->outfile, "SIGNAL %u (%s)\n", si->si_status, signame); + fprintf(info->outfile, "SIGNAL %u (%s)", si->si_status, signame); + if (pl->pl_event == PL_EVENT_SIGNAL && pl->pl_flags & PL_FLAG_SI) + decode_siginfo(info->outfile, &pl->pl_siginfo); + fprintf(info->outfile, "\n"); + } /* @@ -673,7 +731,7 @@ eventloop(struct trussinfo *info) pending_signal = 0; } else { if ((info->flags & NOSIGS) == 0) - report_signal(info, &si); + report_signal(info, &si, &pl); pending_signal = si.si_status; } ptrace(PT_SYSCALL, si.si_pid, (caddr_t)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: r322960 - in head/sys/dev/cxgbe: . common
Author: np Date: Mon Aug 28 03:13:16 2017 New Revision: 322960 URL: https://svnweb.freebsd.org/changeset/base/322960 Log: cxgbe(4): Verify that the driver accesses the firmware mailbox in a thread-safe manner. MFC after:3 days Modified: head/sys/dev/cxgbe/adapter.h head/sys/dev/cxgbe/common/t4_hw.c head/sys/dev/cxgbe/t4_main.c Modified: head/sys/dev/cxgbe/adapter.h == --- head/sys/dev/cxgbe/adapter.hMon Aug 28 02:42:20 2017 (r322959) +++ head/sys/dev/cxgbe/adapter.hMon Aug 28 03:13:16 2017 (r322960) @@ -151,7 +151,7 @@ enum { /* adapter flags */ FULL_INIT_DONE = (1 << 0), FW_OK = (1 << 1), - /* INTR_DIRECT = (1 << 2), No longer used. */ + CHK_MBOX_ACCESS = (1 << 2), MASTER_PF = (1 << 3), ADAP_SYSCTL_CTX = (1 << 4), /* TOM_INIT_DONE= (1 << 5), No longer used */ Modified: head/sys/dev/cxgbe/common/t4_hw.c == --- head/sys/dev/cxgbe/common/t4_hw.c Mon Aug 28 02:42:20 2017 (r322959) +++ head/sys/dev/cxgbe/common/t4_hw.c Mon Aug 28 03:13:16 2017 (r322960) @@ -286,6 +286,9 @@ int t4_wr_mbox_meat_timeout(struct adapter *adap, int __be64 cmd_rpl[MBOX_LEN/8]; u32 pcie_fw; + if (adap->flags & CHK_MBOX_ACCESS) + ASSERT_SYNCHRONIZED_OP(adap); + if ((size & 15) || size > MBOX_LEN) return -EINVAL; Modified: head/sys/dev/cxgbe/t4_main.c == --- head/sys/dev/cxgbe/t4_main.cMon Aug 28 02:42:20 2017 (r322959) +++ head/sys/dev/cxgbe/t4_main.cMon Aug 28 03:13:16 2017 (r322960) @@ -1221,6 +1221,15 @@ t4_attach(device_t dev) goto done; } + /* +* Ensure thread-safe mailbox access (in debug builds). +* +* So far this was the only thread accessing the mailbox but various +* ifnets and sysctls are about to be created and their handlers/ioctls +* will access the mailbox from different threads. +*/ + sc->flags |= CHK_MBOX_ACCESS; + rc = bus_generic_attach(dev); if (rc != 0) { device_printf(dev, @@ -1336,6 +1345,7 @@ t4_detach_common(device_t dev) sc = device_get_softc(dev); + sc->flags &= ~CHK_MBOX_ACCESS; if (sc->flags & FULL_INIT_DONE) { if (!(sc->flags & IS_VF)) t4_intr_disable(sc); ___ 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: r322961 - head/sys/dev/cxgbe
Author: np Date: Mon Aug 28 03:25:41 2017 New Revision: 322961 URL: https://svnweb.freebsd.org/changeset/base/322961 Log: cxgbe(4): Fix some assertions during driver detach. The netmap queues can't be initialized if the VI isn't. MFC after:3 days Modified: head/sys/dev/cxgbe/t4_sge.c Modified: head/sys/dev/cxgbe/t4_sge.c == --- head/sys/dev/cxgbe/t4_sge.c Mon Aug 28 03:13:16 2017(r322960) +++ head/sys/dev/cxgbe/t4_sge.c Mon Aug 28 03:25:41 2017(r322961) @@ -3306,7 +3306,10 @@ free_nm_rxq(struct vi_info *vi, struct sge_nm_rxq *nm_ { struct adapter *sc = vi->pi->adapter; - MPASS(nm_rxq->iq_cntxt_id == INVALID_NM_RXQ_CNTXT_ID); + if (vi->flags & VI_INIT_DONE) + MPASS(nm_rxq->iq_cntxt_id == INVALID_NM_RXQ_CNTXT_ID); + else + MPASS(nm_rxq->iq_cntxt_id == 0); free_ring(sc, nm_rxq->iq_desc_tag, nm_rxq->iq_desc_map, nm_rxq->iq_ba, nm_rxq->iq_desc); @@ -3366,7 +3369,10 @@ free_nm_txq(struct vi_info *vi, struct sge_nm_txq *nm_ { struct adapter *sc = vi->pi->adapter; - MPASS(nm_txq->cntxt_id == INVALID_NM_TXQ_CNTXT_ID); + if (vi->flags & VI_INIT_DONE) + MPASS(nm_txq->cntxt_id == INVALID_NM_TXQ_CNTXT_ID); + else + MPASS(nm_txq->cntxt_id == 0); free_ring(sc, nm_txq->desc_tag, nm_txq->desc_map, nm_txq->ba, nm_txq->desc); ___ 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: r322962 - head/sys/dev/cxgbe/common
Author: np Date: Mon Aug 28 04:06:40 2017 New Revision: 322962 URL: https://svnweb.freebsd.org/changeset/base/322962 Log: cxgbe(4): Remove write only variable from t4_port_init. MFC after:3 days Modified: head/sys/dev/cxgbe/common/t4_hw.c Modified: head/sys/dev/cxgbe/common/t4_hw.c == --- head/sys/dev/cxgbe/common/t4_hw.c Mon Aug 28 03:25:41 2017 (r322961) +++ head/sys/dev/cxgbe/common/t4_hw.c Mon Aug 28 04:06:40 2017 (r322962) @@ -8354,12 +8354,9 @@ int t4_port_init(struct adapter *adap, int mbox, int p { u8 addr[6]; int ret, i, j; - struct fw_port_cmd c; u16 rss_size; struct port_info *p = adap2pinfo(adap, port_id); u32 param, val; - - memset(&c, 0, sizeof(c)); for (i = 0, j = -1; i <= p->port_id; i++) { do { ___ 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: r322875 - head/sys/dev/nvme
Mark, 2017-08-25 14:53 GMT+02:00 Ed Schouten : > 2017-08-25 9:46 GMT+02:00 Mark Millard : >> It appears that at least 11.1-STABLE -r322807 does not handle >> -std=c++98 styles of use of _Static_assert for g++7 in that >> g++7 reports an error: > > Maybe we need to do something like this? > > Index: sys/sys/cdefs.h > === > --- sys/sys/cdefs.h (revision 322887) > +++ sys/sys/cdefs.h (working copy) > @@ -294,7 +294,7 @@ > #if (defined(__cplusplus) && __cplusplus >= 201103L) || \ > __has_extension(cxx_static_assert) > #define _Static_assert(x, y) static_assert(x, y) > -#elif __GNUC_PREREQ__(4,6) > +#elif __GNUC_PREREQ__(4,6) && !defined(__cplusplus) > /* Nothing, gcc 4.6 and higher has _Static_assert built-in */ > #elif defined(__COUNTER__) > #define _Static_assert(x, y) __Static_assert(x, __COUNTER__) Could you let me know whether this patch fixes the build for you? If so, I'll commit it! -- Ed Schouten Nuxi, 's-Hertogenbosch, the Netherlands KvK-nr.: 62051717 ___ 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"