Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

IB/core: Add flow control to the portmapper netlink calls

During connection establishment with a large number of
connections, it is possible that the connection requests
might fail. Adding flow control prevents this failure.
Change ibnl_unicast to use blocking to enable flow control.

Signed-off-by: Mustafa Ismail <mustafa.ismail@intel.com>
Signed-off-by: Faisal Latif <faisal.latif@intel.com>
Signed-off-by: Shiraz Saleem <shiraz.saleem@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>

authored by

Mustafa Ismail and committed by
Doug Ledford
cea05ead 3b8fb4b8

+5 -1
+5 -1
drivers/infiniband/core/netlink.c
··· 229 229 int ibnl_unicast(struct sk_buff *skb, struct nlmsghdr *nlh, 230 230 __u32 pid) 231 231 { 232 - return nlmsg_unicast(nls, skb, pid); 232 + int err; 233 + 234 + err = netlink_unicast(nls, skb, pid, 0); 235 + return (err < 0) ? err : 0; 233 236 } 234 237 EXPORT_SYMBOL(ibnl_unicast); 235 238 ··· 255 252 return -ENOMEM; 256 253 } 257 254 255 + nls->sk_sndtimeo = 10 * HZ; 258 256 return 0; 259 257 } 260 258