Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 247641
b: refs/heads/master
c: 889cb36
h: refs/heads/master
i:
  247639: baf9786
v: v3
  • Loading branch information
Eliad Peller authored and Luciano Coelho committed May 12, 2011
1 parent 707257c commit 6d3b60d
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 22 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: 1159024d4c0aafecaa0c6635c55153b4b39cc1c8
refs/heads/master: 889cb360b4f48c1334311093161f06f7b4bd77d2
26 changes: 15 additions & 11 deletions trunk/drivers/net/wireless/wl12xx/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2376,20 +2376,24 @@ static int wl1271_op_set_rts_threshold(struct ieee80211_hw *hw, u32 value)
static int wl1271_ssid_set(struct wl1271 *wl, struct sk_buff *skb,
int offset)
{
u8 *ptr = skb->data + offset;
u8 ssid_len;
const u8 *ptr = cfg80211_find_ie(WLAN_EID_SSID, skb->data + offset,
skb->len - offset);

/* find the location of the ssid in the beacon */
while (ptr < skb->data + skb->len) {
if (ptr[0] == WLAN_EID_SSID) {
wl->ssid_len = ptr[1];
memcpy(wl->ssid, ptr+2, wl->ssid_len);
return 0;
}
ptr += (ptr[1] + 2);
if (!ptr) {
wl1271_error("No SSID in IEs!");
return -ENOENT;
}

wl1271_error("No SSID in IEs!\n");
return -ENOENT;
ssid_len = ptr[1];
if (ssid_len > IEEE80211_MAX_SSID_LEN) {
wl1271_error("SSID is too long!");
return -EINVAL;
}

wl->ssid_len = ssid_len;
memcpy(wl->ssid, ptr+2, ssid_len);
return 0;
}

static int wl1271_bss_erp_info_changed(struct wl1271 *wl,
Expand Down
14 changes: 4 additions & 10 deletions trunk/drivers/ssb/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1332,27 +1332,21 @@ EXPORT_SYMBOL(ssb_bus_powerup);
static void ssb_broadcast_value(struct ssb_device *dev,
u32 address, u32 data)
{
#ifdef CONFIG_SSB_DRIVER_PCICORE
/* This is used for both, PCI and ChipCommon core, so be careful. */
BUILD_BUG_ON(SSB_PCICORE_BCAST_ADDR != SSB_CHIPCO_BCAST_ADDR);
BUILD_BUG_ON(SSB_PCICORE_BCAST_DATA != SSB_CHIPCO_BCAST_DATA);
#endif

ssb_write32(dev, SSB_CHIPCO_BCAST_ADDR, address);
ssb_read32(dev, SSB_CHIPCO_BCAST_ADDR); /* flush */
ssb_write32(dev, SSB_CHIPCO_BCAST_DATA, data);
ssb_read32(dev, SSB_CHIPCO_BCAST_DATA); /* flush */
ssb_write32(dev, SSB_PCICORE_BCAST_ADDR, address);
ssb_read32(dev, SSB_PCICORE_BCAST_ADDR); /* flush */
ssb_write32(dev, SSB_PCICORE_BCAST_DATA, data);
ssb_read32(dev, SSB_PCICORE_BCAST_DATA); /* flush */
}

void ssb_commit_settings(struct ssb_bus *bus)
{
struct ssb_device *dev;

#ifdef CONFIG_SSB_DRIVER_PCICORE
dev = bus->chipco.dev ? bus->chipco.dev : bus->pcicore.dev;
#else
dev = bus->chipco.dev;
#endif
if (WARN_ON(!dev))
return;
/* This forces an update of the cached registers. */
Expand Down

0 comments on commit 6d3b60d

Please sign in to comment.