]> git.openfabrics.org - ~shefty/rdma-dev.git/commit
e1000e: cleanup goto statements to exit points without common work
authorBruce Allan <bruce.w.allan@intel.com>
Wed, 8 Feb 2012 02:55:56 +0000 (02:55 +0000)
committerJeff Kirsher <jeffrey.t.kirsher@intel.com>
Mon, 13 Feb 2012 21:30:16 +0000 (13:30 -0800)
commit5015e53a4cf0c88977120faede7eb02b0459d90e
tree1db95348f1fc1c5487f5dbecd01620a680c587c6
parent2a31b37a8956154df099400ba93cd6898a629c6d
e1000e: cleanup goto statements to exit points without common work

Per ./Documentation/CodingStyle, goto statements are acceptable for the
centralized exiting of functions when there are multiple exit points which
share common work such as cleanup.  When no common work is required for
multiple exit points, the function should just return at these exit points
instead of doing an unnecessary jump to a centralized return.  This patch
cleans up the inappropriate use of goto statements, and removes unnecessary
variables (or move to a smaller scope) where possible as a result of the
cleanups.

Signed-off-by: Bruce Allan <bruce.w.allan@intel.com>
Tested-by: Aaron Brown <aaron.f.brown@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
drivers/net/ethernet/intel/e1000e/80003es2lan.c
drivers/net/ethernet/intel/e1000e/82571.c
drivers/net/ethernet/intel/e1000e/ich8lan.c
drivers/net/ethernet/intel/e1000e/mac.c
drivers/net/ethernet/intel/e1000e/manage.c
drivers/net/ethernet/intel/e1000e/netdev.c
drivers/net/ethernet/intel/e1000e/nvm.c
drivers/net/ethernet/intel/e1000e/phy.c