Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 197433
b: refs/heads/master
c: 3dfe08e
h: refs/heads/master
i:
  197431: c73ade5
v: v3
  • Loading branch information
Florian Schilhabel authored and Greg Kroah-Hartman committed May 14, 2010
1 parent 41292c2 commit aedade7
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 9 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: 5c2af91bbcc19c96d2fb35c4bb3f3d66b039e978
refs/heads/master: 3dfe08e6073f40a742fe3e5d6b43ca8184c55722
27 changes: 19 additions & 8 deletions trunk/drivers/staging/rtl8192su/r8192U_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1219,6 +1219,7 @@ void rtl8192_set_mode(struct net_device *dev,int mode)
void rtl8192_update_msr(struct net_device *dev)
{
struct r8192_priv *priv = ieee80211_priv(dev);
LED_CTL_MODE LedAction = LED_CTL_NO_LINK;
u8 msr;

msr = read_nic_byte(dev, MSR);
Expand All @@ -1229,19 +1230,23 @@ void rtl8192_update_msr(struct net_device *dev)
* this is intentional and make sense for ad-hoc and
* master (see the create BSS/IBSS func)
*/
if (priv->ieee80211->state == IEEE80211_LINKED){
if (priv->ieee80211->state == IEEE80211_LINKED) {

if (priv->ieee80211->iw_mode == IW_MODE_INFRA)
if (priv->ieee80211->iw_mode == IW_MODE_INFRA) {
msr |= (MSR_LINK_MANAGED<<MSR_LINK_SHIFT);
else if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
LedAction = LED_CTL_LINK;
} else if (priv->ieee80211->iw_mode == IW_MODE_ADHOC)
msr |= (MSR_LINK_ADHOC<<MSR_LINK_SHIFT);
else if (priv->ieee80211->iw_mode == IW_MODE_MASTER)
msr |= (MSR_LINK_MASTER<<MSR_LINK_SHIFT);

}else
} else
msr |= (MSR_LINK_NONE<<MSR_LINK_SHIFT);

write_nic_byte(dev, MSR, msr);

if(priv->ieee80211->LedControlHandler != NULL)
priv->ieee80211->LedControlHandler(dev, LedAction);
}

void rtl8192_set_chan(struct net_device *dev,short ch)
Expand Down Expand Up @@ -2154,15 +2159,13 @@ short rtl8192SU_tx(struct net_device *dev, struct sk_buff* skb)
struct r8192_priv *priv = ieee80211_priv(dev);
cb_desc *tcb_desc = (cb_desc *)(skb->cb + MAX_DEV_ADDR_SIZE);
tx_desc_819x_usb *tx_desc = (tx_desc_819x_usb *)skb->data;
//tx_fwinfo_819x_usb *tx_fwinfo = (tx_fwinfo_819x_usb *)(skb->data + USB_HWDESC_HEADER_LEN);//92su del
struct usb_device *udev = priv->udev;
int pend;
int status;
struct urb *tx_urb = NULL, *tx_urb_zero = NULL;
//int urb_len;
unsigned int idx_pipe;
u16 MPDUOverhead = 0;
//RT_DEBUG_DATA(COMP_SEND, tcb_desc, sizeof(cb_desc));
u16 MPDUOverhead = 0;
u16 type = 0;

pend = atomic_read(&priv->tx_pending[tcb_desc->queue_index]);
/* we are locked here so the two atomic_read and inc are executed
Expand Down Expand Up @@ -2359,6 +2362,11 @@ short rtl8192SU_tx(struct net_device *dev, struct sk_buff* skb)
skb->data,
skb->len, rtl8192_tx_isr, skb);

if (type == IEEE80211_FTYPE_DATA) {
if (priv->ieee80211->LedControlHandler != NULL)
priv->ieee80211->LedControlHandler(dev, LED_CTL_TX);
}

status = usb_submit_urb(tx_urb, GFP_ATOMIC);
if (!status) {
/*
Expand Down Expand Up @@ -5487,6 +5495,9 @@ void rtl819x_watchdog_wqcallback(struct work_struct *work)
priv->ieee80211->current_network.bssid);
ieee->is_roaming = true;
priv->ieee80211->link_change(dev);
if(ieee->LedControlHandler != NULL)
ieee->LedControlHandler(ieee->dev,
LED_CTL_START_TO_LINK);
queue_work(priv->ieee80211->wq,
&priv->ieee80211->associate_procedure_wq);
}
Expand Down

0 comments on commit aedade7

Please sign in to comment.