blobmsg: add blobmsg_parse_attr function
authorFelix Fietkau <nbd@nbd.name>
Wed, 23 Nov 2022 11:29:19 +0000 (12:29 +0100)
committerFelix Fietkau <nbd@nbd.name>
Wed, 23 Nov 2022 11:30:10 +0000 (12:30 +0100)
commitb09b316aeaf6282bf2d2f7df9d2cc2cdf3977691
tree15e4abbe6391b6b6861c99da2f46f75046bde314
parentea56013409d5823001b47a9bba6f74055a6d76a5
blobmsg: add blobmsg_parse_attr function

This allows turning the common pattern of:
  blobmsg_parse(policy, ARRAY_SIZE(policy), tb, blobmsg_data(data), blobmsg_len(data));

into:
  blobmsg_parse_attr(policy, ARRAY_SIZE(policy), tb, data);

Signed-off-by: Felix Fietkau <nbd@nbd.name>
blobmsg.h