diff options
| author | Ben Hutchings <ben@decadent.org.uk> | 2014-02-12 17:14:17 -0500 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2014-02-12 17:33:02 -0500 |
| commit | c8364a63f6483db0826ccec6e485c1646522faf1 (patch) | |
| tree | f4fa29a5035c9beb3e56561e7907102fe38d63df /include/uapi/linux | |
| parent | 09fb8bb068c86ff6b79dd7d4cb8f706bedf86d73 (diff) | |
ethtool: Expand documentation of struct ethtool_eeprom
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/uapi/linux')
| -rw-r--r-- | include/uapi/linux/ethtool.h | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h index 441bd316b850..d5a0d20a9ff0 100644 --- a/include/uapi/linux/ethtool.h +++ b/include/uapi/linux/ethtool.h | |||
| @@ -231,12 +231,29 @@ struct ethtool_regs { | |||
| 231 | __u8 data[0]; | 231 | __u8 data[0]; |
| 232 | }; | 232 | }; |
| 233 | 233 | ||
| 234 | /* for passing EEPROM chunks */ | 234 | /** |
| 235 | * struct ethtool_eeprom - EEPROM dump | ||
| 236 | * @cmd: Command number = %ETHTOOL_GEEPROM, %ETHTOOL_GMODULEEEPROM or | ||
| 237 | * %ETHTOOL_SEEPROM | ||
| 238 | * @magic: A 'magic cookie' value to guard against accidental changes. | ||
| 239 | * The value passed in to %ETHTOOL_SEEPROM must match the value | ||
| 240 | * returned by %ETHTOOL_GEEPROM for the same device. This is | ||
| 241 | * unused when @cmd is %ETHTOOL_GMODULEEEPROM. | ||
| 242 | * @offset: Offset within the EEPROM to begin reading/writing, in bytes | ||
| 243 | * @len: On entry, number of bytes to read/write. On successful | ||
| 244 | * return, number of bytes actually read/written. In case of | ||
| 245 | * error, this may indicate at what point the error occurred. | ||
| 246 | * @data: Buffer to read/write from | ||
| 247 | * | ||
| 248 | * Users may use %ETHTOOL_GDRVINFO or %ETHTOOL_GMODULEINFO to find | ||
| 249 | * the length of an on-board or module EEPROM, respectively. They | ||
| 250 | * must allocate the buffer immediately following this structure. | ||
| 251 | */ | ||
| 235 | struct ethtool_eeprom { | 252 | struct ethtool_eeprom { |
| 236 | __u32 cmd; | 253 | __u32 cmd; |
| 237 | __u32 magic; | 254 | __u32 magic; |
| 238 | __u32 offset; /* in bytes */ | 255 | __u32 offset; |
| 239 | __u32 len; /* in bytes */ | 256 | __u32 len; |
| 240 | __u8 data[0]; | 257 | __u8 data[0]; |
| 241 | }; | 258 | }; |
| 242 | 259 | ||
