The NetBSD Project

CVS log for src/sys/dev/pci/if_wmvar.h

[BACK] Up to [cvs.NetBSD.org] / src / sys / dev / pci

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.33.6.12 / (download) - annotate - [select for diffs], Wed Oct 18 14:41:55 2023 UTC (5 months, 4 weeks ago) by martin
Branch: netbsd-8
Changes since 1.33.6.11: +2 -1 lines
Diff to previous 1.33.6.11 (colored) to branchpoint 1.33 (colored) next main 1.34 (colored)

Pull up the following, requested by msaitoh in ticket #1915:

	sys/dev/pci/pcidevs			1.1497
	sys/dev/pci/if_wm.c			1.689,1.790-1.791 via patch
	sys/dev/pci/if_wmreg.h			1.120 via patch
	sys/dev/pci/if_wmvar.h			1.51

- Use 12K for packet buffer for jumbo frame on PCH2 and newer.
- Add new workaround for Tiger Lake and newer to avoid packet loss.
- Add I219{V,LM}({22,23}) devices (Raptor Lake).

Revision 1.44.4.7 / (download) - annotate - [select for diffs], Wed Oct 18 14:29:18 2023 UTC (5 months, 4 weeks ago) by martin
Branch: netbsd-9
Changes since 1.44.4.6: +2 -1 lines
Diff to previous 1.44.4.6 (colored) to branchpoint 1.44 (colored) next main 1.45 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1754):

	sys/dev/pci/pcidevs: revision 1.1497
	sys/dev/pci/if_wm.c: revision 1.790
	sys/dev/pci/if_wm.c: revision 1.791
	sys/dev/pci/if_wmvar.h: revision 1.51

pcidevs: Add Intel I219{V,LM}({22,23})

wm(4): Add a new workaround for Tiger Lake and newer.
 - Define new WM_T_PCH_TGP and use it for Tiger Lake and newer.
   Note that we don't define WM_T_PCH_ADP because we have no any
   Alder Lake specific workaround yet.
 - Add new workaround for Tiger Lake (and newer) in wm_init_locked()
   to avoid packet loss.

wm(4): Add I219{V,LM}({22,23}) devices (Raptor Lake).

Revision 1.48.4.3 / (download) - annotate - [select for diffs], Wed Oct 18 14:27:38 2023 UTC (5 months, 4 weeks ago) by martin
Branch: netbsd-10
CVS Tags: netbsd-10-0-RELEASE, netbsd-10-0-RC6, netbsd-10-0-RC5, netbsd-10-0-RC4, netbsd-10-0-RC3, netbsd-10-0-RC2, netbsd-10-0-RC1
Changes since 1.48.4.2: +2 -1 lines
Diff to previous 1.48.4.2 (colored) to branchpoint 1.48 (colored) next main 1.49 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #421):

	sys/dev/pci/pcidevs: revision 1.1497
	sys/dev/pci/if_wm.c: revision 1.790
	sys/dev/pci/if_wm.c: revision 1.791
	sys/dev/pci/if_wmvar.h: revision 1.51

pcidevs: Add Intel I219{V,LM}({22,23})

wm(4): Add a new workaround for Tiger Lake and newer.
 - Define new WM_T_PCH_TGP and use it for Tiger Lake and newer.
   Note that we don't define WM_T_PCH_ADP because we have no any
   Alder Lake specific workaround yet.
 - Add new workaround for Tiger Lake (and newer) in wm_init_locked()
   to avoid packet loss.

wm(4): Add I219{V,LM}({22,23}) devices (Raptor Lake).

Revision 1.51 / (download) - annotate - [select for diffs], Wed Oct 11 15:05:26 2023 UTC (6 months ago) by msaitoh
Branch: MAIN
CVS Tags: thorpej-ifq-base, thorpej-ifq, thorpej-altq-separation-base, thorpej-altq-separation, HEAD
Changes since 1.50: +2 -1 lines
Diff to previous 1.50 (colored)

wm(4): Add a new workaround for Tiger Lake and newer.

 - Define new WM_T_PCH_TGP and use it for Tiger Lake and newer.
   Note that we don't define WM_T_PCH_ADP because we have no any
   Alder Lake specific workaround yet.
 - Add new workaround for Tiger Lake (and newer) in wm_init_locked()
   to avoid packet loss.

Revision 1.33.6.11 / (download) - annotate - [select for diffs], Mon Sep 4 17:57:49 2023 UTC (7 months, 1 week ago) by martin
Branch: netbsd-8
Changes since 1.33.6.10: +3 -2 lines
Diff to previous 1.33.6.10 (colored) to branchpoint 1.33 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1894):

	sys/dev/pci/if_wmvar.h: revision 1.50
	sys/dev/pci/if_wm.c: revision 1.783,1.784 via patch

Delay sending LINK_STATE_UP to prevent dropping packets on I35[04] and I21[01].

 Some (not all) systems use I35[04] or I21[01] don't send packet soon
after linkup. The MAC send a packet to the PHY and any error is not
observed. This behavior causes a problem that gratuitous ARP and/or
IPv6 DAD packet are silently dropped. To avoid this problem, don't
call mii_pollstat() here which will send LINK_STATE_UP notification
to the upper layer. Instead, mii_pollstat() will be called in
wm_gmii_mediastatus() or mii_tick() will be called in wm_tick().

Note that the similar workaround is in Linux's igb driver though it's
only for I21[01].

OK'd by hikaru@ and knakahara@.

Fix #ifdef WM_DEBUG code in wm_gmii_i82544_{read,write}reg_locked.

Revision 1.44.4.6 / (download) - annotate - [select for diffs], Mon Sep 4 17:55:24 2023 UTC (7 months, 1 week ago) by martin
Branch: netbsd-9
Changes since 1.44.4.5: +3 -2 lines
Diff to previous 1.44.4.5 (colored) to branchpoint 1.44 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #344):

	sys/dev/pci/if_wmvar.h: revision 1.50
	sys/dev/pci/if_wm.c: revision 1.783,1.784 via patch

Delay sending LINK_STATE_UP to prevent dropping packets on I35[04] and I21[01].

 Some (not all) systems use I35[04] or I21[01] don't send packet soon
after linkup. The MAC send a packet to the PHY and any error is not
observed. This behavior causes a problem that gratuitous ARP and/or
IPv6 DAD packet are silently dropped. To avoid this problem, don't
call mii_pollstat() here which will send LINK_STATE_UP notification
to the upper layer. Instead, mii_pollstat() will be called in
wm_gmii_mediastatus() or mii_tick() will be called in wm_tick().

Note that the similar workaround is in Linux's igb driver though it's
only for I21[01].

OK'd by hikaru@ and knakahara@.

Fix #ifdef WM_DEBUG code in wm_gmii_i82544_{read,write}reg_locked.

Revision 1.48.4.2 / (download) - annotate - [select for diffs], Mon Sep 4 17:45:24 2023 UTC (7 months, 1 week ago) by martin
Branch: netbsd-10
Changes since 1.48.4.1: +3 -2 lines
Diff to previous 1.48.4.1 (colored) to branchpoint 1.48 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #344):

	sys/dev/pci/if_wmvar.h: revision 1.50
	sys/dev/pci/if_wm.c: revision 1.783
	sys/dev/pci/if_wm.c: revision 1.784

Delay sending LINK_STATE_UP to prevent dropping packets on I35[04] and I21[01].

 Some (not all) systems use I35[04] or I21[01] don't send packet soon
after linkup. The MAC send a packet to the PHY and any error is not
observed. This behavior causes a problem that gratuitous ARP and/or
IPv6 DAD packet are silently dropped. To avoid this problem, don't
call mii_pollstat() here which will send LINK_STATE_UP notification
to the upper layer. Instead, mii_pollstat() will be called in
wm_gmii_mediastatus() or mii_tick() will be called in wm_tick().

Note that the similar workaround is in Linux's igb driver though it's
only for I21[01].

OK'd by hikaru@ and knakahara@.

Fix #ifdef WM_DEBUG code in wm_gmii_i82544_{read,write}reg_locked.

Revision 1.50 / (download) - annotate - [select for diffs], Fri Aug 25 08:14:14 2023 UTC (7 months, 3 weeks ago) by msaitoh
Branch: MAIN
Changes since 1.49: +3 -2 lines
Diff to previous 1.49 (colored)

Delay sending LINK_STATE_UP to prevent dropping packets on I35[04] and I21[01].

 Some (not all) systems use I35[04] or I21[01] don't send packet soon
after linkup. The MAC send a packet to the PHY and any error is not
observed. This behavior causes a problem that gratuitous ARP and/or
IPv6 DAD packet are silently dropped. To avoid this problem, don't
call mii_pollstat() here which will send LINK_STATE_UP notification
to the upper layer. Instead, mii_pollstat() will be called in
wm_gmii_mediastatus() or mii_tick() will be called in wm_tick().

Note that the similar workaround is in Linux's igb driver though it's
only for I21[01].

OK'd by hikaru@ and knakahara@.

Revision 1.33.6.10 / (download) - annotate - [select for diffs], Tue Jun 27 18:36:53 2023 UTC (9 months, 2 weeks ago) by martin
Branch: netbsd-8
Changes since 1.33.6.9: +4 -1 lines
Diff to previous 1.33.6.9 (colored) to branchpoint 1.33 (colored)

Pull up the following revisions, requested by msaitoh in #1847:

	sys/dev/pci/if_wm.c				1.768-1.782 via patch
	sys/dev/pci/if_wmreg.h				1.129-1.130
	sys/dev/pci/if_wmvar.h				1.49

wm(4):
- Rework for event counters:
  - Fix calculation of GORC, GOTC, TOR and TOT counters correctly.
  - Rearrange the order of the registers so that they are roughly
    in ascending order.
  - Reorder evcnt_attach_dynamic(), WM_EVCNT_ADD() and evcnt_detach()
    to match.
  - IC{TX,RX}*C registers are for older than 82575.
  - Fix a bug that the transmit underrun counter is incorrectly
    counted.
  - Don't add "Count" for event counter's description.
  - Some statistics registers were replaced with new counters on newer
    chips. Treat 0x403c(CEXTERR->HTDPMC), 0x40fc(TSCTFC->CBRMPC),
    0x4124(ICRXOC->HTCBDPC) and from 0x4104 to 0x4124.
  - Add some new counters:
    - Circuit Breaker TX Manageability Packet
    - Circuit Breaker RX Dropped Packet
    - Host Good Octets RX
    - Host Good Octets TX
    - Length Errors
    - SerDes/SGMII Code Violation Packet
    - Header Redirection Missed Packet
    - EEE TX LPI
    - EEE RX LPI
  - Fix prc511's comment and description.
- Add SOICZIFDATA (ifconfig -z) support for evcnt(9).
- Use WM_IS_ICHPCH(). No functional change.
- Fix typo. s/ictxact/ictxatc/. No functional change.
- Add comment.

Revision 1.44.4.5 / (download) - annotate - [select for diffs], Tue Jun 27 18:32:46 2023 UTC (9 months, 2 weeks ago) by martin
Branch: netbsd-9
Changes since 1.44.4.4: +4 -1 lines
Diff to previous 1.44.4.4 (colored) to branchpoint 1.44 (colored)

Pull up the following revisions, requested by msaitoh in #1656:

	sys/dev/pci/if_wm.c				1.768-1.782 via patch
	sys/dev/pci/if_wmreg.h				1.129-1.130
	sys/dev/pci/if_wmvar.h				1.49

wm(4):
- Rework for event counters:
  - Fix calculation of GORC, GOTC, TOR and TOT counters correctly.
  - Rearrange the order of the registers so that they are roughly
    in ascending order.
  - Reorder evcnt_attach_dynamic(), WM_EVCNT_ADD() and evcnt_detach()
    to match.
  - IC{TX,RX}*C registers are for older than 82575.
  - Fix a bug that the transmit underrun counter is incorrectly
    counted.
  - Don't add "Count" for event counter's description.
  - Some statistics registers were replaced with new counters on newer
    chips. Treat 0x403c(CEXTERR->HTDPMC), 0x40fc(TSCTFC->CBRMPC),
    0x4124(ICRXOC->HTCBDPC) and from 0x4104 to 0x4124.
  - Add some new counters:
    - Circuit Breaker TX Manageability Packet
    - Circuit Breaker RX Dropped Packet
    - Host Good Octets RX
    - Host Good Octets TX
    - Length Errors
    - SerDes/SGMII Code Violation Packet
    - Header Redirection Missed Packet
    - EEE TX LPI
    - EEE RX LPI
  - Fix prc511's comment and description.
- Add SOICZIFDATA (ifconfig -z) support for evcnt(9).
- Use WM_IS_ICHPCH(). No functional change.
- Fix typo. s/ictxact/ictxatc/. No functional change.
- Add comment.

Revision 1.48.4.1 / (download) - annotate - [select for diffs], Thu Jun 22 08:14:35 2023 UTC (9 months, 3 weeks ago) by martin
Branch: netbsd-10
Changes since 1.48: +4 -1 lines
Diff to previous 1.48 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #213):

	sys/dev/pci/if_wm.c: revision 1.770
	sys/dev/pci/if_wm.c: revision 1.771
	sys/dev/pci/if_wm.c: revision 1.772
	sys/dev/pci/if_wm.c: revision 1.773
	sys/dev/pci/if_wm.c: revision 1.774
	sys/dev/pci/if_wm.c: revision 1.775
	sys/dev/pci/if_wm.c: revision 1.776
	sys/dev/pci/if_wmreg.h: revision 1.129
	sys/dev/pci/if_wm.c: revision 1.777
	sys/dev/pci/if_wm.c: revision 1.778
	sys/dev/pci/if_wmvar.h: revision 1.49
	sys/dev/pci/if_wm.c: revision 1.779
	sys/dev/pci/if_wm.c: revision 1.768
	sys/dev/pci/if_wm.c: revision 1.769
	sys/dev/pci/if_wmreg.h: revision 1.130
	sys/dev/pci/if_wm.c: revision 1.780
	sys/dev/pci/if_wm.c: revision 1.781

Count some 64bit counters correctly.
 - Fix calculation of GORC, GOTC, TOR and TOT counters correctly.
 - Found by knakahara.

Add note for the TORL register.

The TOR register includes error, flow control and broadcast rejected.

Sort lines. No functional change.

 Rearrange the order of the registers so that they are roughly in ascending
order.

Sort lines. No functional change.

Reorder evcnt_attach_dynamic(), WM_EVCNT_ADD() and evcnt_detach() to match.
IC{TX,RX}*C registers are for older than 82575.

Fix a bug that the transmit underrun counter is incorrectly counted.
 The transmit underrun bit in the transmit status filed is only for 82544
(and older?), so don't use the counter for newer chips. The bit is reserved
for newer chips, but the bit sometimes set on 82575 at least.

Don't add "Count" for event counter's description.

 Some statistics registers were replaced with new counters.
 - 0x403c was CEXTERR(Carrier Extension Error). 82575 and newer except 80003,
   ICHs and PCHs have HTDPMC(Host Tx Discarded Packets by MAC). I don't really
   know for 82575. The 82575 datasheet say nothing about it.
 - The following two are changed for circuit breaker. Only 82576's datasheet
   describes abut it, so the registers might be only for 82576.
   Use those registers for 82575 and newer except 80003, ICHs and PCHs just in
   case.
   - 0x40fc was TSCTFC(TCP Segmentation Context Tx Fail). It was replaced by
     the CBRMPC(Circuit Breaker Rx Manageability Packet) register.
   - 0x4124 was ICRXOC(Interrupt Cause Receiver Overrun). It was replaced by
     the HTCBDPC(Host Tx Circuit Breaker Dropped Packet) register.
 - From 0x4104 to 0x4124:
   - For 0x4124, 82575's datasheet says it's not changed(ICRXOC).
     I don't know if it's correct. We use new HTCBDPC register for 82575.
   - 82576 and newer changed the meaning.
   - I don't know for 80003, ICHs and PCHs. Don't count those registers.
     At least, those registers in PCH2 and PCH_CNP are all zero.

Add some new event counters.

Add the following counters for 82575 and newer except 80003, ICHs and PCHs:
    - Only 82576 document describes about the circuit breaker,
      so the following two might be only for 82575:
        - Circuit Breaker TX Manageability Packet
        - Circuit Breaker RX Dropped Packet
    - 82575's document doesn't describe the following two, but we can see
      the same value as GO{T,R}C have:
        - Host Good Octets RX
        - Host Good Octets TX
    - 82575's document doesn't describe the LENERRS (Length Errors) counter.
      I don't know if it has.
    - Perhaps Non-SerDes/SGMII devices don't have SCVPC
      (SerDes/SGMII Code Violation Packet) register. We don't care if
      it's SerDes/SGMII or not for now.
    - HRMPC (Header Redirection Missed Packet) appears only once
      in 8257[56]'s datasheet. FreeBSD's igb counts it, so we do, too.
    - Count the following two for I350 and newer. I don't know if PCHs have:
        - EEE TX LPI
        - EEE RX LPI

 Move statistics updating code from wm_tick() to new wm_update_stats().
 - To reuse.
 - No functional change.

