| 5d384a0d | 09-Dec-2011 |
Pyun YongHyeon <[email protected]> |
Announce flow control ability to PHY driver and enable RX flow control. Controller does not automatically generate pause frames based on number of available RX buffers so it's very hard to know when
Announce flow control ability to PHY driver and enable RX flow control. Controller does not automatically generate pause frames based on number of available RX buffers so it's very hard to know when driver should generate XON frame in time. The only mechanism driver can detect low number of RX buffer condition is ET_INTR_RXRING0_LOW or ET_INTR_RXRING1_LOW interrupt. This interrupt is generated whenever controller notices the number of available RX buffers are lower than pre-programmed value( ET_RX_RING0_MINCNT and ET_RX_RING1_MINCNT register). This scheme does not provide a way to detect when controller sees enough number of RX buffers again such that efficient generation of XON/XOFF frame is not easy.
While here, add more flow control related register definition.
show more ...
|
| 38953bb0 | 07-Dec-2011 |
Pyun YongHyeon <[email protected]> |
Disable all clocks and put PHY into COMA before entering into suspend state. This will save more power. On resume, make sure to enable all clocks. While I'm here, if controller is not fast ethernet
Disable all clocks and put PHY into COMA before entering into suspend state. This will save more power. On resume, make sure to enable all clocks. While I'm here, if controller is not fast ethernet, enable gigabit PHY.
show more ...
|
| 8e5ad990 | 07-Dec-2011 |
Pyun YongHyeon <[email protected]> |
Protect SIOCSIFMTU ioctl handler with driver lock. Don't blindly re-initialize controller whenever MTU is changed. Now, reinitializing is done only when driver is running.
While here, remove unneces
Protect SIOCSIFMTU ioctl handler with driver lock. Don't blindly re-initialize controller whenever MTU is changed. Now, reinitializing is done only when driver is running.
While here, remove unnecessary assignment of error value since it was already initialized to 0.
show more ...
|
| 1f009e2f | 07-Dec-2011 |
Pyun YongHyeon <[email protected]> |
Rework link state tracking and TX/RX MAC configuration. o Do not report link status if driver is not running. o TX/RX MAC configuration should be done with resolved speed, duplex and flow contro
Rework link state tracking and TX/RX MAC configuration. o Do not report link status if driver is not running. o TX/RX MAC configuration should be done with resolved speed, duplex and flow control after establishing a link so it can't be done in driver initialization routine. Move the configuration to miibus_statchg callback which will be called whenever any link state change is detected. At this moment, flow-control is not enabled yet mainly because I was not able to set correct flow control parameters to generate TX pause frames. o Now TX/RX MAC is enabled only when a valid link is detected. Rearragnge hardware initialization routine a bit to leave enabling MAC to miibus_statchg callback. In order to that, TX/RX DMA engine is enabled in et_init_locked(). o Introduce ET_FLAG_LINK flag to track current link state. o Introduce ET_FLAG_FASTETHER flag to mark whether controller is fast ethernet. This flag is checked in miibus_statchg callback to know whether PHY established a valid link. o In et_stop(), TX/RX MAC is explicitly disabled instead of relying on et_reset(). And move et_reset() from et_stop() to controller initialization. Controler reset is not required here and it would also clear critial registers(i.e station address, RX filter configuration, WOL etc) that are required to make WOL work. o Switching to current media is done in et_init_locked() after setting IFF_DRV_RUNNING flag. This should ensure reliable auto-negotiation/manual link establishment. o In et_start_locked(), check whether driver got a valid link before trying to send frames. o Remove checking a link in et_tick() as this is done by miibus_statchg callback.
show more ...
|
| 6537ffa6 | 07-Dec-2011 |
Pyun YongHyeon <[email protected]> |
Remove et_enable_intrs(), et_disable_intrs() functions and manipulation of interrupt register access is done through CSR_WRITE_4 macro. Also add disabling interrupt into et_reset() because we want i
Remove et_enable_intrs(), et_disable_intrs() functions and manipulation of interrupt register access is done through CSR_WRITE_4 macro. Also add disabling interrupt into et_reset() because we want interrupt disabled state after controller reset. While I'm here slightly change interrupt handler to be more readable one.
show more ...
|