History log of /src/sys/arch/powerpc/booke/dev/pq3etsec.c |
Revision | | Date | Author | Comments |
1.61 |
| 07-Jan-2025 |
andvar | s/remaing/remaining/ s/containg/containing/, mainly in comments.
|
1.60 |
| 29-Jun-2024 |
riastradh | if_stats(9): Add ifp argument to if_stat..._ref.
This will enable us to pass the ifp through to a dtrace probe inside.
No functional change intended in this change, but this is an API change visible to modules so it shouldn't be pulled up.
PR kern/58377
|
1.59 |
| 09-Feb-2024 |
andvar | fix spelling mistakes, mainly in comments and log messages.
|
1.58 |
| 18-Sep-2022 |
thorpej | Eliminate use of IFF_OACTIVE.
|
1.57 |
| 07-May-2022 |
rin | Obsolete mdio_lock for pq3mdio_mii_{read,write}reg().
Callers (mii(4) layer and atphy(4) driver) acquire mii_lock() for this purpose.
Found by LOCKDEBUG.
|
1.56 |
| 07-Aug-2021 |
thorpej | Merge thorpej-cfargs2.
|
1.55 |
| 16-Jun-2021 |
riastradh | branches: 1.55.2; if_attach and if_initialize cannot fail, don't test return value
These were originally made failable back in 2017 when if_initialize allocated a softint in every interface for link state changes, so that it could fail gracefully instead of panicking:
https://mail-index.NetBSD.org/source-changes/2017/10/23/msg089053.html
However, this spawned many seldom- or never-tested error branches, which are risky to have around. And that softint in every interface has since been replaced by a single global workqueue, because link state changes require thread context but not low latency or high throughput:
https://mail-index.NetBSD.org/source-changes/2020/02/06/msg113759.html
So there is no longer any reason for if_initialize to fail. (The subroutine if_stats_init can't fail because percpu_alloc can't fail either.)
There is a snag: the softint_establish in if_percpuq_create could fail, potentially leading to bad consequences later on trying to use the softint. This change doesn't introduce any new bugs because of the snag -- if_percpuq_attach was already broken. However, the snag can be better addressed without spawning error branches, either by using a single softint or making softints less scarce.
(Separate commit will change the signatures of if_attach and if_initialize to return void, scheduled to ride whatever is the next convenient kernel bump.)
Patch and testing on amd64 and evbmips64-eb by maya@; commit message soliloquy, and compile-testing on evbppc/i386/earmv7hf, by me.
|
1.54 |
| 24-Apr-2021 |
thorpej | branches: 1.54.2; Merge thorpej-cfargs branch:
Simplify and make extensible the config_search() / config_found() / config_attach() interfaces: rather than having different variants for which arguments you want pass along, just have a single call that takes a variadic list of tag-value arguments.
Adjust all call sites: - Simplify wherever possible; don't pass along arguments that aren't actually needed. - Don't be explicit about what interface attribute is attaching if the device only has one. (More simplification.) - Add a config_probe() function to be used in indirect configuiration situations, making is visibly easier to see when indirect config is in play, and allowing for future change in semantics. (As of now, this is just a wrapper around config_match(), but that is an implementation detail.)
Remove unnecessary or redundant interface attributes where they're not needed.
There are currently 5 "cfargs" defined: - CFARG_SUBMATCH (submatch function for direct config) - CFARG_SEARCH (search function for indirect config) - CFARG_IATTR (interface attribte) - CFARG_LOCATORS (locators array) - CFARG_DEVHANDLE (devhandle_t - wraps OFW, ACPI, etc. handles)
...and a sentinel value CFARG_EOL.
Add some extra sanity checking to ensure that interface attributes aren't ambiguous.
Use CFARG_DEVHANDLE in MI FDT, OFW, and ACPI code, and macppc and shark ports to associate those device handles with device_t instance. This will trickle trough to more places over time (need back-end for pre-OFW Sun OBP; any others?).
|
1.53 |
| 22-Apr-2021 |
rin | Fix rnd(9) support; events were not sampled actually in the previous.
Remove #if-0'ed and wrap long line for clarity.
|
1.52 |
| 24-Jan-2021 |
rin | branches: 1.52.2; Add rnd(9) support.
|
1.51 |
| 24-Jan-2021 |
rin | Switch to if_percpuq_enqueue() from if_input().
|
1.50 |
| 06-Jul-2020 |
rin | branches: 1.50.2; Style and cosmetic changes. No binary changes intended.
|
1.49 |
| 30-Jan-2020 |
martin | Fix typo
|
1.48 |
| 29-Jan-2020 |
thorpej | Adopt <net/if_stats.h>.
|
1.47 |
| 30-Oct-2019 |
msaitoh | branches: 1.47.2; ether_input() automatically add input bytes to if_ibytes, so it's not required to do in the driver who use ether_input().
|
1.46 |
| 09-Jul-2019 |
msaitoh | branches: 1.46.2; Don't automatically set ec_capenable's ETHERCAP_VLAN_HWTAGGING bit in vlan_config() to make it user-controllable. Instead, set the bit in xxx_attach().
|
1.45 |
| 28-May-2019 |
msaitoh | Use ETHER_LOCK()/ETHER_UNLOCK() for all ethernet drivers to protect ec_multi*.
|
1.44 |
| 23-May-2019 |
msaitoh | No functional change: - Simplify MII structure initialization and reference. - u_int*_t -> uint*_t. - KNF
|
1.43 |
| 26-Apr-2019 |
msaitoh | No functional change: - u_int_{8,16,32}_t -> uint_{8,16,32}_t - KNF. - Tabify. - Remove extra space.
|
1.42 |
| 24-Apr-2019 |
msaitoh | SIOCS is 'S'et function and the ioctl argument is ifreq. SIOCG is 'G'et function and the ioctl armument is ifmediareq. Before this change, SIOCG modify request unexpectedly but it doesn't cause a real bug because the modification is overriden in ifmedia_ioctl().
|
1.41 |
| 08-Mar-2019 |
msaitoh | s/ the the / the /
|
1.40 |
| 22-Jan-2019 |
msaitoh | Change MII PHY read/write API from:
int (*mii_readreg_t)(device_t, int, int); void (*mii_writereg_t)(device_t, int, int, int); to:
int (*mii_readreg_t)(device_t, int, int, uint16_t *); int (*mii_writereg_t)(device_t, int, int, uint16_t);
Now we can test if a read/write operation failed or not by the return value.
In 802.3 spec says that the PHY shall not respond to read/write transaction to the unimplemented register(22.2.4.3). Detecting timeout can be used to check whether a register is implemented or not (if the register conforms to the spec). ukphy(4) can be used this for MII_MMDACR and MII_MMDAADR.
Note that I noticed that the following code do infinite loop in the read/wirte function. If it accesses unimplemented PHY register, it will hang. It should be fixed:
arm/at91/at91emac.c arm/ep93xx/epe.c arm/omap/omapl1x_emac.c mips/ralink/ralink_eth.c arch/powerpc/booke/dev/pq3etsec.c(read) dev/cadence/if_cemac.c <- hkenken dev/ic/lan9118.c
Tested with the following device:
axe+ukphy axe+rgephy axen+rgephy (tested by Andrius V) wm+atphy wm+ukphy wm+igphy wm+ihphy wm+makphy sk+makphy sk+brgphy sk+gentbi msk+makphy sip+icsphy sip+ukphy re+rgephy bge+brgphy bnx+brgphy gsip+gphyter rtk+rlphy fxp+inphy (tested by Andrius V) tlp+acphy ex+exphy epic+qsphy vge+ciphy (tested by Andrius V) vr+ukphy (tested by Andrius V) vte+ukphy (tested by Andrius V)
Not tested (MAC): arm:at91emac arm:cemac arm:epe arm:geminigmac arm:enet arm:cpsw arm:emac(omac) arm:emac(sunxi) arm:npe evbppc:temac macppc:bm macppc:gm mips:aumac mips:ae mips:cnmac mips:reth mips:sbmac playstation2:smap powerpc:tsec powerpc:emac(ibm4xx) sgimips:mec sparc:be sf ne(ax88190, dl10019) awge ep gem hme smsh mtd sm age alc ale bce cas et jme lii nfe pcn ste stge tl xi aue mue smsc udav url
Not tested (PHY): amhphy bmtphy dmphy etphy glxtphy ikphy iophy lxtphy nsphyter pnaphy rdcphy sqphy tlphy tqphy urlphy
|
1.39 |
| 22-Dec-2018 |
maxv | Replace M_ALIGN and MH_ALIGN by m_align.
|
1.38 |
| 22-Dec-2018 |
maxv | Replace: M_MOVE_PKTHDR -> m_move_pkthdr. No functional change, since the former is a macro to the latter.
|
1.37 |
| 03-Sep-2018 |
riastradh | Rename min/max -> uimin/uimax for better honesty.
These functions are defined on unsigned int. The generic name min/max should not silently truncate to 32 bits on 64-bit systems. This is purely a name change -- no functional change intended.
HOWEVER! Some subsystems have
#define min(a, b) ((a) < (b) ? (a) : (b)) #define max(a, b) ((a) > (b) ? (a) : (b))
even though our standard name for that is MIN/MAX. Although these may invite multiple evaluation bugs, these do _not_ cause integer truncation.
To avoid `fixing' these cases, I first changed the name in libkern, and then compile-tested every file where min/max occurred in order to confirm that it failed -- and thus confirm that nothing shadowed min/max -- before changing it.
I have left a handful of bootloaders that are too annoying to compile-test, and some dead code:
cobalt ews4800mips hp300 hppa ia64 luna68k vax acorn32/if_ie.c (not included in any kernels) macppc/if_gm.c (superseded by gem(4))
It should be easy to fix the fallout once identified -- this way of doing things fails safe, and the goal here, after all, is to _avoid_ silent integer truncations, not introduce them.
Maybe one day we can reintroduce min/max as type-generic things that never silently truncate. But we should avoid doing that for a while, so that existing code has a chance to be detected by the compiler for conversion to uimin/uimax without changing the semantics until we can properly audit it all. (Who knows, maybe in some cases integer truncation is actually intended!)
|
1.36 |
| 10-Aug-2018 |
maxv | Rename
ip6_undefer_csum -> in6_undefer_cksum in6_delayed_cksum -> in6_undefer_cksum_tcpudp
The two previous names were inconsistent and misleading.
Put the two functions into in6_offload.c. Add comments to explain what we're doing.
Same as IPv4.
|
1.35 |
| 11-Jul-2018 |
maxv | Rename
ip_undefer_csum -> in_undefer_cksum in_delayed_cksum -> in_undefer_cksum_tcpudp
The two previous names were inconsistent and misleading.
Put the two functions into in_offload.c. Add comments to explain what we're doing.
The same could be done for IPv6.
|
1.34 |
| 26-Jun-2018 |
msaitoh | branches: 1.34.2; Implement the BPF direction filter (BIOC[GS]DIRECTION). It provides backward compatibility with BIOC[GS]SEESENT ioctl. The userland interface is the same as FreeBSD.
This change also fixes a bug that the direction is misunderstand on some environment by passing the direction to bpf_mtap*() instead of checking m->m_pkthdr.rcvif.
|
1.33 |
| 01-Jun-2018 |
maxv | Rename
M_CSUM_DATA_IPv6_HL -> M_CSUM_DATA_IPv6_IPHL M_CSUM_DATA_IPv6_HL_SET -> M_CSUM_DATA_IPv6_SET
Reduces the diff against IPv4. Also, clarify the definitions.
|
1.32 |
| 23-Oct-2017 |
msaitoh | branches: 1.32.2; If error occured in pq3etsec_attach(), free resources and return.
|
1.31 |
| 02-Oct-2017 |
knakahara | only get vtag when we have vtag like the other drivers.
like if_bge.c:1.312 and if_stge.c:1.64. fixed by s-yamaguchi@IIJ, thanks.
|
1.30 |
| 26-Sep-2017 |
knakahara | VLAN ID uses pkthdr instead of mtag now. Contributed by s-yamaguchi@IIJ.
I just commit by proxy. Reviewed by joerg@n.o and christos@n.o, thanks. See http://mail-index.netbsd.org/tech-net/2017/09/26/msg006459.html
XXX need pullup to -8 branch
|
1.29 |
| 15-Dec-2016 |
ozaki-r | branches: 1.29.8; Move bpf_mtap and if_ipackets++ on Rx of each driver to percpuq if_input
The benefits of the change are: - We can reduce codes - We can provide the same behavior between drivers - Where/When if_ipackets is counted up - Note that some drivers still update packet statistics in their own way (periodical update) - Moved bpf_mtap run in softint - This makes it easy to MP-ify bpf
Proposed on tech-kern and tech-net
|
1.28 |
| 26-Jul-2016 |
nonaka | IFQ_PURGE() must be called only after call if_initialize(). it lock ifp->if_snd.ifq_lock.
|
1.27 |
| 10-Jun-2016 |
ozaki-r | branches: 1.27.2; Introduce m_set_rcvif and m_reset_rcvif
The API is used to set (or reset) a received interface of a mbuf. They are counterpart of m_get_rcvif, which will come in another commit, hide internal of rcvif operation, and reduce the diff of the upcoming change.
No functional change.
|
1.26 |
| 09-Feb-2016 |
ozaki-r | Introduce softint-based if_input
This change intends to run the whole network stack in softint context (or normal LWP), not hardware interrupt context. Note that the work is still incomplete by this change; to that end, we also have to softint-ify if_link_state_change (and bpf) which can still run in hardware interrupt.
This change softint-ifies at ifp->if_input that is called from each device driver (and ieee80211_input) to ensure Layer 2 runs in softint (e.g., ether_input and bridge_input). To this end, we provide a framework (called percpuq) that utlizes softint(9) and percpu ifqueues. With this patch, rxintr of most drivers just queues received packets and schedules a softint, and the softint dequeues packets and does rest packet processing.
To minimize changes to each driver, percpuq is allocated in struct ifnet for now and that is initialized by default (in if_attach). We probably have to move percpuq to softc of each driver, but it's future work. At this point, only wm(4) has percpuq in its softc as a reference implementation.
Additional information including performance numbers can be found in the thread at tech-kern@ and tech-net@: http://mail-index.netbsd.org/tech-kern/2016/01/14/msg019997.html
Acknowledgment: riastradh@ greatly helped this work. Thank you very much!
|
1.25 |
| 17-Feb-2015 |
nonaka | Added Interrupt coalescing support.
|
1.24 |
| 23-Jan-2015 |
nonaka | Avoid if_snd race condition when MP.
|
1.23 |
| 16-Jan-2015 |
nonaka | Fix various conditions with setting IMASK.
|
1.22 |
| 16-Jan-2015 |
nonaka | Added missing tx bpf_mtap().
|
1.21 |
| 16-Jan-2015 |
nonaka | Replace if_attach with if_initialize and if_register.
|
1.20 |
| 16-Jan-2015 |
nonaka | Use IFQ_* macro instead of IF_*.
|
1.19 |
| 07-Jan-2015 |
nonaka | Remove non-printable character.
|
1.18 |
| 20-Dec-2014 |
nonaka | Revert previous accidental commit.
|
1.17 |
| 20-Dec-2014 |
nonaka | Revert previous commit.
|
1.16 |
| 22-Jul-2012 |
matt | branches: 1.16.2; 1.16.16; Split mdio/mii access into its own "device" and update accordingly. (on the P1025 the mdio functionality is separate from the etsec functions). Provide locking for mii access.
|
1.15 |
| 17-Jul-2012 |
matt | The ETSEC on the P1025 has been moved/split so the MDIO stayed in the same place but each ETSEC has been split into two virtual halves (G0 and G1) and each one has a new different base address. For some reason, tsec1 connects to phy 2 and tsec2 connects to phy 1. Adjust config file to match
|
1.14 |
| 15-Jul-2012 |
matt | Add support for the Freescale TWR-P1025 evaluation board and the P1025/P1016 QorIQ processors. XXX tsec isn't working yet on the TWR-P1025.
|
1.13 |
| 07-May-2012 |
matt | Preserve some MACCFG2 bits
|
1.12 |
| 20-Apr-2012 |
matt | Don't use the current value of maccfg2.
|
1.11 |
| 19-Apr-2012 |
matt | Read maccfg1/maccfg2/ecntrl so we can preserve bits we don't change (like GMII mode).
|
1.10 |
| 21-Feb-2012 |
matt | Don't rely on being able to allocate while in a softintr. So preallocate all the bus_dma maps in ifinit where we can sleep.
|
1.9 |
| 13-Oct-2011 |
matt | branches: 1.9.2; 1.9.6; 1.9.8; Fix printing of phy.
|
1.8 |
| 27-Sep-2011 |
jym | Modify *ASSERTMSG() so they are now used as variadic macros. The main goal is to provide routines that do as KASSERT(9) says: append a message to the panic format string when the assertion triggers, with optional arguments.
Fix call sites to reflect the new definition.
Discussed on tech-kern@. See http://mail-index.netbsd.org/tech-kern/2011/09/07/msg011427.html
|
1.7 |
| 01-Aug-2011 |
matt | Add missing __KERNEL_RCSID
|
1.6 |
| 21-Jun-2011 |
matt | Add DEBUG around a variable.
|
1.5 |
| 17-Jun-2011 |
matt | struct device * -> device_t struct cfdata * -> cfdata_t split device/softc (CFATTACH_DECL_NEW) use device_accessors and device_private constify
|
1.4 |
| 12-Jun-2011 |
matt | Make sure initialize the ATTR registers.
|
1.3 |
| 16-Mar-2011 |
matt | branches: 1.3.2; Fix various nits related to P2020 support.
|
1.2 |
| 18-Jan-2011 |
matt | branches: 1.2.4; Add support for BookE Freescale MPC85xx (e500 core) processors. Add fast softint support for PowerPC (though only booke uses it). Redo FPU/VEC support and add e500 SPE support. Rework trap/intrs to use a common trapframe format. Support SOFTFLOAT (no hardfloat or fpu emulation) for BookE.
|
1.1 |
| 07-Jan-2011 |
matt | branches: 1.1.2; 1.1.4; file pq3etsec.c was initially added on branch matt-nb5-pq3.
|
1.1.4.1 |
| 06-Jun-2011 |
jruoho | Sync with HEAD.
|
1.1.2.2 |
| 11-Jan-2011 |
matt | Fix bpf_mtap call (tcpdump now works).
|
1.1.2.1 |
| 07-Jan-2011 |
matt | Add mpc85xx support for netbsd-5 (with some incompatible kernel changes).
|
1.2.4.3 |
| 21-Apr-2011 |
rmind | sync with head
|
1.2.4.2 |
| 05-Mar-2011 |
rmind | sync with head
|
1.2.4.1 |
| 18-Jan-2011 |
rmind | file pq3etsec.c was added on branch rmind-uvmplock on 2011-03-05 20:51:34 +0000
|
1.3.2.1 |
| 23-Jun-2011 |
cherry | Catchup with rmind-uvmplock merge.
|
1.9.8.2 |
| 03-Jul-2012 |
jdc | Pull up revision 1.10 (requested by matt in ticket #382).
Don't rely on being able to allocate while in a softintr. So preallocate all the bus_dma maps in ifinit where we can sleep.
|
1.9.8.1 |
| 17-May-2012 |
riz | Pull up following revision(s) (requested by matt in ticket #245): sys/arch/powerpc/booke/dev/pq3etsec.c: revision 1.13 sys/arch/powerpc/include/booke/etsecreg.h: revision 1.4 sys/arch/powerpc/booke/dev/pq3etsec.c: revision 1.11 sys/arch/powerpc/booke/dev/pq3etsec.c: revision 1.12 Read maccfg1/maccfg2/ecntrl so we can preserve bits we don't change (like GMII mode). Don't use the current value of maccfg2. Preserve some MACCFG2 bits
|
1.9.6.3 |
| 02-Jun-2012 |
mrg | sync to latest -current.
|
1.9.6.2 |
| 29-Apr-2012 |
mrg | sync to latest -current.
|
1.9.6.1 |
| 24-Feb-2012 |
mrg | sync to -current.
|
1.9.2.3 |
| 30-Oct-2012 |
yamt | sync with head
|
1.9.2.2 |
| 23-May-2012 |
yamt | sync with head.
|
1.9.2.1 |
| 17-Apr-2012 |
yamt | sync with head
|
1.16.16.5 |
| 05-Feb-2017 |
skrll | Sync with HEAD
|
1.16.16.4 |
| 05-Oct-2016 |
skrll | Sync with HEAD
|
1.16.16.3 |
| 09-Jul-2016 |
skrll | Sync with HEAD
|
1.16.16.2 |
| 19-Mar-2016 |
skrll | Sync with HEAD
|
1.16.16.1 |
| 06-Apr-2015 |
skrll | Sync with HEAD
|
1.16.2.1 |
| 03-Dec-2017 |
jdolecek | update from HEAD
|
1.27.2.2 |
| 07-Jan-2017 |
pgoyette | Sync with HEAD. (Note that most of these changes are simply $NetBSD$ tag issues.)
|
1.27.2.1 |
| 26-Jul-2016 |
pgoyette | Sync with HEAD
|
1.29.8.3 |
| 06-Nov-2019 |
martin | Pull up following revision(s) (requested by msaitoh in ticket #1427):
sys/arch/arm/broadcom/bcm53xx_eth.c: revision 1.39 sys/dev/pcmcia/if_xi.c: revision 1.91 sys/dev/ic/aic6915.c: revision 1.40 sys/dev/pci/if_tl.c: revision 1.117 sys/arch/arm/gemini/gemini_gmac.c: revision 1.18 sys/dev/ic/elinkxl.c: revision 1.133 sys/dev/pci/if_ste.c: revision 1.57 sys/dev/pci/if_alc.c: revision 1.43 sys/dev/pci/if_stge.c: revision 1.72 sys/dev/pci/if_ale.c: revision 1.34 sys/dev/pci/if_age.c: revision 1.62 sys/dev/pci/if_txp.c: revision 1.60 sys/dev/ic/i82557.c: revision 1.156 sys/dev/pci/if_vte.c: revision 1.27 sys/arch/powerpc/booke/dev/pq3etsec.c: revision 1.47 sys/arch/arm/gemini/if_gpn.c: revision 1.13
if_percpuq(9) and ether_input() automatically increment if_ipackets, so don't add number of RX frames from device's statistics counter to if_ipackets to avoid double count.
|
1.29.8.2 |
| 10-Dec-2017 |
snj | Pull up following revision(s) (requested by msaitoh in ticket #427): sys/arch/amiga/dev/if_bah_zbus.c: 1.17 sys/arch/arm/broadcom/bcm53xx_eth.c: 1.30 sys/arch/powerpc/booke/dev/pq3etsec.c: 1.32 sys/arch/usermode/dev/if_veth.c: 1.9 sys/dev/ic/an.c: 1.66 sys/dev/ic/athn.c: 1.17 sys/dev/ic/atw.c: 1.162 sys/dev/ic/bwi.c: 1.33 sys/dev/ic/dwc_gmac.c: 1.41-1.42 sys/dev/ic/malo.c: 1.10 sys/dev/ic/rt2560.c: 1.31 sys/dev/ic/rt2661.c: 1.36 sys/dev/ic/rt2860.c: 1.29 sys/dev/ic/rtw.c: 1.127 sys/dev/ic/rtwvar.h: 1.46 sys/dev/ic/smc90cx6.c: 1.71 sys/dev/ic/smc90cx6var.h: 1.12 sys/dev/ic/wi.c: 1.244 sys/dev/pci/if_ipw.c: 1.66 sys/dev/pci/if_iwi.c: 1.104 sys/dev/pci/if_iwm.c: 1.76 sys/dev/pci/if_iwn.c: 1.86 sys/dev/pci/if_rtwn.c: 1.13 sys/dev/pci/if_wm.c: 1.541 sys/dev/pci/if_wpi.c: 1.79 sys/dev/pci/ixgbe/ixgbe.c: 1.106 sys/dev/pci/ixgbe/ixv.c: 1.73 via patch sys/dev/pcmcia/if_malo_pcmcia.c: 1.15 sys/dev/scsipi/if_se.c: 1.95 sys/dev/usb/if_upl.c: 1.60 sys/net/if.c: 1.396 sys/net/if.h: 1.241 sys/net/if_arc.h: 1.23 sys/net/if_arcsubr.c: 1.78 sys/net/if_bridge.c: 1.136-1.137 sys/net/if_etherip.c: 1.39 sys/net/if_faith.c: 1.56 sys/net/if_gif.c: 1.131 sys/net/if_loop.c: 1.96 sys/net/if_mpls.c: 1.30 sys/net/if_pppoe.c: 1.129 sys/net/if_srt.c: 1.27 sys/net/if_stf.c: 1.102 sys/net/if_tap.c: 1.100 sys/net/if_vlan.c: 1.105 sys/netinet/ip_carp.c: 1.91 sys/rump/net/lib/libshmif/if_shmem.c: 1.73-1.74 sys/rump/net/lib/libvirtif/if_virt.c: 1.55-1.56 if_initalize() and if_attach() failed when resource allocation failed (e.g. allocating softint). Without this change, it panics. It's bad because resource shortage really occured when a lot of pseudo interface is created. To avoid this problem, don't panic and change return value of if_initialize() and if_attach() to int. Caller fanction will be recover from error cleanly by checking the return value. Return if bah_attach_subr() failed. If if_attach() failed in the attach function, return. - If if_initialize() failed in the attach function, free resources and return. - Add some missing frees in bridge_clone_destroy(). - KNF If error occured in bcmeth_ccb_attach(), free resources and return. If error occured in pq3etsec_attach(), free resources and return. If error occured in the attach function, free resources and return. - If if_initialize() failed in athn_attach(), free resources and return. - Add missing pmf_event_deregister() in athn_detach(). - Free resources correctly on some errors in atw_attach(). - Use apint*() insread of printf() in the attach function. If if_initialize() failed in the attach function, return. - If if_initialize() failed in the attach function, free resources and return. - Add missing dwc_gmac_free_dma_rings() and mutex_destroy() when attach failed. - If if_initialize() failed in the attach function, free resources and return. - ifp is always not NULL in iwi_detach(). Check correctly with ifp->if_softc. - If if_initialize() failed in the attach function, free resources and return. - Fix error path in the attach function correctly. If if_initialize() failed in the attach function, free resources and return. If if_attach() failed in the attach function, free resources and return. - If if_initialize() failed in the attach function, free resources and return. - KNF - If if_attach() failed in the attach function, free resources and return. - KNF Fix compile error. Fix compile error. We don't need '&mii', but just 'mii' for mii_detach(). Don't free sc_rthash twice
|
1.29.8.1 |
| 24-Oct-2017 |
snj | Pull up following revision(s) (requested by knakahara in ticket #302): sys/arch/powerpc/booke/dev/pq3etsec.c: 1.30-1.31 sys/arch/x86/pci/if_vmx.c: 1.20 sys/dev/ic/i82557.c: 1.148 sys/dev/ic/rtl8169.c: 1.152 sys/dev/pci/cxgb/cxgb_sge.c: 1.5 sys/dev/pci/if_age.c: 1.51 sys/dev/pci/if_alc.c: 1.25 sys/dev/pci/if_ale.c: 1.23 sys/dev/pci/if_bge.c: 1.311 sys/dev/pci/if_bge.c: 1.312 sys/dev/pci/if_bnx.c: 1.62 sys/dev/pci/if_jme.c: 1.32 sys/dev/pci/if_nfe.c: 1.64 sys/dev/pci/if_sip.c: 1.167 sys/dev/pci/if_stge.c: 1.63-1.64 sys/dev/pci/if_ti.c: 1.102 sys/dev/pci/if_txp.c: 1.48 sys/dev/pci/if_vge.c: 1.61 sys/dev/pci/if_wm.c: 1.538 sys/dev/pci/ixgbe/ix_txrx.c: 1.29 via patch sys/net/agr/if_agrether_hash.c: 1.4 sys/net/if_ether.h: 1.67-1.68 sys/net/if_ethersubr.c: 1.244 sys/net/if_vlan.c: 1.100 sys/net80211/ieee80211_input.c: 1.89 sys/net80211/ieee80211_output.c: 1.59 sys/sys/mbuf.h: 1.171 VLAN ID uses pkthdr instead of mtag now. Contributed by s-yamaguchi@IIJ. I just commit by proxy. Reviewed by joerg@n.o and christos@n.o, thanks. See http://mail-index.netbsd.org/tech-net/2017/09/26/msg006459.html -- only get vtag when we have vtag like the other drivers. -- - only get the vtag if we have it like the other drivers - mask the hardware vlan tag -- - add a constant for the vlan mask. - enforce that we have a tag before we get it. only get vtag when we have vtag like the other drivers. like if_bge.c:1.312 and if_stge.c:1.64. fixed by s-yamaguchi@IIJ, thanks.
|
1.32.2.5 |
| 26-Jan-2019 |
pgoyette | Sync with HEAD
|
1.32.2.4 |
| 26-Dec-2018 |
pgoyette | Sync with HEAD, resolve a few conflicts
|
1.32.2.3 |
| 06-Sep-2018 |
pgoyette | Sync with HEAD
Resolve a couple of conflicts (result of the uimin/uimax changes)
|
1.32.2.2 |
| 28-Jul-2018 |
pgoyette | Sync with HEAD
|
1.32.2.1 |
| 25-Jun-2018 |
pgoyette | Sync with HEAD
|
1.34.2.3 |
| 13-Apr-2020 |
martin | Mostly merge changes from HEAD upto 20200411
|
1.34.2.2 |
| 08-Apr-2020 |
martin | Merge changes from current as of 20200406
|
1.34.2.1 |
| 10-Jun-2019 |
christos | Sync with HEAD
|
1.46.2.1 |
| 06-Nov-2019 |
martin | Pull up following revision(s) (requested by msaitoh in ticket #403):
sys/arch/arm/broadcom/bcm53xx_eth.c: revision 1.39 sys/dev/pcmcia/if_xi.c: revision 1.91 sys/dev/ic/aic6915.c: revision 1.40 sys/dev/pci/if_tl.c: revision 1.117 sys/arch/arm/gemini/gemini_gmac.c: revision 1.18 sys/dev/ic/elinkxl.c: revision 1.133 sys/dev/pci/if_ste.c: revision 1.57 sys/dev/pci/if_alc.c: revision 1.43 sys/dev/pci/if_stge.c: revision 1.72 sys/dev/pci/if_ale.c: revision 1.34 sys/dev/pci/if_age.c: revision 1.62 sys/dev/pci/if_txp.c: revision 1.60 sys/dev/ic/i82557.c: revision 1.156 sys/dev/pci/if_vte.c: revision 1.27 sys/arch/powerpc/booke/dev/pq3etsec.c: revision 1.47 sys/arch/arm/gemini/if_gpn.c: revision 1.13
if_percpuq(9) and ether_input() automatically increment if_ipackets, so don't add number of RX frames from device's statistics counter to if_ipackets to avoid double count.
|
1.47.2.1 |
| 29-Feb-2020 |
ad | Sync with head.
|
1.50.2.1 |
| 03-Apr-2021 |
thorpej | Sync with HEAD.
|
1.52.2.2 |
| 03-Apr-2021 |
thorpej | Give config_attach() the tagged variadic argument treatment and mechanically convert all call sites.
|
1.52.2.1 |
| 20-Mar-2021 |
thorpej | The proliferation if config_search_*() and config_found_*() combinations is a little absurd, so begin to tidy this up:
- Introduce a new cfarg_t enumerated type, that defines the types of tag-value variadic arguments that can be passed to the various config_*() functions (CFARG_SUBMATCH, CFARG_IATTR, and CFARG_LOCATORS, for now, plus a CFARG_EOL sentinel). - Collapse config_search_*() into config_search() that takes these variadic arguments. - Convert all call sites of config_search_*() to the new signature. Noticed several incorrect usages along the way, which will be audited in a future commit.
|
1.54.2.1 |
| 17-Jun-2021 |
thorpej | Sync w/ HEAD.
|
1.55.2.1 |
| 04-Aug-2021 |
thorpej | Adapt to CFARGS().
|