Add SOICZIFDATA (ifconfig -z) support for evcnt(9).

 First update the statistics data, then clear the event counters,
and finally copy and clear if_data via ether_ioctl().

Fix prc511's comment and description.

 Use WM_IS_ICHPCH(). No functional change.

Fix typo. s/ictxact/ictxatc/. No functional change.

Revision 1.49 / (download) - annotate - [select for diffs], Thu May 11 07:14:46 2023 UTC (11 months ago) by msaitoh
Branch: MAIN
Changes since 1.48: +4 -1 lines
Diff to previous 1.48 (colored)

 Some statistics registers were replaced with new counters.

 - 0x403c was CEXTERR(Carrier Extension Error). 82575 and newer except 80003,
   ICHs and PCHs have HTDPMC(Host Tx Discarded Packets by MAC). I don't really
   know for 82575. The 82575 datasheet say nothing about it.
 - The following two are changed for circuit breaker. Only 82576's datasheet
   describes abut it, so the registers might be only for 82576.
   Use those registers for 82575 and newer except 80003, ICHs and PCHs just in
   case.
   - 0x40fc was TSCTFC(TCP Segmentation Context Tx Fail). It was replaced by
     the CBRMPC(Circuit Breaker Rx Manageability Packet) register.
   - 0x4124 was ICRXOC(Interrupt Cause Receiver Overrun). It was replaced by
     the HTCBDPC(Host Tx Circuit Breaker Dropped Packet) register.
 - From 0x4104 to 0x4124:
   - For 0x4124, 82575's datasheet says it's not changed(ICRXOC).
     I don't know if it's correct. We use new HTCBDPC register for 82575.
   - 82576 and newer changed the meaning.
   - I don't know for 80003, ICHs and PCHs. Don't count those registers.
     At least, those registers in PCH2 and PCH_CNP are all zero.

Revision 1.33.6.9 / (download) - annotate - [select for diffs], Mon Jul 11 14:15:58 2022 UTC (21 months ago) by martin
Branch: netbsd-8
Changes since 1.33.6.8: +21 -21 lines
Diff to previous 1.33.6.8 (colored) to branchpoint 1.33 (colored)

Pull up the following revisions, requested by msaitoh in ticket #1751:

	sys/dev/pci/if_wmreg.h				1.122-1.125 via patch
	sys/dev/pci/if_wmvar.h				1.48
	sys/dev/pci/if_wm.c				1.719-1.720,1.722-1.725,
							1.727-1.740 via patch

- wm_tick: Add missing splx(s) when not WM_MPSAFE.
- Print DMA range info if the system is booting in the verbose mode.
- Micro optimization:
  - Call m_freem(m) only if m0 == NULL.
  - Call wm_xxeof() only when limit > 0.
  - Don't set the more flag when there is no packet to process.
- No functional changes:
  - Call txeof first, then rxeof for the consistency.
  - Remove duplicated break.
  - Remove stray semicolons from struct declaration.
  - Fix value return from void function.
  - Use macros.
  - Modify comment.
  - KNF.

Revision 1.44.4.4 / (download) - annotate - [select for diffs], Mon Jul 11 14:10:18 2022 UTC (21 months ago) by martin
Branch: netbsd-9
CVS Tags: netbsd-9-3-RELEASE
Changes since 1.44.4.3: +21 -21 lines
Diff to previous 1.44.4.3 (colored) to branchpoint 1.44 (colored)

Pull up the following revisions, requested by msaitoh in ticket #1477:

	sys/dev/pci/if_wmreg.h				1.122-1.125
	sys/dev/pci/if_wmvar.h				1.48
	sys/dev/pci/if_wm.c				1.719-1.720,
							1.722-1.725,
							1.727-1.740 via patch

- wm_tick: Add missing splx(s) when not WM_MPSAFE.
- Print DMA range info if the system is booting in the verbose mode.
- Micro optimization:
  - Call m_freem(m) only if m0 == NULL.
  - Call wm_xxeof() only when limit > 0.
  - Don't set the more flag when there is no packet to process.
- No functional changes:
  - Call txeof first, then rxeof for the consistency.
  - Remove duplicated break.
  - Remove stray semicolons from struct declaration.
  - Fix value return from void function.
  - Use macros.
  - Modify comment.
  - KNF.

Revision 1.48 / (download) - annotate - [select for diffs], Mon Dec 20 12:50:35 2021 UTC (2 years, 3 months ago) by skrll
Branch: MAIN
CVS Tags: netbsd-10-base, bouyer-sunxi-drm-base, bouyer-sunxi-drm
Branch point for: netbsd-10
Changes since 1.47: +21 -21 lines
Diff to previous 1.47 (colored)

Trailing whitespace

Revision 1.33.6.8 / (download) - annotate - [select for diffs], Sat Oct 23 11:49:22 2021 UTC (2 years, 5 months ago) by martin
Branch: netbsd-8
Changes since 1.33.6.7: +3 -2 lines
Diff to previous 1.33.6.7 (colored) to branchpoint 1.33 (colored)

Pull up the following, requested by msaitoh in ticket #1701:

	share/man/man4/wm.4				1.42
	sys/dev/pci/files.pci				1.434
	sys/dev/pci/if_wm.c				1.686-1.687,1.692-1.693,
							1.697,1.699-1.703,
							1.706-1.715 via patch
	sys/dev/pci/if_wmvar.h				1.46

- Add missing drain for pcq in wm_stop_locked().
- Add support for I219V 15-19 and I219LM 16-19.
- Fix Tx stall.
- Use wm_flush_desc_rings() workaround more on I219.
- Change DMA physical address in wm_flush_desc_rings() to match other
  OSes.
- Check return value correctly in wm_lv_jumbo_workaround_ich8lan().
- Add new sysctl hw.wmN.debug_flags. This sysctl can be used if
  WM_DEBUG is set.
- Add some sysctl values for debugging TX/RX queues.
- WM_EVENT_COUNTER is enabled by default on 64 bit architectures.
- Remove extra unlock/lock processing around if_percpuq_enqueue().
- Refactor rxq->rxq_ptr updating.
- Stop legacy interrupts before calling softint.
- Disable printf()s in wm_flush_desc_rings() because the code is
  verified.
- Print I219's version number.
- Uniform INTx/MSI handler's Tx/Rx behavior to MSI-X's one.
- Fix return value of interrupt handler.
- Only print an error about missing I/O BARs for chips that need it.
- Do not return a void value from a void function.
- Add new flag named WM_F_CRC_STRIP and use it. No functional change.
- Whitespace fixes. Fix comments. No functional change.

Revision 1.33.6.7 / (download) - annotate - [select for diffs], Wed Nov 4 11:51:57 2020 UTC (3 years, 5 months ago) by martin
Branch: netbsd-8
Changes since 1.33.6.6: +4 -3 lines
Diff to previous 1.33.6.6 (colored) to branchpoint 1.33 (colored)

Pull up following revision(s) (requested by knakahara in ticket #1620):

	sys/dev/pci/if_wm.c: revision 1.694
	sys/dev/pci/if_wm.c: revision 1.695 (via patch)
	sys/dev/pci/if_wmvar.h: revision 1.47

Add WMPHY_I350. Not used yet.

Workaround for ihphy and atphy(ICH*/PCH*, 82580 and I350).
These phys stop DMA while link is down which causes device timeout.
Fix PR/kern 40981
Reviewed and tested by msaitoh@n.o, thanks.
XXX pullup-[89]

Revision 1.44.4.3 / (download) - annotate - [select for diffs], Wed Nov 4 11:48:26 2020 UTC (3 years, 5 months ago) by martin
Branch: netbsd-9
CVS Tags: netbsd-9-2-RELEASE
Changes since 1.44.4.2: +4 -3 lines
Diff to previous 1.44.4.2 (colored) to branchpoint 1.44 (colored)

Pull up following revision(s) (requested by knakahara in ticket #1126):

	sys/dev/pci/if_wm.c: revision 1.694
	sys/dev/pci/if_wm.c: revision 1.695 (via patch)
	sys/dev/pci/if_wmvar.h: revision 1.47

Add WMPHY_I350. Not used yet.

Workaround for ihphy and atphy(ICH*/PCH*, 82580 and I350).
These phys stop DMA while link is down which causes device timeout.
Fix PR/kern 40981
Reviewed and tested by msaitoh@n.o, thanks.
XXX pullup-[89]

Revision 1.47 / (download) - annotate - [select for diffs], Fri Oct 30 06:29:47 2020 UTC (3 years, 5 months ago) by msaitoh
Branch: MAIN
CVS Tags: thorpej-i2c-spi-conf2-base, thorpej-i2c-spi-conf2, thorpej-i2c-spi-conf-base, thorpej-i2c-spi-conf, thorpej-futex2-base, thorpej-futex2, thorpej-futex-base, thorpej-futex, thorpej-cfargs2-base, thorpej-cfargs2, thorpej-cfargs-base, thorpej-cfargs, cjep_sun2x-base1, cjep_sun2x-base, cjep_sun2x, cjep_staticlib_x-base1, cjep_staticlib_x-base, cjep_staticlib_x
Changes since 1.46: +4 -3 lines
Diff to previous 1.46 (colored)

Add WMPHY_I350. Not used yet.

Revision 1.44.4.2 / (download) - annotate - [select for diffs], Wed Sep 23 08:46:54 2020 UTC (3 years, 6 months ago) by martin
Branch: netbsd-9
CVS Tags: netbsd-9-1-RELEASE
Changes since 1.44.4.1: +3 -2 lines
Diff to previous 1.44.4.1 (colored) to branchpoint 1.44 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1093):

	sys/dev/pci/if_wmreg.h: revision 1.120
	sys/dev/pci/if_wmvar.h: revision 1.46
	sys/dev/pci/if_wm.c: revision 1.686
	sys/dev/pci/if_wm.c: revision 1.687
	sys/dev/mii/inbmphyreg.h: revision 1.20
	sys/dev/pci/if_wm.c: revision 1.688
	sys/dev/pci/if_wm.c: revision 1.689

s/ressource/resource/. Found by knakahara.

  Add new flag named WM_F_CRC_STRIP and use it. No functional change.

  This change also sets the RCTL_SECRC bit on I211 but it doesn't change
the behavior because I211 always strips CRC like I35[04] and I210.

  Add a workaround for jumbo frame on PCH2 and newer. Tested by chs@.

- Add wm_lv_jumbo_workaround_ich8lan() and use it. From FreeBSD.
   XXX For KUMCTRLSTA_OFFSET_HD_CTRL register modification, it's doubtful.
   FreeBSD and Linux do the same thing that they set the same value on both
   jumbo frame's enable case and the disable case. It seems the default value
   is 0x0b0c and it's not changed on the enable case, so it might be a bug
   on the enable case or the modification is not required.
- Rename I219_UNKNOWN1 to I82579_UNKNOWN1.
  Use 12K for packet buffer for jumbo frame on PCH2 and newer.

XXX Note that Linux Use 14K.

Revision 1.46 / (download) - annotate - [select for diffs], Tue Sep 15 08:39:04 2020 UTC (3 years, 7 months ago) by msaitoh
Branch: MAIN
Changes since 1.45: +3 -2 lines
Diff to previous 1.45 (colored)

 Add new flag named WM_F_CRC_STRIP and use it. No functional change.

 This change also sets the RCTL_SECRC bit on I211 but it doesn't change
the behavior because I211 always strips CRC like I35[04] and I210.

Revision 1.33.6.6 / (download) - annotate - [select for diffs], Wed Aug 5 17:22:46 2020 UTC (3 years, 8 months ago) by martin
Branch: netbsd-8
Changes since 1.33.6.5: +5 -2 lines
Diff to previous 1.33.6.5 (colored) to branchpoint 1.33 (colored)

Pull up the following revisions, requested by msaitoh in ticket #1594:

	sys/dev/pci/if_wm.c			1.655-1.658, 1.660,
						1.662, 1.664-1.668,
						1.671-1.674, 1.678,
						1.680-1.685 via patch
	sys/dev/pci/if_wmreg.c			1.118-1.119 via patch
	sys/dev/pci/if_wmvar.c			1.45 via patch
	sys/dev/mii/igphy.c			1.35-1.36 via patch
	sys/dev/mii/igphyreg.h			1.12-1.13
	sys/dev/mii/makphy.c			1.66 via patch
	sys/dev/mii/makphyreg.h			1.11

- Add SFP support. Module insertion/removal is not supported yet.
  Currently, SFP detection is only done in the driver's attach phase.
- Detect the Media Auto Sense feature. Not supported yet.
- Fix SFF_SFP_ETH_FLAGS_100FX. It's not 0x10 but 0x20.
- Add extra delay in wm_serdes_power_up_link_82575().
- Add Intel I219 LM10-LM15 and V10-V14.
- wm(4) can use workqueue as deferred Rx/Tx handler).
  Set hw.wm*.txrx_workqueue=1 to use workqueue instead of softint.
  The default value of hw.wm*.txrx_workqueue is 0 which use softint
  as before.
- Unset RSS UDP flags like ixg(4) and other OSes. To handle IP
  fragmented UDP, first packet and second packet should be processed
  in the same Rx queue.
- It's useless to not to set PCI_PMCSR_PME_STS bit when writing because
  the bit is W1C. Instead, always write PCI_PMCSR_PME_STS bit to clear
  in case it's already set.
- Actually writing always the checksum offload context descriptor
  makes the HW do extra processing, avoid doing that if possible.
- Fix a bug that the WMREG_EEARBC_I210 register is incorrectly set if
  the system uses iNVM.
- "wmX: 0" on 82542 is difficult to understand, so don't print it.
- Explicitly cast from uint16_t to uint32_t before shifting 16bit left
  when printing Image Unique ID to avoid undefined behavior.
- Set if_baudrate for non-MII device.
- Rename some macros and function.
- KNF. Add comment.

Revision 1.44.4.1 / (download) - annotate - [select for diffs], Fri Jul 10 10:45:56 2020 UTC (3 years, 9 months ago) by martin
Branch: netbsd-9
Changes since 1.44: +5 -2 lines
Diff to previous 1.44 (colored)

Pull up the following revisions, requested by msaitoh in ticket #994:

	sys/dev/pci/if_wm.c		1.655-1.658, 1.660, 1.662, 1.664-1.668,
					1.671-1.674, 1.678,1.680-1.681 via patch
	sys/dev/pci/if_wmreg.c		1.118-1.119
	sys/dev/pci/if_wmvar.c		1.45

- Add SFP support. Module insertion/removal is not supported yet.
  Currently, SFP detection is only done in the driver's attach phase.
- Detect the Media Auto Sense feature. Not supported yet.
- Fix SFF_SFP_ETH_FLAGS_100FX. It's not 0x10 but 0x20.
- Add extra delay in wm_serdes_power_up_link_82575().
- Add Intel I219 LM10-LM15 and V10-V14.
- wm(4) can use workqueue as deferred Rx/Tx handler.
  Set hw.wm*.txrx_workqueue=1 to use workqueue instead of softint.
  The default value of hw.wm*.txrx_workqueue is 0 which use softint
  as before.
- Unset RSS UDP flags like ixg(4) and other OSes. To handle IP
  fragmented UDP, first packet and second packet should be processed
  in the same Rx queue.
- It's useless to not to set PCI_PMCSR_PME_STS bit when writing because
  the bit is W1C. Instead, always write PCI_PMCSR_PME_STS bit to clear
  in case it's already set.
- Actually writing always the checksum offload context descriptor
  makes the HW do extra processing, avoid doing that if possible.
- Fix a bug that the WMREG_EEARBC_I210 register is incorrectly set if
  the system uses iNVM.
- "wmX: 0" on 82542 is difficult to understand, so don't print it.
- Rename some macros and function.
- KNF. Add comment.

Revision 1.38.2.2 / (download) - annotate - [select for diffs], Wed Apr 8 14:08:09 2020 UTC (4 years ago) by martin
Branch: phil-wifi
Changes since 1.38.2.1: +5 -2 lines
Diff to previous 1.38.2.1 (colored) to branchpoint 1.38 (colored) next main 1.39 (colored)

Merge changes from current as of 20200406

Revision 1.45 / (download) - annotate - [select for diffs], Wed Dec 11 10:28:19 2019 UTC (4 years, 4 months ago) by msaitoh
Branch: MAIN
CVS Tags: phil-wifi-20200421, phil-wifi-20200411, phil-wifi-20200406, is-mlppp-base, is-mlppp, bouyer-xenpvh-base2, bouyer-xenpvh-base1, bouyer-xenpvh-base, bouyer-xenpvh, ad-namecache-base3, ad-namecache-base2, ad-namecache-base1, ad-namecache-base, ad-namecache
Changes since 1.44: +5 -2 lines
Diff to previous 1.44 (colored)

