Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
eb7a4190
Commit
eb7a4190
authored
Apr 26, 2004
by
David S. Miller
Browse files
Options
Browse Files
Download
Plain Diff
Merge nuts.davemloft.net:/disk1/BK/tg3work-2.6
into nuts.davemloft.net:/disk1/BK/tg3-2.6
parents
3dcad070
c71413f8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
21 deletions
+24
-21
drivers/net/tg3.c
drivers/net/tg3.c
+23
-21
drivers/net/tg3.h
drivers/net/tg3.h
+1
-0
No files found.
drivers/net/tg3.c
View file @
eb7a4190
...
...
@@ -700,14 +700,29 @@ static int tg3_phy_reset(struct tg3 *tp)
tg3_writephy
(
tp
,
0x1c
,
0x8d68
);
tg3_writephy
(
tp
,
0x1c
,
0x8d68
);
}
if
(
tp
->
tg3_flags2
&
TG3_FLG2_PHY_BER_BUG
)
{
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
0x0c00
);
tg3_writephy
(
tp
,
MII_TG3_DSP_ADDRESS
,
0x000a
);
tg3_writephy
(
tp
,
MII_TG3_DSP_RW_PORT
,
0x310b
);
tg3_writephy
(
tp
,
MII_TG3_DSP_ADDRESS
,
0x201f
);
tg3_writephy
(
tp
,
MII_TG3_DSP_RW_PORT
,
0x9506
);
tg3_writephy
(
tp
,
MII_TG3_DSP_ADDRESS
,
0x401f
);
tg3_writephy
(
tp
,
MII_TG3_DSP_RW_PORT
,
0x14e2
);
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
0x0400
);
}
/* Set Extended packet length bit (bit 14) on all chips that */
/* support jumbo frames */
if
((
tp
->
phy_id
&
PHY_ID_MASK
)
==
PHY_ID_BCM5401
||
(
tp
->
phy_id
&
PHY_ID_MASK
)
==
PHY_ID_BCM5411
)
{
if
((
tp
->
phy_id
&
PHY_ID_MASK
)
==
PHY_ID_BCM5401
)
{
/* Cannot do read-modify-write on 5401 */
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
0x4c20
);
}
else
if
(
GET_ASIC_REV
(
tp
->
pci_chip_rev_id
)
!=
ASIC_REV_5705
)
{
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
0x4400
);
u32
phy_reg
;
/* Set bit 14 with read-modify-write to preserve other bits */
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
0x0007
);
tg3_readphy
(
tp
,
MII_TG3_AUX_CTRL
,
&
phy_reg
);
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
phy_reg
|
0x4000
);
}
tg3_phy_set_wirespeed
(
tp
);
return
0
;
...
...
@@ -1060,8 +1075,6 @@ static int tg3_phy_copper_begin(struct tg3 *tp)
u32
new_adv
;
int
i
;
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
0x0400
);
if
(
tp
->
link_config
.
phy_is_low_power
)
{
/* Entering low power mode. Disable gigabit and
* 100baseT advertisements.
...
...
@@ -3910,7 +3923,7 @@ static int tg3_load_5701_a0_firmware_fix(struct tg3 *tp)
#define TG3_TSO_FW_START_ADDR 0x08000000
#define TG3_TSO_FW_TEXT_ADDR 0x08000000
#define TG3_TSO_FW_TEXT_LEN 0x1a90
#define TG3_TSO_FW_RODATA_ADDR 0x08001a90
0
#define TG3_TSO_FW_RODATA_ADDR 0x08001a90
#define TG3_TSO_FW_RODATA_LEN 0x60
#define TG3_TSO_FW_DATA_ADDR 0x08001b20
#define TG3_TSO_FW_DATA_LEN 0x20
...
...
@@ -6605,21 +6618,6 @@ static int __devinit tg3_phy_probe(struct tg3 *tp)
return
err
;
}
if
(
GET_ASIC_REV
(
tp
->
pci_chip_rev_id
)
==
ASIC_REV_5703
)
{
tg3_writephy
(
tp
,
MII_TG3_AUX_CTRL
,
0x4c00
);
tg3_writephy
(
tp
,
MII_TG3_DSP_ADDRESS
,
0x201f
);
tg3_writephy
(
tp
,
MII_TG3_DSP_RW_PORT
,
0x2aaa
);
}
if
((
GET_ASIC_REV
(
tp
->
pci_chip_rev_id
)
==
ASIC_REV_5704
)
&&
(
tp
->
pci_chip_rev_id
==
CHIPREV_ID_5704_A0
))
{
tg3_writephy
(
tp
,
0x1c
,
0x8d68
);
tg3_writephy
(
tp
,
0x1c
,
0x8d68
);
}
/* Enable Ethernet@WireSpeed */
tg3_phy_set_wirespeed
(
tp
);
if
(
!
err
&&
((
tp
->
phy_id
&
PHY_ID_MASK
)
==
PHY_ID_BCM5401
))
{
err
=
tg3_init_5401phy_dsp
(
tp
);
}
...
...
@@ -6934,6 +6932,10 @@ static int __devinit tg3_get_invariants(struct tg3 *tp)
if
(
tp
->
pci_chip_rev_id
==
CHIPREV_ID_5704_A0
)
tp
->
tg3_flags2
|=
TG3_FLG2_PHY_5704_A0_BUG
;
/* Note: 5750 also needs this flag set to improve bit error rate. */
if
(
GET_ASIC_REV
(
tp
->
pci_chip_rev_id
)
==
ASIC_REV_5705
)
tp
->
tg3_flags2
|=
TG3_FLG2_PHY_BER_BUG
;
/* Only 5701 and later support tagged irq status mode.
* Also, 5788 chips cannot use tagged irq status.
*
...
...
drivers/net/tg3.h
View file @
eb7a4190
...
...
@@ -1929,6 +1929,7 @@ struct tg3 {
#define TG3_FLG2_TSO_CAPABLE 0x00000020
#define TG3_FLG2_PHY_ADC_BUG 0x00000040
#define TG3_FLG2_PHY_5704_A0_BUG 0x00000080
#define TG3_FLG2_PHY_BER_BUG 0x00000100
u32
split_mode_max_reqs
;
#define SPLIT_MODE_5704_MAX_REQ 3
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment