]> git.baikalelectronics.ru Git - kernel.git/commit
cxgb4: Account for stid entries properly in case of IPv6
authorKumar Sanghvi <kumaras@chelsio.com>
Wed, 18 Dec 2013 11:08:22 +0000 (16:38 +0530)
committerDavid S. Miller <davem@davemloft.net>
Sun, 22 Dec 2013 23:09:08 +0000 (18:09 -0500)
commit334c20cd7cc5b55ccf794d01b6937176d2cb39cd
tree090fa046ecf1e60cf8b8a546355b91cbe7170fc4
parent8d21bcd64f84d2d1218bf07f17415e913a1463d4
cxgb4: Account for stid entries properly in case of IPv6

IPv6 uses 2 TIDs with CLIP enabled and 4 TIDs without CLIP.
Currently we are incrementing STIDs in use by 1 for both IPv4 and IPv6 which
is wrong.

Further, driver currently does not have interface to query if CLIP is programmed
for particular IPv6 address. So, in this patch we increment/decrement TIDs in use
by 4 for IPv6 assuming absence of CLIP. Such assumption keeps us on safe side and
we don't end up allocating more stids for IPv6 than actually supported.

Based on original work by Santosh Rastapur <santosh@chelsio.com>

Signed-off-by: Kumar Sanghvi <kumaras@chelsio.com>
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c