Add SFP support part 1. The code for SerDes and SGMII setting is not include
in this commit. SFP module removal interrupt detects but not used yet:
- Detect SFP's 1000BASE-SX, 1000BASE-LX, 100BASE-FX and 1000BASE-T correctly.
- Detect the Media Auto Sense feature. Not supported yet.
- Add comment.

Revision 1.38.2.1 / (download) - annotate - [select for diffs], Mon Jun 10 22:07:17 2019 UTC (4 years, 10 months ago) by christos
Branch: phil-wifi
Changes since 1.38: +37 -15 lines
Diff to previous 1.38 (colored)

Sync with HEAD

Revision 1.33.6.5 / (download) - annotate - [select for diffs], Thu Mar 7 17:11:53 2019 UTC (5 years, 1 month ago) by martin
Branch: netbsd-8
CVS Tags: netbsd-8-2-RELEASE, netbsd-8-1-RELEASE, netbsd-8-1-RC1
Changes since 1.33.6.4: +30 -8 lines
Diff to previous 1.33.6.4 (colored) to branchpoint 1.33 (colored)

Pull up the following, requested by msaitoh in ticket #1206:

	sys/dev/pci/if_wmreg.h			1.113
	sys/dev/pci/if_wmvar.h			1.43-1.44
	sys/dev/pci/if_wm.c			1.626-1.627, 1.629-1.636 via patch

- Add support for I210 SGMII Flash-less device.
- Add I219 variations for Cannon Lake.
- Add missing rnd_detach_source().
- Use  do { ... } while (0) for DPRINTF(x, y).
- Swap enumeration of 82578 and 82577 PHY in if_wmvar.h. No functional
  change.
- Add KASSERT.
- Update TODO list. Add comment. Fix typo in comment.

Revision 1.44 / (download) - annotate - [select for diffs], Tue Feb 19 07:59:17 2019 UTC (5 years, 1 month ago) by msaitoh
Branch: MAIN
CVS Tags: phil-wifi-20191119, phil-wifi-20190609, netbsd-9-base, netbsd-9-0-RELEASE, netbsd-9-0-RC2, netbsd-9-0-RC1, isaki-audio2-base, isaki-audio2
Branch point for: netbsd-9
Changes since 1.43: +13 -7 lines
Diff to previous 1.43 (colored)

 Modify PHY tree in comment.

Revision 1.43 / (download) - annotate - [select for diffs], Thu Feb 7 10:29:53 2019 UTC (5 years, 2 months ago) by msaitoh
Branch: MAIN
Changes since 1.42: +24 -8 lines
Diff to previous 1.42 (colored)

 Swap enumeration of 82578 and 82577. Same as FreeBSD. Chip Model number of
82578 is +1 from 82577 but 82577 is functionally newer than 82578 (and 82577's
MII_MODEL(0x05) is greater than 82578's (0x04)). This change doesn't affect any
behavior to if_wm.c (NFCI).

 Add comment.

Revision 1.33.6.4 / (download) - annotate - [select for diffs], Thu Jan 31 06:43:48 2019 UTC (5 years, 2 months ago) by martin
Branch: netbsd-8
Changes since 1.33.6.3: +12 -12 lines
Diff to previous 1.33.6.3 (colored) to branchpoint 1.33 (colored)

Pull up the following, requested by msaitoh in ticket #1179:

	sys/dev/pci/if_wm.c			1.603-1.605,1.607-1.611,
						1.613,1.615,1.618-1.620
						via patch
	sys/dev/pci/if_wmreg.h			1.110-1.111
	sys/dev/pci/if_wmvar.h			1.40-1.42
	sys/dev/mii/inbmphyreg.h		1.13-1.15

- Add some code for suspend/resume:
  - Rename wm_smbustopci() to wm_init_phy_workarounds_pchlan(). It will
    also called when resume.
  - Call wm_phy_resetisblocked() after PHY reset in
    wm_init_phy_workarounds_pchlan() to wait for the PHY to quiesce to
    an accessible state.
  - Add new wm_resume_workarounds_pchlan() function and use it in
    wm_resume(). This workaround is only for PCH2 and newer.
  - Don't call wm_disable_aspm() neither in wm_attach() nor in
    wm_resume() but in wm_reset().
  - Do some initialization in wm_resume() when IFF_UP is NOT set.
  - Don't continue when it failed to acquire semaphore in
    wm_ulp_disable().
- Print CLSEM workaround bit correctly.
- Fix availability detection of WoL on some chips.
- Print the WUS (WakeUp Status) register bits when resume.
- Don't setup WoL on non-WoL capable port.
- Setup PHY wakeup feature on PCH and newer. Tested on Thinkpad X220.
- Remove an extra register read in
  wm_kmrn_lock_loss_workaround_ich8lan().
- Don't leave the MDICNFG register modified when the Power Management
  capability offset can't get.
- Reduce indent level of wm_linkintr_gmii(). No functional change.
- 80003's SERDES is not the same as 82575's but the same as legacy
  devices. Use the old methods on 80003.
- Use __nothing for null DPRINTF().
- Rename functions. Add comment.

Revision 1.37.2.3 / (download) - annotate - [select for diffs], Wed Dec 26 14:01:50 2018 UTC (5 years, 3 months ago) by pgoyette
Branch: pgoyette-compat
CVS Tags: pgoyette-compat-merge-20190127
Changes since 1.37.2.2: +12 -12 lines
Diff to previous 1.37.2.2 (colored) to branchpoint 1.37 (colored) next main 1.38 (colored)

Sync with HEAD, resolve a few conflicts

Revision 1.42 / (download) - annotate - [select for diffs], Tue Dec 25 07:41:21 2018 UTC (5 years, 3 months ago) by msaitoh
Branch: MAIN
CVS Tags: pgoyette-compat-20190127, pgoyette-compat-20190118, pgoyette-compat-1226
Changes since 1.41: +11 -11 lines
Diff to previous 1.41 (colored)

 Add comment.

Revision 1.41 / (download) - annotate - [select for diffs], Thu Dec 20 09:32:13 2018 UTC (5 years, 3 months ago) by msaitoh
Branch: MAIN
Changes since 1.40: +3 -3 lines
Diff to previous 1.40 (colored)

- Don't setup WoL on non-WoL capable port.
- Setup PHY wakeup feature on PCH and newer. Tested on Thinkpad X220.

Revision 1.40 / (download) - annotate - [select for diffs], Fri Dec 14 06:28:09 2018 UTC (5 years, 4 months ago) by msaitoh
Branch: MAIN
Changes since 1.39: +2 -2 lines
Diff to previous 1.39 (colored)

 Print CLSEM workaround bit correctly.

Revision 1.37.2.2 / (download) - annotate - [select for diffs], Thu Sep 6 06:55:51 2018 UTC (5 years, 7 months ago) by pgoyette
Branch: pgoyette-compat
Changes since 1.37.2.1: +2 -2 lines
Diff to previous 1.37.2.1 (colored) to branchpoint 1.37 (colored)

Sync with HEAD

Resolve a couple of conflicts (result of the uimin/uimax changes)

Revision 1.33.6.3 / (download) - annotate - [select for diffs], Sat Aug 11 14:47:32 2018 UTC (5 years, 8 months ago) by martin
Branch: netbsd-8
Changes since 1.33.6.2: +2 -2 lines
Diff to previous 1.33.6.2 (colored) to branchpoint 1.33 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #969):

	sys/dev/pci/if_wm.c: revision 1.584
	sys/dev/pci/if_wmvar.h: revision 1.39

Add MDIC_WA and CLSEMWA to snprintb() string for WM_F_* flags.

Fix two bugs for non-SERDES fiber. Tested on 82544EI(0x1009), 82545GM(0x1027),
82546GB(0x107a), 82571GB(0x105f), 82572EI(0x107e). Tested on SERDES
82580(0x150e (Winyao SERDES SFP)) and 82580(0x150e) as regression test:

- Fix a bug that the link can't detect in link interrupt function for
   non-SERDES fiber. When the signal is detected & STATUS_LU == 0 & RXCW == 0,
   it's required to set CTRL_SLU and CTRL_FD bit. wm_check_for_link() is the
   function to do it. If a link status change interrupt occurred, call
   wm_check_for_link() before checking current link status.

- Fix a bug that 82542 misunderstand fiber's signal detection. CTRL_SWDPIN(1)
   is used for fiber's signal and it's value is reversed only on 82543 and
   82544. Simplify the code and move it into a new function wm_tbi_havesignal()
   and use it.

Revision 1.19.2.7 / (download) - annotate - [select for diffs], Sat Aug 11 13:34:21 2018 UTC (5 years, 8 months ago) by martin
Branch: netbsd-7
CVS Tags: netbsd-7-2-RELEASE
Changes since 1.19.2.6: +15 -7 lines
Diff to previous 1.19.2.6 (colored) to branchpoint 1.19 (colored) next main 1.20 (colored)

Pull up the following, requested by msaitoh in ticket #1628:

share/man/man4/wm.4				1.40 via patch
sys/dev/mii/ihphyreg.h				1.2
sys/dev/mii/inbmphyreg.h			1.10
sys/dev/pci/if_wm.c				1.504, 1.506, 1.510-1.535, 1.539-1.540, 1.546, 1.548, 1.551-1.552, 1.558, 1.565-1.573, 1.575, 1.579, 1.582, 1.584 via patch
sys/dev/pci/if_wmreg.h				1.99-1.103, 1.106-1.107 via patch
sys/dev/pci/if_wmvar.h				1.34-1.39 via patch
sys/dev/pci/pcidevs				1.1327 via patch
sys/dev/pci/pcidevs.h				regen
sys/dev/pci/pcidevs_data.h			regen
sys/dev/pci/pcireg.h				patch

	Sync wm(4) up to 2018/08/08 except MSI/MSI-X and NET_MPSAFE:
	- remove extra "+"
	- Fix a bug that non-GMII devices don't send a routing message when
	  the link status is changed.
	- Set WMREG_KABGTXD not in wm_init_locked() but in wm_reset(). Same as
	  other OSes.
	- If a interrupt is a spurious interrupt, don't print debug message.
	- Don't print the Image Unique ID if an NVM is iNVM (i210 and I211).
	- Print sc_flags with snprintb().
	- Fix a bug that a RAL was written at incorrect address when the index
	  number is more than 16 on 82544 and newer.
	- The layout of RAL on PCH* are different from others. Fix it.
	- Flush every MTA write. Same as Linux.
	- Move the location of calling wm_set_filter. Same as some other OSes.
	- Add CSR_WRITE_FLUSH() after writing WMREG_CTRL in
	  wm_gmii_mediachange().
	- Add missing "else" in wm_nvm_release().
	- Make new wm_phy_post_reset() and use this function at all location
	  after resetting phy.
	- Move the location of calling wm_get_hw_control. Same as Linux.
	- Add I219 specific wokaround for legacy interrupt. From OpenBSD.
	- Move the location of calling wm_lplu_d0_disable().
	- Fix latency calculation in wm_platform_pm_pch_lpt().
	- Set OBFF water mark and enable OBFF on PCH_LPT and newer.
	- Disable D0 LPLU on 8257[12356], 82580, I350 and I21[01], too.	Before
	  this commit, above devices and non-PCIe devices accessed wrong
	  register.
	- Use device_printf() instead of aprint_error_dev() for PHY read/write
	  functions because those are used not only in device attach.
	- Fix a bug that wm_gmii_i82544_{read,write}reg() didn't take care of
	  page select. PHY access from igphy() automatically did it, but
	  accessing from wm(4) for wrokaround didn't work correctly. This
	  change affects 8254[17], 8257[12] ICH8, ICH9 and ICH10.
	- Call wm_kmrn_lock_loss_workaround_ich8lan() before any PHY access in
	  wm_linkintr_gmii().
	- Register access in wm_kmrn_lock_loss_workaround_ich8lan() now works
	  correctly. Enable this function.
	- Configure the LCD with the extended configuration region in NVM if
	  it's required.
	- If TX is not required to flush, RX is also not required to flush
	  in wm_flush_desc_rings(). Same as other OSes.
	- Remove wrong semaphore access in wm_nvm_{read,write}_{ich8,spt} to
	  prevent hangup. A semaphore is get/put in wm_nvm_{read,write}.
	- Move some initialization stuff in wm_attach() before wm_reset(). Some
	  flags and callback function are required to set correctly before
	  wm_reset() because wm_reset() and some helper functions refer them.
	- Add wm_write_smbus_addr() to set SMBus address by software.
	- Modify wm_gmii_hv_{read,write}reg_locked() to make them access
	  HV_SMB_ADDR correctly.
	- Use new nvm.{acquire,release}() for semaphore.
	- Our MII readreg/writereg API has not way to detect an error.
	  kmrn_{read,write}reg() are not used for MII API, so it's not required
	  for these functions to use the same API. So,
	  - Change return value as error code.
	  - Change register value from int to uint16_t.
	  - read: pass pointer for uint16_t as an argument.
	  - Check return value on caller side.
	- Check whether it's required to use MDIC workaround for 80003 or not
	  in wm_reset(). If the workaround isn't required, don't use the
	  workaround code in wm_gmii_i80003_{read,write}reg.
	- Add WM_F_WA_I210_CLSEM flag for a workaround. FreeBSD/Linux drivers
	  say "In rare circumstances, the SW semaphore may already be held
	  unintentionally on I21[01]". PXE boot is one of the case.
	- Qemu's e1000e emulation (82574L)'s SPI has only 64 words. I've never
	  seen on real 82574 hardware with such small SPI ROM. Check
	  sc->sc_nvm_wordsize before accessing higher address words to prevent
	  timeout.
	- Check some wm_nvm_read()'s return vale.
	- Print NVM offset and word count when EERD polling failed.
	- On I219, drop TARC0 bit 28 for DMA hang workaround (from Linux).
	- 82583 supports jumbo frame. Fixes PR#52773 reported by
	  Shinichi Doyashiki.
	- Fix typo in comment. Reported by Shinichi Doyashiki in PR#52885.
	- Add ASPM workaround for 8257[1234] and 82583 to prevent device
	  timeout or hangup. Fixes PR#52818 reported by Shinichi Doyashiki.
	- CID-1427779: Fix uninitialized variables.
	- Fix a bug that wm_pll_workaround_i210() is not called when
	  a) Chip is I211 or b) Chip is I210 and it uses iNVM (not FLASH).
	- Do wm_reset_mdicnfg_82580() on 82580 only.
	- Fix FLASH access on PCH_SPT and newer. Their FLASH access should be
	  done by 32bit. Especially for ICH_FLASH_HSFCTL register, it's located
	  at 0x0006, so it must be accessed via ICH_FLASH_HSFSTS(0x0004) and
	  use shift or mask.
	- Make wm_nvm_valid_bank_detect_ich8lan() the same as other OSes.
	- If the extended configuration size in the EXTCNFSIZE register is 0,
	  don't continue in wm_init_lcd_from_nvm().
	- Add PCH_CNP support (I219 with Intel 300 series chipset).
	- Enable I219 support.
	- I354 uses an external PHY, so don't use wm_set_eee_i350().
	- Fix a bug that the link can't detect in link interrupt function for
	  non-SERDES fiber.
	- Fix a bug that 82542 misunderstand fiber's signal detection.
	- Add debug printf()s.
	- Update comment.
	- Rename functions and variables.
	- Add diagnostic code.
	- Sort registers.
	- Lowercase hexadecimal values.
	- KNF.

Revision 1.39 / (download) - annotate - [select for diffs], Wed Aug 8 03:15:18 2018 UTC (5 years, 8 months ago) by msaitoh
Branch: MAIN
CVS Tags: pgoyette-compat-1126, pgoyette-compat-1020, pgoyette-compat-0930, pgoyette-compat-0906, jdolecek-ncqfixes-base, jdolecek-ncqfixes
Changes since 1.38: +2 -2 lines
Diff to previous 1.38 (colored)

Add MDIC_WA and CLSEMWA to snprintb() string for WM_F_* flags.

Revision 1.33.6.2 / (download) - annotate - [select for diffs], Mon Apr 16 14:25:49 2018 UTC (6 years ago) by martin
Branch: netbsd-8
CVS Tags: netbsd-8-0-RELEASE, netbsd-8-0-RC2, netbsd-8-0-RC1
Changes since 1.33.6.1: +3 -2 lines
Diff to previous 1.33.6.1 (colored) to branchpoint 1.33 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #764):

	sys/dev/pci/if_wm.c: revision 1.567
	sys/dev/pci/if_wm.c: revision 1.568
	sys/dev/pci/if_wm.c: revision 1.569
	sys/dev/pci/if_wmvar.h: revision 1.38
	sys/dev/pci/if_wm.c: revision 1.570
	sys/dev/pci/if_wm.c: revision 1.571
	sys/dev/pci/if_wm.c: revision 1.572
	share/man/man4/wm.4: revision 1.40
	sys/dev/pci/if_wmreg.h: revision 1.106
	sys/dev/pci/if_wmreg.h: revision 1.107

SW PHY Config Enable bit for ICH8 B0 stepping is not bit 1 but bit 0.

 No binary change:
