mirror of
https://github.com/openvswitch/ovs
synced 2025-08-31 06:15:47 +00:00
netdev-dpdk: Fix crash in QoS.
qos_conf can be NULL. This can be easily reproduced by setting egress
QoS on a port:
```
ovs-vsctl set port dpdk2 qos=@newqos -- --id=@newqos create qos
type=egress-policer other-config:cir=46000000 other-config:cbs=2048
```
Reported-by: Ian Stokes <ian.stokes@intel.com>
Fixes: 78bd47cf44
("netdev-dpdk: Use RCU for egress QoS.")
Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
Tested-by: Ian Stokes <ian.stokes@intel.com>
Acked-by: Ian Stokes <ian.stokes@intel.com>
This commit is contained in:
@@ -2803,7 +2803,7 @@ netdev_dpdk_set_qos(struct netdev *netdev, const char *type,
|
||||
if (type && type[0]) {
|
||||
error = EOPNOTSUPP;
|
||||
}
|
||||
} else if (qos_conf->ops == new_ops
|
||||
} else if (qos_conf && qos_conf->ops == new_ops
|
||||
&& qos_conf->ops->qos_is_equal(qos_conf, details)) {
|
||||
new_qos_conf = qos_conf;
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user