e1000_82571.h revision 287492
1213904Sandreast/******************************************************************************
2213904Sandreast
3213904Sandreast  Copyright (c) 2001-2015, Intel Corporation
4213904Sandreast  All rights reserved.
5213904Sandreast
6213904Sandreast  Redistribution and use in source and binary forms, with or without
7213904Sandreast  modification, are permitted provided that the following conditions are met:
8213904Sandreast
9213904Sandreast   1. Redistributions of source code must retain the above copyright notice,
10213904Sandreast      this list of conditions and the following disclaimer.
11213904Sandreast
12213904Sandreast   2. Redistributions in binary form must reproduce the above copyright
13213904Sandreast      notice, this list of conditions and the following disclaimer in the
14213904Sandreast      documentation and/or other materials provided with the distribution.
15213904Sandreast
16213904Sandreast   3. Neither the name of the Intel Corporation nor the names of its
17213904Sandreast      contributors may be used to endorse or promote products derived from
18213904Sandreast      this software without specific prior written permission.
19213904Sandreast
20213904Sandreast  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21213904Sandreast  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22213904Sandreast  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23213904Sandreast  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
24213904Sandreast  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25213904Sandreast  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26213904Sandreast  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27213904Sandreast  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28213904Sandreast  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29213904Sandreast  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
30213904Sandreast  POSSIBILITY OF SUCH DAMAGE.
31213904Sandreast
32213904Sandreast******************************************************************************/
33213904Sandreast/*$FreeBSD: head/sys/dev/e1000/e1000_82571.h 287492 2015-09-05 21:12:19Z sbruno $*/
34213904Sandreast
35213904Sandreast#ifndef _E1000_82571_H_
36213904Sandreast#define _E1000_82571_H_
37213904Sandreast
38213904Sandreast#define ID_LED_RESERVED_F746	0xF746
39213904Sandreast#define ID_LED_DEFAULT_82573	((ID_LED_DEF1_DEF2 << 12) | \
40213904Sandreast				 (ID_LED_OFF1_ON2  <<  8) | \
41213904Sandreast				 (ID_LED_DEF1_DEF2 <<  4) | \
42213904Sandreast				 (ID_LED_DEF1_DEF2))
43213904Sandreast
44213904Sandreast#define E1000_GCR_L1_ACT_WITHOUT_L0S_RX	0x08000000
45213904Sandreast#define AN_RETRY_COUNT		5 /* Autoneg Retry Count value */
46213904Sandreast
47213904Sandreast/* Intr Throttling - RW */
48213904Sandreast#define E1000_EITR_82574(_n)	(0x000E8 + (0x4 * (_n)))
49213904Sandreast
50213904Sandreast#define E1000_EIAC_82574	0x000DC /* Ext. Interrupt Auto Clear - RW */
51213904Sandreast#define E1000_EIAC_MASK_82574	0x01F00000
52222458Snwhitehorn
53213904Sandreast#define E1000_NVM_INIT_CTRL2_MNGM 0x6000 /* Manageability Operation Mode mask */
54213904Sandreast
55213904Sandreast#define E1000_RXCFGL    0x0B634 /* TimeSync Rx EtherType & Msg Type Reg - RW */
56213904Sandreast
57213904Sandreast#define E1000_BASE1000T_STATUS		10
58213904Sandreast#define E1000_IDLE_ERROR_COUNT_MASK	0xFF
59213904Sandreast#define E1000_RECEIVE_ERROR_COUNTER	21
60213904Sandreast#define E1000_RECEIVE_ERROR_MAX		0xFFFF
61213904Sandreastbool e1000_check_phy_82574(struct e1000_hw *hw);
62213904Sandreastbool e1000_get_laa_state_82571(struct e1000_hw *hw);
63213904Sandreastvoid e1000_set_laa_state_82571(struct e1000_hw *hw, bool state);
64213904Sandreast
65213904Sandreast#endif
66217286Sandreast