- Sort registers.
- Lowercase hexadecimal value.

 On PCH_SPT (and newer), FLASH access should be done by 32bit.
Especially for ICH_FLASH_HSFCTL register, it's located at 0x0006, so
it should be accessed via ICH_FLASH_HSFSTS(0x0004) and use shift or mask.

 Our PCH_SPT part of wm_nvm_valid_bank_detect_ich8lan() was based on
FreeBSD r287467. After that, they reverted it and committed the different
code in r287762. r287762's bank detect code didn't work for us because our wm
dirver had a problem in flash access. The problem was fixed in if_wm.c rev.
1.567, so we can use the new way now.

 If the extended configration size in the EXTCNFSIZE register is 0, don't
continue.
 Add PCH_CNP support (I219 with Intel 300 series chipset).
It's required more test, so it's disabled by default.

 Enable I219.

 I354 uses an external PHY, so don't use wm_set_eee_i350().

Revision 1.37.2.1 / (download) - annotate - [select for diffs], Mon Apr 16 01:59:58 2018 UTC (6 years ago) by pgoyette
Branch: pgoyette-compat
Changes since 1.37: +3 -2 lines
Diff to previous 1.37 (colored)

Sync with HEAD, resolve some conflicts

Revision 1.38 / (download) - annotate - [select for diffs], Thu Apr 12 03:25:08 2018 UTC (6 years ago) by msaitoh
Branch: MAIN
CVS Tags: phil-wifi-base, pgoyette-compat-0728, pgoyette-compat-0625, pgoyette-compat-0521, pgoyette-compat-0502, pgoyette-compat-0422, pgoyette-compat-0415
Branch point for: phil-wifi
Changes since 1.37: +3 -2 lines
Diff to previous 1.37 (colored)

 Add PCH_CNP support (I219 with Intel 300 series chipset).
It's required more test, so it's disabled by default.

Revision 1.13.2.4 / (download) - annotate - [select for diffs], Sun Dec 3 11:37:08 2017 UTC (6 years, 4 months ago) by jdolecek
Branch: tls-maxphys
Changes since 1.13.2.3: +39 -9 lines
Diff to previous 1.13.2.3 (colored) to branchpoint 1.13 (colored) next main 1.14 (colored)

update from HEAD

Revision 1.23.2.6 / (download) - annotate - [select for diffs], Mon Aug 28 17:52:06 2017 UTC (6 years, 7 months ago) by skrll
Branch: nick-nhusb
Changes since 1.23.2.5: +13 -6 lines
Diff to previous 1.23.2.5 (colored) to branchpoint 1.23 (colored) next main 1.24 (colored)

Sync with HEAD

Revision 1.33.6.1 / (download) - annotate - [select for diffs], Tue Aug 1 23:33:18 2017 UTC (6 years, 8 months ago) by snj
Branch: netbsd-8
CVS Tags: matt-nb8-mediatek-base, matt-nb8-mediatek
Changes since 1.33: +13 -6 lines
Diff to previous 1.33 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #173):
	sys/dev/pci/if_wmreg.h: 1.99-1.103
	sys/dev/pci/if_wmvar.h: 1.34-1.37
	sys/dev/pci/if_wm.c: 1.510-1.537
	sys/dev/mii/ihphyreg.h: 1.2
	sys/dev/mii/inbmphyreg.h: 1.10
	sys/dev/mii/igphy.c: 1.27
Sync wm(4) up to if_wm.c rev. 1.537:
- Set WMREG_KABGTXD not in wm_init_locked() but in wm_reset().
- If a legacy interrupt is a spurious interrupt, don't print debug
  message.
- Don't print the Image Unique ID if an NVM is iNVM (i210 and I211).
- Fix a bug that a RAL was written at incorrect address when the index
  number is more than 16 on 82544 and newer.
- The layout of RAL on PCH* are different from others. Fix it.
- Flush every MTA write. Same as Linux.
- Move the location of calling wm_set_filter. Same as some other OSes.
- Flush writing WMREG_CTRL in wm_gmii_mediachange().
- Make new wm_phy_post_reset() and use this function at all location
  after resetting phy.
- Add I219 specific workaround for legacy interrupt. From OpenBSD.
- Move the location of calling wm_lplu_d0_disable().
- Disable D0 LPLU on 8257[12356], 82580, I350 and I21[01], too. Before
  this commit, above devices and non-PCIe devices accessed wrong
  register.
- Fix latency calculation in wm_platform_pm_pch_lpt().
- Set OBFF water mark and enable OBFF on PCH_LPT and newer.
- Fix a bug that wm_gmii_i82544_{read,write}reg() didn't take care of
  page select. PHY access from igphy() automatically did it, but
  accessing from wm(4) for workaround didn't work correctly. This
  change affects 8254[17], 8257[12] ICH8, ICH9 and ICH10.
- Call wm_kmrn_lock_loss_workaround_ich8lan() before any PHY access in
  wm_linkintr_gmii().
- Register access in wm_kmrn_lock_loss_workaround_ich8lan() now works
  correctly. Enable this function.
- IF TX is not required to flush, RX is also not required to flush in
  wm_flush_desc_rings(). Same as other OSes.
- Remove wrong semaphore access in wm_nvm_{read,write}_{ich8,spt} to
  prevent hangup. A semaphore is get/put in wm_nvm_{read,write}.
- Move some initialization stuff in wm_attach() before wm_reset().
  Some flags and callback function is required to set correctly before
  wm_reset() because wm_reset() and some helper functions refer them.
- Add wm_write_smbus_addr() to set SMBus address by software.
- Modify wm_gmii_hv_{read,write}reg_locked() to make them access
  HV_SMB_ADDR correctly.
- Configure the LCD with the extended configuration region in NVM if
  it's required. Tested with Thinkpad X220.
- 8257[12]: Don't directly access SPI but use EERD register.
- 82575-I354: If the size of SPI ROM >= 32K words, use direct SPI
  access instead of EERD register access.
- Add wm_nvm_eec_clock_raise() and wm_nvm_eec_clock_lower() and use
  them for Microwire/SPI bus control. Same as Linux and FreeBSD.
- Reduce timeout value for 80003 in wm_get_swfw_semaphore(). Same as
  Linux and FreeBSD.
- Change API of kmrn_{read,write}reg() and check the return value.
- Check whether it's required to use MDIC workaround for 80003 or not
  in wm_reset(). If the workaround isn't required, don't use the
  workaround code in wm_gmii_i80003_{read,write}reg.
- Add WM_F_WA_I210_CLSEM flag for a workaround. FreeBSD/Linux drivers
  say "In rare circumstances, the SW semaphore may already be held
  unintentionally." on I21[01]. PXE boot is one of the case.
- Qemu's e1000e emulation (82574L)'s SPI has only 64 words. I've never
  seen on real 82574 hardware with such small SPI ROM. Check
  NVM word size before accessing higher address words to prevent
  timeout.
- Check some wm_nvm_read()'s return vale.
- Use device_printf() instead of aprint_error_dev() for PHY read/write
  functions because those are used not only in device attach.
- Print internal driver flags when attaching.
- Add debug printf()s.
- Rename variables.
- Add comment, update comment and remove wrong comment.

Revision 1.37 / (download) - annotate - [select for diffs], Thu Jul 27 03:21:42 2017 UTC (6 years, 8 months ago) by msaitoh
Branch: MAIN
CVS Tags: tls-maxphys-base-20171202, pgoyette-compat-base, pgoyette-compat-0407, pgoyette-compat-0330, pgoyette-compat-0322, pgoyette-compat-0315, nick-nhusb-base-20170825
Branch point for: pgoyette-compat
Changes since 1.36: +2 -1 lines
Diff to previous 1.36 (colored)

 Add WM_F_WA_I210_CLSEM flag for a workaround. FreeBSD/Linux drivers say
"In rare circumstances, the SW semaphore may already be held unintentionally."
on I21[01]. PXE boot is one of the case.

XXX pullup-[678].

Revision 1.36 / (download) - annotate - [select for diffs], Wed Jul 26 06:48:49 2017 UTC (6 years, 8 months ago) by msaitoh
Branch: MAIN
Changes since 1.35: +2 -1 lines
Diff to previous 1.35 (colored)

-  Our MII readreg/writereg API has not way to detect an error.
  kmrn_{read,write}reg() are not used for MII API, so it's not required for
  these functions to use the same API. So,
  - Change return value as error code.
  - Change register vaule from int to uint16_t.
  - read: pass pointer for uint16_t as an argument.
  - Check return value on caller side.
- Check whether it's required to use MDIC workaround for 80003 or not in
  wm_reset(). If the workaround isn't required, don't use the workaround code
  in wm_gmii_i80003_{read,write}reg.

Revision 1.35 / (download) - annotate - [select for diffs], Tue Jul 25 06:00:17 2017 UTC (6 years, 8 months ago) by msaitoh
Branch: MAIN
Changes since 1.34: +5 -9 lines
Diff to previous 1.34 (colored)

 Use new nvm.{acquire,release}() for semaphore. Almost the same except the
following:
 - 8257[12]: Don't directly access SPI but use EERD register.
 - 82575-I354: If the size of SPI ROM >= 32K words, use direct SPI access
   instead of EERD register access.
 - Add wm_nvm_eec_clock_raise() and wm_nvm_eec_clock_lower() and use them for
   Microwire/SPI bus control. Same as Linux and FreeBSD.
 - Redude timeout value for 80003 in wm_get_swfw_semaphore(). Same as
   Linux and FreeBSD.

Revision 1.34 / (download) - annotate - [select for diffs], Mon Jun 26 04:03:34 2017 UTC (6 years, 9 months ago) by msaitoh
Branch: MAIN
CVS Tags: perseant-stdc-iso10646-base, perseant-stdc-iso10646
Changes since 1.33: +10 -1 lines
Diff to previous 1.33 (colored)

 Print sc_flags with snprintb().

Revision 1.32.2.1 / (download) - annotate - [select for diffs], Fri Apr 21 16:53:48 2017 UTC (6 years, 11 months ago) by bouyer
Branch: bouyer-socketcan
Changes since 1.32: +2 -2 lines
Diff to previous 1.32 (colored) next main 1.33 (colored)

Sync with HEAD

Revision 1.31.2.2 / (download) - annotate - [select for diffs], Mon Mar 20 06:57:29 2017 UTC (7 years ago) by pgoyette
Branch: pgoyette-localcount
Changes since 1.31.2.1: +2 -2 lines
Diff to previous 1.31.2.1 (colored) to branchpoint 1.31 (colored) next main 1.32 (colored)

Sync with HEAD

Revision 1.19.2.4.2.2 / (download) - annotate - [select for diffs], Mon Mar 13 07:41:27 2017 UTC (7 years, 1 month ago) by skrll
Branch: netbsd-7-nhusb
Changes since 1.19.2.4.2.1: +2 -2 lines
Diff to previous 1.19.2.4.2.1 (colored) to branchpoint 1.19.2.4 (colored) next main 1.19.2.5 (colored)

Sync with netbsd-7-1-RELEASE

Revision 1.19.2.6 / (download) - annotate - [select for diffs], Thu Mar 9 06:28:36 2017 UTC (7 years, 1 month ago) by snj
Branch: netbsd-7
CVS Tags: netbsd-7-1-RELEASE, netbsd-7-1-2-RELEASE, netbsd-7-1-1-RELEASE, netbsd-7-1
Changes since 1.19.2.5: +2 -2 lines
Diff to previous 1.19.2.5 (colored) to branchpoint 1.19 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1372):
	sys/dev/pci/if_wm.c: revisions 1.462, 1.464-1.465 1.474 via patch
	sys/dev/pci/if_wmreg.h: revision 1.97
	sys/dev/pci/if_wmvar.h: revision 1.33
- Set IPV6EXDIS bit in RFCTL register because of an Errata on 82575 and
  newer devices.
- Linux and FreeBSD defines 0x10f5 as E1000_DEV_ID_ICH9_IGP_M_AMT. In
  reality, This is not IGP but BM. Add new case to identify PHY type
  device. Fixes PR#51924 reported byJarle Greipsland.
- Use new wm_gmii_setup_phytype() function to setup sc_phytype and
  mii_{read|write}reg. This change improves detection of PHY type.
- Fix typo in comment.

Revision 1.23.2.5 / (download) - annotate - [select for diffs], Sun Feb 5 13:40:30 2017 UTC (7 years, 2 months ago) by skrll
Branch: nick-nhusb
Changes since 1.23.2.4: +2 -2 lines
Diff to previous 1.23.2.4 (colored) to branchpoint 1.23 (colored)

Sync with HEAD

Revision 1.33 / (download) - annotate - [select for diffs], Wed Feb 1 08:56:41 2017 UTC (7 years, 2 months ago) by msaitoh
Branch: MAIN
CVS Tags: prg-localcount2-base3, prg-localcount2-base2, prg-localcount2-base1, prg-localcount2-base, prg-localcount2, pgoyette-localcount-20170426, pgoyette-localcount-20170320, nick-nhusb-base-20170204, netbsd-8-base, jdolecek-ncq-base, jdolecek-ncq, bouyer-socketcan-base1
Branch point for: netbsd-8
Changes since 1.32: +2 -2 lines
Diff to previous 1.32 (colored)

 Use new wm_gmii_setup_phytype() function to setup sc_phytype and
mii_{read|write}reg. This function is called twie.

 To identify PHY type, correct read/write function should be selected. To
select correct read/write function, PCI ID or MAC type are required without
accessing PHY registers.

 On the first call of this function, PHY ID is not known yet. Check PCI ID or
MAC type. The list of the PCI ID may not be perfect, so the result might be
incorrect.

 In the second call, PHY OUI and model are used to identify PHY type. It might
not be perfpect because of the lack of compared entry, but it would be better
than the first call.

 If the detected new result and previous assumption is different, diagnous
message will be printed.

Revision 1.19.2.4.2.1 / (download) - annotate - [select for diffs], Wed Jan 18 08:46:27 2017 UTC (7 years, 2 months ago) by skrll
Branch: netbsd-7-nhusb
Changes since 1.19.2.4: +6 -2 lines
Diff to previous 1.19.2.4 (colored)

Sync with netbsd-5

Revision 1.19.2.5 / (download) - annotate - [select for diffs], Mon Dec 12 07:18:29 2016 UTC (7 years, 4 months ago) by snj
Branch: netbsd-7
CVS Tags: netbsd-7-nhusb-base-20170116, netbsd-7-1-RC2, netbsd-7-1-RC1
Changes since 1.19.2.4: +6 -2 lines
Diff to previous 1.19.2.4 (colored) to branchpoint 1.19 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1302):
	sys/dev/mii/igphyreg.h: revisions 1.7-1.10
	sys/dev/mii/ikphyreg.h: revisions 1.3
	sys/dev/mii/inbmphyreg.h: revisions 1.4-1.9
	sys/dev/mii/mii.h: revisions 1.19-1.20
	sys/dev/pci/if_wm.c: revisions 1.390, 1.392-1.395, 1.397, 1.419-1.425, 1.427-1.428, 1.430-1.435, 1.437-1.453 via patch
	sys/dev/pci/if_wmreg.: revisions 1.89-1.93 via patch
	sys/dev/pci/if_wmvar.h: revisions 1.31-1.32
Update wm(4) up to if_wm.c rev. 1.453 except MSI/MSI-X, multiqueue and
NET_MPSAFE:
- Add I219 support. It's not stable so it's disabled by default.
- wm_gate_hw_phy_config_ich8lan() is for younger than PCH2.
- Drop the host wakeup bit after resetting PHY on PCH and newer
  devices.
- Increase delay while toggling LANPHYPC
- Move call of wm_reset() in wm_attach() after setting PHY and NVM
  related flags because those flags are used in wm_reset().
- Use mutex for NVM access on ICH8 and newer devices. Same as FreeBSD.
- Rewrite PHY related lock stuff. Almost the same as FreeBSD.
  This change will fix a bug that PHY read/write fail on some cases.
- Increase delay in wm_phy_resetisblocked(). Same as FreeBSD.
- Use semaphore in wm_hv_phy_workaround_ich8lan() and
  wm_k1_gig_workaround_hv()
- Use wm_gii_mdic_readreg/writereg() in wm_access_phy_wakeup_reg_bm()
  because these functions are called with taking lock.
- 82567V_3 is BME1000_E_2(bm). Tested with Advantech AIMB-212 1st
  Ethernet port.
- Use wm_gmii_82544_{read,write}reg() on non-82567 ICH8, 9 and 10.
- Remove an 82578 workaround which was for PCH rev < 3. FreeBSD
  removed this workaround in r228386.
- Add an 82578 workaround which is for PHY rev < 2. From FreeBSD and
  Linux.
- Fix wm(4) input drop packet counter. WMREG_RNBC is incremented when
  there is no available buffers in host memory. However, ethernet
  controller can receive packets in such case if there is space in
  phy's FIFO. That is, ethernet controller drops packet only if there
  is no available buffers *and* there is no space in phy's FIFO. So,
  the number of dropped packets should be added WMREG_MPC only.
