diff options
author | Johannes Berg <johannes.berg@intel.com> | 2024-11-08 11:41:44 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-11-11 10:32:06 -0800 |
commit | 7f4b3960e54faec72132a71da4a84a8e2a0b9037 (patch) | |
tree | e63b18683db35079080299f013b2e0cc913a2532 /mm/shrinker.c | |
parent | 774ca6d3bf24287ff60b7d6dd4171ebb6e47760a (diff) |
net: netlink: add nla_get_*_default() accessors
There are quite a number of places that use patterns
such as
if (attr)
val = nla_get_u16(attr);
else
val = DEFAULT;
Add nla_get_u16_default() and friends like that to
not have to type this out all the time.
Acked-by: Toke Høiland-Jørgensen <toke@kernel.org>
Acked-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Link: https://patch.msgid.link/20241108114145.acd2aadb03ac.I3df6aac71d38a5baa1c0a03d0c7e82d4395c030e@changeid
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'mm/shrinker.c')
0 files changed, 0 insertions, 0 deletions