On 7/2/25 5:28 AM, chia-yu.chang@nokia-bell-labs.com wrote:
+static int dualpi2_change(struct Qdisc *sch, struct nlattr *opt,
struct netlink_ext_ack *extack)
+{
- struct nlattr *tb[TCA_DUALPI2_MAX + 1];
- struct dualpi2_sched_data *q;
- int old_backlog;
- int old_qlen;
- int err;
- if (!opt) {
NL_SET_ERR_MSG_MOD(extack, "Dualpi2 options are reuqired");
Minor note: typo above ("reuqired" -> "required")
More importantly: the above is inconsistent with the below code, where AFAICS it's not enforced/mandated the presence of any Dualpi2 option.
i.e. User space could successfully provide a TCA_OPTIONS with no nested attributes.
Am I missing something?
Thanks,
Paolo