- Use MII_ADDRMASK.
- Define WMPHY_I217, WMPHY_VF and WMPHY_210.
- Use BME1000_PHY_PAGE_SELECT in wm_gmii_bm_{read,write}reg(). This
  change has no effect because GG82563_PHY_PAGE_SELECT and
  BME1000_PHY_PAGE_SELECT have the same value.
- Fix PHY access on  82567(ICH8 or ICH10), 82574 and 82583:
  - Use wm_gmii_bm_{read,write}reg() on 82574 and 82573.
  - Issue page select correctly on BM PHYs.
- Fix workaround which did dummy read BM_WUC register. This code was
  changed to drop BM_WUC_HOST_WU_BIT of BM_PROT_GEN_CFG register in
  FreeBSD r228386. The code was added rev. 1.149, but the location was
  not the best.
- wm_gmii_hv_{read/write}reg*(): USE PHY address 1 for some special
  registers.
- Add check code for an 82578 workaround. Not completed yet.
- wm_release_hw_control(): Remove extra line. No any effect.
- Add "10/100" into non-gigabit devices' name.
- Call wm_enable_wakeup() in wm_detach() and wm_suspend(). Now wake on
  lan works on Thinkpad X61(ICH8).
- Fix wm_access_phy_wakeup_reg_bm(). This change has no effect because
  this function is used for WUC register and our driver currenlty
  doesn't access to it.
- Call wm_enable_phy_wakeup() on PCH2 and newer, too. Now these devices
  can do WOL. Tested with Thinkpad X220(PCH2).
- Set CTRL_MEHE correctly (PCH_{LPT,SPT} only).
- Add three workarounds for PCH_{LPT,SPT}.
- Fix a bug that 8257[56], 82580, I35[04] and I21[01] didn't use
  wm_{get,release}_hw_control() correctly.
- Sync wm_smbustopci() with Linux and FreeBSD. This change effects PCH
  and newer devices.
- Move the location of wm_smbustopci() call.
- Fix flag check in wm_get_wakeup()
  - 8254[17]* and 8257[124] should not set WM_F_ARC_SUBSYS_VALID.
  - Add missing WM_T_82541_2 and WM_T_82547_2.
- Fix WOL related setting of the WUC register for other than PCH* in
  wm_enable_wakeup(). Tested with 82567V(ICH8) and 82583V.
- Use common MII_ADDRMASK.
- igphy(4): No binary change:
  - s/IGPPHY/IGPHY/
  - Fix the definition of PLHR_VALID_CHANNEL_*
  - Fix the definition of MSE_CHANNEL_*
  - Add MII_IGPHY_POWER_MGMT.
- Add some KASSERT.
- Add comment. Modify comment.
- Add debug code.

Revision 1.23.2.4 / (download) - annotate - [select for diffs], Mon Dec 5 10:55:03 2016 UTC (7 years, 4 months ago) by skrll
Branch: nick-nhusb
Changes since 1.23.2.3: +5 -2 lines
Diff to previous 1.23.2.3 (colored) to branchpoint 1.23 (colored)

Sync with HEAD

Revision 1.31.2.1 / (download) - annotate - [select for diffs], Fri Nov 4 14:49:10 2016 UTC (7 years, 5 months ago) by pgoyette
Branch: pgoyette-localcount
Changes since 1.31: +5 -2 lines
Diff to previous 1.31 (colored)

Sync with HEAD

Revision 1.32 / (download) - annotate - [select for diffs], Fri Oct 28 06:27:11 2016 UTC (7 years, 5 months ago) by msaitoh
Branch: MAIN
CVS Tags: pgoyette-localcount-20170107, pgoyette-localcount-20161104, nick-nhusb-base-20161204, bouyer-socketcan-base
Branch point for: bouyer-socketcan
Changes since 1.31: +5 -2 lines
Diff to previous 1.31 (colored)

- Define WMPHY_I217, WMPHY_VF and WMPHY_210.
- Use BME1000_PHY_PAGE_SELECT in wm_gmii_bm_{read,write}reg(). This change has
  no effect because GG82563_PHY_PAGE_SELECT and BME1000_PHY_PAGE_SELECT have
  the same value.

Revision 1.23.2.3 / (download) - annotate - [select for diffs], Sun May 29 08:44:22 2016 UTC (7 years, 10 months ago) by skrll
Branch: nick-nhusb
Changes since 1.23.2.2: +2 -1 lines
Diff to previous 1.23.2.2 (colored) to branchpoint 1.23 (colored)

Sync with HEAD

Revision 1.12.10.7 / (download) - annotate - [select for diffs], Fri May 6 18:43:34 2016 UTC (7 years, 11 months ago) by snj
Branch: netbsd-6
Changes since 1.12.10.6: +45 -27 lines
Diff to previous 1.12.10.6 (colored) to branchpoint 1.12 (colored) next main 1.13 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1366):
	sys/dev/pci/if_wm.c: 1.281, 1.318, 1.320, 1.324-1.332, 1.334, 1.336, 1.343-1.344, 1.347-1.348, 1.350, 1.376-1.382, 1.386-1.387, 1.389 via patch
	sys/dev/pci/if_wmreg.h: 1.68-1.70, 1.73-1.77, 1.79-1.80, 1.82, 1.86-1.88 via patch
	sys/dev/pci/if_wmvar.h: 1.22-1.23, 1.25-1.30 via patch
	sys/dev/mii/igphy.c: 1.25
	sys/dev/mii/ukphy.c: 1.48
Sync wm(4) as of if_wm.c rev 1.389 except SERDES, MSI/MSI-X, multiqueue
and NET_MPSAFE:
- Set ICH9 and ICH10's PBA size to 14K if the RX buffer size is more
  than 4096. Almost the same as other OSes.
- For 82576 and newer devices, the PBA register is deleted. Don't write
  PBA for those chips. Also change the calculation of RX packet buffer
  size in new way.
- Print NVM image version and option ROM version.
- Add workaround for I210 Errata 25 and I211 Errata 10 (PLL bug). This
  workaround is required if the NVM image version < 3.25.
- Fix a bug that wm_detach() didn't unmap the FHASH's area. Now
  "drvctl -d wm0" -> "drvctl -r pci0" works on ICH* and PCH*.
- Add workaround for 82574 Errata 25 and 82583 Errata 12 "Dropped RX
  packets" and for 82573 (unknown). Set GCR_L1_ACT_WITHOUT_L0S_RX bit.
  The NVM Image version 2.1.4 and newer have this workaround.
- Check PHY type correctly. This change is required to use igphy(4)
  device correctly.
- Disable LPLU (Low Power Link Up) on D0 state on 82574, 82583 and ICH*
  too.
- Call wm_get_hw_control() correctly. This change fixes a bug that some
  AMT based systems doesn't linkup at 1000BaseT. The problem was
  observed on HP Compaq dc7700. A lot of fixes have been done for wm(4)
  and igphy(4), so now PR#44893 should be fixed.
- Call wm_get_wakeup(sc) before checking WM_F_HAS_AMT. It's required to
  check the existence of AMT correctly.
- Fix a problem that wm_gate_hw_phy_config_ich8lan() isn't called in
  wm_reset() on PCH2.
- Clear WMREG_WUC in wm_reset() if the chip >= 82544. This might fix
  the behavior on suspend/resume.
- Fix logic of wm_check_reset_block() on ICH* and PCH*. This change
  might fix a problem that PHY's read/write functions can't get
  semaphore.
- On ICH8, call wm_gig_downshift_workaround_ich8lan() when link changed
  down.
- Drop PHY_CTRL_GBE_DIS explicitly in wm_lplu_d0_disable() in case BIOS
  sets this bit.
- Fix two bugs in wm_kmrn_lock_loss_workaround_ich8lan(). Now the
  function checks the status correctly but it causes linkdown up to 10
  times, so it's disabled for the time being.
- PR/50527: David Binderman: Fix impossible code. Odd offsets need
  special treatment.
- Fix RAL table's size of PCH2 and PCH_LPT.
- PCH_LPT (and newer device) is required to check FWSM_WLOCK_MAC bit to
  determine the range of the RAL.
- Use sc->sc_itr instead of hard-coded number.
- Rename wm_tbi_check_link() to wm_tbi_tick() because this function
  acts as mii_tick().
- ACK Accelerate Disable in the RFCTL register is not bit 13 but 12.
  No binary change because this definition has not used yet.
- Add ACK data Disable bit's definition (not used yet).
- PHY_CTRL_GBE_DIS is not bit 4 but bit 6. This change has no any
  effect by default because WM_WOL is not defined yet and
  m_kmrn_lock_loss_workaround_ich8lan() is broken.
- Fix wm_check_mng_mode_ich8lan(). This function is used only when
  WM_WOL is defined and it's disabled by default.
- Rename wm_check_reset_block() to wm_phy_resetisblocked() and make it
  returns bool. No functional change.
- Reorder function definitions and macro definitions. No functional
  change.
- Fix comment. Add comment. Update comment.
- KNF.

Revision 1.31 / (download) - annotate - [select for diffs], Fri May 6 08:56:20 2016 UTC (7 years, 11 months ago) by msaitoh
Branch: MAIN
CVS Tags: pgoyette-localcount-base, pgoyette-localcount-20160806, pgoyette-localcount-20160726, nick-nhusb-base-20161004, nick-nhusb-base-20160907, nick-nhusb-base-20160529, localcount-20160914
Branch point for: pgoyette-localcount
Changes since 1.30: +2 -1 lines
Diff to previous 1.30 (colored)

Basic support for I219. It doesn't work on I219, so it's disabled.

Revision 1.19.2.4 / (download) - annotate - [select for diffs], Fri Feb 26 22:08:17 2016 UTC (8 years, 1 month ago) by snj
Branch: netbsd-7
CVS Tags: netbsd-7-nhusb-base
Branch point for: netbsd-7-nhusb
Changes since 1.19.2.3: +23 -5 lines
Diff to previous 1.19.2.3 (colored) to branchpoint 1.19 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1102):
	sys/dev/mii/igphy.c: 1.25
	sys/dev/mii/ukphy.c: 1.48
	sys/dev/pci/if_wm.c: revisions 1.308, 1.318, 1.320, 1.324-1.332, 1.334, 1.336, 1.343-1.344, 1.347-1.348, 1.350, 1.376-1.382, 1.386-1.389 via patch
	sys/dev/pci/if_wmreg.h: revisions 1.68-1.70, 1.73-1.77, 1.79-1.80, 1.82, 1.86-1.88 via patch
	sys/dev/pci/if_wmvar.h: revisions 1.22-1.23, 1.25-1.30 via patch
Sync wm(4) as of if_wm.c rev 1.389 except MSI/MSI-X, multiqueue and NET_MPSAFE:
- Add C2000 KX and 2.5G support.
- Set ICH9 and ICH10's PBA size to 14K if the RX buffer size is more than
  4096. Almost the same as other OSes.
- For 82576 and newer devices, the PBA register is deleted. Don't write PBA
  for those chips. Also change the calculation of RX packet buffer size in
  new way.
- Fix a lot of bugs to make 82575 and newer SERDES based systems work.
- Print NVM image version and option ROM version.
- Add workaround for I210 Errata 25 and I211 Errata 10 (PLL bug). This
  workaround is required if the NVM image version < 3.25.
- Fix a bug that wm_detach() didn't unmap the FHASH's area. Now
  "drvct -d wm0" -> "drvctl -r pci0" works on ICH* and PCH*.
- Add workaround for 82574 Errata 25 and 82583 Errata 12 "Dropped RX packets"
  and for 82573 (unknown). Set GCR_L1_ACT_WITHOUT_L0S_RX bit. The NVM Image
  version 2.1.4 and newer have this workaround.
- Check PHY type correctly. This change is required to use igphy(4) device
  correctly.
- Disable LPLU (Low Power Link Up) on D0 state on 82574, 82583 and ICH* too.
- Call wm_get_hw_control() correctly. This change fixes a bug that some AMT
  based systems doesn't linkup at 1000BaseT. The problem was observed on HP
  Compaq dc7700. A lot of fixes have been done for wm(4) and igphy(4), so now
  PR#44893 should be fixed.
- Call wm_get_wakeup(sc) before checking WM_F_HAS_AMT. It's required to
  check the existence of AMT correctly.
- Fix a problem that wm_gate_hw_phy_config_ich8lan() isn't called in
  wm_reset() on PCH2.
- Clear WMREG_WUC in wm_reset() if the chip >= 82544. This might fix the
  behavior on suspend/resume.
- Fix logic of wm_check_reset_block() on ICH* and PCH*. This change might fix
  a problem that PHY's read/write functions can't get semaphore.
- On ICH8, call wm_gig_downshift_workaround_ich8lan() when link changed down.
- Drop PHY_CTRL_GBE_DIS explicitly in wm_lplu_d0_disable() in case BIOS sets
  this bit.
- Fix two bugs in wm_kmrn_lock_loss_workaround_ich8lan(). Now the function
  checks the status correctly but it causes linkdown up to 10 times, so it's
  disabled for the time being.
- PR/50527: David Binderman: Fix impossible code. Odd offsets need special
  treatment.
- Fix RAL table's size of PCH2 and PCH_LPT.
- PCH_LPT (and newer device) is required to check FWSM_WLOCK_MAC bit to
  determine the range of the RAL.
- Use sc->sc_itr instead of hard-coded number.
- Rename wm_tbi_check_link() to wm_tbi_tick() because this function acts as
  mii_tick().
- ACK Accelerate Disable in the RFCTL register is not bit 13 but 12.
  No binary change because this definition has not used yet.
- Add ACK data Disable bit's definition (not used yet).
- PHY_CTRL_GBE_DIS is not bit 4 but bit 6. This change has no any effect by
  default because WM_WOL is not defined yet and
  m_kmrn_lock_loss_workaround_ich8lan() is broken.
- Fix wm_check_mng_mode_ich8lan(). This function is used only when WM_WOL is
  defined and it's disabled by default.
- Rename wm_check_reset_block() to wm_phy_resetisblocked() and make it returns
  bool. No functional change.
- Reorder function definitions and macro definitions. No functional change.
- Fix comment. Add comment. Update comment.
- KNF.

Revision 1.23.2.2 / (download) - annotate - [select for diffs], Sun Dec 27 12:09:50 2015 UTC (8 years, 3 months ago) by skrll
Branch: nick-nhusb
Changes since 1.23.2.1: +4 -4 lines
Diff to previous 1.23.2.1 (colored) to branchpoint 1.23 (colored)

Sync with HEAD (as of 26th Dec)

Revision 1.30 / (download) - annotate - [select for diffs], Fri Dec 25 04:50:16 2015 UTC (8 years, 3 months ago) by msaitoh
Branch: MAIN
CVS Tags: nick-nhusb-base-20160422, nick-nhusb-base-20160319, nick-nhusb-base-20151226
Changes since 1.29: +4 -4 lines
Diff to previous 1.29 (colored)

- Fix RAL table's size of PCH2 and PCH_LPT.
- PCH_LPT (and newer device) is required to check FWSM_WLOCK_MAC bit to
  determine the range of the RAL.
- Fix typo in comment and modify comment by tnn@.
- Rename wm_check_reset_block() to wm_phy_resetisblocked() and make it returns
  bool. No functional change.

Revision 1.23.2.1 / (download) - annotate - [select for diffs], Sat Jun 6 14:40:09 2015 UTC (8 years, 10 months ago) by skrll
Branch: nick-nhusb
Changes since 1.23: +5 -2 lines
Diff to previous 1.23 (colored)

Sync with HEAD

Revision 1.29 / (download) - annotate - [select for diffs], Sat Jun 6 04:39:12 2015 UTC (8 years, 10 months ago) by msaitoh
Branch: MAIN
CVS Tags: nick-nhusb-base-20150921, nick-nhusb-base-20150606
Changes since 1.28: +2 -2 lines
Diff to previous 1.28 (colored)

- Add workaround for I210 Errata 25 and I211 Errata 10.
   - Add wm_gmii_gs40g_{read|write}reg() and use it to access non-standatrd
     page.
   - Add wm_pll_workaround_i210() and call it when
       chip is i211
       chip is i210 and it use INVM
       chip is i210 and NVM image version < 3.25
- Add comment
- Rename macros.

Revision 1.28 / (download) - annotate - [select for diffs], Sat Jun 6 03:38:40 2015 UTC (8 years, 10 months ago) by msaitoh
Branch: MAIN
Changes since 1.27: +1 -0 lines
Diff to previous 1.27 (colored)

 Print NVM image version.

Revision 1.27 / (download) - annotate - [select for diffs], Sat Jun 6 03:37:01 2015 UTC (8 years, 10 months ago) by msaitoh
Branch: MAIN
Changes since 1.26: +1 -2 lines
Diff to previous 1.26 (colored)

 Revert previos. Sorry, I committed in another working directory...

Revision 1.26 / (download) - annotate - [select for diffs], Sat Jun 6 03:33:37 2015 UTC (8 years, 10 months ago) by msaitoh
Branch: MAIN
Changes since 1.25: +3 -2 lines
Diff to previous 1.25 (colored)

 Print NVM image version.

