summaryrefslogtreecommitdiffstats
path: root/hw/pcnet.h
Commit message (Collapse)AuthorAgeFilesLines
* exec: move include files to include/exec/Paolo Bonzini2012-12-191-1/+1
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* janitor: add guards to headersPaolo Bonzini2012-12-191-0/+5
| | | | Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* Rename target_phys_addr_t to hwaddrAvi Kivity2012-10-231-2/+2
| | | | | | | | | | | | | | | target_phys_addr_t is unwieldly, violates the C standard (_t suffixes are reserved) and its purpose doesn't match the name (most target_phys_addr_t addresses are not target specific). Replace it with a finger-friendly, standards conformant hwaddr. Outstanding patchsets can be fixed up with the command git rebase -i --exec 'find -name "*.[ch]" | xargs s/target_phys_addr_t/hwaddr/g' origin Signed-off-by: Avi Kivity <avi@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* net: Rename VLANClientState to NetClientStateStefan Hajnoczi2012-08-011-3/+3
| | | | | | | | | | | | | | | The vlan feature is no longer part of net core. Rename VLANClientState to NetClientState because net clients are not explicitly associated with a vlan at all, instead they have a peer net client to which they are connected. This patch is a mechanical search-and-replace except for a few whitespace fixups where changing VLANClientState to NetClientState misaligned whitespace. Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com> Signed-off-by: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com>
* pcnet: Properly handle TX requests during Link FailJan Kiszka2012-04-161-0/+1
| | | | | | | | As long as we have no link and we aren't in internal loopback mode, no packet must be sent. Instead, LCAR needs to be set in any active TX descriptor and also CERR in CSR0. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
* pcnet: Add link state supportJan Kiszka2011-11-011-0/+1
| | | | | | | | | Update lnkst on link state changes so that guests can obtain this information via reading back the LED output pin. Works for Linux but not for guests that depend on the missing PHY. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* pcnet: Move BCR defines to headerJan Kiszka2011-11-011-0/+19
| | | | | | | | | This moves BCR defines to the common header and immediately makes use of them to add BCR_APROMWE, replacing the open-coded write check in pcnet_aprom_writeb. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* pcnet: avoid structure holes spotted by paholeBlue Swirl2011-08-211-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Edited report from pahole on amd64 host: struct PCNetState_st { ... uint16_t bcr[32]; /* 340 64 */ /* XXX 4 bytes hole, try to pack */ ... int tx_busy; /* 4520 4 */ /* XXX 4 bytes hole, try to pack */ qemu_irq irq; /* 4528 8 */ void (*phys_mem_read)(void *, target_phys_addr_t, uint8_t *, int, int); /* 4536 8 */ /* --- cacheline 71 boundary (4544 bytes) --- */ void (*phys_mem_write)(void *, target_phys_addr_t, uint8_t *, int, int); /* 4544 8 */ void * dma_opaque; /* 4552 8 */ int looptest; /* 4560 4 */ /* size: 4568, cachelines: 72 */ /* sum members: 4556, holes: 2, sum holes: 8 */ /* padding: 4 */ /* last cacheline: 24 bytes */ }; /* definitions: 2 */ Fix by rearranging the structure to avoid padding. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* pcnet: convert to memory APIAvi Kivity2011-08-081-1/+3
| | | | | | | | | Also related chips. Reviewed-by: Richard Henderson <rth@twiddle.net> Reviewed-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Avi Kivity <avi@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* Split out common pcnet codePaul Brook2010-11-271-0/+3
| | | | | | | | The core pcnet emulation code is used by both the PCI "pcnet" device and the SPARC "lance" device. Split the common code frm the PCI code so that that can be configures independantly. Signed-off-by: Paul Brook <paul@codesourcery.com>
* net: convert pcnet to NICStateMark McLoughlin2009-12-031-3/+4
| | | | | Signed-off-by: Mark McLoughlin <markmc@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* pcnet: port to vmstateJuan Quintela2009-10-271-2/+1
| | | | | Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* pcnet: split away lance.c (sparc32 code).Gerd Hoffmann2009-10-271-0/+39
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
OpenPOWER on IntegriCloud