diff options
author | Mirko Lindner <mlindner@marvell.com> | 2008-01-10 05:12:44 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-10 05:12:44 -0500 |
commit | b0de8e402dc5d3ee04f4d0f669ae492a3e569933 (patch) | |
tree | e692537e3a834e1ed415beda87be1ce0d492827c /drivers/net/niu.h | |
parent | fd0b45dfd1858c6b49d06355a460bcf36d654c06 (diff) |
[NIU]: Support for Marvell PHY
From: Mirko Lindner <mlindner@marvell.com>
This patch makes necessary changes in the Neptune driver to support
the new Marvell PHY. It also adds support for the LED blinking
on Neptune cards with Marvell PHY. All registers are using defines
in the niu.h header file as is already done for the BCM8704 registers.
[ Coding style, etc. cleanups -DaveM ]
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/niu.h')
-rw-r--r-- | drivers/net/niu.h | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/drivers/net/niu.h b/drivers/net/niu.h index 10e3f111b6d5..0e8626adc573 100644 --- a/drivers/net/niu.h +++ b/drivers/net/niu.h | |||
@@ -2538,6 +2538,39 @@ struct fcram_hash_ipv6 { | |||
2538 | #define NIU_PHY_ID_MASK 0xfffff0f0 | 2538 | #define NIU_PHY_ID_MASK 0xfffff0f0 |
2539 | #define NIU_PHY_ID_BCM8704 0x00206030 | 2539 | #define NIU_PHY_ID_BCM8704 0x00206030 |
2540 | #define NIU_PHY_ID_BCM5464R 0x002060b0 | 2540 | #define NIU_PHY_ID_BCM5464R 0x002060b0 |
2541 | #define NIU_PHY_ID_MRVL88X2011 0x01410020 | ||
2542 | |||
2543 | /* MRVL88X2011 register addresses */ | ||
2544 | #define MRVL88X2011_USER_DEV1_ADDR 1 | ||
2545 | #define MRVL88X2011_USER_DEV2_ADDR 2 | ||
2546 | #define MRVL88X2011_USER_DEV3_ADDR 3 | ||
2547 | #define MRVL88X2011_USER_DEV4_ADDR 4 | ||
2548 | #define MRVL88X2011_PMA_PMD_CTL_1 0x0000 | ||
2549 | #define MRVL88X2011_PMA_PMD_STATUS_1 0x0001 | ||
2550 | #define MRVL88X2011_10G_PMD_STATUS_2 0x0008 | ||
2551 | #define MRVL88X2011_10G_PMD_TX_DIS 0x0009 | ||
2552 | #define MRVL88X2011_10G_XGXS_LANE_STAT 0x0018 | ||
2553 | #define MRVL88X2011_GENERAL_CTL 0x8300 | ||
2554 | #define MRVL88X2011_LED_BLINK_CTL 0x8303 | ||
2555 | #define MRVL88X2011_LED_8_TO_11_CTL 0x8306 | ||
2556 | |||
2557 | /* MRVL88X2011 register control */ | ||
2558 | #define MRVL88X2011_ENA_XFPREFCLK 0x0001 | ||
2559 | #define MRVL88X2011_ENA_PMDTX 0x0000 | ||
2560 | #define MRVL88X2011_LOOPBACK 0x1 | ||
2561 | #define MRVL88X2011_LED_ACT 0x1 | ||
2562 | #define MRVL88X2011_LNK_STATUS_OK 0x4 | ||
2563 | #define MRVL88X2011_LED_BLKRATE_MASK 0x70 | ||
2564 | #define MRVL88X2011_LED_BLKRATE_034MS 0x0 | ||
2565 | #define MRVL88X2011_LED_BLKRATE_067MS 0x1 | ||
2566 | #define MRVL88X2011_LED_BLKRATE_134MS 0x2 | ||
2567 | #define MRVL88X2011_LED_BLKRATE_269MS 0x3 | ||
2568 | #define MRVL88X2011_LED_BLKRATE_538MS 0x4 | ||
2569 | #define MRVL88X2011_LED_CTL_OFF 0x0 | ||
2570 | #define MRVL88X2011_LED_CTL_PCS_ACT 0x5 | ||
2571 | #define MRVL88X2011_LED_CTL_MASK 0x7 | ||
2572 | #define MRVL88X2011_LED(n,v) ((v)<<((n)*4)) | ||
2573 | #define MRVL88X2011_LED_STAT(n,v) ((v)>>((n)*4)) | ||
2541 | 2574 | ||
2542 | #define BCM8704_PMA_PMD_DEV_ADDR 1 | 2575 | #define BCM8704_PMA_PMD_DEV_ADDR 1 |
2543 | #define BCM8704_PCS_DEV_ADDR 2 | 2576 | #define BCM8704_PCS_DEV_ADDR 2 |