Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 20471
b: refs/heads/master
c: 2ae5b30
h: refs/heads/master
i:
  20469: 911d9cb
  20467: b33a06f
  20463: 0dbc41a
v: v3
  • Loading branch information
Dan Williams authored and Jeff Garzik committed Feb 17, 2006
1 parent 643bdfb commit f343fd5
Show file tree
Hide file tree
Showing 16 changed files with 192 additions and 202 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: 00ab2f3df33dd3e649904765767dd87ffbcb3acf
refs/heads/master: 2ae5b30ff08cee422c7f6388a759f743633c7542
5 changes: 3 additions & 2 deletions trunk/drivers/net/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2020,8 +2020,8 @@ config SIS190
will be called sis190. This is recommended.

config SKGE
tristate "New SysKonnect GigaEthernet support"
depends on PCI
tristate "New SysKonnect GigaEthernet support (EXPERIMENTAL)"
depends on PCI && EXPERIMENTAL
select CRC32
---help---
This driver support the Marvell Yukon or SysKonnect SK-98xx/SK-95xx
Expand Down Expand Up @@ -2082,6 +2082,7 @@ config SK98LIN
- Allied Telesyn AT-2971SX Gigabit Ethernet Adapter
- Allied Telesyn AT-2971T Gigabit Ethernet Adapter
- Belkin Gigabit Desktop Card 10/100/1000Base-T Adapter, Copper RJ-45
- DGE-530T Gigabit Ethernet Adapter
- EG1032 v2 Instant Gigabit Network Adapter
- EG1064 v2 Instant Gigabit Network Adapter
- Marvell 88E8001 Gigabit LOM Ethernet Adapter (Abit)
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/net/bonding/bond_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1581,7 +1581,6 @@ int bond_release(struct net_device *bond_dev, struct net_device *slave_dev)
printk(KERN_INFO DRV_NAME
": %s: %s not enslaved\n",
bond_dev->name, slave_dev->name);
write_unlock_bh(&bond->lock);
return -EINVAL;
}

Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/net/sis190.c
Original file line number Diff line number Diff line change
Expand Up @@ -1791,8 +1791,6 @@ static int __devinit sis190_init_one(struct pci_dev *pdev,
goto out;
}

pci_set_drvdata(pdev, dev);

tp = netdev_priv(dev);
ioaddr = tp->mmio_addr;

