diff options
author | yongari <yongari@FreeBSD.org> | 2008-11-27 01:57:23 +0000 |
---|---|---|
committer | yongari <yongari@FreeBSD.org> | 2008-11-27 01:57:23 +0000 |
commit | 5b628c272e60c4faa69aea69e604b79e3399f347 (patch) | |
tree | c6da331b30ebf15903690a8ff24dfd1863032cdf /sys/dev/fxp/if_fxpreg.h | |
parent | acf860ad541ce9529aff0bf17061183badd98903 (diff) | |
download | FreeBSD-src-5b628c272e60c4faa69aea69e604b79e3399f347.zip FreeBSD-src-5b628c272e60c4faa69aea69e604b79e3399f347.tar.gz |
Add basic WOL support for 82550/82551/82558 and 82559 based
controllers. ICH based controllers are treated as 82559. 82557,
earlier revision of 82558 and 82559ER have no WOL capability.
o WOL support requires help of a firmware so add check whether
hardware is capable of handling magic frames by reading EEPROM.
o Enable accepting WOL frames only when hardware is about to
suspend or shutdown. Previously fxp(4) used to allow receipt of
magic frame under normal operation mode which could cause
hardware hang if magic frame is received by hardware. Datasheet
clearly states driver should not allow WOL frames under normal
operation mode.
o Disable WOL frame reception in device attach so have fxp(4)
immunize against system hang which can be triggered by magic
packets when the hardware is not in fully initialized state.
o Don't reset all hardware configuration data in fxp_stop()
otherwise important configuration data is lost and this would
reset WOL configuration to default state which in turn cause
hardware hang on receipt of magic frames. To fix the issue,
preserve hardware configuration data by issuing a selective
reset.
o Explicitly disable interrupts after issuing selective reset as
reset may unmask interrupts.
Tested by: Alexey Shuvaev < shuvaev <> physik DOT uni-wuerzburg DOT de >
Diffstat (limited to 'sys/dev/fxp/if_fxpreg.h')
-rw-r--r-- | sys/dev/fxp/if_fxpreg.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/dev/fxp/if_fxpreg.h b/sys/dev/fxp/if_fxpreg.h index 982d2f0..a0bd142 100644 --- a/sys/dev/fxp/if_fxpreg.h +++ b/sys/dev/fxp/if_fxpreg.h @@ -46,6 +46,7 @@ #define FXP_CSR_EEPROMCONTROL 14 /* eeprom control (2 bytes) */ #define FXP_CSR_MDICONTROL 16 /* mdi control (4 bytes) */ #define FXP_CSR_FLOWCONTROL 0x19 /* flow control (2 bytes) */ +#define FXP_CSR_PMDR 0x1B /* power management driver (1 byte) */ #define FXP_CSR_GENCONTROL 0x1C /* general control (1 byte) */ /* |