]> git.baikalelectronics.ru Git - kernel.git/commit
mlxsw: spectrum_router: Align RIF index allocation with existing code
authorIdo Schimmel <idosch@mellanox.com>
Sun, 4 Jun 2017 14:53:40 +0000 (16:53 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 5 Jun 2017 03:49:49 +0000 (23:49 -0400)
commiteaed3019300beed21e9b1af0a2a0279519852264
tree1746950039e57e11c44674b289d216f469b7b006
parentb72d686d5ed981c301ccc58688e1f12f848fc4c1
mlxsw: spectrum_router: Align RIF index allocation with existing code

The way we usually allocate an index is by letting the allocation
function return an error instead of an invalid index.

Do the same for RIF index.

Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: Petr Machata <petrm@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c