Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 111384
b: refs/heads/master
c: 458a9f6
h: refs/heads/master
v: v3
  • Loading branch information
Francois Romieu committed Aug 17, 2008
1 parent 388cd97 commit 2952118
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: ccdffb9a88b2907b159538d7bfd6256621db4f84
refs/heads/master: 458a9f617adfb2fc5f38e7673339115c4ba3290f
15 changes: 10 additions & 5 deletions trunk/drivers/net/r8169.c
Original file line number Diff line number Diff line change
Expand Up @@ -2054,12 +2054,20 @@ static void rtl_hw_start_8169(struct net_device *dev)
RTL_W16(IntrMask, tp->intr_event);
}

static void rtl_tx_performance_tweak(struct pci_dev *pdev, u8 force)
{
u8 ctl;

pci_read_config_byte(pdev, 0x69, &ctl);
ctl = (ctl & ~0x70) | force;
pci_write_config_byte(pdev, 0x69, ctl);
}

static void rtl_hw_start_8168(struct net_device *dev)
{
struct rtl8169_private *tp = netdev_priv(dev);
void __iomem *ioaddr = tp->mmio_addr;
struct pci_dev *pdev = tp->pci_dev;
u8 ctl;

RTL_W8(Cfg9346, Cfg9346_Unlock);

Expand All @@ -2073,10 +2081,7 @@ static void rtl_hw_start_8168(struct net_device *dev)

RTL_W16(CPlusCmd, tp->cp_cmd);

/* Tx performance tweak. */
pci_read_config_byte(pdev, 0x69, &ctl);
ctl = (ctl & ~0x70) | 0x50;
pci_write_config_byte(pdev, 0x69, ctl);
rtl_tx_performance_tweak(pdev, 0x50);

RTL_W16(IntrMitigate, 0x5151);

Expand Down

0 comments on commit 2952118

Please sign in to comment.