Revision 1.25 / (download) - annotate - [select for diffs], Tue Jun 2 14:19:26 2015 UTC (8 years, 10 months ago) by msaitoh
Branch: MAIN
Changes since 1.24: +2 -1 lines
Diff to previous 1.24 (colored)

Fix a lot of bugs to make 82575 and newer's SERDES based systems work.
 - Add SERDES specific functions.
 - Fix IO pin configuration.
 - Reset autonego timer when link becomes up.

TODO:
 - Fix a bug that SFP ROM can't read.
 - Perhaps some work is required for 8257[12] serdes systems.
 - Remove duplicated code in TBI's link related functions.

Revision 1.19.2.3 / (download) - annotate - [select for diffs], Tue May 19 05:09:02 2015 UTC (8 years, 11 months ago) by snj
Branch: netbsd-7
CVS Tags: netbsd-7-0-RELEASE, netbsd-7-0-RC3, netbsd-7-0-RC2, netbsd-7-0-RC1, netbsd-7-0-2-RELEASE, netbsd-7-0-1-RELEASE, netbsd-7-0
Changes since 1.19.2.2: +2 -1 lines
Diff to previous 1.19.2.2 (colored) to branchpoint 1.19 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #784):
	sys/dev/pci/if_wm.c: revision 1.321
	sys/dev/pci/if_wmreg.h: revision 1.71
	sys/dev/pci/if_wmvar.h: 1.24 via patch
Add support iNVM (integrated Non-Volatile Memory) for I21[01].
This change fixes a bug that a MAC address is wrongly set on
iNVM machines/NICs.

Revision 1.24 / (download) - annotate - [select for diffs], Sat May 16 22:41:59 2015 UTC (8 years, 11 months ago) by msaitoh
Branch: MAIN
Changes since 1.23: +2 -1 lines
Diff to previous 1.23 (colored)

 Add support iNVM (integrated Non-Volatile Memory) for I21[01]. This change
fixes a bug that a MAC address is wrongly set on iNVM machines and NICs.
Tested with Shuttle DS57U(iNVM based) and other non iNVM based I210 machines.

Revision 1.2.46.7 / (download) - annotate - [select for diffs], Thu Apr 30 20:00:27 2015 UTC (8 years, 11 months ago) by snj
Branch: netbsd-5
Changes since 1.2.46.6: +3 -2 lines
Diff to previous 1.2.46.6 (colored) to branchpoint 1.2 (colored) next main 1.3 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1962):
	sys/dev/pci/if_wm.c: revisions 1.259-1.266, 1.269, 1.271, 1.273-1.274, 1.277-1.278, 1.282, 1.284-1.285, 1.287, 1.290, 1.294, 1.297-1.298, 1.300-1.301, 1.304-1.307, 1.310, 1.312-1.314, 1.316 via patch
	sys/dev/pci/if_wmreg.c: revisions 1.54-1.57, 1.59-1.60, 1.62, 1.64-1.66 via patch
	sys/dev/pci/if_wmvar.c: revisions 1.17, 1.20-1.21 via patch
	sys/dev/pci/pcidevs: revisions 1.1172, 1.1195, 1.1201 via patch
- Fix "MDIC write error" bug for 82574 and 82583. For those chips, the
  semaphore must be released after chip reset. Found and tested by
  Mark Davies.
- Fix BMC related bugs.
- Fix yet another NVM bank detect problem in wm(4). Use bank 0 if the detect
  function failed. It's the same as FreeBSD. Observed and tested with
  Asus P8P67 Deluxe motherboard and tested by jnemeth.
- Add support for I354 DH89xxCC and some new I218 devices.
- Fix definition of CTRL_GIO_M_DIS bit.
- Insert completion barrier between register write and delay().
- Bump max TX DMA size to avoid pathological condition with TSO. From dyoung.
- Fix semaphore related bugs.
- Call wm_set_pcie_completion_timeout() on I350, I354, I210 and I211, too.
  Same as FreeBSD and OpenBSD.
- Drop PHPM_GO_LINK_D bit in WMREG_PHPM on some chips. From FreeBSD.
-  Fix fiber link problem (PR#44776 and PR#30880).
- WM_T_82545 is not 1000base-SX but 1000base-LX. Same as FreeBSD.
- Set the WM_F_ATTACHED flag if wm_attach() finished succesfully and check
  the flag in wm_detach(). It will avoid to panic in wm_detach().
  Fixes PR#49102.
- It's not required to print "failed to detect NVM bank" with
  aprint_error_dev(). Use DPRINTF(). Same as {Free,Open}BSD.
- Fix a bug that the offset of alt MAC address is wrongly calculated to 0
  when alt MAC address function is really used. This bug does not appear
  as real bug if the same MAC address is written in the default location
  and alt MAC address's location.
- Initialize some hardware bits for 8257[1234], 82583, 80003, ICH* and PCH*.
  Some of them are workaround code. From other *BSDs, Linux and documents.
- Fix a bug that wm_sgmii_writereg() function doesn't pass the "val" argument
  to the I2CCMD register. Reported by Bernard Merindol in PR#49789.
- Delete 82580ER related code. It was from FreeBSD and was removed
  in r203049.
- Remove extra debug message.
- Remove unused variable.
- Remove a duplicated error message.
- Cleanup comments.
- Fix debug message.

Revision 1.12.10.6 / (download) - annotate - [select for diffs], Thu Apr 30 19:53:28 2015 UTC (8 years, 11 months ago) by snj
Branch: netbsd-6
Changes since 1.12.10.5: +2 -1 lines
Diff to previous 1.12.10.5 (colored) to branchpoint 1.12 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1296):
	sys/dev/pci/pcidevs: revision 1.1195 via patch
	sys/dev/pci/if_wm.c: revisions 1.290, 1.304 via patch
	sys/dev/pci/if_wmvar.h: revision 1.20 via patch
- Set the WM_F_ATTACHED flag if wm_attach() finished succesfully and
  check the flag in wm_detach(). It will avoid to panic in wm_detach().
  Fixes PR#49102.
- Support DH89xxCC device.
- Add extra delay for 82580 and newer devices except DH89XXCC SGMII device.
  Same as FreeBSD.

Revision 1.12.10.5 / (download) - annotate - [select for diffs], Thu Dec 4 06:04:07 2014 UTC (9 years, 4 months ago) by snj
Branch: netbsd-6
Changes since 1.12.10.4: +19 -20 lines
Diff to previous 1.12.10.4 (colored) to branchpoint 1.12 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #1203):
	sys/dev/pci/if_wm.c: revisions 1.271, 1.273-1.274, 1.277-1.278,
				       1.280, 1.282, 1.284-1.285, 1.287,
				       1.293-1.294, 1.297-1.298,
				       1.300-1.301, 1.305-1.307 via patch
	sys/dev/pci/if_wmreg.h: revisions 1.57-1.62, 1.64-1.65 via patch
	sys/dev/pci/if_wmvar.h: revisions 1.19, 1.21 via patch
- Acquire SW semaphore in wm_get_swsm_semaphore().
- Fix some bugs realted to semaphore. This change fixes a problem which
  was exposed in if_wm.c rev. 1.271. Tested by riastradh@.
  - Clear the SMBI bit in SWSM register before accessing NVM and PHY in
    wm_attach(). Same as FreeBSD.
  - Fix a bug that 82573 doesn't put the hardware semaphore. Same as
    FreeBSD r256200.
- Call wm_set_pcie_completion_timeout() on I350, I354, I210 and I211, too.
  Same as FreeBSD and OpenBSD.
