Lines Matching refs:f

40     listen_cmd = f"socat -{ipver} -t 2 -u TCP-LISTEN:{port},reuseport /dev/null,ignoreeof"
106 …ip(f"link add {tun_type}-ksft type {tun_type} {tun_arg} local {local_addr} remote {remote_addr} de…
107 defer(ip, f"link del {tun_type}-ksft")
108 ip(f"link set dev {tun_type}-ksft up")
109 ip(f"addr add {local_v4}/24 dev {tun_type}-ksft")
110 ip(f"addr add {local_v6}/64 dev {tun_type}-ksft")
112 …ip(f"link add {tun_type}-ksft type {tun_type} {tun_arg} local {remote_addr} remote {local_addr} de…
114 defer(ip, f"link del {tun_type}-ksft", host=cfg.remote)
115 ip(f"link set dev {tun_type}-ksft up", host=cfg.remote)
116 ip(f"addr add {remote_v4}/24 dev {tun_type}-ksft", host=cfg.remote)
117 ip(f"addr add {remote_v6}/64 dev {tun_type}-ksft", host=cfg.remote)
126 features_cmd += f" {feature} {setting}"
128 ethtool(f"-K {cfg.ifname} {features_cmd}")
130 ksft_pr(f"WARNING: failure restoring wanted features: {e}")
135 def f(cfg): function
141 raise KsftSkipEx(f"Device does not support LSO queue stats")
144 raise KsftSkipEx(f"Device does not support {feature}")
155 ethtool(f"-K {cfg.ifname} {feature} off")
158 ethtool(f"-K {cfg.ifname} tx-gso-partial off")
159 ethtool(f"-K {cfg.ifname} tx-tcp-mangleid-segmentation off")
161 ethtool(f"-K {cfg.ifname} tx-gso-partial on")
164 ethtool(f"-K {cfg.ifname} tx-tcp-mangleid-segmentation on")
167 ethtool(f"-K {cfg.ifname} {feature} on")
170 f.__name__ = name + ((outer_ipver + "_") if tun else "") + "ipv" + inner_ipver
171 return f
182 for f in features["wanted"]["bits"]["bit"]:
183 cfg.wanted_features.add(f["name"])
187 for f in features["hw"]["bits"]["bit"]:
188 if f.get("value", False):
189 feature = f["name"]
191 hw_all_features_cmd += f" {feature} on"
193 ethtool(f"-K {cfg.ifname} {hw_all_features_cmd}")
195 ksft_pr(f"WARNING: failure enabling all hw features: {e}")
201 ethtool(f"-K {cfg.ifname} tx-gso-partial off")
205 for f in features["active"]["bits"]["bit"]:
206 no_partial.add(f["name"])
208 ethtool(f"-K {cfg.ifname} tx-gso-partial on")