android_kernel_motorola_sm6225/drivers/net
Jack Morgenstein 95646373c9 net/mlx4_core: Fix SRIOV free-pool management when enforcing resource quotas
The Hypervisor driver tracks free slots and reserved slots at the global level
and tracks allocated slots and guaranteed slots per VF.

Guaranteed slots are treated as reserved by the driver, so the total
reserved slots is the sum of all guaranteed slots over all the VFs.

As VFs allocate resources, free (global) is decremented and allocated (per VF)
is incremented for those resources. However, reserved (global) is never changed.

This means that effectively, when a VF allocates a resource from its
guaranteed pool, it is actually reducing that resource's free pool (since
the global reserved count was not also reduced).

The fix for this problem is the following: For each resource, as long as a
VF's allocated count is <= its guaranteed number, when allocating for that
VF, the reserved count (global) should be reduced by the allocation as well.

When the global reserved count reaches zero, the remaining global free count
is still accessible as the free pool for that resource.

When the VF frees resources, the reverse happens: the global reserved count
for a resource is incremented only once the VFs allocated number falls below
its guaranteed number.

This fix was developed by Rick Kready <kready@us.ibm.com>

Reported-by: Rick Kready <kready@us.ibm.com>
Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2014-06-11 00:32:46 -07:00
..
appletalk
arcnet
bonding bonding: Support macvlans on top of tlb/rlb mode bonds 2014-06-04 15:13:54 -07:00
caif
can Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-06-03 23:32:12 -07:00
cris
dsa net: dsa: update DSA drivers to use ds_to_priv 2014-04-30 13:31:25 -04:00
ethernet net/mlx4_core: Fix SRIOV free-pool management when enforcing resource quotas 2014-06-11 00:32:46 -07:00
fddi
hamradio yam: replace del_timer by del_timer_sync 2014-03-27 15:28:06 -04:00
hippi
hyperv hyperv: Add hash value into RNDIS Per-packet info 2014-05-23 14:49:00 -04:00
ieee802154 ieee802154: Introduce the use of the managed version of kzalloc 2014-05-21 16:29:52 -04:00
irda via-ircc: Remove useless return variables 2014-06-02 17:04:05 -07:00
phy amd-xgbe: fix unused variable compilation warning in phylib driver 2014-06-11 00:13:16 -07:00
plip
ppp inetpeer: get rid of ip_id_count 2014-06-02 11:00:41 -07:00
slip slip: fix spinlock variant 2014-04-27 23:35:12 -04:00
team Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-06-03 23:32:12 -07:00
usb Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-06-03 23:32:12 -07:00
vmxnet3 net: use SPEED_UNKNOWN and DUPLEX_UNKNOWN when appropriate 2014-06-06 16:24:07 -07:00
wan wan: Use usleep_range() 2014-06-02 17:01:33 -07:00
wimax net: wimax: i2400m: control.c: Cleaning up conjunction always evaluates to false 2014-06-11 00:13:16 -07:00
wireless Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem 2014-06-06 11:59:11 -04:00
xen-netback Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-06-05 16:22:02 -07:00
dummy.c net: Replace u64_stats_fetch_begin_bh to u64_stats_fetch_begin_irq 2014-03-14 22:41:36 -04:00
eql.c
ifb.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-03-29 18:48:54 -04:00
Kconfig netpoll: Remove dead packet receive code (CONFIG_NETPOLL_TRAP) 2014-03-17 15:48:12 -04:00
LICENSE.SRC
loopback.c net: Replace u64_stats_fetch_begin_bh to u64_stats_fetch_begin_irq 2014-03-14 22:41:36 -04:00
macvlan.c macvlan: Support bonding events 2014-06-04 15:13:54 -07:00
macvtap.c mactap: Fix checksum errors for non-gso packets in bridge mode 2014-04-30 16:12:22 -04:00
Makefile
mdio.c
mii.c
netconsole.c
nlmon.c net: nlmon: flag nlmon devs with LLTX/SG 2014-03-28 16:49:47 -04:00
ntb_netdev.c net: use ethtool_cmd_speed_set helper to set ethtool speed value 2014-06-06 16:24:07 -07:00
rionet.c net: get rid of SET_ETHTOOL_OPS 2014-05-13 17:43:20 -04:00
sb1000.c
Space.c
sungem_phy.c
tun.c net-tun: restructure tun_do_read for better sleep/wakeup efficiency 2014-05-21 15:50:28 -04:00
veth.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-03-29 18:48:54 -04:00
virtio_net.c net: get rid of SET_ETHTOOL_OPS 2014-05-13 17:43:20 -04:00
vxlan.c vxlan: Add support for UDP checksums (v4 sending, v6 zero csums) 2014-06-04 22:46:39 -07:00
xen-netfront.c xen-netfront: initialise queue name in xennet_init_queue 2014-06-04 14:48:17 -07:00