e1000x_common.c (d6271b657286de80260413684a1f2a63f44ea17b) | e1000x_common.c (b7728c9f62d8ee5c4772a08ebe2f21bd789c73f7) |
---|---|
1/* 2* QEMU e1000(e) emulation - shared code 3* 4* Copyright (c) 2008 Qumranet 5* 6* Based on work done by: 7* Nir Peleg, Tutis Systems Ltd. for Qumranet Inc. 8* Copyright (c) 2007 Dan Aloni --- 10 unchanged lines hidden (view full) --- 19* Lesser General Public License for more details. 20* 21* You should have received a copy of the GNU Lesser General Public 22* License along with this library; if not, see <http://www.gnu.org/licenses/>. 23*/ 24 25#include "qemu/osdep.h" 26#include "qemu/units.h" | 1/* 2* QEMU e1000(e) emulation - shared code 3* 4* Copyright (c) 2008 Qumranet 5* 6* Based on work done by: 7* Nir Peleg, Tutis Systems Ltd. for Qumranet Inc. 8* Copyright (c) 2007 Dan Aloni --- 10 unchanged lines hidden (view full) --- 19* Lesser General Public License for more details. 20* 21* You should have received a copy of the GNU Lesser General Public 22* License along with this library; if not, see <http://www.gnu.org/licenses/>. 23*/ 24 25#include "qemu/osdep.h" 26#include "qemu/units.h" |
27#include "hw/net/mii.h" |
|
27#include "hw/pci/pci_device.h" 28#include "net/net.h" 29 30#include "e1000x_common.h" 31 32#include "trace.h" 33 34bool e1000x_rx_ready(PCIDevice *d, uint32_t *mac) --- 112 unchanged lines hidden (view full) --- 147 148 qemu_format_nic_info_str(qemu_get_queue(nic), mac_addr); 149 trace_e1000x_mac_indicate(MAC_ARG(mac_addr)); 150} 151 152void e1000x_update_regs_on_autoneg_done(uint32_t *mac, uint16_t *phy) 153{ 154 e1000x_update_regs_on_link_up(mac, phy); | 28#include "hw/pci/pci_device.h" 29#include "net/net.h" 30 31#include "e1000x_common.h" 32 33#include "trace.h" 34 35bool e1000x_rx_ready(PCIDevice *d, uint32_t *mac) --- 112 unchanged lines hidden (view full) --- 148 149 qemu_format_nic_info_str(qemu_get_queue(nic), mac_addr); 150 trace_e1000x_mac_indicate(MAC_ARG(mac_addr)); 151} 152 153void e1000x_update_regs_on_autoneg_done(uint32_t *mac, uint16_t *phy) 154{ 155 e1000x_update_regs_on_link_up(mac, phy); |
155 phy[PHY_LP_ABILITY] |= MII_LPAR_LPACK; 156 phy[PHY_STATUS] |= MII_SR_AUTONEG_COMPLETE; | 156 phy[MII_ANLPAR] |= MII_ANLPAR_ACK; 157 phy[MII_BMSR] |= MII_BMSR_AN_COMP; |
157 trace_e1000x_link_negotiation_done(); 158} 159 160void 161e1000x_core_prepare_eeprom(uint16_t *eeprom, 162 const uint16_t *templ, 163 uint32_t templ_size, 164 uint16_t dev_id, --- 103 unchanged lines hidden --- | 158 trace_e1000x_link_negotiation_done(); 159} 160 161void 162e1000x_core_prepare_eeprom(uint16_t *eeprom, 163 const uint16_t *templ, 164 uint32_t templ_size, 165 uint16_t dev_id, --- 103 unchanged lines hidden --- |