- Drop PHPM_GO_LINK_D bit in WMREG_PHPM on some chips. From FreeBSD.
- Fix fiber link problem (PR#44776 and PR#30880). Tested with 82543GC, 82544EI,
  82545EM, 82546GB 82571EB and 82572EI fiber cards.
  - Don't use the RXCFG interrupt. It's not required and the interrupt is very
    heavy (a lot of interrupts). Same as {Free,Open}BSD.
  - Modify wm_tbi_mediachange() to be close to em_setup_fiber_serdes_link()
    of {Free,Open}BSD. At least, don't forget to set duplex setting.
  - WM_T_82545 is not 1000base-SX but 1000base-LX. Same as FreeBSD.
- Don't check SWSM_SMBI bit if WM_F_LOCK_SWSM isn't set. Fix a problem when
  using vmware with e1000"e". With e1000e which is regarded as 82574L,
  wm_gmii_init() fails with "could not acquire SWSM SMBI" message without
  this change. This problem doesn't occur with real 82574L card.
- Fix a bug that wm_get_swsm_semaphore() timed out when attaching device on
  some machines.
  - Calculate NVM word size correctly.
  - Determine timeout value based on the NVM word size.
- It's not required to print "failed to detect NVM bank" message.
  Only print while debugging. Same as {Free,Open}BSD.
- Add some new I218 devices.
- Delete 82580ER related code. It was from FreeBSD and was removed in r203049.
- Fix a bug that the offset of alt MAC address is wrongly calculated to 0
  when alt MAC address function is really used. This bug does not appear
  as real bug if the same MAC address is written in the default location
  and alt MAC address's location.
- Move some NVM related macros from if_wm.c to if_wmreg.h.
- Sort definitions in if_wmreg.h
  - move NVM related values to the bottom.
  - sort in register's address' order.
- Simplify wm_read_mac_addr().
- Fix debug message.
- Add missing prototypes.
- Rename some functions for consistency and clarify.
- Rename some macros for consistency.
- Remove a duplicated error message.
- Fix typo in comment.
- Cleanup comments.
- KNF.

Revision 1.23 / (download) - annotate - [select for diffs], Thu Nov 27 11:42:02 2014 UTC (9 years, 4 months ago) by msaitoh
Branch: MAIN
CVS Tags: nick-nhusb-base-20150406, nick-nhusb-base
Branch point for: nick-nhusb
Changes since 1.22: +2 -2 lines
Diff to previous 1.22 (colored)

Fix typo in comment.

Revision 1.22 / (download) - annotate - [select for diffs], Tue Nov 25 05:05:16 2014 UTC (9 years, 4 months ago) by msaitoh
Branch: MAIN
Changes since 1.21: +17 -1 lines
Diff to previous 1.21 (colored)

Add note about the variations of Intel gigabit Ethernet controller.

Revision 1.12.10.4 / (download) - annotate - [select for diffs], Sun Nov 9 12:03:18 2014 UTC (9 years, 5 months ago) by martin
Branch: netbsd-6
Changes since 1.12.10.3: +2 -1 lines
Diff to previous 1.12.10.3 (colored) to branchpoint 1.12 (colored)

Pullup the following revisions, requested by msaitoh in ticket #1188:
sys/dev/pci/pcidevs			1.1172
sys/dev/pci/if_wm.c			1.263-1.266 via patch
sys/dev/pci/if_wmreg.h			1.55-1.56
sys/dev/pci/if_wmvar.h			1.17
share/man/man4/wm.4			1.26-1.27 and 1.29 via patch

- Add I354 support.
- Insert completion barrier between register write and delay().
- Fix the definition of CTRL_GIO_M_DIS. This bit is not bit 3 but bit 2.
- Cleanup

Revision 1.19.2.2 / (download) - annotate - [select for diffs], Fri Nov 7 21:34:56 2014 UTC (9 years, 5 months ago) by snj
Branch: netbsd-7
Changes since 1.19.2.1: +1 -2 lines
Diff to previous 1.19.2.1 (colored) to branchpoint 1.19 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #190):
	sys/dev/pci/pcidevs			1.1201-1.1202 via patch
	sys/dev/pci/if_wm.c			1.291-1.301, 1.304, 1.306-1.307 via patch
	sys/dev/pci/if_wmreg.h			1.61-1.65 via patch
	sys/dev/pci/if_wmvar.h			1.21 via patch
	share/man/man4/wm.4			1.31 via patch
- Add Internal SERDES mode support newer than or equal to 82575.
- Add new I218 devices.
- Add DH89xxCC device.
- Add some old devices.
- Fix a bug that wm_get_swsm_semaphore() timed out when attaching device on
  some machines.
- Fix a bug that the offset of alt MAC address is wrongly calculated to 0
  when alt MAC address function is really used. This bug does not appear
  as real bug if the same MAC address is written in the default location
  and alt MAC address's location.
- Don't print "failed to detect NVM bank" message.
- Delete 82580ER related code.
- Fix typo in comment.
- Fix debug message.
- Cleanup

Revision 1.21 / (download) - annotate - [select for diffs], Mon Oct 6 07:31:24 2014 UTC (9 years, 6 months ago) by msaitoh
Branch: MAIN
Changes since 1.20: +1 -2 lines
Diff to previous 1.20 (colored)

 Delete 82580ER related code. It was from FreeBSD and was removed in r203049.

Revision 1.19.2.1 / (download) - annotate - [select for diffs], Fri Aug 29 11:37:51 2014 UTC (9 years, 7 months ago) by martin
Branch: netbsd-7
Changes since 1.19: +2 -1 lines
Diff to previous 1.19 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #61):
	sys/dev/pci/if_wm.c: revision 1.290
	sys/dev/pci/if_wmvar.h: revision 1.20
Set the WM_F_ATTACHED flag if wm_attach() finished succesfully and check
the flag in wm_detach(). It will avoid to panic in wm_detach().
Fixes PR#49102.

Revision 1.20 / (download) - annotate - [select for diffs], Sun Aug 24 21:15:35 2014 UTC (9 years, 7 months ago) by msaitoh
Branch: MAIN
Changes since 1.19: +2 -1 lines
Diff to previous 1.19 (colored)

 Set the WM_F_ATTACHED flag if wm_attach() finished succesfully and check
the flag in wm_detach(). It will avoid to panic in wm_detach().
Fixes PR#49102.

Revision 1.13.2.3 / (download) - annotate - [select for diffs], Wed Aug 20 00:03:43 2014 UTC (9 years, 7 months ago) by tls
Branch: tls-maxphys
Changes since 1.13.2.2: +24 -23 lines
Diff to previous 1.13.2.2 (colored) to branchpoint 1.13 (colored)

Rebase to HEAD as of a few days ago.

Revision 1.17.2.1 / (download) - annotate - [select for diffs], Sun Aug 10 06:54:54 2014 UTC (9 years, 8 months ago) by tls
Branch: tls-earlyentropy
Changes since 1.17: +24 -24 lines
Diff to previous 1.17 (colored) next main 1.18 (colored)

Rebase.

Revision 1.19 / (download) - annotate - [select for diffs], Mon Jul 14 05:00:18 2014 UTC (9 years, 9 months ago) by msaitoh
Branch: MAIN
CVS Tags: tls-maxphys-base, tls-earlyentropy-base, netbsd-7-base
Branch point for: netbsd-7
Changes since 1.18: +19 -19 lines
Diff to previous 1.18 (colored)

Cleanup comments. No functional change.

Revision 1.18 / (download) - annotate - [select for diffs], Fri Jul 11 08:34:27 2014 UTC (9 years, 9 months ago) by msaitoh
Branch: MAIN
Changes since 1.17: +23 -23 lines
Diff to previous 1.17 (colored)

Rename some WM_F_* flags to clarify. Renumbering flags. No functional change.

 WM_F_EEPROM_HANDSHAKE -> WM_F_LOCK_EECD
 WM_F_EEPROM_SEMAPHORE -> WM_F_LOCK_SWSM
 WM_F_SWFW_SYNC        -> WM_F_LOCK_SWFW
 WM_F_SWFWHW_SYNC      -> WM_F_LOCK_EXTCNF

Revision 1.12.4.2 / (download) - annotate - [select for diffs], Thu May 22 11:40:25 2014 UTC (9 years, 10 months ago) by yamt
Branch: yamt-pagecache
Changes since 1.12.4.1: +8 -2 lines
Diff to previous 1.12.4.1 (colored) to branchpoint 1.12 (colored) next main 1.13 (colored)

sync with head.

for a reference, the tree before this commit was tagged
as yamt-pagecache-tag8.

this commit was splitted into small chunks to avoid
a limitation of cvs.  ("Protocol error: too many arguments")

Revision 1.16.2.1 / (download) - annotate - [select for diffs], Sun May 18 17:45:40 2014 UTC (9 years, 11 months ago) by rmind
Branch: rmind-smpnet
Changes since 1.16: +2 -1 lines
Diff to previous 1.16 (colored) next main 1.17 (colored)

sync with head

Revision 1.17 / (download) - annotate - [select for diffs], Sun Dec 29 21:28:41 2013 UTC (10 years, 3 months ago) by msaitoh
Branch: MAIN
CVS Tags: yamt-pagecache-base9, rmind-smpnet-nbase, rmind-smpnet-base, riastradh-xf86-video-intel-2-7-1-pre-2-21-15, riastradh-drm2-base3
Branch point for: tls-earlyentropy
Changes since 1.16: +2 -1 lines
Diff to previous 1.16 (colored)

Add support For I354(C2000 interna Ethernet controller):
 - Add I354 support.
 - Fix SGMII+MDIO case. SGMII+I2C is not supported yet.
 - Not tested well.
 - Sprinkle "XXX" to check later.

Revision 1.2.46.6 / (download) - annotate - [select for diffs], Sat Sep 7 17:10:18 2013 UTC (10 years, 7 months ago) by bouyer
Branch: netbsd-5
Changes since 1.2.46.5: +5 -1 lines
Diff to previous 1.2.46.5 (colored) to branchpoint 1.2 (colored)

sys/dev/pci/if_wm.c				1.246-1.247, 1.249-1.258
sys/dev/pci/if_wmreg.h				1.51, 1.53
sys/dev/pci/if_wmvar.h				1.15-1.16
sys/dev/pci/pcidevs				1.1152-1.1153
sys/dev/pci/pcidevs.h				regen
sys/dev/pci/pcidevs_data.h			regen

	Add I21[0178] support.
	Fix a bug that wm_attach() may fail on some PCH2 or newer system.
	wm_valid_nvm_bank_detect_ich8lan() misunderstood the NVM's bank
	number. Fixes PR#47878.
	Fix a bug that the check of reset complete fails on Intel 8 series
	with "wm_lan_init_done: lan_init_done failed to complete" message.
	The broken code was used for ICH8, 9... and PCH2.
	The wm_linkintr_gmii() function is called from interrupt. That's
	not tick, so call mii_pollstat() instead of mii_tick().
	Add ECC support for the packet buffer. Only 82571 and I21[78] support
	ECC.
	Fix a bug that wrong semaphore is used in wm_gmii_hv_{read,write}reg.
	Add comments, fix some comments, use macros and remove trailing
	whitespaces.
	[msaitoh, ticket #1867]

Revision 1.12.10.3 / (download) - annotate - [select for diffs], Sun Jul 14 20:39:13 2013 UTC (10 years, 9 months ago) by riz
Branch: netbsd-6
Changes since 1.12.10.2: +5 -1 lines
Diff to previous 1.12.10.2 (colored) to branchpoint 1.12 (colored)

Apply changes (requested by msaitoh in ticket #907):

sys/dev/pci/if_wm.c				1.238, 1.244-1.247, 1.249-1.258
sys/dev/pci/if_wmreg.h				1.50-1.51, 1.53
sys/dev/pci/if_wmvar.h				1.15-1.16

	Various fixes to wm(4):
	Add I21[0178] support.
	Fix a bug that wm_attach() may fail on some PCH2 or newer system.
	wm_valid_nvm_bank_detect_ich8lan() misunderstood the NVM's bank
	number. Fixes PR#47878.
	Fix a bug that the check of reset complete fails on Intel 8 series
	with "wm_lan_init_done: lan_init_done failed to complete" message.
	The broken code was used for ICH8, 9... and PCH2.
	The wm_linkintr_gmii() function is called from interrupt. That's
	not tick, so call mii_pollstat() instead of mii_tick().
	Add ECC support for the packet buffer. Only 82571 and I21[78] support
	ECC.
	Fix a bug that wrong semaphore is used in wm_gmii_hv_{read,write}reg.
	Change style, add comments, fix some comments, use macros and
	remove trailing whitespaces.
	[msaitoh, ticket #907]

Revision 1.13.2.2 / (download) - annotate - [select for diffs], Sun Jun 23 06:20:18 2013 UTC (10 years, 9 months ago) by tls
Branch: tls-maxphys
Changes since 1.13.2.1: +5 -1 lines
Diff to previous 1.13.2.1 (colored) to branchpoint 1.13 (colored)

resync from head

Revision 1.2.46.5 / (download) - annotate - [select for diffs], Wed Jun 19 07:50:15 2013 UTC (10 years, 9 months ago) by bouyer
Branch: netbsd-5
Changes since 1.2.46.4: +28 -18 lines
Diff to previous 1.2.46.4 (colored) to branchpoint 1.2 (colored)

Pullup the following revisions via patch, requested by msaitoh in ticket #1850:
	sys/dev/pci/if_wm.c			1.201, 1.203-1.204,
						1.207-1.212, 1.215,
						1.217-1.218, 1.220-1.223,
						1.228, 1.232-245
	sys/dev/pci/if_wmreg.h			1.40-1.45, 1.47-1.48
	sys/dev/pci/if_wmvar.h			1.11-1.13
	sys/dev/pci/pcidevs			1.1074, 1.1077, 1.1117
	sys/dev/pci/pcidevs.h			regen
	sys/dev/pci/pcidevs_data.h		regen
	sys/dev/mii/igphyreg.h			1.6
	sys/dev/mii/ihphy.c			1.1-1.2
	sys/dev/mii/ihphyreg.h			1.1
	sys/dev/mii/inbmphyreg.h		1.3
	sys/dev/mii/files.mii			1.47 via patch
	sys/dev/mii/miidevs			1.97 and 1.100
	sys/dev/mii/miidevs.h			regen
	sys/dev/mii/miidevs_data.h		regen
	sys/arch/i386/conf/ALL			1.280
	sys/arch/i386/conf/GENERIC		1.1001
	sys/arch/i386/conf/INSTALL_FLOPPY	1.11
	sys/arch/i386/conf/XEN2_DOM0		patch
	sys/arch/amd64/conf/GENERIC		1.293
	sys/arch/amd64/conf/XEN3_DOM0		1.61
	share/man/man4/wm.4			1.21-1.24

Apply almost all fixes and improvements from netbsd-6 except for
the rev. 1.196's iqdrops' change.

- Add the detach code.
- Add code for WOL, ASF, IPMI and Intel AMT. WOL is disabled by default
- Add Yet another workaround for ICH8.
- 82576 is dual port, so check the FUNCID and increment the MAC address for
  the 2nd port.
- Fix the names of 82577L[MC] LAN controllers (for mobile).
- Fix CTRL_EXT_SWDPIN() and CTRL_EXT_SWDPIO() macros. The bit order of the
  SW definable pin is not 6543 but 3654!!!
- Rewrite the code to read MAC address from eeprom.
- Add 82580 support.
- 82571 quirk. Only 82571 shares port 0 of EEMNGCTL_CFGDONE.
- The document says that the TDH register must be set after
  TCL.EN is set on 82575 and newer devices.
- Fix some register names. No functional change.
- Omit U+00AE "REGISTERED SIGN" in a product name due to its non-ASCII nature.
- Stop wm(4) from needlessly resetting when you add or delete a vlan(4).
- Fix MAC address check on 8257[156] and 80003 case. Some cards have non 0xffff
  pointer but those don't use alternative MAC address in reality. So we check
  whether the broadcast bit is set or not like Intel's e1000 driver.
  Fixes PR kern/44072 reported by Jean-Yves Moulin.
- Add PCH2(and 82579) support. Fixes PR#46487
- Add yet another 82567V support.
- Add ICH10+HANKSVILL support.
- Add support Intel I350 Ethernet.
- Make vlan and all ip/ip6 checksum offload work for the I350.
- Fix compile error with  WM_DEBUG.
- Fix a bug that PHY isn't set to low-power mode on PCH and PCH2.
- Add WM_DEBUG_NVM. If WM_DEBUG_NVM is enabled, dump the FLASH ROM data.
- Skip 64bit BAR correctly.
- Fix RAL_TABSIZE for ICH8, 82576, 82580 and I350.
- Use 82580(and I350) specific PHY read/write functions. Fixes PR#47542.
- Style fix. Fix typo in comment. Fix comments. Add comments.

Revision 1.16 / (download) - annotate - [select for diffs], Sun Jun 2 09:36:22 2013 UTC (10 years, 10 months ago) by msaitoh
Branch: MAIN
CVS Tags: riastradh-drm2-base2, riastradh-drm2-base1, riastradh-drm2-base, riastradh-drm2
Branch point for: rmind-smpnet
Changes since 1.15: +1 -3 lines
Diff to previous 1.15 (colored)

Add I217 (and I218) support.
- The name of I217 is similar to I210, but the function is rather similar to
  PCH2.
- Not tested well. Tested with my own Intel DQ87PG which has I217LM onboard.
- It seems that PCH2 and PCH_LPT specific function for RAL should be written.
- Quick hack for the NVM checksum mismatch. if_wm.c currently has no
  wm_write_eeprom(), so it cannot update NVM's "updated bit". To avoid this
  problem, check only the last 12bits of the checksum. My own DQ87PG's
  updated bit is not set, and I could avoid the problem using with this
  hack.

Revision 1.15 / (download) - annotate - [select for diffs], Thu Apr 18 12:42:03 2013 UTC (11 years ago) by msaitoh
Branch: MAIN
CVS Tags: khorben-n900
Changes since 1.14: +7 -1 lines
Diff to previous 1.14 (colored)

Add support I21[01]. Only tested with my own I210-T1 Ethernet Server Adapter.

Revision 1.13.2.1 / (download) - annotate - [select for diffs], Mon Feb 25 00:29:18 2013 UTC (11 years, 1 month ago) by tls
Branch: tls-maxphys
Changes since 1.13: +3 -2 lines
Diff to previous 1.13 (colored)

resync with head

Revision 1.12.10.2 / (download) - annotate - [select for diffs], Thu Feb 14 22:08:28 2013 UTC (11 years, 2 months ago) by jdc
Branch: netbsd-6
CVS Tags: netbsd-6-1-RELEASE, netbsd-6-1-RC4, netbsd-6-1-RC3, netbsd-6-1-RC2, netbsd-6-1-RC1, netbsd-6-1-5-RELEASE, netbsd-6-1-4-RELEASE, netbsd-6-1-3-RELEASE, netbsd-6-1-2-RELEASE, netbsd-6-1-1-RELEASE, netbsd-6-1
Changes since 1.12.10.1: +3 -2 lines
Diff to previous 1.12.10.1 (colored) to branchpoint 1.12 (colored)

Pull up revisions:
  src/sys/dev/pci/if_wm.c revision 1.243
  src/sys/dev/pci/if_wmvar.h revision 1.14
(requested by msaitoh in ticket #820).

Use 82580(and I350) specific PHY read/write functions.
Fixes PR#47542.

Revision 1.14 / (download) - annotate - [select for diffs], Tue Feb 12 03:11:43 2013 UTC (11 years, 2 months ago) by msaitoh
Branch: MAIN
CVS Tags: agc-symver-base, agc-symver
Changes since 1.13: +3 -2 lines
Diff to previous 1.13 (colored)

Use 82580(and I350) specific PHY read/write functions.
Fixes PR#47542.

Revision 1.12.4.1 / (download) - annotate - [select for diffs], Tue Oct 30 17:21:34 2012 UTC (11 years, 5 months ago) by yamt
Branch: yamt-pagecache
CVS Tags: yamt-pagecache-tag8
Changes since 1.12: +3 -1 lines
Diff to previous 1.12 (colored)

sync with head

Revision 1.12.10.1 / (download) - annotate - [select for diffs], Thu Jun 28 16:06:36 2012 UTC (11 years, 9 months ago) by riz
Branch: netbsd-6
CVS Tags: netbsd-6-0-RELEASE, netbsd-6-0-RC2, netbsd-6-0-RC1, netbsd-6-0-6-RELEASE, netbsd-6-0-5-RELEASE, netbsd-6-0-4-RELEASE, netbsd-6-0-3-RELEASE, netbsd-6-0-2-RELEASE, netbsd-6-0-1-RELEASE, netbsd-6-0, matt-nb6-plus-nbase, matt-nb6-plus-base, matt-nb6-plus
Changes since 1.12: +3 -1 lines
Diff to previous 1.12 (colored)

Pull up following revision(s) (requested by msaitoh in ticket #362):
sys/dev/pci/if_wm.c             1.228
        sys/dev/pci/if_wmreg.h          1.47
        sys/dev/pci/if_wmvar.h          1.13
        sys/dev/pci/pcidevs             1.1117
        sys/dev/pci/pcidevs.h           regen
        sys/dev/pci/pcidevs_data.h      regen
        share/man/man4/wm.4             1.22-1.25

                Add support for Intel I350 Ethernet.
                Update document.

Revision 1.12.8.1 / (download) - annotate - [select for diffs], Sat Jun 2 11:09:18 2012 UTC (11 years, 10 months ago) by mrg
Branch: jmcneill-usbmp
Changes since 1.12: +3 -1 lines
Diff to previous 1.12 (colored) next main 1.13 (colored)

sync to latest -current.

Revision 1.13 / (download) - annotate - [select for diffs], Fri May 25 23:37:38 2012 UTC (11 years, 10 months ago) by msaitoh
Branch: MAIN
CVS Tags: yamt-pagecache-base8, yamt-pagecache-base7, yamt-pagecache-base6, jmcneill-usbmp-base10
Branch point for: tls-maxphys
Changes since 1.12: +3 -1 lines
Diff to previous 1.12 (colored)

Add support Intel I350 Ethernet.

Revision 1.11.6.1 / (download) - annotate - [select for diffs], Mon Jun 6 09:08:16 2011 UTC (12 years, 10 months ago) by jruoho
Branch: jruoho-x86intr
Changes since 1.11: +4 -2 lines
Diff to previous 1.11 (colored) next main 1.12 (colored)

Sync with HEAD.

Revision 1.11.2.1 / (download) - annotate - [select for diffs], Tue May 31 03:04:41 2011 UTC (12 years, 10 months ago) by rmind
Branch: rmind-uvmplock
Changes since 1.11: +4 -2 lines
Diff to previous 1.11 (colored) next main 1.12 (colored)

sync with head

Revision 1.12 / (download) - annotate - [select for diffs], Fri May 20 01:51:36 2011 UTC (12 years, 11 months ago) by msaitoh
Branch: MAIN
CVS Tags: yamt-pagecache-base5, yamt-pagecache-base4, yamt-pagecache-base3, yamt-pagecache-base2, yamt-pagecache-base, rmind-uvmplock-nbase, rmind-uvmplock-base, netbsd-6-base, jmcneill-usbmp-pre-base2, jmcneill-usbmp-base9, jmcneill-usbmp-base8, jmcneill-usbmp-base7, jmcneill-usbmp-base6, jmcneill-usbmp-base5, jmcneill-usbmp-base4, jmcneill-usbmp-base3, jmcneill-usbmp-base2, jmcneill-usbmp-base, jmcneill-audiomp3-base, jmcneill-audiomp3, cherry-xenmp-base, cherry-xenmp
Branch point for: yamt-pagecache, netbsd-6, jmcneill-usbmp
Changes since 1.11: +4 -2 lines
Diff to previous 1.11 (colored)

Add PCH2 support.

Revision 1.2.46.4 / (download) - annotate - [select for diffs], Fri Nov 19 23:40:28 2010 UTC (13 years, 4 months ago) by riz
Branch: netbsd-5
CVS Tags: netbsd-5-2-RELEASE, netbsd-5-2-RC1, netbsd-5-2-3-RELEASE, netbsd-5-2-2-RELEASE, netbsd-5-2-1-RELEASE, netbsd-5-2, matt-nb5-pq3-base, matt-nb5-pq3
Changes since 1.2.46.3: +7 -1 lines
Diff to previous 1.2.46.3 (colored) to branchpoint 1.2 (colored)

Pull up revisions (requested by msaitoh in ticket #1358):
	sys/dev/pci/if_wm.c		1.196-1.199,1.202,1.205
	sys/dev/pci/if_wmvar.h		1.9
	sys/dev/pci/if_wmreg.h		1.36-1.39
	sys/dev/pci/pcireg.h		1.61-1.64
	sys/dev/pci/pcidevs		1.1023
	sys/dev/pci/pcidevs.h		regen
	sys/dev/pci/pcidevs_data.h	regen
	mii/igphy.c			1.21
	mii/igphyvar.h			1.1
	mii/inbmphyreg.h		1.2

- Count Receive error, CRC error, Alignment error, Symbol error, Sequence
  error, Carrier extension error and Receive length error into ierror.
  Fixes PR#30349 reported by UMEZAWA Takeshi.
- Add support for 82575, 82576 and 82580(ER).
  - Apply the patch for 82575 from Wolfgang Stukenbrock (PR#42422). We use
    only one RX ring and with the legacy mode.
  - Add support for 82576.
  - Partial support for 82580.
  - Partial support for the serdes systems.
- Add two workarounds for ICH8 with igp3.
  - Workaround for 82566 Kumeran PCS lock loss.
  - WOL from S5 stops working.
- (pcireg.h) Add PCIe config register definitions.
- Note that the changes to count Missed packet (rx fifo overflow) and Receive
  no buffers (rx ring full) into iqdrops in rev. 1.196 of if_wm.c is not
  pulled up.

Revision 1.8.2.1 / (download) - annotate - [select for diffs], Fri Apr 30 14:43:38 2010 UTC (13 years, 11 months ago) by uebayasi
Branch: uebayasi-xip
Changes since 1.8: +27 -15 lines
Diff to previous 1.8 (colored) next main 1.9 (colored)

Sync with HEAD.

Revision 1.11.4.2 / (download) - annotate - [select for diffs], Wed Apr 21 00:27:42 2010 UTC (13 years, 11 months ago) by matt
Branch: matt-nb5-mips64
CVS Tags: matt-nb5-mips64-premerge-20101231, matt-nb5-mips64-k15
Changes since 1.11.4.1: +137 -0 lines
Diff to previous 1.11.4.1 (colored) to branchpoint 1.11 (colored) next main 1.12 (colored)

sync to netbsd-5

Revision 1.2.40.1 / (download) - annotate - [select for diffs], Thu Mar 11 15:03:49 2010 UTC (14 years, 1 month ago) by yamt
Branch: yamt-nfs-mp
Changes since 1.2: +142 -4 lines
Diff to previous 1.2 (colored) next main 1.3 (colored)

sync with head

Revision 1.11.4.1, Sun Mar 7 09:05:19 2010 UTC (14 years, 1 month ago) by matt
Branch: matt-nb5-mips64
Changes since 1.11: +0 -148 lines
FILE REMOVED

file if_wmvar.h was added on branch matt-nb5-mips64 on 2010-04-21 00:27:42 +0000

Revision 1.11 / (download) - annotate - [select for diffs], Sun Mar 7 09:05:19 2010 UTC (14 years, 1 month ago) by msaitoh
Branch: MAIN
CVS Tags: yamt-nfs-mp-base9, yamt-nfs-mp-base11, yamt-nfs-mp-base10, uebayasi-xip-base4, uebayasi-xip-base3, uebayasi-xip-base2, uebayasi-xip-base1, matt-mips64-premerge-20101231, jruoho-x86intr-base, bouyer-quota2-nbase, bouyer-quota2-base, bouyer-quota2
Branch point for: rmind-uvmplock, matt-nb5-mips64, jruoho-x86intr
Changes since 1.10: +22 -17 lines
Diff to previous 1.10 (colored)

- Add code for WOL, ASF, IPMI and Intel AMT.
    - wm_enable_wakeup() is disabled by default. If you want to use WOL with
      the Magic Packet, define WM_WOL.
    - Add the following flags:
        WM_F_ASF_FIRMWARE_PRESENT
        WM_F_ARC_SUBSYSTEM_VALID
        WM_F_HAS_AMT
        WM_F_HAS_MANAGE
        WM_F_WOL
    - Add wm_suspend() and wm_resume(). Give/get the control to/from the
      firmware.
    - Need more work for PCH. See wm_enable_phy_wakeup().
- Enable wm_get_hw_control() for 82574 and 82583.
- Add Yet another workaround for ICH8.
    - Add wm_igp3_phy_powerdown_workaround_ich8lan() for power down problem
      on D3.

Revision 1.10 / (download) - annotate - [select for diffs], Thu Feb 25 15:07:06 2010 UTC (14 years, 1 month ago) by msaitoh
Branch: MAIN
Changes since 1.9: +2 -1 lines
Diff to previous 1.9 (colored)

 Merge if_wm.c rev. 1.162.4.13 and if_wmvar.h rev. 1.2.46.3 into maintrunk.
Increase the timeout value to prevent timeout on 80003. The values are taken
from Intel's e1000 driver. Tested by spz and me.

Revision 1.2.46.3 / (download) - annotate - [select for diffs], Thu Feb 25 10:59:58 2010 UTC (14 years, 1 month ago) by sborrill
Branch: netbsd-5
CVS Tags: netbsd-5-1-RELEASE, netbsd-5-1-RC4, netbsd-5-1-RC3, netbsd-5-1-RC2, netbsd-5-1-RC1, netbsd-5-1-5-RELEASE, netbsd-5-1-4-RELEASE, netbsd-5-1-3-RELEASE, netbsd-5-1-2-RELEASE, netbsd-5-1-1-RELEASE, netbsd-5-1
Changes since 1.2.46.2: +2 -1 lines
Diff to previous 1.2.46.2 (colored) to branchpoint 1.2 (colored)

Fix regression caused by pullup #1277 requested by msaitoh.

Revision 1.9 / (download) - annotate - [select for diffs], Tue Feb 16 15:17:17 2010 UTC (14 years, 2 months ago) by msaitoh
Branch: MAIN
Changes since 1.8: +7 -1 lines
Diff to previous 1.8 (colored)

Add support for 82575, 82576 and 82580(ER).
- Apply the patch for 82575 from Wolfgang Stukenbrock (PR#42422). We use
  only one RX ring and with the legacy mode.
- Add support for 82576.
- Partial support for 82580.
- Partial support for the serdes systems.

Revision 1.2.46.2 / (download) - annotate - [select for diffs], Wed Jan 27 22:27:42 2010 UTC (14 years, 2 months ago) by sborrill
Branch: netbsd-5
Changes since 1.2.46.1: +22 -1 lines
Diff to previous 1.2.46.1 (colored) to branchpoint 1.2 (colored)

Pull up the following revisions(s) (requested by msaitoh in ticket #1277):
sys/dev/pci/if_wm.c		1.184-1.192, 1.194
sys/dev/pci/if_wmreg.h		1.29-1.35
sys/dev/pci/if_wmvar.h		1.5-1.8
sys/dev/pci/pcidevs		1.1006,1.1009-1.1010, 1.1012-1.1013 via patch
sys/dev/pci/pcidevs.h		regen
sys/dev/pci/pcidevs_data.h	regen
sys/dev/mii/igphyreg.h		1.5
sys/dev/mii/inbmphyreg.h	1.1

- Add support for i82583V.
- Add some ICH9 and ICH10 devices.
- Add support for PCH.
- Fix the bug that ICH9 can't found a PHY. Fixes PR#42237
- Fix an incorrect test for WM_F_EEPROM_INVALID since rev. 1.183. Some old
  chips don't set EECD_EE_PRES.
- Fix a bug that both WM_F_EEPROM_SPI and WM_F_EEPROM_FLASH are set.
- Add a missing decrement for a timeout reported by Wolfgang Stukenbrock
  in PR#42422.
- PBA setting for i82574 is not 12K but 20K.
- Enable checking the management mode on 82574.
- Fix the length of the delay() in wm_gmii_reset(). It fixed the problem that
  sometimes the driver misunderstood PHYs in mii_attach(). It was reported
  by MATSUI Yoshihiro. We observed it on ICH9.
- Fix the checking of jumbo frame function
- Remove the extra macro definition for the offset 0x1a in EEPROM.
- Add missing break in wm_reset()...
- Fix the offset of WMREG_PBS...
- Make wm_reset() and wm_gmii_reset() close to e1000 driver.
  At least, this change make wm_attach() stable on ICH9.
- Reset GMII interface after wm_reset() in wm_init().
- Rework for assigning mii_{read,write}reg(). Use PCI product ID to identify
  the PHY.
- Add code about LPLU(Low Power Link Up) function. It seems that we have to
  do the same work for ICH9.
- Fixes the rx stall problem on 82578 by MANY workaround code. We need more
  work for 82577.

Revision 1.8 / (download) - annotate - [select for diffs], Thu Jan 14 18:56:02 2010 UTC (14 years, 3 months ago) by msaitoh
Branch: MAIN
CVS Tags: uebayasi-xip-base
Branch point for: uebayasi-xip
Changes since 1.7: +16 -1 lines
Diff to previous 1.7 (colored)

Fixes the rx stall problem on 82578 by MANY workaround code.
We need more work for 82577.

Revision 1.7 / (download) - annotate - [select for diffs], Mon Jan 11 12:29:28 2010 UTC (14 years, 3 months ago) by msaitoh
Branch: MAIN
Changes since 1.6: +2 -1 lines
Diff to previous 1.6 (colored)

 Add partial support for PCH. We have to do more work for PCH. Especially
I don't know what driver i82578 should be attached to. makephy? or atphy?
MII_OUI() says that the PHY is from Attansic (== Atheros). Intel's e1000
driver says that it's close to makphy...

 I can't link up at 1000BaseT yet...

Revision 1.6 / (download) - annotate - [select for diffs], Thu Jan 7 17:45:58 2010 UTC (14 years, 3 months ago) by msaitoh
Branch: MAIN
Changes since 1.5: +5 -1 lines
Diff to previous 1.5 (colored)

Make wm_reset() and wm_gmii_reset() close to e1000 driver.
At least, this change make wm_attach() stable on ICH9.

Revision 1.5 / (download) - annotate - [select for diffs], Tue Dec 29 16:01:21 2009 UTC (14 years, 3 months ago) by msaitoh
Branch: MAIN
Changes since 1.4: +2 -1 lines
Diff to previous 1.4 (colored)

- Fix an incorrect test for WM_F_EEPROM_INVALID since rev. 1.183. Some old
  chips don't set EECD_EE_PRES.
- Fix a bug that both WM_F_EEPROM_SPI and WM_F_EEPROM_FLASH are set.
- Add a missing decrement for a timeout reported by Wolfgang Stukenbrock
  in PR#42422.
- Add support for i82583V.
- PBA setting for i82574 is not 12K but 20K.
- Enable checking the management mode on 82574.

Revision 1.2.46.1 / (download) - annotate - [select for diffs], Wed Dec 23 10:37:37 2009 UTC (14 years, 3 months ago) by sborrill
Branch: netbsd-5
Changes since 1.2: +109 -4 lines
Diff to previous 1.2 (colored)

Pull up the following revisions(s) (requested by msaitoh in ticket #1203):
	sys/dev/pci/if_wm.c:		1.176-1.179, 1.181-1.183
	sys/dev/pci/if_wmreg.h:		1.28
	sys/dev/pci/if_wmvar.h:		1.1-1.4
	sys/dev/mii/igphy.c:		1.18-1.20 via patch

Many bugfixes:
- Some fixes for i80003 and ICH{8,9,10} from e1000 driver and document:
  - Add setting for KABGTXD register for ICH{8,9,10}.
  - ICH9 and ICH10 has no FCAL, FCAH and FCT like ICH8.
  - Add special setting for FCTTV and TCTL_EXT register for i80003
  - The special setting for TIPG is only for i80003.
  - Some of kumeran settings are only for i80003's bugs.
  - Add some ICH10 fixes.
  - Fix the bug that another lock mechanism is used to access Kumeran
    registers on i80003 and ICHs.
  - Fix yet another i80003 ONLY workaround. The code to modifing TIPG
    register is only for i80003.
- Set the Re-Transmit on Late Collision(RTLC) flag for all devices.
- Fix a typo in a printf message.
- If the difference bettween last flag and new flag is only IFF_PROMISC
  or IFF_ALLMULTI, set multicast filter only to prevent link down.
  Tested by Mark Davies and me. Fixes PR#29126 for wm.
- Cleanup interrupt establish error messages. Do not mix
  aprint_error/aprint_normal/printf calls for a single line.
- Fix igphy's 82566 support.
  - Patch for the DSP code is only for 8254[17] and we have to apply
    the different patches between rev. 1 and rev. 2.
  - The workaround for analog fuse is only for 82547 rev. 1.
  - The workaround for smartspeed is only for 8254[17]
- Sync with Intel's original em driver:
  - Check PCI-X mode as e1000 driver.
  - Add dspcode for igp3 and use it when the EEPROM isn't available.
  - Add some delays.
  - Stop the PHY transmitter before patching the DSP code and
    restart it after writing.
  - Save and restore register 0x2f5b.

Revision 1.4 / (download) - annotate - [select for diffs], Wed Dec 16 14:37:26 2009 UTC (14 years, 4 months ago) by msaitoh
Branch: MAIN
Changes since 1.3: +17 -1 lines
Diff to previous 1.3 (colored)

Sync with Intel's original em driver:
- Add dspcode for igp3 and use it when the EEPROM isn't available.
- Add some delays.
- Stop the PHY transmitter before patching the DSP code and restart it after wrote.
- Save and restore register 0x2f5b.

Revision 1.3 / (download) - annotate - [select for diffs], Wed Dec 16 04:50:36 2009 UTC (14 years, 4 months ago) by msaitoh
Branch: MAIN
Changes since 1.2: +93 -4 lines
Diff to previous 1.2 (colored)

Re-enable igphy's 82566 support.
 - Patch for the DSP code is only for 8254[17] and we have to apply the
   different patches between rev. 1 and rev. 2.
 - The workaround for analog fuse is only for 82547 rev. 1.
 - The workaround for smartspeed is only for 8254[17]

see http://mail-index.netbsd.org/tech-net/2009/08/05/msg001546.html

Revision 1.1.2.3, Wed Mar 1 09:28:21 2006 UTC (18 years, 1 month ago) by yamt
Branch: yamt-uio_vmspace
Changes since 1.1.2.2: +0 -10 lines
FILE REMOVED

sync with head.

Revision 1.2, Wed Feb 22 00:17:43 2006 UTC (18 years, 1 month ago) by gavan
Branch: MAIN
CVS Tags: yamt-x86pmap-base4, yamt-x86pmap-base3, yamt-x86pmap-base2, yamt-x86pmap-base, yamt-x86pmap, yamt-uio_vmspace-base5, yamt-splraiseipl-base5, yamt-splraiseipl-base4, yamt-splraiseipl-base3, yamt-splraiseipl-base2, yamt-splraiseipl-base, yamt-splraiseipl, yamt-pf42-base4, yamt-pf42-base3, yamt-pf42-base2, yamt-pf42-base, yamt-pf42, yamt-pdpolicy-base8, yamt-pdpolicy-base7, yamt-pdpolicy-base6, yamt-pdpolicy-base5, yamt-pdpolicy-base4, yamt-pdpolicy-base3, yamt-pdpolicy-base2, yamt-pdpolicy-base, yamt-pdpolicy, yamt-nfs-mp-base8, yamt-nfs-mp-base7, yamt-nfs-mp-base6, yamt-nfs-mp-base5, yamt-nfs-mp-base4, yamt-nfs-mp-base3, yamt-nfs-mp-base2, yamt-nfs-mp-base, yamt-lazymbuf-base15, yamt-lazymbuf-base14, yamt-kmem-base3, yamt-kmem-base2, yamt-kmem-base, yamt-kmem, yamt-idlelwp-base8, yamt-idlelwp, vmlocking2-base3, vmlocking2-base2, vmlocking2-base1, vmlocking2, vmlocking-nbase, vmlocking-base, vmlocking, simonb-wapbl-nbase, simonb-wapbl-base, simonb-wapbl, simonb-timecounters-base, rpaulo-netinet-merge-pcb-base, reinoud-bufcleanup-nbase, reinoud-bufcleanup-base, post-newlock2-merge, newlock2-nbase, newlock2-base, newlock2, netbsd-5-base, netbsd-5-0-RELEASE, netbsd-5-0-RC4, netbsd-5-0-RC3, netbsd-5-0-RC2, netbsd-5-0-RC1, netbsd-5-0-2-RELEASE, netbsd-5-0-1-RELEASE, netbsd-5-0, mjf-ufs-trans-base, mjf-devfs2-base, mjf-devfs2, mjf-devfs-base, mjf-devfs, keiichi-mipv6-nbase, keiichi-mipv6-base, keiichi-mipv6, jymxensuspend-base, jym-xensuspend-nbase, jym-xensuspend-base, jym-xensuspend, jmcneill-pm-base, jmcneill-pm, jmcneill-base, hpcarm-cleanup-nbase, hpcarm-cleanup-base, hpcarm-cleanup, haad-nbase2, haad-dm-base2, haad-dm-base1, haad-dm-base, haad-dm, gdamore-uart-base, gdamore-uart, elad-kernelauth-nbase, cube-autoconf-base, cube-autoconf, bouyer-xeni386-nbase, bouyer-xeni386-merge1, bouyer-xeni386-base, bouyer-xeni386, bouyer-xenamd64-base2, bouyer-xenamd64-base, bouyer-xenamd64, ad-socklock-base1, ad-audiomp2-base, ad-audiomp2, ad-audiomp-base, ad-audiomp
Branch point for: yamt-nfs-mp, netbsd-5
Changes since 1.1: +1 -1 lines
FILE REMOVED

Convert MD hook to device property reads.

Device properties, if present, take precedence over EEPROM values.

Revision 1.1.2.2 / (download) - annotate - [select for diffs], Sat Feb 18 15:39:08 2006 UTC (18 years, 2 months ago) by yamt
Branch: yamt-uio_vmspace
Changes since 1.1.2.1: +10 -0 lines
Diff to previous 1.1.2.1 (colored)

sync with head.

Revision 1.1.2.1, Thu Feb 16 00:02:00 2006 UTC (18 years, 2 months ago) by yamt
Branch: yamt-uio_vmspace
Changes since 1.1: +0 -10 lines
FILE REMOVED

file if_wmvar.h was added on branch yamt-uio_vmspace on 2006-02-18 15:39:08 +0000

Revision 1.1 / (download) - annotate - [select for diffs], Thu Feb 16 00:02:00 2006 UTC (18 years, 2 months ago) by gavan
Branch: MAIN
Branch point for: yamt-uio_vmspace

Compute the EEPROM checksum to determine the presence of valid EEPROM data.
If EEPROM data is invalid, allow a MD hook to supply EEPROM data instead.

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>