]> git.baikalelectronics.ru Git - kernel.git/commit
ntb_netdev: Fix list_for_each_entry exit issue
authorJon Mason <jon.mason@intel.com>
Fri, 22 Nov 2013 23:44:13 +0000 (16:44 -0700)
committerJon Mason <jon.mason@intel.com>
Mon, 7 Apr 2014 17:58:14 +0000 (10:58 -0700)
commitd6dc3ea91145eee97ee3d05189aa8e0327d1274a
treebfe894438f7c9a22b0ce1735106748d590cfdf0e
parent837ca78edf52818164c21c170b79badb0e52548b
ntb_netdev: Fix list_for_each_entry exit issue

If list_for_each_entry exits without finding the ntb_device, the dev
pointer will not be NULL.  Thus the check will never be true and the
code will not exit when it should.  Correct this by adding a bool to
determine when the device is found, otherwise exit in good fashion.

Signed-off-by: Jon Mason <jon.mason@intel.com>
drivers/net/ntb_netdev.c