]> git.ipfire.org Git - thirdparty/iproute2.git/commit
iplink: double the buffer size also in iplink_get()
authorMichal Kubecek <mkubecek@suse.cz>
Fri, 1 Sep 2017 16:39:16 +0000 (18:39 +0200)
committerStephen Hemminger <stephen@networkplumber.org>
Fri, 1 Sep 2017 21:15:00 +0000 (14:15 -0700)
commit460c03f3f3cc436ff4673d75722ba68a6ec9343d
treee13e714759799e2b31eea097384b98d0ce04fc13
parent6599162b958ea5a43d729df4f30aad515db26ff4
iplink: double the buffer size also in iplink_get()

Commit 72b365e8e0fd ("libnetlink: Double the dump buffer size") increased
the buffer size for "ip link show" command to 32 KB to handle NICs with
large number of VFs. With "dev" filter, a different code path is taken and
iplink_get() still uses only 16 KB buffer.

The size of 32768 is not very future-proof as NICs supporting 120-128 VFs
are already in use so that single RTM_NEWLINK message in the dump can
exceed 30000 bytes. But it's what rtnl_talk() and rtnl_dump_filter_l() use
so let's be consistent. Once this proves insufficient, all three sizes
should be increased.

Signed-off-by: Michal Kubecek <mkubecek@suse.cz>
ip/iplink.c