ethtool: Added support for FW dump
authorAnirban Chakraborty <anirban.chakraborty@qlogic.com>
Thu, 12 May 2011 12:48:32 +0000 (12:48 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 13 May 2011 18:37:28 +0000 (14:37 -0400)
commit29dd54b72ba8c5ad0dd6dd33584449b5953f700b
tree6decce1d19849a67916219a7d918acb0001c78d3
parentbdc220da3209d50b8c295490dec94845c88670a2
ethtool: Added support for FW dump

Added code to take FW dump via ethtool. Dump level can be controlled via setting the
dump flag. A get function is provided to query the current setting of the dump flag.
Dump data is obtained from the driver via a separate get function.

Changes from v3:
Fixed buffer length issue in ethtool_get_dump_data function.
Updated kernel doc for ethtool_dump struct and get_dump_flag function.

Changes from v2:
Provided separate commands for get flag and data.
Check for minimum of the two buffer length obtained via ethtool and driver and
use that for dump buffer
Pass up the driver return error codes up to the caller.
Added kernel doc comments.

Signed-off-by: Anirban Chakraborty <anirban.chakraborty@qlogic.com>
Reviewed-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/ethtool.h
net/core/ethtool.c