]> git.baikalelectronics.ru Git - kernel.git/commit
liquidio: CN23XX: fix a loop timeout
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 13 Oct 2016 08:56:57 +0000 (11:56 +0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 13 Oct 2016 16:12:50 +0000 (12:12 -0400)
commit50c7e169abf51410932e01a993cadd2644bf3f4f
tree894ec103f7821c783a42274bd17e61cfaeeca103
parent4f66d8432955d2ebaf3b81f3c7d6edb1dd18e4cb
liquidio: CN23XX: fix a loop timeout

This is supposed to loop 1000 times and then give up.  The problem is
it's a post-op and after the loop we test if "loop" is zero when really
it would be -1.  Fix this by making it a pre-op.

Fixes: 3648778c0c92 ("liquidio: CN23XX queue manipulation")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/cavium/liquidio/cn23xx_pf_device.c