nic_phan_reg.h revision 9a5557fdd04be37785607871e8d4189e39490129
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2008 NetXen, Inc. All rights reserved.
* Use is subject to license terms.
*/
#ifndef NIC_PHAN_REG_H
#define NIC_PHAN_REG_H
#define UNM_NIC_REG(X) (NIC_CRB_BASE+(X))
#define UNM_NIC_REG_2(X) (NIC_CRB_BASE_2+(X))
/* C0 EPG BUG */
/* interrupt coalescing */
/* XG Link status */
/* XG PF Link status */
/* Debug -performance */
/* Multiport Mode */
/* 12 registers to store MAC addresses for 8 PCI functions */
#define CRB_SW_INT_MASK_OFFSET_0 0x1d8
#define CRB_SW_INT_MASK_OFFSET_1 0x1e0
#define CRB_SW_INT_MASK_OFFSET_2 0x1e4
#define CRB_SW_INT_MASK_OFFSET_3 0x1e8
#define CRB_SW_INT_MASK_OFFSET_4 0x450
#define CRB_SW_INT_MASK_OFFSET_5 0x454
#define CRB_SW_INT_MASK_OFFSET_6 0x458
#define CRB_SW_INT_MASK_OFFSET_7 0x45c
/*
* for backward compability
*/
#define INTR_SCHEME_PERPORT 0x1
#define MSI_MODE_MULTIFUNC 0x1
/*
* Driver must set the version number register as follows:
* (major << 16) | (minor << 8) | (subminor)
*/
/* last -> 0x2a0 */
/* Upper 16 bits of CRB_TEMP_STATE:temperature value. Lower 16 bits: state */
#define nx_get_temp_val(x) ((x) >> 16)
#define nx_get_temp_state(x) ((x) & 0xffff)
0xffffffff))
/*
* Temperature control.
*/
enum {
NX_TEMP_WARN, /* Sound alert, temperature getting high */
NX_TEMP_PANIC /* Fatal error, hardware has shut down. */
};
#endif /* NIC_PHAN_REG_H */