From owner-svn-src-all@freebsd.org Wed May 10 00:47:49 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DDC9FD64F5C; Wed, 10 May 2017 00:47:49 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from mail107.syd.optusnet.com.au (mail107.syd.optusnet.com.au [211.29.132.53]) by mx1.freebsd.org (Postfix) with ESMTP id A643D1A57; Wed, 10 May 2017 00:47:49 +0000 (UTC) (envelope-from brde@optusnet.com.au) Received: from besplex.bde.org (c122-106-153-191.carlnfd1.nsw.optusnet.com.au [122.106.153.191]) by mail107.syd.optusnet.com.au (Postfix) with ESMTPS id 4EB3DD444EE; Wed, 10 May 2017 10:47:41 +1000 (AEST) Date: Wed, 10 May 2017 10:47:36 +1000 (EST) From: Bruce Evans X-X-Sender: bde@besplex.bde.org To: Ian Lepore cc: Edward Tomasz Napierala , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r318017 - head/share/man/man4 In-Reply-To: <1494372587.59865.9.camel@freebsd.org> Message-ID: <20170510095816.X5705@besplex.bde.org> References: <201705090836.v498a9JJ035778@repo.freebsd.org> <1494372587.59865.9.camel@freebsd.org> MIME-Version: 1.0 X-Optus-CM-Score: 0 X-Optus-CM-Analysis: v=2.2 cv=VbSHBBh9 c=1 sm=1 tr=0 a=Tj3pCpwHnMupdyZSltBt7Q==:117 a=Tj3pCpwHnMupdyZSltBt7Q==:17 a=nlC_4_pT8q9DhB4Ho9EA:9 a=6I5d2MoRAAAA:8 a=n3V31rENc5Mu-Ry0EfMA:9 a=45ClL6m2LaAA:10 a=IjZwj45LgO3ly-622nXo:22 Content-Type: TEXT/PLAIN; charset=X-UNKNOWN; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 May 2017 00:47:50 -0000 On Tue, 9 May 2017, Ian Lepore wrote: > On Tue, 2017-05-09 at 08:36 +0000, Edward Tomasz Napierala wrote: >> Author: trasz >> Date: Tue May=A0=A09 08:36:09 2017 >> New Revision: 318017 >> URL: https://svnweb.freebsd.org/changeset/base/318017 >> >> Log: >> =A0 Fix device paths for USB serial adapters: the formatting strings >> =A0 contain "%u", differently from eg uart(4) which uses "%r". >> =A0=A0 > > What is %r and where is it documented? In the source code. It was a ddb internal (but supported by -fformat-extensions, except IIRC for %jr (1)), but is now used by makedev(). For ddb, %r means to use ddb's radix. All output in ddb must go through db_printf(). db_printf() calls kvprintf() with ddb's radix as an arg. Unlike printf(3), kvprintf(9) supports arbitrary radixes and special formats like signed hex (%y format). kvprintf() is of course undocumented. %y is another ddb internal, like %r except it is not so useful or used outside of ddb. make_dev() supports a dumbed down version of %r. %r for make_dev() always means radix 32. This is implemented by calling vnsrprintf(9) with a hard-coded 32 as an arg since kvprintf() is unsuitable. vnsrprintf() is of course undocumented. %r implies %d. I think the strange-looking %dr works too, but the normal-looking %rd might not. db mostly use %...lr, but never a bare %lr, so use of %r is a bit hard to grep for. ddb rarely uses the long long abomination or intmax_t (it assumes that plain long is long enough, as was correct in C90), and never uses %...jr or %...yr, but I think these work except for (1). It might be a bug to hard-code hex or decimal formats instead of using %r (this is sometimes done for addresses, when the user's radix is not usually wanted, but is still too hard-coded). (1) kvprintf() handles extensions like %r and %y[r] in a general way that should work if %d or %x[r] works. But -fformat-extensions doesn't support %r or %y for intmax_t, so these formats are unusable and unused in practice= =2E The serial driver man pages are still deficient in not documenting what '?' and '*' mean. '?' is not a general wild card, but means specifically base 32 with 1 digit. This naming scheme was familar since it was used by ptys, to go up to 1024 with only 2 digits. It is still documented in pty(4) with enough details as 2 digits but not full range ([l-sL-S][0-9a-v]). I'm not sure if the first digit is restricted by the implementation or just by convention. Bruce From owner-svn-src-all@freebsd.org Wed May 10 01:01:21 2017 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F31EBD653FF; Wed, 10 May 2017 01:01:21 +0000 (UTC) (envelope-from davidcs@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CE8FD82; Wed, 10 May 2017 01:01:21 +0000 (UTC) (envelope-from davidcs@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v4A11KRJ051952; Wed, 10 May 2017 01:01:20 GMT (envelope-from davidcs@FreeBSD.org) Received: (from davidcs@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v4A11KEw051951; Wed, 10 May 2017 01:01:20 GMT (envelope-from davidcs@FreeBSD.org) Message-Id: <201705100101.v4A11KEw051951@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: davidcs set sender to davidcs@FreeBSD.org using -f From: David C Somayajulu Date: Wed, 10 May 2017 01:01:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r318126 - head/sys/dev/qlnx/qlnxe X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 May 2017 01:01:22 -0000 Author: davidcs Date: Wed May 10 01:01:20 2017 New Revision: 318126 URL: https://svnweb.freebsd.org/changeset/base/318126 Log: llh_func_filter needs to be configured for 100G MFC after:3 days Modified: head/sys/dev/qlnx/qlnxe/ecore_dev.c Modified: head/sys/dev/qlnx/qlnxe/ecore_dev.c ============================================================================== --- head/sys/dev/qlnx/qlnxe/ecore_dev.c Wed May 10 00:42:28 2017 (r318125) +++ head/sys/dev/qlnx/qlnxe/ecore_dev.c Wed May 10 01:01:20 2017 (r318126) @@ -1986,6 +1986,15 @@ static enum _ecore_status_t ecore_hw_ini } } #endif + /* Add an LLH filter with the primary MAC address. */ + if (p_hwfn->p_dev->num_hwfns > 1 && IS_LEAD_HWFN(p_hwfn)) { + rc = ecore_llh_add_mac_filter(p_hwfn, p_ptt, + p_hwfn->hw_info.hw_mac_addr); + if (rc != ECORE_SUCCESS) + DP_NOTICE(p_hwfn, false, + "Failed to add an LLH filter with the primary MAC\n"); + } + if (b_hw_start) { /* enable interrupts */ rc = ecore_int_igu_enable(p_hwfn, p_ptt, int_mode); @@ -2473,6 +2482,11 @@ enum _ecore_status_t ecore_hw_stop(struc rc2 = ECORE_UNKNOWN_ERROR; } } + + /* remove the LLH filter with the primary MAC addres */ + if (p_hwfn->p_dev->num_hwfns > 1 && IS_LEAD_HWFN(p_hwfn)) + ecore_llh_remove_mac_filter(p_hwfn, p_ptt, + p_hwfn->hw_info.hw_mac_addr); } /* hwfn loop */ if (IS_PF(p_dev)) { @@ -4569,7 +4583,7 @@ enum _ecore_status_t ecore_llh_add_mac_f } DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "MAC: %02hhx:%02hhx:%02hhx:%02hhx:%02hhx:%02hhx is added at %d\n", + "MAC: %02hhx:%02hhx:%02hhx:%02hhx:%02hhx:%02hhx is added at LLH entry %d\n", p_filter[0], p_filter[1], p_filter[2], p_filter[3], p_filter[4], p_filter[5], entry_num); @@ -4651,7 +4665,7 @@ void ecore_llh_remove_mac_filter(struct } DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "MAC: %02hhx:%02hhx:%02hhx:%02hhx:%02hhx:%02hhx was removed from %d\n", + "MAC: %02hhx:%02hhx:%02hhx:%02hhx:%02hhx:%02hhx was removed from LLH entry %d\n", p_filter[0], p_filter[1], p_filter[2], p_filter[3], p_filter[4], p_filter[5], entry_num); } @@ -4760,37 +4774,37 @@ ecore_llh_add_protocol_filter(struct eco switch (type) { case ECORE_LLH_FILTER_ETHERTYPE: DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "ETH type %x is added at %d\n", + "ETH type %x is added at LLH entry %d\n", source_port_or_eth_type, entry_num); break; case ECORE_LLH_FILTER_TCP_SRC_PORT: DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "TCP src port %x is added at %d\n", + "TCP src port %x is added at LLH entry %d\n", source_port_or_eth_type, entry_num); break; case ECORE_LLH_FILTER_UDP_SRC_PORT: DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "UDP src port %x is added at %d\n", + "UDP src port %x is added at LLH entry %d\n", source_port_or_eth_type, entry_num); break; case ECORE_LLH_FILTER_TCP_DEST_PORT: DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "TCP dst port %x is added at %d\n", + "TCP dst port %x is added at LLH entry %d\n", dest_port, entry_num); break; case ECORE_LLH_FILTER_UDP_DEST_PORT: DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "UDP dst port %x is added at %d\n", + "UDP dst port %x is added at LLH entry %d\n", dest_port, entry_num); break; case ECORE_LLH_FILTER_TCP_SRC_AND_DEST_PORT: DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "TCP src/dst ports %x/%x are added at %d\n", + "TCP src/dst ports %x/%x are added at LLH entry %d\n", source_port_or_eth_type, dest_port, entry_num); break; case ECORE_LLH_FILTER_UDP_SRC_AND_DEST_PORT: DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "UDP src/dst ports %x/%x are added at %d\n", + "UDP src/dst ports %x/%x are added at LLH entry %d\n", source_port_or_eth_type, dest_port, entry_num); break; } @@ -4917,7 +4931,7 @@ ecore_llh_remove_protocol_filter(struct } DP_VERBOSE(p_hwfn, ECORE_MSG_HW, - "Protocol filter [type %d, source_port_or_eth_type 0x%x, dest_port 0x%x] was removed from %d\n", + "Protocol filter [type %d, source_port_or_eth_type 0x%x, dest_port 0x%x] was removed from LLH entry %d\n", type, source_port_or_eth_type, dest_port, entry_num); }