The branch main has been updated by jhibbits:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=12e99b63d2fae07fc54e53d9187a3995a2005ec9

commit 12e99b63d2fae07fc54e53d9187a3995a2005ec9
Author:     Justin Hibbits <jhibb...@freebsd.org>
AuthorDate: 2023-04-19 15:21:32 +0000
Commit:     Justin Hibbits <jhibb...@freebsd.org>
CommitDate: 2023-04-19 15:56:25 +0000

    ofed: Fix a logic inversion from IfAPI conversion
    
    Reported by:    bartosz.sobczak_intel.com
    Fixes:          3e142e07675b ("ofed: Mechanically convert to IfAPI")
    Sponsored by:   Juniper Networks, Inc.
---
 sys/ofed/include/rdma/ib_addr.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/ofed/include/rdma/ib_addr.h b/sys/ofed/include/rdma/ib_addr.h
index d7930eff66f1..2af055ea8950 100644
--- a/sys/ofed/include/rdma/ib_addr.h
+++ b/sys/ofed/include/rdma/ib_addr.h
@@ -180,7 +180,7 @@ static inline u16 rdma_vlan_dev_vlan_id(if_t dev)
 {
        uint16_t tag;
 
-       if (if_gettype(dev) != IFT_ETHER || if_getpcp(dev) == IFNET_PCP_NONE)
+       if (if_gettype(dev) == IFT_ETHER && if_getpcp(dev) != IFNET_PCP_NONE)
                return 0x0000;  /* prio-tagged traffic */
        if (VLAN_TAG(__DECONST(if_t, dev), &tag) != 0)
                return 0xffff;

Reply via email to