ktls_alloc_rcv_tag: Fix capability checks for RXTLS4/6.
IFCAP2_* has the bit position and not the shifted value. Reviewed by: kib@ MFC after: 1 week Sponsored by: Chelsio Communications Differential Revision: https://reviews.freebsd.org/D41100
This commit is contained in:
@@ -993,12 +993,12 @@ ktls_alloc_rcv_tag(struct inpcb *inp, struct ktls_session *tls,
|
||||
INP_RUNLOCK(inp);
|
||||
|
||||
if (inp->inp_vflag & INP_IPV6) {
|
||||
if ((if_getcapenable2(ifp) & IFCAP2_RXTLS6) == 0) {
|
||||
if ((if_getcapenable2(ifp) & IFCAP2_BIT(IFCAP2_RXTLS6)) == 0) {
|
||||
error = EOPNOTSUPP;
|
||||
goto out;
|
||||
}
|
||||
} else {
|
||||
if ((if_getcapenable2(ifp) & IFCAP2_RXTLS4) == 0) {
|
||||
if ((if_getcapenable2(ifp) & IFCAP2_BIT(IFCAP2_RXTLS4)) == 0) {
|
||||
error = EOPNOTSUPP;
|
||||
goto out;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user