Expand Down Expand Up @@ -1829,6 +1827,8 @@ static int __devinit sis190_init_one(struct pci_dev *pdev,
if (rc < 0)
goto err_remove_mii;

pci_set_drvdata(pdev, dev);

net_probe(tp, KERN_INFO "%s: %s at %p (IRQ: %d), "
"%2.2x:%2.2x:%2.2x:%2.2x:%2.2x:%2.2x\n",
pci_name(pdev), sis_chip_info[ent->driver_data].name,
Expand Down
10 changes: 1 addition & 9 deletions trunk/drivers/net/skge.c
Original file line number Diff line number Diff line change
Expand Up @@ -1697,31 +1697,23 @@ static void yukon_mac_init(struct skge_hw *hw, int port)
skge_write32(hw, SK_REG(port, GPHY_CTRL), reg | GPC_RST_SET);
skge_write32(hw, SK_REG(port, GPHY_CTRL), reg | GPC_RST_CLR);
skge_write32(hw, SK_REG(port, GMAC_CTRL), GMC_PAUSE_ON | GMC_RST_CLR);

if (skge->autoneg == AUTONEG_DISABLE) {
reg = GM_GPCR_AU_ALL_DIS;
gma_write16(hw, port, GM_GP_CTRL,
gma_read16(hw, port, GM_GP_CTRL) | reg);

switch (skge->speed) {
case SPEED_1000:
reg &= ~GM_GPCR_SPEED_100;
reg |= GM_GPCR_SPEED_1000;
break;
/* fallthru */
case SPEED_100:
reg &= ~GM_GPCR_SPEED_1000;
reg |= GM_GPCR_SPEED_100;
break;
case SPEED_10:
reg &= ~(GM_GPCR_SPEED_1000 | GM_GPCR_SPEED_100);
break;
}

if (skge->duplex == DUPLEX_FULL)
reg |= GM_GPCR_DUP_FULL;
} else
reg = GM_GPCR_SPEED_1000 | GM_GPCR_SPEED_100 | GM_GPCR_DUP_FULL;

switch (skge->flow_control) {
case FLOW_MODE_NONE:
skge_write32(hw, SK_REG(port, GMAC_CTRL), GMC_PAUSE_OFF);
Expand Down
31 changes: 1 addition & 30 deletions trunk/drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -520,16 +520,10 @@ static void sky2_mac_init(struct sky2_hw *hw, unsigned port)

switch (sky2->speed) {
case SPEED_1000:
reg &= ~GM_GPCR_SPEED_100;
reg |= GM_GPCR_SPEED_1000;
break;
/* fallthru */
case SPEED_100:
reg &= ~GM_GPCR_SPEED_1000;
reg |= GM_GPCR_SPEED_100;
break;
case SPEED_10:
reg &= ~(GM_GPCR_SPEED_1000 | GM_GPCR_SPEED_100);
break;
}

if (sky2->duplex == DUPLEX_FULL)
Expand Down Expand Up @@ -1452,29 +1446,6 @@ static void sky2_link_up(struct sky2_port *sky2)
sky2_write8(hw, SK_REG(port, GMAC_IRQ_MSK), GMAC_DEF_MSK);

reg = gma_read16(hw, port, GM_GP_CTRL);
if (sky2->autoneg == AUTONEG_DISABLE) {
reg |= GM_GPCR_AU_ALL_DIS;

/* Is write/read necessary? Copied from sky2_mac_init */
gma_write16(hw, port, GM_GP_CTRL, reg);
gma_read16(hw, port, GM_GP_CTRL);

switch (sky2->speed) {
case SPEED_1000:
reg &= ~GM_GPCR_SPEED_100;
reg |= GM_GPCR_SPEED_1000;
break;
case SPEED_100:
reg &= ~GM_GPCR_SPEED_1000;
reg |= GM_GPCR_SPEED_100;
break;
case SPEED_10:
reg &= ~(GM_GPCR_SPEED_1000 | GM_GPCR_SPEED_100);
break;
}
} else
reg &= ~GM_GPCR_AU_ALL_DIS;

if (sky2->duplex == DUPLEX_FULL || sky2->autoneg == AUTONEG_ENABLE)
reg |= GM_GPCR_DUP_FULL;

Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/net/tokenring/smctr.h
Original file line number Diff line number Diff line change
Expand Up @@ -1042,7 +1042,7 @@ typedef struct net_local {
__u16 functional_address[2];
__u16 bitwise_group_address[2];

const __u8 *ptr_ucode;
__u8 *ptr_ucode;

__u8 cleanup;

Expand Down
98 changes: 39 additions & 59 deletions trunk/drivers/net/wireless/atmel.c
Original file line number Diff line number Diff line change
Expand Up @@ -1872,7 +1872,7 @@ static int atmel_set_encodeext(struct net_device *dev,
struct atmel_private *priv = netdev_priv(dev);
struct iw_point *encoding = &wrqu->encoding;
struct iw_encode_ext *ext = (struct iw_encode_ext *)extra;
int idx, key_len, alg = ext->alg, set_key = 1;
int idx, key_len;

/* Determine and validate the key index */
idx = encoding->flags & IW_ENCODE_INDEX;
Expand All @@ -1883,42 +1883,39 @@ static int atmel_set_encodeext(struct net_device *dev,
} else
idx = priv->default_key;

if (encoding->flags & IW_ENCODE_DISABLED)
alg = IW_ENCODE_ALG_NONE;
if ((encoding->flags & IW_ENCODE_DISABLED) ||
ext->alg == IW_ENCODE_ALG_NONE) {
priv->wep_is_on = 0;
priv->encryption_level = 0;
priv->pairwise_cipher_suite = CIPHER_SUITE_NONE;
}

if (ext->ext_flags & IW_ENCODE_EXT_SET_TX_KEY) {
if (ext->ext_flags & IW_ENCODE_EXT_SET_TX_KEY)
priv->default_key = idx;
set_key = ext->key_len > 0 ? 1 : 0;
}

if (set_key) {
/* Set the requested key first */
switch (alg) {
case IW_ENCODE_ALG_NONE:
priv->wep_is_on = 0;
priv->encryption_level = 0;
priv->pairwise_cipher_suite = CIPHER_SUITE_NONE;
break;
case IW_ENCODE_ALG_WEP:
if (ext->key_len > 5) {
priv->wep_key_len[idx] = 13;
priv->pairwise_cipher_suite = CIPHER_SUITE_WEP_128;
priv->encryption_level = 2;
} else if (ext->key_len > 0) {
priv->wep_key_len[idx] = 5;
priv->pairwise_cipher_suite = CIPHER_SUITE_WEP_64;
priv->encryption_level = 1;
} else {
return -EINVAL;
}
priv->wep_is_on = 1;
memset(priv->wep_keys[idx], 0, 13);
key_len = min ((int)ext->key_len, priv->wep_key_len[idx]);
memcpy(priv->wep_keys[idx], ext->key, key_len);
break;
default:
/* Set the requested key */
switch (ext->alg) {
case IW_ENCODE_ALG_NONE:
break;
case IW_ENCODE_ALG_WEP:
if (ext->key_len > 5) {
priv->wep_key_len[idx] = 13;
priv->pairwise_cipher_suite = CIPHER_SUITE_WEP_128;
priv->encryption_level = 2;
} else if (ext->key_len > 0) {
priv->wep_key_len[idx] = 5;
priv->pairwise_cipher_suite = CIPHER_SUITE_WEP_64;
priv->encryption_level = 1;
} else {
return -EINVAL;
}
priv->wep_is_on = 1;
memset(priv->wep_keys[idx], 0, 13);
key_len = min ((int)ext->key_len, priv->wep_key_len[idx]);
memcpy(priv->wep_keys[idx], ext->key, key_len);
break;
default:
return -EINVAL;
}

return -EINPROGRESS;
Expand Down Expand Up @@ -3064,26 +3061,17 @@ static void authenticate(struct atmel_private *priv, u16 frame_len)
}

if (status == C80211_MGMT_SC_Success && priv->wep_is_on) {
int should_associate = 0;
/* WEP */
if (trans_seq_no != priv->ExpectedAuthentTransactionSeqNum)
return;

if (system == C80211_MGMT_AAN_OPENSYSTEM) {
if (trans_seq_no == 0x0002) {
should_associate = 1;
}
} else if (system == C80211_MGMT_AAN_SHAREDKEY) {
if (trans_seq_no == 0x0002 &&
auth->el_id == C80211_MGMT_ElementID_ChallengeText) {
send_authentication_request(priv, system, auth->chall_text, auth->chall_text_len);
return;
} else if (trans_seq_no == 0x0004) {
should_associate = 1;
}
if (trans_seq_no == 0x0002 &&
auth->el_id == C80211_MGMT_ElementID_ChallengeText) {
send_authentication_request(priv, system, auth->chall_text, auth->chall_text_len);
return;
}

if (should_associate) {
if (trans_seq_no == 0x0004) {
if(priv->station_was_associated) {
atmel_enter_state(priv, STATION_STATE_REASSOCIATING);
send_association_request(priv, 1);
Expand All @@ -3096,13 +3084,11 @@ static void authenticate(struct atmel_private *priv, u16 frame_len)
}
}

if (status == WLAN_STATUS_NOT_SUPPORTED_AUTH_ALG) {
if (status == C80211_MGMT_SC_AuthAlgNotSupported) {
/* Do opensystem first, then try sharedkey */
if (system == WLAN_AUTH_OPEN) {
if (system == C80211_MGMT_AAN_OPENSYSTEM) {
priv->CurrentAuthentTransactionSeqNum = 0x001;
priv->exclude_unencrypted = 1;
send_authentication_request(priv, WLAN_AUTH_SHARED_KEY, NULL, 0);
return;
send_authentication_request(priv, C80211_MGMT_AAN_SHAREDKEY, NULL, 0);
} else if (priv->connect_to_any_BSS) {
int bss_index;

Expand Down Expand Up @@ -3453,13 +3439,10 @@ static void atmel_management_timer(u_long a)
priv->AuthenticationRequestRetryCnt = 0;
restart_search(priv);
} else {
int auth = C80211_MGMT_AAN_OPENSYSTEM;
priv->AuthenticationRequestRetryCnt++;
priv->CurrentAuthentTransactionSeqNum = 0x0001;
mod_timer(&priv->management_timer, jiffies + MGMT_JIFFIES);
if (priv->wep_is_on && priv->exclude_unencrypted)
auth = C80211_MGMT_AAN_SHAREDKEY;
send_authentication_request(priv, auth, NULL, 0);
send_authentication_request(priv, C80211_MGMT_AAN_OPENSYSTEM, NULL, 0);
}
break;

Expand Down Expand Up @@ -3558,15 +3541,12 @@ static void atmel_command_irq(struct atmel_private *priv)
priv->station_was_associated = priv->station_is_associated;
atmel_enter_state(priv, STATION_STATE_READY);
} else {
int auth = C80211_MGMT_AAN_OPENSYSTEM;
priv->AuthenticationRequestRetryCnt = 0;
atmel_enter_state(priv, STATION_STATE_AUTHENTICATING);

mod_timer(&priv->management_timer, jiffies + MGMT_JIFFIES);
priv->CurrentAuthentTransactionSeqNum = 0x0001;
if (priv->wep_is_on && priv->exclude_unencrypted)
auth = C80211_MGMT_AAN_SHAREDKEY;
send_authentication_request(priv, auth, NULL, 0);
send_authentication_request(priv, C80211_MGMT_AAN_SHAREDKEY, NULL, 0);
}
return;
}
Expand Down
16 changes: 12 additions & 4 deletions trunk/drivers/net/wireless/wavelan_cs.c
Original file line number Diff line number Diff line change
Expand Up @@ -950,8 +950,16 @@ wv_82593_cmd(struct net_device * dev,
static inline int
wv_diag(struct net_device * dev)
{
return(wv_82593_cmd(dev, "wv_diag(): diagnose",
OP0_DIAGNOSE, SR0_DIAGNOSE_PASSED));
int ret = FALSE;

if(wv_82593_cmd(dev, "wv_diag(): diagnose",
OP0_DIAGNOSE, SR0_DIAGNOSE_PASSED))
ret = TRUE;

#ifdef DEBUG_CONFIG_ERRORS
printk(KERN_INFO "wavelan_cs: i82593 Self Test failed!\n");
#endif
return(ret);
} /* wv_diag */

/*------------------------------------------------------------------*/
Expand Down Expand Up @@ -3596,8 +3604,8 @@ wv_82593_config(struct net_device * dev)
cfblk.lin_prio = 0; /* conform to 802.3 backoff algoritm */
cfblk.exp_prio = 5; /* conform to 802.3 backoff algoritm */
cfblk.bof_met = 1; /* conform to 802.3 backoff algoritm */
cfblk.ifrm_spc = 0x20 >> 4; /* 32 bit times interframe spacing */
cfblk.slottim_low = 0x20 >> 5; /* 32 bit times slot time */
cfblk.ifrm_spc = 0x20; /* 32 bit times interframe spacing */
cfblk.slottim_low = 0x20; /* 32 bit times slot time */
cfblk.slottim_hi = 0x0;
cfblk.max_retr = 15;
cfblk.prmisc = ((lp->promiscuous) ? TRUE: FALSE); /* Promiscuous mode */
Expand Down
Loading

0 comments on commit f343fd5

Please sign in to comment.