- struct rtattr *tb1, *tb2[TCA_ACT_MAX+1];
- struct rtattr *tb[TCA_ACT_MAX_PRIO + 1];
- struct rtattr *rta[TCAA_MAX + 1];
- struct rtattr *kind;
- int min_len = NLMSG_LENGTH(sizeof(struct tcamsg));
- int attrlen = n->nlmsg_len - NLMSG_ALIGN(min_len);
- struct rtattr *attr = (void *) n + NLMSG_ALIGN(min_len);
-
- if (rtattr_parse(rta, TCAA_MAX, attr, attrlen) < 0)
+ struct nlattr *tb1, *tb2[TCA_ACT_MAX+1];
+ struct nlattr *tb[TCA_ACT_MAX_PRIO + 1];
+ struct nlattr *nla[TCAA_MAX + 1];
+ struct nlattr *kind;
+
+ if (nlmsg_parse(n, sizeof(struct tcamsg), nla, TCAA_MAX, NULL) < 0)