diff options
author | Dhananjay Phadke <dhananjay@netxen.com> | 2009-08-23 04:35:13 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-08-23 22:00:29 -0400 |
commit | 7d6fd5e7e97a2188d56441e4e96494c21c5994a7 (patch) | |
tree | 23cb119c2d2a094363f2dd5cc53e9443e87f5ae3 /drivers/net/netxen/netxen_nic_hdr.h | |
parent | 22b5794b5d58ea81e91d68d00e49357b66d5a559 (diff) |
netxen: remove netxen_nic_phan_reg.h
Consolidate register definitions in netxen_nic_hdr.h
Signed-off-by: Dhananjay Phadke <dhananjay@netxen.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/netxen/netxen_nic_hdr.h')
-rw-r--r-- | drivers/net/netxen/netxen_nic_hdr.h | 85 |
1 files changed, 84 insertions, 1 deletions
diff --git a/drivers/net/netxen/netxen_nic_hdr.h b/drivers/net/netxen/netxen_nic_hdr.h index a7328584a21a..c4a4a8ba14f4 100644 --- a/drivers/net/netxen/netxen_nic_hdr.h +++ b/drivers/net/netxen/netxen_nic_hdr.h | |||
@@ -723,9 +723,92 @@ enum { | |||
723 | #define NETXEN_FW_VERSION_MINOR (NETXEN_CAM_RAM(0x154)) | 723 | #define NETXEN_FW_VERSION_MINOR (NETXEN_CAM_RAM(0x154)) |
724 | #define NETXEN_FW_VERSION_SUB (NETXEN_CAM_RAM(0x158)) | 724 | #define NETXEN_FW_VERSION_SUB (NETXEN_CAM_RAM(0x158)) |
725 | #define NETXEN_ROM_LOCK_ID (NETXEN_CAM_RAM(0x100)) | 725 | #define NETXEN_ROM_LOCK_ID (NETXEN_CAM_RAM(0x100)) |
726 | #define NETXEN_PHY_LOCK_ID (NETXEN_CAM_RAM(0x120)) | ||
726 | #define NETXEN_CRB_WIN_LOCK_ID (NETXEN_CAM_RAM(0x124)) | 727 | #define NETXEN_CRB_WIN_LOCK_ID (NETXEN_CAM_RAM(0x124)) |
727 | 728 | ||
728 | #define NETXEN_PHY_LOCK_ID (NETXEN_CAM_RAM(0x120)) | 729 | #define NIC_CRB_BASE (NETXEN_CAM_RAM(0x200)) |
730 | #define NIC_CRB_BASE_2 (NETXEN_CAM_RAM(0x700)) | ||
731 | #define NETXEN_NIC_REG(X) (NIC_CRB_BASE+(X)) | ||
732 | #define NETXEN_NIC_REG_2(X) (NIC_CRB_BASE_2+(X)) | ||
733 | |||
734 | #define NX_CDRP_CRB_OFFSET (NETXEN_NIC_REG(0x18)) | ||
735 | #define NX_ARG1_CRB_OFFSET (NETXEN_NIC_REG(0x1c)) | ||
736 | #define NX_ARG2_CRB_OFFSET (NETXEN_NIC_REG(0x20)) | ||
737 | #define NX_ARG3_CRB_OFFSET (NETXEN_NIC_REG(0x24)) | ||
738 | #define NX_SIGN_CRB_OFFSET (NETXEN_NIC_REG(0x28)) | ||
739 | |||
740 | #define CRB_HOST_DUMMY_BUF_ADDR_HI (NETXEN_NIC_REG(0x3c)) | ||
741 | #define CRB_HOST_DUMMY_BUF_ADDR_LO (NETXEN_NIC_REG(0x40)) | ||
742 | |||
743 | #define CRB_CMDPEG_STATE (NETXEN_NIC_REG(0x50)) | ||
744 | #define CRB_RCVPEG_STATE (NETXEN_NIC_REG(0x13c)) | ||
745 | |||
746 | #define CRB_XG_STATE (NETXEN_NIC_REG(0x94)) | ||
747 | #define CRB_XG_STATE_P3 (NETXEN_NIC_REG(0x98)) | ||
748 | #define CRB_PF_LINK_SPEED_1 (NETXEN_NIC_REG(0xe8)) | ||
749 | #define CRB_PF_LINK_SPEED_2 (NETXEN_NIC_REG(0xec)) | ||
750 | |||
751 | #define CRB_MPORT_MODE (NETXEN_NIC_REG(0xc4)) | ||
752 | #define CRB_DMA_SHIFT (NETXEN_NIC_REG(0xcc)) | ||
753 | #define CRB_INT_VECTOR (NETXEN_NIC_REG(0xd4)) | ||
754 | |||
755 | #define CRB_CMD_PRODUCER_OFFSET (NETXEN_NIC_REG(0x08)) | ||
756 | #define CRB_CMD_CONSUMER_OFFSET (NETXEN_NIC_REG(0x0c)) | ||
757 | #define CRB_CMD_PRODUCER_OFFSET_1 (NETXEN_NIC_REG(0x1ac)) | ||
758 | #define CRB_CMD_CONSUMER_OFFSET_1 (NETXEN_NIC_REG(0x1b0)) | ||
759 | #define CRB_CMD_PRODUCER_OFFSET_2 (NETXEN_NIC_REG(0x1b8)) | ||
760 | #define CRB_CMD_CONSUMER_OFFSET_2 (NETXEN_NIC_REG(0x1bc)) | ||
761 | #define CRB_CMD_PRODUCER_OFFSET_3 (NETXEN_NIC_REG(0x1d0)) | ||
762 | #define CRB_CMD_CONSUMER_OFFSET_3 (NETXEN_NIC_REG(0x1d4)) | ||
763 | #define CRB_TEMP_STATE (NETXEN_NIC_REG(0x1b4)) | ||
764 | |||
765 | #define CRB_V2P_0 (NETXEN_NIC_REG(0x290)) | ||
766 | #define CRB_V2P(port) (CRB_V2P_0+((port)*4)) | ||
767 | #define CRB_DRIVER_VERSION (NETXEN_NIC_REG(0x2a0)) | ||
768 | |||
769 | #define CRB_SW_INT_MASK_0 (NETXEN_NIC_REG(0x1d8)) | ||
770 | #define CRB_SW_INT_MASK_1 (NETXEN_NIC_REG(0x1e0)) | ||
771 | #define CRB_SW_INT_MASK_2 (NETXEN_NIC_REG(0x1e4)) | ||
772 | #define CRB_SW_INT_MASK_3 (NETXEN_NIC_REG(0x1e8)) | ||
773 | |||
774 | #define CRB_FW_CAPABILITIES_1 (NETXEN_CAM_RAM(0x128)) | ||
775 | #define CRB_MAC_BLOCK_START (NETXEN_CAM_RAM(0x1c0)) | ||
776 | |||
777 | /* | ||
778 | * capabilities register, can be used to selectively enable/disable features | ||
779 | * for backward compability | ||
780 | */ | ||
781 | #define CRB_NIC_CAPABILITIES_HOST NETXEN_NIC_REG(0x1a8) | ||
782 | #define CRB_NIC_CAPABILITIES_FW NETXEN_NIC_REG(0x1dc) | ||
783 | #define CRB_NIC_MSI_MODE_HOST NETXEN_NIC_REG(0x270) | ||
784 | #define CRB_NIC_MSI_MODE_FW NETXEN_NIC_REG(0x274) | ||
785 | |||
786 | #define INTR_SCHEME_PERPORT 0x1 | ||
787 | #define MSI_MODE_MULTIFUNC 0x1 | ||
788 | |||
789 | /* used for ethtool tests */ | ||
790 | #define CRB_SCRATCHPAD_TEST NETXEN_NIC_REG(0x280) | ||
791 | |||
792 | /* | ||
793 | * CrbPortPhanCntrHi/Lo is used to pass the address of HostPhantomIndex address | ||
794 | * which can be read by the Phantom host to get producer/consumer indexes from | ||
795 | * Phantom/Casper. If it is not HOST_SHARED_MEMORY, then the following | ||
796 | * registers will be used for the addresses of the ring's shared memory | ||
797 | * on the Phantom. | ||
798 | */ | ||
799 | |||
800 | #define nx_get_temp_val(x) ((x) >> 16) | ||
801 | #define nx_get_temp_state(x) ((x) & 0xffff) | ||
802 | #define nx_encode_temp(val, state) (((val) << 16) | (state)) | ||
803 | |||
804 | /* | ||
805 | * Temperature control. | ||
806 | */ | ||
807 | enum { | ||
808 | NX_TEMP_NORMAL = 0x1, /* Normal operating range */ | ||
809 | NX_TEMP_WARN, /* Sound alert, temperature getting high */ | ||
810 | NX_TEMP_PANIC /* Fatal error, hardware has shut down. */ | ||
811 | }; | ||
729 | 812 | ||
730 | /* Lock IDs for PHY lock */ | 813 | /* Lock IDs for PHY lock */ |
731 | #define PHY_LOCK_DRIVER 0x44524956 | 814 | #define PHY_LOCK_DRIVER 0x44524956 |