mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
sys/dev/irdma/irdma_cm: fix compile without INET
irdma_get_vlan_ipv4() calls ip_ifp_find() even if INET isn't defined, in
which case this function isn't available.
Stub this out for the non-INET case to return an error (0xffff) instead.
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1156
(cherry picked from commit 0478a0356272ab3907af9d97711f0bb8b14bf38b)
(cherry picked from commit 7aba922879)
Approved-by: re (cperciva)
This commit is contained in:
parent
e8adcfd14a
commit
78ccc5af3d
1 changed files with 4 additions and 1 deletions
|
|
@ -1664,9 +1664,11 @@ irdma_get_vlan_mac_ipv6(struct iw_cm_id *cm_id, u32 *addr, u16 *vlan_id, u8 *mac
|
|||
u16
|
||||
irdma_get_vlan_ipv4(struct iw_cm_id *cm_id, u32 *addr)
|
||||
{
|
||||
u16 vlan_id = 0xFFFF;
|
||||
|
||||
#ifdef INET
|
||||
if_t netdev;
|
||||
struct vnet *vnet = &init_net;
|
||||
u16 vlan_id = 0xFFFF;
|
||||
|
||||
#ifdef VIMAGE
|
||||
vnet = irdma_cmid_to_vnet(cm_id);
|
||||
|
|
@ -1676,6 +1678,7 @@ irdma_get_vlan_ipv4(struct iw_cm_id *cm_id, u32 *addr)
|
|||
vlan_id = rdma_vlan_dev_vlan_id(netdev);
|
||||
dev_put(netdev);
|
||||
}
|
||||
#endif
|
||||
|
||||
return vlan_id;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue