Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (45 commits)
cnic: Fix ISCSI_KEVENT_IF_DOWN message handling.
net: irda: init spinlock after memcpy
ixgbe: fix for 82599 errata marking UDP checksum errors
r8169: WakeOnLan fix for the 8168
netxen: reset ring consumer during cleanup
net/bridge: use kobject_put to release kobject in br_add_if error path
smc91x.h: add config for Nomadik evaluation kit
NET: ROSE: Don't use static buffer.
eepro: Read buffer overflow
tokenring: Read buffer overflow
at1700: Read buffer overflow
fealnx: Write outside array bounds
ixgbe: remove unnecessary call to device_init_wakeup
ixgbe: Don't priority tag control frames in DCB mode
ixgbe: Enable FCoE offload when DCB is enabled for 82599
net: Rework mdio-ofgpio driver to use of_mdio infrastructure
register at91_ether using platform_driver_probe
skge: Enable WoL by default if supported
net: KS8851 needs to depend on MII
be2net: Bug fix in the non-lro path. Size of received packet was not updated in statistics properly.
...

+338 -176
+1
drivers/net/Kconfig
··· 1732 config KS8851 1733 tristate "Micrel KS8851 SPI" 1734 depends on SPI 1735 help 1736 SPI driver for Micrel KS8851 SPI attached network chip. 1737
··· 1732 config KS8851 1733 tristate "Micrel KS8851 SPI" 1734 depends on SPI 1735 + select MII 1736 help 1737 SPI driver for Micrel KS8851 SPI attached network chip. 1738
+1 -2
drivers/net/arm/at91_ether.c
··· 1228 #endif 1229 1230 static struct platform_driver at91ether_driver = { 1231 - .probe = at91ether_probe, 1232 .remove = __devexit_p(at91ether_remove), 1233 .suspend = at91ether_suspend, 1234 .resume = at91ether_resume, ··· 1239 1240 static int __init at91ether_init(void) 1241 { 1242 - return platform_driver_register(&at91ether_driver); 1243 } 1244 1245 static void __exit at91ether_exit(void)
··· 1228 #endif 1229 1230 static struct platform_driver at91ether_driver = { 1231 .remove = __devexit_p(at91ether_remove), 1232 .suspend = at91ether_suspend, 1233 .resume = at91ether_resume, ··· 1240 1241 static int __init at91ether_init(void) 1242 { 1243 + return platform_driver_probe(&at91ether_driver, at91ether_probe); 1244 } 1245 1246 static void __exit at91ether_exit(void)
+1 -1
drivers/net/at1700.c
··· 318 pos3 = mca_read_stored_pos( slot, 3 ); 319 pos4 = mca_read_stored_pos( slot, 4 ); 320 321 - for (l_i = 0; l_i < 0x09; l_i++) 322 if (( pos3 & 0x07) == at1700_ioaddr_pattern[l_i]) 323 break; 324 ioaddr = at1700_mca_probe_list[l_i];
··· 318 pos3 = mca_read_stored_pos( slot, 3 ); 319 pos4 = mca_read_stored_pos( slot, 4 ); 320 321 + for (l_i = 0; l_i < 8; l_i++) 322 if (( pos3 & 0x07) == at1700_ioaddr_pattern[l_i]) 323 break; 324 ioaddr = at1700_mca_probe_list[l_i];
+4 -4
drivers/net/benet/be_main.c
··· 667 struct be_queue_info *rxq = &adapter->rx_obj.q; 668 struct be_rx_page_info *page_info; 669 u16 rxq_idx, i, num_rcvd, j; 670 - u32 pktsize, hdr_len, curr_frag_len; 671 u8 *start; 672 673 rxq_idx = AMAP_GET_BITS(struct amap_eth_rx_compl, fragndx, rxcp); ··· 708 } 709 710 /* More frags present for this completion */ 711 - pktsize -= curr_frag_len; /* account for above copied frag */ 712 for (i = 1, j = 0; i < num_rcvd; i++) { 713 index_inc(&rxq_idx, rxq->len); 714 page_info = get_rx_page_info(adapter, rxq_idx); 715 716 - curr_frag_len = min(pktsize, rx_frag_size); 717 718 /* Coalesce all frags from the same physical page in one slot */ 719 if (page_info->page_offset == 0) { ··· 732 skb_shinfo(skb)->frags[j].size += curr_frag_len; 733 skb->len += curr_frag_len; 734 skb->data_len += curr_frag_len; 735 - pktsize -= curr_frag_len; 736 737 memset(page_info, 0, sizeof(*page_info)); 738 }
··· 667 struct be_queue_info *rxq = &adapter->rx_obj.q; 668 struct be_rx_page_info *page_info; 669 u16 rxq_idx, i, num_rcvd, j; 670 + u32 pktsize, hdr_len, curr_frag_len, size; 671 u8 *start; 672 673 rxq_idx = AMAP_GET_BITS(struct amap_eth_rx_compl, fragndx, rxcp); ··· 708 } 709 710 /* More frags present for this completion */ 711 + size = pktsize; 712 for (i = 1, j = 0; i < num_rcvd; i++) { 713 + size -= curr_frag_len; 714 index_inc(&rxq_idx, rxq->len); 715 page_info = get_rx_page_info(adapter, rxq_idx); 716 717 + curr_frag_len = min(size, rx_frag_size); 718 719 /* Coalesce all frags from the same physical page in one slot */ 720 if (page_info->page_offset == 0) { ··· 731 skb_shinfo(skb)->frags[j].size += curr_frag_len; 732 skb->len += curr_frag_len; 733 skb->data_len += curr_frag_len; 734 735 memset(page_info, 0, sizeof(*page_info)); 736 }
+21 -2
drivers/net/cnic.c
··· 227 } 228 229 rcu_read_lock(); 230 - ulp_ops = rcu_dereference(cp->ulp_ops[CNIC_ULP_ISCSI]); 231 if (ulp_ops) 232 ulp_ops->iscsi_nl_send_msg(cp->dev, msg_type, buf, len); 233 rcu_read_unlock(); ··· 319 return 0; 320 } 321 322 int cnic_register_driver(int ulp_type, struct cnic_ulp_ops *ulp_ops) 323 { 324 struct cnic_dev *dev; ··· 403 } 404 } 405 read_unlock(&cnic_dev_lock); 406 407 rcu_assign_pointer(cnic_ulp_tbl[ulp_type], NULL); 408 ··· 649 int i = 0; 650 651 if (cp->cnic_uinfo) { 652 - cnic_send_nlmsg(cp, ISCSI_KEVENT_IF_DOWN, NULL); 653 while (cp->uio_dev != -1 && i < 15) { 654 msleep(100); 655 i++; ··· 1072 { 1073 struct cnic_local *cp = dev->cnic_priv; 1074 int if_type; 1075 1076 rcu_read_lock(); 1077 for (if_type = 0; if_type < MAX_CNIC_ULP_TYPE; if_type++) {
··· 227 } 228 229 rcu_read_lock(); 230 + ulp_ops = rcu_dereference(cnic_ulp_tbl[CNIC_ULP_ISCSI]); 231 if (ulp_ops) 232 ulp_ops->iscsi_nl_send_msg(cp->dev, msg_type, buf, len); 233 rcu_read_unlock(); ··· 319 return 0; 320 } 321 322 + static void cnic_uio_stop(void) 323 + { 324 + struct cnic_dev *dev; 325 + 326 + read_lock(&cnic_dev_lock); 327 + list_for_each_entry(dev, &cnic_dev_list, list) { 328 + struct cnic_local *cp = dev->cnic_priv; 329 + 330 + if (cp->cnic_uinfo) 331 + cnic_send_nlmsg(cp, ISCSI_KEVENT_IF_DOWN, NULL); 332 + } 333 + read_unlock(&cnic_dev_lock); 334 + } 335 + 336 int cnic_register_driver(int ulp_type, struct cnic_ulp_ops *ulp_ops) 337 { 338 struct cnic_dev *dev; ··· 389 } 390 } 391 read_unlock(&cnic_dev_lock); 392 + 393 + if (ulp_type == CNIC_ULP_ISCSI) 394 + cnic_uio_stop(); 395 396 rcu_assign_pointer(cnic_ulp_tbl[ulp_type], NULL); 397 ··· 632 int i = 0; 633 634 if (cp->cnic_uinfo) { 635 while (cp->uio_dev != -1 && i < 15) { 636 msleep(100); 637 i++; ··· 1056 { 1057 struct cnic_local *cp = dev->cnic_priv; 1058 int if_type; 1059 + 1060 + if (cp->cnic_uinfo) 1061 + cnic_send_nlmsg(cp, ISCSI_KEVENT_IF_DOWN, NULL); 1062 1063 rcu_read_lock(); 1064 for (if_type = 0; if_type < MAX_CNIC_ULP_TYPE; if_type++) {
+1 -1
drivers/net/eepro.c
··· 1784 printk(KERN_INFO "eepro_init_module: Auto-detecting boards (May God protect us...)\n"); 1785 } 1786 1787 - for (i = 0; io[i] != -1 && i < MAX_EEPRO; i++) { 1788 dev = alloc_etherdev(sizeof(struct eepro_local)); 1789 if (!dev) 1790 break;
··· 1784 printk(KERN_INFO "eepro_init_module: Auto-detecting boards (May God protect us...)\n"); 1785 } 1786 1787 + for (i = 0; i < MAX_EEPRO && io[i] != -1; i++) { 1788 dev = alloc_etherdev(sizeof(struct eepro_local)); 1789 if (!dev) 1790 break;
+2 -1
drivers/net/fealnx.c
··· 584 if (np->flags == HAS_MII_XCVR) { 585 int phy, phy_idx = 0; 586 587 - for (phy = 1; phy < 32 && phy_idx < 4; phy++) { 588 int mii_status = mdio_read(dev, phy, 1); 589 590 if (mii_status != 0xffff && mii_status != 0x0000) {
··· 584 if (np->flags == HAS_MII_XCVR) { 585 int phy, phy_idx = 0; 586 587 + for (phy = 1; phy < 32 && phy_idx < ARRAY_SIZE(np->phys); 588 + phy++) { 589 int mii_status = mdio_read(dev, phy, 1); 590 591 if (mii_status != 0xffff && mii_status != 0x0000) {
+10 -10
drivers/net/fs_enet/fs_enet-main.c
··· 754 fep->oldlink = 0; 755 fep->oldspeed = 0; 756 fep->oldduplex = -1; 757 - if(fep->fpi->phy_node) 758 - phydev = of_phy_connect(dev, fep->fpi->phy_node, 759 - &fs_adjust_link, 0, 760 - PHY_INTERFACE_MODE_MII); 761 - else { 762 - printk("No phy bus ID specified in BSP code\n"); 763 - return -EINVAL; 764 } 765 - if (IS_ERR(phydev)) { 766 - printk(KERN_ERR "%s: Could not attach to PHY\n", dev->name); 767 - return PTR_ERR(phydev); 768 } 769 770 fep->phydev = phydev; ··· 1004 goto out_free_fpi; 1005 } 1006 1007 dev_set_drvdata(&ofdev->dev, ndev); 1008 1009 fep = netdev_priv(ndev);
··· 754 fep->oldlink = 0; 755 fep->oldspeed = 0; 756 fep->oldduplex = -1; 757 + 758 + phydev = of_phy_connect(dev, fep->fpi->phy_node, &fs_adjust_link, 0, 759 + PHY_INTERFACE_MODE_MII); 760 + if (!phydev) { 761 + phydev = of_phy_connect_fixed_link(dev, &fs_adjust_link, 762 + PHY_INTERFACE_MODE_MII); 763 } 764 + if (!phydev) { 765 + dev_err(&dev->dev, "Could not attach to PHY\n"); 766 + return -ENODEV; 767 } 768 769 fep->phydev = phydev; ··· 1005 goto out_free_fpi; 1006 } 1007 1008 + SET_NETDEV_DEV(ndev, &ofdev->dev); 1009 dev_set_drvdata(&ofdev->dev, ndev); 1010 1011 fep = netdev_priv(ndev);
+8 -16
drivers/net/gianfar.c
··· 264 priv->device_flags |= FSL_GIANFAR_DEV_HAS_MAGIC_PACKET; 265 266 priv->phy_node = of_parse_phandle(np, "phy-handle", 0); 267 - if (!priv->phy_node) { 268 - u32 *fixed_link; 269 - 270 - fixed_link = (u32 *)of_get_property(np, "fixed-link", NULL); 271 - if (!fixed_link) { 272 - err = -ENODEV; 273 - goto err_out; 274 - } 275 - } 276 277 /* Find the TBI PHY. If it's not there, we don't support SGMII */ 278 priv->tbi_node = of_parse_phandle(np, "tbi-handle", 0); ··· 650 651 interface = gfar_get_interface(dev); 652 653 - if (priv->phy_node) { 654 - priv->phydev = of_phy_connect(dev, priv->phy_node, &adjust_link, 655 - 0, interface); 656 - if (!priv->phydev) { 657 - dev_err(&dev->dev, "error: Could not attach to PHY\n"); 658 - return -ENODEV; 659 - } 660 } 661 662 if (interface == PHY_INTERFACE_MODE_SGMII)
··· 264 priv->device_flags |= FSL_GIANFAR_DEV_HAS_MAGIC_PACKET; 265 266 priv->phy_node = of_parse_phandle(np, "phy-handle", 0); 267 268 /* Find the TBI PHY. If it's not there, we don't support SGMII */ 269 priv->tbi_node = of_parse_phandle(np, "tbi-handle", 0); ··· 659 660 interface = gfar_get_interface(dev); 661 662 + priv->phydev = of_phy_connect(dev, priv->phy_node, &adjust_link, 0, 663 + interface); 664 + if (!priv->phydev) 665 + priv->phydev = of_phy_connect_fixed_link(dev, &adjust_link, 666 + interface); 667 + if (!priv->phydev) { 668 + dev_err(&dev->dev, "could not attach to PHY\n"); 669 + return -ENODEV; 670 } 671 672 if (interface == PHY_INTERFACE_MODE_SGMII)
+1
drivers/net/ixgbe/ixgbe.h
··· 327 #define IXGBE_FLAG_IN_SFP_MOD_TASK (u32)(1 << 25) 328 #define IXGBE_FLAG_FDIR_HASH_CAPABLE (u32)(1 << 26) 329 #define IXGBE_FLAG_FDIR_PERFECT_CAPABLE (u32)(1 << 27) 330 #define IXGBE_FLAG_FCOE_ENABLED (u32)(1 << 29) 331 332 u32 flags2;
··· 327 #define IXGBE_FLAG_IN_SFP_MOD_TASK (u32)(1 << 25) 328 #define IXGBE_FLAG_FDIR_HASH_CAPABLE (u32)(1 << 26) 329 #define IXGBE_FLAG_FDIR_PERFECT_CAPABLE (u32)(1 << 27) 330 + #define IXGBE_FLAG_FCOE_CAPABLE (u32)(1 << 28) 331 #define IXGBE_FLAG_FCOE_ENABLED (u32)(1 << 29) 332 333 u32 flags2;
+24
drivers/net/ixgbe/ixgbe_dcb_nl.c
··· 139 adapter->flags &= ~IXGBE_FLAG_FDIR_PERFECT_CAPABLE; 140 } 141 adapter->flags |= IXGBE_FLAG_DCB_ENABLED; 142 ixgbe_init_interrupt_scheme(adapter); 143 if (netif_running(netdev)) 144 netdev->netdev_ops->ndo_open(netdev); ··· 168 adapter->flags |= IXGBE_FLAG_RSS_ENABLED; 169 if (adapter->hw.mac.type == ixgbe_mac_82599EB) 170 adapter->flags |= IXGBE_FLAG_FDIR_HASH_CAPABLE; 171 ixgbe_init_interrupt_scheme(adapter); 172 if (netif_running(netdev)) 173 netdev->netdev_ops->ndo_open(netdev);
··· 139 adapter->flags &= ~IXGBE_FLAG_FDIR_PERFECT_CAPABLE; 140 } 141 adapter->flags |= IXGBE_FLAG_DCB_ENABLED; 142 + #ifdef IXGBE_FCOE 143 + /* Turn on FCoE offload */ 144 + if ((adapter->flags & IXGBE_FLAG_FCOE_CAPABLE) && 145 + (!(adapter->flags & IXGBE_FLAG_FCOE_ENABLED))) { 146 + adapter->flags |= IXGBE_FLAG_FCOE_ENABLED; 147 + adapter->ring_feature[RING_F_FCOE].indices = 148 + IXGBE_FCRETA_SIZE; 149 + netdev->features |= NETIF_F_FCOE_CRC; 150 + netdev->features |= NETIF_F_FSO; 151 + netdev->fcoe_ddp_xid = IXGBE_FCOE_DDP_MAX - 1; 152 + } 153 + #endif /* IXGBE_FCOE */ 154 ixgbe_init_interrupt_scheme(adapter); 155 if (netif_running(netdev)) 156 netdev->netdev_ops->ndo_open(netdev); ··· 156 adapter->flags |= IXGBE_FLAG_RSS_ENABLED; 157 if (adapter->hw.mac.type == ixgbe_mac_82599EB) 158 adapter->flags |= IXGBE_FLAG_FDIR_HASH_CAPABLE; 159 + 160 + #ifdef IXGBE_FCOE 161 + /* Turn off FCoE offload */ 162 + if (adapter->flags & (IXGBE_FLAG_FCOE_CAPABLE | 163 + IXGBE_FLAG_FCOE_ENABLED)) { 164 + adapter->flags &= ~IXGBE_FLAG_FCOE_ENABLED; 165 + adapter->ring_feature[RING_F_FCOE].indices = 0; 166 + netdev->features &= ~NETIF_F_FCOE_CRC; 167 + netdev->features &= ~NETIF_F_FSO; 168 + netdev->fcoe_ddp_xid = 0; 169 + } 170 + #endif /* IXGBE_FCOE */ 171 ixgbe_init_interrupt_scheme(adapter); 172 if (netif_running(netdev)) 173 netdev->netdev_ops->ndo_open(netdev);
+33 -19
drivers/net/ixgbe/ixgbe_main.c
··· 34 #include <linux/in.h> 35 #include <linux/ip.h> 36 #include <linux/tcp.h> 37 #include <linux/ipv6.h> 38 #include <net/checksum.h> 39 #include <net/ip6_checksum.h> ··· 511 * @skb: skb currently being received and modified 512 **/ 513 static inline void ixgbe_rx_checksum(struct ixgbe_adapter *adapter, 514 - u32 status_err, struct sk_buff *skb) 515 { 516 skb->ip_summed = CHECKSUM_NONE; 517 518 /* Rx csum disabled */ ··· 533 return; 534 535 if (status_err & IXGBE_RXDADV_ERR_TCPE) { 536 adapter->hw_csum_rx_error++; 537 return; 538 } ··· 816 goto next_desc; 817 } 818 819 - ixgbe_rx_checksum(adapter, staterr, skb); 820 821 /* probably a little skewed due to removing CRC */ 822 total_rx_bytes += skb->len; ··· 3820 adapter->atr_sample_rate = 20; 3821 adapter->fdir_pballoc = 0; 3822 #ifdef IXGBE_FCOE 3823 - adapter->flags |= IXGBE_FLAG_FCOE_ENABLED; 3824 - adapter->ring_feature[RING_F_FCOE].indices = IXGBE_FCRETA_SIZE; 3825 #endif /* IXGBE_FCOE */ 3826 } 3827 ··· 5140 int count = 0; 5141 unsigned int f; 5142 5143 - r_idx = skb->queue_mapping; 5144 - tx_ring = &adapter->tx_ring[r_idx]; 5145 - 5146 if (adapter->vlgrp && vlan_tx_tag_present(skb)) { 5147 tx_flags |= vlan_tx_tag_get(skb); 5148 if (adapter->flags & IXGBE_FLAG_DCB_ENABLED) { ··· 5149 tx_flags <<= IXGBE_TX_FLAGS_VLAN_SHIFT; 5150 tx_flags |= IXGBE_TX_FLAGS_VLAN; 5151 } else if (adapter->flags & IXGBE_FLAG_DCB_ENABLED) { 5152 - tx_flags |= (skb->queue_mapping << 13); 5153 - tx_flags <<= IXGBE_TX_FLAGS_VLAN_SHIFT; 5154 - tx_flags |= IXGBE_TX_FLAGS_VLAN; 5155 } 5156 5157 if ((adapter->flags & IXGBE_FLAG_FCOE_ENABLED) && 5158 (skb->protocol == htons(ETH_P_FCOE))) ··· 5600 #endif 5601 5602 #ifdef IXGBE_FCOE 5603 - if (adapter->flags & IXGBE_FLAG_FCOE_ENABLED) { 5604 if (hw->mac.ops.get_device_caps) { 5605 hw->mac.ops.get_device_caps(hw, &device_caps); 5606 - if (!(device_caps & IXGBE_DEVICE_CAPS_FCOE_OFFLOADS)) { 5607 - netdev->features |= NETIF_F_FCOE_CRC; 5608 - netdev->features |= NETIF_F_FSO; 5609 - netdev->fcoe_ddp_xid = IXGBE_FCOE_DDP_MAX - 1; 5610 - } else { 5611 - adapter->flags &= ~IXGBE_FLAG_FCOE_ENABLED; 5612 - } 5613 } 5614 } 5615 #endif /* IXGBE_FCOE */ ··· 5653 adapter->wol = 0; 5654 break; 5655 } 5656 - device_init_wakeup(&adapter->pdev->dev, true); 5657 device_set_wakeup_enable(&adapter->pdev->dev, adapter->wol); 5658 5659 /* pick up the PCI bus settings for reporting later */
··· 34 #include <linux/in.h> 35 #include <linux/ip.h> 36 #include <linux/tcp.h> 37 + #include <linux/pkt_sched.h> 38 #include <linux/ipv6.h> 39 #include <net/checksum.h> 40 #include <net/ip6_checksum.h> ··· 510 * @skb: skb currently being received and modified 511 **/ 512 static inline void ixgbe_rx_checksum(struct ixgbe_adapter *adapter, 513 + union ixgbe_adv_rx_desc *rx_desc, 514 + struct sk_buff *skb) 515 { 516 + u32 status_err = le32_to_cpu(rx_desc->wb.upper.status_error); 517 + 518 skb->ip_summed = CHECKSUM_NONE; 519 520 /* Rx csum disabled */ ··· 529 return; 530 531 if (status_err & IXGBE_RXDADV_ERR_TCPE) { 532 + u16 pkt_info = rx_desc->wb.lower.lo_dword.hs_rss.pkt_info; 533 + 534 + /* 535 + * 82599 errata, UDP frames with a 0 checksum can be marked as 536 + * checksum errors. 537 + */ 538 + if ((pkt_info & IXGBE_RXDADV_PKTTYPE_UDP) && 539 + (adapter->hw.mac.type == ixgbe_mac_82599EB)) 540 + return; 541 + 542 adapter->hw_csum_rx_error++; 543 return; 544 } ··· 802 goto next_desc; 803 } 804 805 + ixgbe_rx_checksum(adapter, rx_desc, skb); 806 807 /* probably a little skewed due to removing CRC */ 808 total_rx_bytes += skb->len; ··· 3806 adapter->atr_sample_rate = 20; 3807 adapter->fdir_pballoc = 0; 3808 #ifdef IXGBE_FCOE 3809 + adapter->flags |= IXGBE_FLAG_FCOE_CAPABLE; 3810 + adapter->flags &= ~IXGBE_FLAG_FCOE_ENABLED; 3811 + adapter->ring_feature[RING_F_FCOE].indices = 0; 3812 #endif /* IXGBE_FCOE */ 3813 } 3814 ··· 5125 int count = 0; 5126 unsigned int f; 5127 5128 if (adapter->vlgrp && vlan_tx_tag_present(skb)) { 5129 tx_flags |= vlan_tx_tag_get(skb); 5130 if (adapter->flags & IXGBE_FLAG_DCB_ENABLED) { ··· 5137 tx_flags <<= IXGBE_TX_FLAGS_VLAN_SHIFT; 5138 tx_flags |= IXGBE_TX_FLAGS_VLAN; 5139 } else if (adapter->flags & IXGBE_FLAG_DCB_ENABLED) { 5140 + if (skb->priority != TC_PRIO_CONTROL) { 5141 + tx_flags |= (skb->queue_mapping << 13); 5142 + tx_flags <<= IXGBE_TX_FLAGS_VLAN_SHIFT; 5143 + tx_flags |= IXGBE_TX_FLAGS_VLAN; 5144 + } else { 5145 + skb->queue_mapping = 5146 + adapter->ring_feature[RING_F_DCB].indices-1; 5147 + } 5148 } 5149 + 5150 + r_idx = skb->queue_mapping; 5151 + tx_ring = &adapter->tx_ring[r_idx]; 5152 5153 if ((adapter->flags & IXGBE_FLAG_FCOE_ENABLED) && 5154 (skb->protocol == htons(ETH_P_FCOE))) ··· 5580 #endif 5581 5582 #ifdef IXGBE_FCOE 5583 + if (adapter->flags & IXGBE_FLAG_FCOE_CAPABLE) { 5584 if (hw->mac.ops.get_device_caps) { 5585 hw->mac.ops.get_device_caps(hw, &device_caps); 5586 + if (device_caps & IXGBE_DEVICE_CAPS_FCOE_OFFLOADS) 5587 + adapter->flags &= ~IXGBE_FLAG_FCOE_CAPABLE; 5588 } 5589 } 5590 #endif /* IXGBE_FCOE */ ··· 5638 adapter->wol = 0; 5639 break; 5640 } 5641 device_set_wakeup_enable(&adapter->pdev->dev, adapter->wol); 5642 5643 /* pick up the PCI bus settings for reporting later */
+7
drivers/net/netxen/netxen_nic_init.c
··· 184 kfree(recv_ctx->rds_rings); 185 186 skip_rds: 187 if (adapter->tx_ring == NULL) 188 return; 189
··· 184 kfree(recv_ctx->rds_rings); 185 186 skip_rds: 187 + if (recv_ctx->sds_rings == NULL) 188 + goto skip_sds; 189 + 190 + for(ring = 0; ring < adapter->max_sds_rings; ring++) 191 + recv_ctx->sds_rings[ring].consumer = 0; 192 + 193 + skip_sds: 194 if (adapter->tx_ring == NULL) 195 return; 196
+38 -43
drivers/net/phy/mdio-gpio.c
··· 30 31 #ifdef CONFIG_OF_GPIO 32 #include <linux/of_gpio.h> 33 #include <linux/of_platform.h> 34 #endif 35 ··· 82 .get_mdio_data = mdio_get, 83 }; 84 85 - static int __devinit mdio_gpio_bus_init(struct device *dev, 86 struct mdio_gpio_platform_data *pdata, 87 int bus_id) 88 { 89 struct mii_bus *new_bus; 90 struct mdio_gpio_info *bitbang; 91 - int ret = -ENOMEM; 92 int i; 93 94 bitbang = kzalloc(sizeof(*bitbang), GFP_KERNEL); ··· 103 goto out_free_bitbang; 104 105 new_bus->name = "GPIO Bitbanged MDIO", 106 - 107 - ret = -ENODEV; 108 109 new_bus->phy_mask = pdata->phy_mask; 110 new_bus->irq = pdata->irqs; ··· 127 128 dev_set_drvdata(dev, new_bus); 129 130 - ret = mdiobus_register(new_bus); 131 - if (ret) 132 - goto out_free_all; 133 134 - return 0; 135 - 136 - out_free_all: 137 - dev_set_drvdata(dev, NULL); 138 - gpio_free(bitbang->mdio); 139 out_free_mdc: 140 gpio_free(bitbang->mdc); 141 out_free_bus: ··· 136 out_free_bitbang: 137 kfree(bitbang); 138 out: 139 - return ret; 140 } 141 142 static void __devexit mdio_gpio_bus_destroy(struct device *dev) 143 { 144 struct mii_bus *bus = dev_get_drvdata(dev); 145 - struct mdio_gpio_info *bitbang = bus->priv; 146 147 mdiobus_unregister(bus); 148 - free_mdio_bitbang(bus); 149 - dev_set_drvdata(dev, NULL); 150 - gpio_free(bitbang->mdc); 151 - gpio_free(bitbang->mdio); 152 - kfree(bitbang); 153 } 154 155 static int __devinit mdio_gpio_probe(struct platform_device *pdev) 156 { 157 struct mdio_gpio_platform_data *pdata = pdev->dev.platform_data; 158 159 if (!pdata) 160 return -ENODEV; 161 162 - return mdio_gpio_bus_init(&pdev->dev, pdata, pdev->id); 163 } 164 165 static int __devexit mdio_gpio_remove(struct platform_device *pdev) ··· 187 } 188 189 #ifdef CONFIG_OF_GPIO 190 - static void __devinit add_phy(struct mdio_gpio_platform_data *pdata, 191 - struct device_node *np) 192 - { 193 - const u32 *data; 194 - int len, id, irq; 195 - 196 - data = of_get_property(np, "reg", &len); 197 - if (!data || len != 4) 198 - return; 199 - 200 - id = *data; 201 - pdata->phy_mask &= ~(1 << id); 202 - 203 - irq = of_irq_to_resource(np, 0, NULL); 204 - if (irq) 205 - pdata->irqs[id] = irq; 206 - } 207 208 static int __devinit mdio_ofgpio_probe(struct of_device *ofdev, 209 const struct of_device_id *match) 210 { 211 - struct device_node *np = NULL; 212 struct mdio_gpio_platform_data *pdata; 213 int ret; 214 215 pdata = kzalloc(sizeof(*pdata), GFP_KERNEL); ··· 206 207 ret = of_get_gpio(ofdev->node, 1); 208 if (ret < 0) 209 - goto out_free; 210 pdata->mdio = ret; 211 212 - while ((np = of_get_next_child(ofdev->node, np))) 213 - if (!strcmp(np->type, "ethernet-phy")) 214 - add_phy(pdata, np); 215 216 - return mdio_gpio_bus_init(&ofdev->dev, pdata, pdata->mdc); 217 218 out_free: 219 kfree(pdata);
··· 30 31 #ifdef CONFIG_OF_GPIO 32 #include <linux/of_gpio.h> 33 + #include <linux/of_mdio.h> 34 #include <linux/of_platform.h> 35 #endif 36 ··· 81 .get_mdio_data = mdio_get, 82 }; 83 84 + static struct mii_bus * __devinit mdio_gpio_bus_init(struct device *dev, 85 struct mdio_gpio_platform_data *pdata, 86 int bus_id) 87 { 88 struct mii_bus *new_bus; 89 struct mdio_gpio_info *bitbang; 90 int i; 91 92 bitbang = kzalloc(sizeof(*bitbang), GFP_KERNEL); ··· 103 goto out_free_bitbang; 104 105 new_bus->name = "GPIO Bitbanged MDIO", 106 107 new_bus->phy_mask = pdata->phy_mask; 108 new_bus->irq = pdata->irqs; ··· 129 130 dev_set_drvdata(dev, new_bus); 131 132 + return new_bus; 133 134 out_free_mdc: 135 gpio_free(bitbang->mdc); 136 out_free_bus: ··· 145 out_free_bitbang: 146 kfree(bitbang); 147 out: 148 + return NULL; 149 + } 150 + 151 + static void __devinit mdio_gpio_bus_deinit(struct device *dev) 152 + { 153 + struct mii_bus *bus = dev_get_drvdata(dev); 154 + struct mdio_gpio_info *bitbang = bus->priv; 155 + 156 + dev_set_drvdata(dev, NULL); 157 + gpio_free(bitbang->mdio); 158 + gpio_free(bitbang->mdc); 159 + free_mdio_bitbang(bus); 160 + kfree(bitbang); 161 } 162 163 static void __devexit mdio_gpio_bus_destroy(struct device *dev) 164 { 165 struct mii_bus *bus = dev_get_drvdata(dev); 166 167 mdiobus_unregister(bus); 168 + mdio_gpio_bus_deinit(dev); 169 } 170 171 static int __devinit mdio_gpio_probe(struct platform_device *pdev) 172 { 173 struct mdio_gpio_platform_data *pdata = pdev->dev.platform_data; 174 + struct mii_bus *new_bus; 175 + int ret; 176 177 if (!pdata) 178 return -ENODEV; 179 180 + new_bus = mdio_gpio_bus_init(&pdev->dev, pdata, pdev->id); 181 + if (!new_bus) 182 + return -ENODEV; 183 + 184 + ret = mdiobus_register(new_bus); 185 + if (ret) 186 + mdio_gpio_bus_deinit(&pdev->dev); 187 + 188 + return ret; 189 } 190 191 static int __devexit mdio_gpio_remove(struct platform_device *pdev) ··· 179 } 180 181 #ifdef CONFIG_OF_GPIO 182 183 static int __devinit mdio_ofgpio_probe(struct of_device *ofdev, 184 const struct of_device_id *match) 185 { 186 struct mdio_gpio_platform_data *pdata; 187 + struct mii_bus *new_bus; 188 int ret; 189 190 pdata = kzalloc(sizeof(*pdata), GFP_KERNEL); ··· 215 216 ret = of_get_gpio(ofdev->node, 1); 217 if (ret < 0) 218 + goto out_free; 219 pdata->mdio = ret; 220 221 + new_bus = mdio_gpio_bus_init(&ofdev->dev, pdata, pdata->mdc); 222 + if (!new_bus) 223 + return -ENODEV; 224 225 + ret = of_mdiobus_register(new_bus, ofdev->node); 226 + if (ret) 227 + mdio_gpio_bus_deinit(&ofdev->dev); 228 + 229 + return ret; 230 231 out_free: 232 kfree(pdata);
+11 -2
drivers/net/r8169.c
··· 2060 } 2061 } 2062 2063 - pci_set_master(pdev); 2064 - 2065 /* ioremap MMIO region */ 2066 ioaddr = ioremap(pci_resource_start(pdev, region), R8169_REGS_SIZE); 2067 if (!ioaddr) { ··· 2086 } 2087 2088 RTL_W16(IntrStatus, 0xffff); 2089 2090 /* Identify chip attached to board */ 2091 rtl8169_get_mac_version(tp, ioaddr); ··· 3874 spin_unlock_irq(&tp->lock); 3875 3876 if (system_state == SYSTEM_POWER_OFF) { 3877 pci_wake_from_d3(pdev, true); 3878 pci_set_power_state(pdev, PCI_D3hot); 3879 }
··· 2060 } 2061 } 2062 2063 /* ioremap MMIO region */ 2064 ioaddr = ioremap(pci_resource_start(pdev, region), R8169_REGS_SIZE); 2065 if (!ioaddr) { ··· 2088 } 2089 2090 RTL_W16(IntrStatus, 0xffff); 2091 + 2092 + pci_set_master(pdev); 2093 2094 /* Identify chip attached to board */ 2095 rtl8169_get_mac_version(tp, ioaddr); ··· 3874 spin_unlock_irq(&tp->lock); 3875 3876 if (system_state == SYSTEM_POWER_OFF) { 3877 + /* WoL fails with some 8168 when the receiver is disabled. */ 3878 + if (tp->features & RTL_FEATURE_WOL) { 3879 + pci_clear_master(pdev); 3880 + 3881 + RTL_W8(ChipCmd, CmdRxEnb); 3882 + /* PCI commit */ 3883 + RTL_R8(ChipCmd); 3884 + } 3885 + 3886 pci_wake_from_d3(pdev, true); 3887 pci_set_power_state(pdev, PCI_D3hot); 3888 }
+3 -1
drivers/net/skge.c
··· 3854 skge->speed = -1; 3855 skge->advertising = skge_supported_modes(hw); 3856 3857 - if (device_may_wakeup(&hw->pdev->dev)) 3858 skge->wol = wol_supported(hw) & WAKE_MAGIC; 3859 3860 hw->dev[port] = dev; 3861
··· 3854 skge->speed = -1; 3855 skge->advertising = skge_supported_modes(hw); 3856 3857 + if (device_can_wakeup(&hw->pdev->dev)) { 3858 skge->wol = wol_supported(hw) & WAKE_MAGIC; 3859 + device_set_wakeup_enable(&hw->pdev->dev, skge->wol); 3860 + } 3861 3862 hw->dev[port] = dev; 3863
+2 -1
drivers/net/smc91x.h
··· 186 #define SMC_outsb(a, r, p, l) writesb((a) + (r), p, (l)) 187 #define SMC_IRQ_FLAGS (-1) /* from resource */ 188 189 - #elif defined(CONFIG_MACH_LOGICPD_PXA270) 190 191 #define SMC_CAN_USE_8BIT 0 192 #define SMC_CAN_USE_16BIT 1
··· 186 #define SMC_outsb(a, r, p, l) writesb((a) + (r), p, (l)) 187 #define SMC_IRQ_FLAGS (-1) /* from resource */ 188 189 + #elif defined(CONFIG_MACH_LOGICPD_PXA270) \ 190 + || defined(CONFIG_MACH_NOMADIK_8815NHK) 191 192 #define SMC_CAN_USE_8BIT 0 193 #define SMC_CAN_USE_16BIT 1
+1 -1
drivers/net/tokenring/ibmtr.c
··· 1912 1913 find_turbo_adapters(io); 1914 1915 - for (i = 0; io[i] && (i < IBMTR_MAX_ADAPTERS); i++) { 1916 struct net_device *dev; 1917 irq[i] = 0; 1918 mem[i] = 0;
··· 1912 1913 find_turbo_adapters(io); 1914 1915 + for (i = 0; i < IBMTR_MAX_ADAPTERS && io[i]; i++) { 1916 struct net_device *dev; 1917 irq[i] = 0; 1918 mem[i] = 0;
+7 -16
drivers/net/ucc_geth.c
··· 1590 priv->oldspeed = 0; 1591 priv->oldduplex = -1; 1592 1593 - if (!ug_info->phy_node) 1594 - return 0; 1595 - 1596 phydev = of_phy_connect(dev, ug_info->phy_node, &adjust_link, 0, 1597 priv->phy_interface); 1598 if (!phydev) { 1599 - printk("%s: Could not attach to PHY\n", dev->name); 1600 return -ENODEV; 1601 } 1602 ··· 3608 struct ucc_geth_private *ugeth = NULL; 3609 struct ucc_geth_info *ug_info; 3610 struct resource res; 3611 - struct device_node *phy; 3612 int err, ucc_num, max_speed = 0; 3613 - const u32 *fixed_link; 3614 const unsigned int *prop; 3615 const char *sprop; 3616 const void *mac_addr; ··· 3706 3707 ug_info->uf_info.regs = res.start; 3708 ug_info->uf_info.irq = irq_of_parse_and_map(np, 0); 3709 - fixed_link = of_get_property(np, "fixed-link", NULL); 3710 - if (fixed_link) { 3711 - phy = NULL; 3712 - } else { 3713 - phy = of_parse_phandle(np, "phy-handle", 0); 3714 - if (phy == NULL) 3715 - return -ENODEV; 3716 - } 3717 - ug_info->phy_node = phy; 3718 3719 /* Find the TBI PHY node. If it's not there, we don't support SGMII */ 3720 ug_info->tbi_node = of_parse_phandle(np, "tbi-handle", 0); ··· 3716 prop = of_get_property(np, "phy-connection-type", NULL); 3717 if (!prop) { 3718 /* handle interface property present in old trees */ 3719 - prop = of_get_property(phy, "interface", NULL); 3720 if (prop != NULL) { 3721 phy_interface = enet_to_phy_interface[*prop]; 3722 max_speed = enet_to_speed[*prop];
··· 1590 priv->oldspeed = 0; 1591 priv->oldduplex = -1; 1592 1593 phydev = of_phy_connect(dev, ug_info->phy_node, &adjust_link, 0, 1594 priv->phy_interface); 1595 + if (!phydev) 1596 + phydev = of_phy_connect_fixed_link(dev, &adjust_link, 1597 + priv->phy_interface); 1598 if (!phydev) { 1599 + dev_err(&dev->dev, "Could not attach to PHY\n"); 1600 return -ENODEV; 1601 } 1602 ··· 3608 struct ucc_geth_private *ugeth = NULL; 3609 struct ucc_geth_info *ug_info; 3610 struct resource res; 3611 int err, ucc_num, max_speed = 0; 3612 const unsigned int *prop; 3613 const char *sprop; 3614 const void *mac_addr; ··· 3708 3709 ug_info->uf_info.regs = res.start; 3710 ug_info->uf_info.irq = irq_of_parse_and_map(np, 0); 3711 + 3712 + ug_info->phy_node = of_parse_phandle(np, "phy-handle", 0); 3713 3714 /* Find the TBI PHY node. If it's not there, we don't support SGMII */ 3715 ug_info->tbi_node = of_parse_phandle(np, "tbi-handle", 0); ··· 3725 prop = of_get_property(np, "phy-connection-type", NULL); 3726 if (!prop) { 3727 /* handle interface property present in old trees */ 3728 + prop = of_get_property(ug_info->phy_node, "interface", NULL); 3729 if (prop != NULL) { 3730 phy_interface = enet_to_phy_interface[*prop]; 3731 max_speed = enet_to_speed[*prop];
+3
drivers/net/wireless/ath/ath5k/base.c
··· 2970 if (modparam_nohwcrypt) 2971 return -EOPNOTSUPP; 2972 2973 switch (key->alg) { 2974 case ALG_WEP: 2975 case ALG_TKIP:
··· 2970 if (modparam_nohwcrypt) 2971 return -EOPNOTSUPP; 2972 2973 + if (sc->opmode == NL80211_IFTYPE_AP) 2974 + return -EOPNOTSUPP; 2975 + 2976 switch (key->alg) { 2977 case ALG_WEP: 2978 case ALG_TKIP:
+12
drivers/net/wireless/ath/ath9k/ani.c
··· 478 "Reset ANI state opmode %u\n", ah->opmode); 479 ah->stats.ast_ani_reset++; 480 481 ath9k_hw_ani_control(ah, ATH9K_ANI_NOISE_IMMUNITY_LEVEL, 0); 482 ath9k_hw_ani_control(ah, ATH9K_ANI_SPUR_IMMUNITY_LEVEL, 0); 483 ath9k_hw_ani_control(ah, ATH9K_ANI_FIRSTEP_LEVEL, 0);
··· 478 "Reset ANI state opmode %u\n", ah->opmode); 479 ah->stats.ast_ani_reset++; 480 481 + if (ah->opmode == NL80211_IFTYPE_AP) { 482 + /* 483 + * ath9k_hw_ani_control() will only process items set on 484 + * ah->ani_function 485 + */ 486 + if (IS_CHAN_2GHZ(chan)) 487 + ah->ani_function = (ATH9K_ANI_SPUR_IMMUNITY_LEVEL | 488 + ATH9K_ANI_FIRSTEP_LEVEL); 489 + else 490 + ah->ani_function = 0; 491 + } 492 + 493 ath9k_hw_ani_control(ah, ATH9K_ANI_NOISE_IMMUNITY_LEVEL, 0); 494 ath9k_hw_ani_control(ah, ATH9K_ANI_SPUR_IMMUNITY_LEVEL, 0); 495 ath9k_hw_ani_control(ah, ATH9K_ANI_FIRSTEP_LEVEL, 0);
+17
drivers/net/wireless/ath/regd.c
··· 474 return 0; 475 } 476 477 int 478 ath_regd_init(struct ath_regulatory *reg, 479 struct wiphy *wiphy, ··· 500 501 if (!reg) 502 return -EINVAL; 503 504 printk(KERN_DEBUG "ath: EEPROM regdomain: 0x%0x\n", reg->current_rd); 505
··· 474 return 0; 475 } 476 477 + /* 478 + * Some users have reported their EEPROM programmed with 479 + * 0x8000 set, this is not a supported regulatory domain 480 + * but since we have more than one user with it we need 481 + * a solution for them. We default to 0x64, which is the 482 + * default Atheros world regulatory domain. 483 + */ 484 + static void ath_regd_sanitize(struct ath_regulatory *reg) 485 + { 486 + if (reg->current_rd != COUNTRY_ERD_FLAG) 487 + return; 488 + printk(KERN_DEBUG "ath: EEPROM regdomain sanitized\n"); 489 + reg->current_rd = 0x64; 490 + } 491 + 492 int 493 ath_regd_init(struct ath_regulatory *reg, 494 struct wiphy *wiphy, ··· 485 486 if (!reg) 487 return -EINVAL; 488 + 489 + ath_regd_sanitize(reg); 490 491 printk(KERN_DEBUG "ath: EEPROM regdomain: 0x%0x\n", reg->current_rd); 492
+1 -3
drivers/net/wireless/iwlwifi/iwl-agn.c
··· 2675 struct device_attribute *attr, char *buf) 2676 { 2677 struct iwl_priv *priv = dev_get_drvdata(d); 2678 - int mode = priv->power_data.user_power_setting; 2679 int level = priv->power_data.power_mode; 2680 char *p = buf; 2681 2682 - p += sprintf(p, "INDEX:%d\t", level); 2683 - p += sprintf(p, "USER:%d\n", mode); 2684 return p - buf + 1; 2685 } 2686
··· 2675 struct device_attribute *attr, char *buf) 2676 { 2677 struct iwl_priv *priv = dev_get_drvdata(d); 2678 int level = priv->power_data.power_mode; 2679 char *p = buf; 2680 2681 + p += sprintf(p, "%d\n", level); 2682 return p - buf + 1; 2683 } 2684
+2 -1
drivers/net/wireless/iwlwifi/iwl-tx.c
··· 872 iwl_print_hex_dump(priv, IWL_DL_TX, (u8 *)tx_cmd->hdr, hdr_len); 873 874 /* Set up entry for this TFD in Tx byte-count array */ 875 - priv->cfg->ops->lib->txq_update_byte_cnt_tbl(priv, txq, 876 le16_to_cpu(tx_cmd->len)); 877 878 pci_dma_sync_single_for_device(priv->pci_dev, txcmd_phys,
··· 872 iwl_print_hex_dump(priv, IWL_DL_TX, (u8 *)tx_cmd->hdr, hdr_len); 873 874 /* Set up entry for this TFD in Tx byte-count array */ 875 + if (info->flags & IEEE80211_TX_CTL_AMPDU) 876 + priv->cfg->ops->lib->txq_update_byte_cnt_tbl(priv, txq, 877 le16_to_cpu(tx_cmd->len)); 878 879 pci_dma_sync_single_for_device(priv->pci_dev, txcmd_phys,
+1 -3
drivers/net/wireless/iwlwifi/iwl3945-base.c
··· 3643 struct device_attribute *attr, char *buf) 3644 { 3645 struct iwl_priv *priv = dev_get_drvdata(d); 3646 - int mode = priv->power_data.user_power_setting; 3647 int level = priv->power_data.power_mode; 3648 char *p = buf; 3649 3650 - p += sprintf(p, "INDEX:%d\t", level); 3651 - p += sprintf(p, "USER:%d\n", mode); 3652 return p - buf + 1; 3653 } 3654
··· 3643 struct device_attribute *attr, char *buf) 3644 { 3645 struct iwl_priv *priv = dev_get_drvdata(d); 3646 int level = priv->power_data.power_mode; 3647 char *p = buf; 3648 3649 + p += sprintf(p, "%d\n", level); 3650 return p - buf + 1; 3651 } 3652
+1 -1
drivers/net/wireless/iwmc3200wifi/netdev.c
··· 151 return; 152 153 free_netdev(iwm_to_ndev(iwm)); 154 - iwm_wdev_free(iwm); 155 iwm_priv_deinit(iwm); 156 } 157 158 int iwm_if_add(struct iwm_priv *iwm)
··· 151 return; 152 153 free_netdev(iwm_to_ndev(iwm)); 154 iwm_priv_deinit(iwm); 155 + iwm_wdev_free(iwm); 156 } 157 158 int iwm_if_add(struct iwm_priv *iwm)
+7 -1
drivers/net/wireless/libertas/cmd.c
··· 135 /* Clamp region code to 8-bit since FW spec indicates that it should 136 * only ever be 8-bit, even though the field size is 16-bit. Some firmware 137 * returns non-zero high 8 bits here. 138 */ 139 - priv->regioncode = le16_to_cpu(cmd.regioncode) & 0xFF; 140 141 for (i = 0; i < MRVDRV_MAX_REGION_CODE; i++) { 142 /* use the region code to search for the index */
··· 135 /* Clamp region code to 8-bit since FW spec indicates that it should 136 * only ever be 8-bit, even though the field size is 16-bit. Some firmware 137 * returns non-zero high 8 bits here. 138 + * 139 + * Firmware version 4.0.102 used in CF8381 has region code shifted. We 140 + * need to check for this problem and handle it properly. 141 */ 142 + if (MRVL_FW_MAJOR_REV(priv->fwrelease) == MRVL_FW_V4) 143 + priv->regioncode = (le16_to_cpu(cmd.regioncode) >> 8) & 0xFF; 144 + else 145 + priv->regioncode = le16_to_cpu(cmd.regioncode) & 0xFF; 146 147 for (i = 0; i < MRVDRV_MAX_REGION_CODE; i++) { 148 /* use the region code to search for the index */
+2
drivers/net/wireless/libertas/defs.h
··· 234 /** Mesh enable bit in FW capability */ 235 #define MESH_CAPINFO_ENABLE_MASK (1<<16) 236 237 /** FW definition from Marvell v5 */ 238 #define MRVL_FW_V5 (0x05) 239 /** FW definition from Marvell v10 */
··· 234 /** Mesh enable bit in FW capability */ 235 #define MESH_CAPINFO_ENABLE_MASK (1<<16) 236 237 + /** FW definition from Marvell v4 */ 238 + #define MRVL_FW_V4 (0x04) 239 /** FW definition from Marvell v5 */ 240 #define MRVL_FW_V5 (0x05) 241 /** FW definition from Marvell v10 */
+3 -3
drivers/net/wireless/mac80211_hwsim.c
··· 709 static void mac80211_hwsim_free(void) 710 { 711 struct list_head tmplist, *i, *tmp; 712 - struct mac80211_hwsim_data *data; 713 714 INIT_LIST_HEAD(&tmplist); 715 ··· 718 list_move(i, &tmplist); 719 spin_unlock_bh(&hwsim_radio_lock); 720 721 - list_for_each_entry(data, &tmplist, list) { 722 debugfs_remove(data->debugfs_group); 723 debugfs_remove(data->debugfs_ps); 724 debugfs_remove(data->debugfs); ··· 1167 { 1168 printk(KERN_DEBUG "mac80211_hwsim: unregister radios\n"); 1169 1170 - unregister_netdev(hwsim_mon); 1171 mac80211_hwsim_free(); 1172 } 1173 1174
··· 709 static void mac80211_hwsim_free(void) 710 { 711 struct list_head tmplist, *i, *tmp; 712 + struct mac80211_hwsim_data *data, *tmpdata; 713 714 INIT_LIST_HEAD(&tmplist); 715 ··· 718 list_move(i, &tmplist); 719 spin_unlock_bh(&hwsim_radio_lock); 720 721 + list_for_each_entry_safe(data, tmpdata, &tmplist, list) { 722 debugfs_remove(data->debugfs_group); 723 debugfs_remove(data->debugfs_ps); 724 debugfs_remove(data->debugfs); ··· 1167 { 1168 printk(KERN_DEBUG "mac80211_hwsim: unregister radios\n"); 1169 1170 mac80211_hwsim_free(); 1171 + unregister_netdev(hwsim_mon); 1172 } 1173 1174
+1 -1
drivers/net/wireless/p54/p54spi.c
··· 635 636 hw = p54_init_common(sizeof(*priv)); 637 if (!hw) { 638 - dev_err(&priv->spi->dev, "could not alloc ieee80211_hw"); 639 return -ENOMEM; 640 } 641
··· 635 636 hw = p54_init_common(sizeof(*priv)); 637 if (!hw) { 638 + dev_err(&spi->dev, "could not alloc ieee80211_hw"); 639 return -ENOMEM; 640 } 641
+3 -1
drivers/net/wireless/rt2x00/rt2500usb.c
··· 1550 rt2500usb_register_read(rt2x00dev, MAC_CSR0, &reg); 1551 rt2x00_set_chip(rt2x00dev, RT2570, value, reg); 1552 1553 - if (!rt2x00_check_rev(&rt2x00dev->chip, 0x000ffff0, 0)) { 1554 ERROR(rt2x00dev, "Invalid RT chipset detected.\n"); 1555 return -ENODEV; 1556 }
··· 1550 rt2500usb_register_read(rt2x00dev, MAC_CSR0, &reg); 1551 rt2x00_set_chip(rt2x00dev, RT2570, value, reg); 1552 1553 + if (!rt2x00_check_rev(&rt2x00dev->chip, 0x000ffff0, 0) || 1554 + rt2x00_check_rev(&rt2x00dev->chip, 0x0000000f, 0)) { 1555 + 1556 ERROR(rt2x00dev, "Invalid RT chipset detected.\n"); 1557 return -ENODEV; 1558 }
+2 -1
drivers/net/wireless/rtl818x/rtl8187_leds.c
··· 208 { 209 struct rtl8187_priv *priv = dev->priv; 210 211 - rtl8187_unregister_led(&priv->led_tx); 212 /* turn the LED off before exiting */ 213 queue_delayed_work(dev->workqueue, &priv->led_off, 0); 214 cancel_delayed_work_sync(&priv->led_off); 215 rtl8187_unregister_led(&priv->led_rx); 216 } 217 #endif /* def CONFIG_RTL8187_LED */ 218
··· 208 { 209 struct rtl8187_priv *priv = dev->priv; 210 211 /* turn the LED off before exiting */ 212 queue_delayed_work(dev->workqueue, &priv->led_off, 0); 213 cancel_delayed_work_sync(&priv->led_off); 214 + cancel_delayed_work_sync(&priv->led_on); 215 rtl8187_unregister_led(&priv->led_rx); 216 + rtl8187_unregister_led(&priv->led_tx); 217 } 218 #endif /* def CONFIG_RTL8187_LED */ 219
+42
drivers/of/of_mdio.c
··· 9 * out of the OpenFirmware device tree and using it to populate an mii_bus. 10 */ 11 12 #include <linux/phy.h> 13 #include <linux/of.h> 14 #include <linux/of_mdio.h> ··· 141 return phy_connect_direct(dev, phy, hndlr, flags, iface) ? NULL : phy; 142 } 143 EXPORT_SYMBOL(of_phy_connect);
··· 9 * out of the OpenFirmware device tree and using it to populate an mii_bus. 10 */ 11 12 + #include <linux/kernel.h> 13 + #include <linux/device.h> 14 + #include <linux/netdevice.h> 15 + #include <linux/err.h> 16 #include <linux/phy.h> 17 #include <linux/of.h> 18 #include <linux/of_mdio.h> ··· 137 return phy_connect_direct(dev, phy, hndlr, flags, iface) ? NULL : phy; 138 } 139 EXPORT_SYMBOL(of_phy_connect); 140 + 141 + /** 142 + * of_phy_connect_fixed_link - Parse fixed-link property and return a dummy phy 143 + * @dev: pointer to net_device claiming the phy 144 + * @hndlr: Link state callback for the network device 145 + * @iface: PHY data interface type 146 + * 147 + * This function is a temporary stop-gap and will be removed soon. It is 148 + * only to support the fs_enet, ucc_geth and gianfar Ethernet drivers. Do 149 + * not call this function from new drivers. 150 + */ 151 + struct phy_device *of_phy_connect_fixed_link(struct net_device *dev, 152 + void (*hndlr)(struct net_device *), 153 + phy_interface_t iface) 154 + { 155 + struct device_node *net_np; 156 + char bus_id[MII_BUS_ID_SIZE + 3]; 157 + struct phy_device *phy; 158 + const u32 *phy_id; 159 + int sz; 160 + 161 + if (!dev->dev.parent) 162 + return NULL; 163 + 164 + net_np = dev_archdata_get_node(&dev->dev.parent->archdata); 165 + if (!net_np) 166 + return NULL; 167 + 168 + phy_id = of_get_property(net_np, "fixed-link", &sz); 169 + if (!phy_id || sz < sizeof(*phy_id)) 170 + return NULL; 171 + 172 + sprintf(bus_id, PHY_ID_FMT, "0", phy_id[0]); 173 + 174 + phy = phy_connect(dev, bus_id, hndlr, 0, iface); 175 + return IS_ERR(phy) ? NULL : phy; 176 + } 177 + EXPORT_SYMBOL(of_phy_connect_fixed_link);
+1 -1
drivers/platform/x86/acer-wmi.c
··· 973 { 974 acpi_status status; 975 u32 cap = (unsigned long)data; 976 - status = set_u32(!!blocked, cap); 977 if (ACPI_FAILURE(status)) 978 return -ENODEV; 979 return 0;
··· 973 { 974 acpi_status status; 975 u32 cap = (unsigned long)data; 976 + status = set_u32(!blocked, cap); 977 if (ACPI_FAILURE(status)) 978 return -ENODEV; 979 return 0;
+3
include/linux/of_mdio.h
··· 18 struct device_node *phy_np, 19 void (*hndlr)(struct net_device *), 20 u32 flags, phy_interface_t iface); 21 22 #endif /* __LINUX_OF_MDIO_H */
··· 18 struct device_node *phy_np, 19 void (*hndlr)(struct net_device *), 20 u32 flags, phy_interface_t iface); 21 + extern struct phy_device *of_phy_connect_fixed_link(struct net_device *dev, 22 + void (*hndlr)(struct net_device *), 23 + phy_interface_t iface); 24 25 #endif /* __LINUX_OF_MDIO_H */
+1 -1
include/linux/rfkill.h
··· 224 * should be blocked) so that drivers need not keep track of the soft 225 * block state -- which they might not be able to. 226 */ 227 - bool __must_check rfkill_set_hw_state(struct rfkill *rfkill, bool blocked); 228 229 /** 230 * rfkill_set_sw_state - Set the internal rfkill software block state
··· 224 * should be blocked) so that drivers need not keep track of the soft 225 * block state -- which they might not be able to. 226 */ 227 + bool rfkill_set_hw_state(struct rfkill *rfkill, bool blocked); 228 229 /** 230 * rfkill_set_sw_state - Set the internal rfkill software block state
+1 -1
include/net/rose.h
··· 156 extern int sysctl_rose_window_size; 157 extern int rosecmp(rose_address *, rose_address *); 158 extern int rosecmpm(rose_address *, rose_address *, unsigned short); 159 - extern const char *rose2asc(const rose_address *); 160 extern struct sock *rose_find_socket(unsigned int, struct rose_neigh *); 161 extern void rose_kill_by_neigh(struct rose_neigh *); 162 extern unsigned int rose_new_lci(struct rose_neigh *);
··· 156 extern int sysctl_rose_window_size; 157 extern int rosecmp(rose_address *, rose_address *); 158 extern int rosecmpm(rose_address *, rose_address *, unsigned short); 159 + extern char *rose2asc(char *buf, const rose_address *); 160 extern struct sock *rose_find_socket(unsigned int, struct rose_neigh *); 161 extern void rose_kill_by_neigh(struct rose_neigh *); 162 extern unsigned int rose_new_lci(struct rose_neigh *);
+1 -1
net/bridge/br_if.c
··· 424 err2: 425 br_fdb_delete_by_port(br, p, 1); 426 err1: 427 - kobject_del(&p->kobj); 428 err0: 429 dev_set_promiscuity(dev, -1); 430 put_back:
··· 424 err2: 425 br_fdb_delete_by_port(br, p, 1); 426 err1: 427 + kobject_put(&p->kobj); 428 err0: 429 dev_set_promiscuity(dev, -1); 430 put_back:
+1
net/irda/irttp.c
··· 1453 } 1454 /* Dup */ 1455 memcpy(new, orig, sizeof(struct tsap_cb)); 1456 1457 /* We don't need the old instance any more */ 1458 spin_unlock_irqrestore(&irttp->tsaps->hb_spinlock, flags);
··· 1453 } 1454 /* Dup */ 1455 memcpy(new, orig, sizeof(struct tsap_cb)); 1456 + spin_lock_init(&new->lock); 1457 1458 /* We don't need the old instance any more */ 1459 spin_unlock_irqrestore(&irttp->tsaps->hb_spinlock, flags);
+1
net/mac80211/Kconfig
··· 83 config MAC80211_MESH 84 bool "Enable mac80211 mesh networking (pre-802.11s) support" 85 depends on MAC80211 && EXPERIMENTAL 86 ---help--- 87 This options enables support of Draft 802.11s mesh networking. 88 The implementation is based on Draft 1.08 of the Mesh Networking
··· 83 config MAC80211_MESH 84 bool "Enable mac80211 mesh networking (pre-802.11s) support" 85 depends on MAC80211 && EXPERIMENTAL 86 + depends on BROKEN 87 ---help--- 88 This options enables support of Draft 802.11s mesh networking. 89 The implementation is based on Draft 1.08 of the Mesh Networking
+8 -3
net/mac80211/mesh_pathtbl.c
··· 175 int err = 0; 176 u32 hash_idx; 177 178 if (memcmp(dst, sdata->dev->dev_addr, ETH_ALEN) == 0) 179 /* never add ourselves as neighbours */ 180 return -ENOTSUPP; ··· 267 int err = 0; 268 u32 hash_idx; 269 270 271 if (memcmp(dst, sdata->dev->dev_addr, ETH_ALEN) == 0) 272 /* never add ourselves as neighbours */ ··· 494 * @skb: frame to discard 495 * @sdata: network subif the frame was to be sent through 496 * 497 - * If the frame was beign forwarded from another MP, a PERR frame will be sent 498 - * to the precursor. 499 * 500 * Locking: the function must me called within a rcu_read_lock region 501 */ ··· 512 u8 *ra, *da; 513 514 da = hdr->addr3; 515 - ra = hdr->addr2; 516 mpath = mesh_path_lookup(da, sdata); 517 if (mpath) 518 dsn = ++mpath->dsn;
··· 175 int err = 0; 176 u32 hash_idx; 177 178 + might_sleep(); 179 + 180 if (memcmp(dst, sdata->dev->dev_addr, ETH_ALEN) == 0) 181 /* never add ourselves as neighbours */ 182 return -ENOTSUPP; ··· 265 int err = 0; 266 u32 hash_idx; 267 268 + might_sleep(); 269 270 if (memcmp(dst, sdata->dev->dev_addr, ETH_ALEN) == 0) 271 /* never add ourselves as neighbours */ ··· 491 * @skb: frame to discard 492 * @sdata: network subif the frame was to be sent through 493 * 494 + * If the frame was being forwarded from another MP, a PERR frame will be sent 495 + * to the precursor. The precursor's address (i.e. the previous hop) was saved 496 + * in addr1 of the frame-to-be-forwarded, and would only be overwritten once 497 + * the destination is successfully resolved. 498 * 499 * Locking: the function must me called within a rcu_read_lock region 500 */ ··· 507 u8 *ra, *da; 508 509 da = hdr->addr3; 510 + ra = hdr->addr1; 511 mpath = mesh_path_lookup(da, sdata); 512 if (mpath) 513 dsn = ++mpath->dsn;
+1 -1
net/mac80211/tx.c
··· 1455 monitor_iface = UNKNOWN_ADDRESS; 1456 1457 len_rthdr = ieee80211_get_radiotap_len(skb->data); 1458 - hdr = (struct ieee80211_hdr *)skb->data + len_rthdr; 1459 hdrlen = ieee80211_hdrlen(hdr->frame_control); 1460 1461 /* check the header is complete in the frame */
··· 1455 monitor_iface = UNKNOWN_ADDRESS; 1456 1457 len_rthdr = ieee80211_get_radiotap_len(skb->data); 1458 + hdr = (struct ieee80211_hdr *)(skb->data + len_rthdr); 1459 hdrlen = ieee80211_hdrlen(hdr->frame_control); 1460 1461 /* check the header is complete in the frame */
+23 -8
net/rfkill/core.c
··· 549 swprev = !!(rfkill->state & RFKILL_BLOCK_SW); 550 hwprev = !!(rfkill->state & RFKILL_BLOCK_HW); 551 __rfkill_set_sw_state(rfkill, sw); 552 553 spin_unlock_irqrestore(&rfkill->lock, flags); 554 ··· 652 struct device_attribute *attr, 653 const char *buf, size_t count) 654 { 655 - /* 656 - * The intention was that userspace can only take control over 657 - * a given device when/if rfkill-input doesn't control it due 658 - * to user_claim. Since user_claim is currently unsupported, 659 - * we never support changing the state from userspace -- this 660 - * can be implemented again later. 661 - */ 662 663 - return -EPERM; 664 } 665 666 static ssize_t rfkill_claim_show(struct device *dev,
··· 549 swprev = !!(rfkill->state & RFKILL_BLOCK_SW); 550 hwprev = !!(rfkill->state & RFKILL_BLOCK_HW); 551 __rfkill_set_sw_state(rfkill, sw); 552 + if (hw) 553 + rfkill->state |= RFKILL_BLOCK_HW; 554 + else 555 + rfkill->state &= ~RFKILL_BLOCK_HW; 556 557 spin_unlock_irqrestore(&rfkill->lock, flags); 558 ··· 648 struct device_attribute *attr, 649 const char *buf, size_t count) 650 { 651 + struct rfkill *rfkill = to_rfkill(dev); 652 + unsigned long state; 653 + int err; 654 655 + if (!capable(CAP_NET_ADMIN)) 656 + return -EPERM; 657 + 658 + err = strict_strtoul(buf, 0, &state); 659 + if (err) 660 + return err; 661 + 662 + if (state != RFKILL_USER_STATE_SOFT_BLOCKED && 663 + state != RFKILL_USER_STATE_UNBLOCKED) 664 + return -EINVAL; 665 + 666 + mutex_lock(&rfkill_global_mutex); 667 + rfkill_set_block(rfkill, state == RFKILL_USER_STATE_SOFT_BLOCKED); 668 + mutex_unlock(&rfkill_global_mutex); 669 + 670 + return err ?: count; 671 } 672 673 static ssize_t rfkill_claim_show(struct device *dev,
+8 -10
net/rose/af_rose.c
··· 92 /* 93 * Convert a ROSE address into text. 94 */ 95 - const char *rose2asc(const rose_address *addr) 96 { 97 - static char buffer[11]; 98 - 99 if (addr->rose_addr[0] == 0x00 && addr->rose_addr[1] == 0x00 && 100 addr->rose_addr[2] == 0x00 && addr->rose_addr[3] == 0x00 && 101 addr->rose_addr[4] == 0x00) { 102 - strcpy(buffer, "*"); 103 } else { 104 - sprintf(buffer, "%02X%02X%02X%02X%02X", addr->rose_addr[0] & 0xFF, 105 addr->rose_addr[1] & 0xFF, 106 addr->rose_addr[2] & 0xFF, 107 addr->rose_addr[3] & 0xFF, 108 addr->rose_addr[4] & 0xFF); 109 } 110 111 - return buffer; 112 } 113 114 /* ··· 1435 1436 static int rose_info_show(struct seq_file *seq, void *v) 1437 { 1438 - char buf[11]; 1439 1440 if (v == SEQ_START_TOKEN) 1441 seq_puts(seq, ··· 1453 devname = dev->name; 1454 1455 seq_printf(seq, "%-10s %-9s ", 1456 - rose2asc(&rose->dest_addr), 1457 - ax2asc(buf, &rose->dest_call)); 1458 1459 if (ax25cmp(&rose->source_call, &null_ax25_address) == 0) 1460 callsign = "??????-?"; ··· 1463 1464 seq_printf(seq, 1465 "%-10s %-9s %-5s %3.3X %05d %d %d %d %d %3lu %3lu %3lu %3lu %3lu %3lu/%03lu %5d %5d %ld\n", 1466 - rose2asc(&rose->source_addr), 1467 callsign, 1468 devname, 1469 rose->lci & 0x0FFF,
··· 92 /* 93 * Convert a ROSE address into text. 94 */ 95 + char *rose2asc(char *buf, const rose_address *addr) 96 { 97 if (addr->rose_addr[0] == 0x00 && addr->rose_addr[1] == 0x00 && 98 addr->rose_addr[2] == 0x00 && addr->rose_addr[3] == 0x00 && 99 addr->rose_addr[4] == 0x00) { 100 + strcpy(buf, "*"); 101 } else { 102 + sprintf(buf, "%02X%02X%02X%02X%02X", addr->rose_addr[0] & 0xFF, 103 addr->rose_addr[1] & 0xFF, 104 addr->rose_addr[2] & 0xFF, 105 addr->rose_addr[3] & 0xFF, 106 addr->rose_addr[4] & 0xFF); 107 } 108 109 + return buf; 110 } 111 112 /* ··· 1437 1438 static int rose_info_show(struct seq_file *seq, void *v) 1439 { 1440 + char buf[11], rsbuf[11]; 1441 1442 if (v == SEQ_START_TOKEN) 1443 seq_puts(seq, ··· 1455 devname = dev->name; 1456 1457 seq_printf(seq, "%-10s %-9s ", 1458 + rose2asc(rsbuf, &rose->dest_addr), 1459 + ax2asc(buf, &rose->dest_call)); 1460 1461 if (ax25cmp(&rose->source_call, &null_ax25_address) == 0) 1462 callsign = "??????-?"; ··· 1465 1466 seq_printf(seq, 1467 "%-10s %-9s %-5s %3.3X %05d %d %d %d %d %3lu %3lu %3lu %3lu %3lu %3lu/%03lu %5d %5d %ld\n", 1468 + rose2asc(rsbuf, &rose->source_addr), 1469 callsign, 1470 devname, 1471 rose->lci & 0x0FFF,
+12 -11
net/rose/rose_route.c
··· 1104 1105 static int rose_node_show(struct seq_file *seq, void *v) 1106 { 1107 int i; 1108 1109 if (v == SEQ_START_TOKEN) ··· 1113 const struct rose_node *rose_node = v; 1114 /* if (rose_node->loopback) { 1115 seq_printf(seq, "%-10s %04d 1 loopback\n", 1116 - rose2asc(&rose_node->address), 1117 - rose_node->mask); 1118 } else { */ 1119 seq_printf(seq, "%-10s %04d %d", 1120 - rose2asc(&rose_node->address), 1121 - rose_node->mask, 1122 - rose_node->count); 1123 1124 for (i = 0; i < rose_node->count; i++) 1125 seq_printf(seq, " %05d", ··· 1268 1269 static int rose_route_show(struct seq_file *seq, void *v) 1270 { 1271 - char buf[11]; 1272 1273 if (v == SEQ_START_TOKEN) 1274 seq_puts(seq, ··· 1280 seq_printf(seq, 1281 "%3.3X %-10s %-9s %05d ", 1282 rose_route->lci1, 1283 - rose2asc(&rose_route->src_addr), 1284 ax2asc(buf, &rose_route->src_call), 1285 rose_route->neigh1->number); 1286 else ··· 1290 if (rose_route->neigh2) 1291 seq_printf(seq, 1292 "%3.3X %-10s %-9s %05d\n", 1293 - rose_route->lci2, 1294 - rose2asc(&rose_route->dest_addr), 1295 - ax2asc(buf, &rose_route->dest_call), 1296 - rose_route->neigh2->number); 1297 else 1298 seq_puts(seq, 1299 "000 * * 00000\n");
··· 1104 1105 static int rose_node_show(struct seq_file *seq, void *v) 1106 { 1107 + char rsbuf[11]; 1108 int i; 1109 1110 if (v == SEQ_START_TOKEN) ··· 1112 const struct rose_node *rose_node = v; 1113 /* if (rose_node->loopback) { 1114 seq_printf(seq, "%-10s %04d 1 loopback\n", 1115 + rose2asc(rsbuf, &rose_node->address), 1116 + rose_node->mask); 1117 } else { */ 1118 seq_printf(seq, "%-10s %04d %d", 1119 + rose2asc(rsbuf, &rose_node->address), 1120 + rose_node->mask, 1121 + rose_node->count); 1122 1123 for (i = 0; i < rose_node->count; i++) 1124 seq_printf(seq, " %05d", ··· 1267 1268 static int rose_route_show(struct seq_file *seq, void *v) 1269 { 1270 + char buf[11], rsbuf[11]; 1271 1272 if (v == SEQ_START_TOKEN) 1273 seq_puts(seq, ··· 1279 seq_printf(seq, 1280 "%3.3X %-10s %-9s %05d ", 1281 rose_route->lci1, 1282 + rose2asc(rsbuf, &rose_route->src_addr), 1283 ax2asc(buf, &rose_route->src_call), 1284 rose_route->neigh1->number); 1285 else ··· 1289 if (rose_route->neigh2) 1290 seq_printf(seq, 1291 "%3.3X %-10s %-9s %05d\n", 1292 + rose_route->lci2, 1293 + rose2asc(rsbuf, &rose_route->dest_addr), 1294 + ax2asc(buf, &rose_route->dest_call), 1295 + rose_route->neigh2->number); 1296 else 1297 seq_puts(seq, 1298 "000 * * 00000\n");
+3 -2
net/wireless/nl80211.c
··· 997 998 if (IS_ERR(hdr)) { 999 err = PTR_ERR(hdr); 1000 - goto out; 1001 } 1002 1003 cookie.msg = msg; ··· 1011 &cookie, get_key_callback); 1012 1013 if (err) 1014 - goto out; 1015 1016 if (cookie.error) 1017 goto nla_put_failure; ··· 1022 1023 nla_put_failure: 1024 err = -ENOBUFS; 1025 nlmsg_free(msg); 1026 out: 1027 cfg80211_put_dev(drv);
··· 997 998 if (IS_ERR(hdr)) { 999 err = PTR_ERR(hdr); 1000 + goto free_msg; 1001 } 1002 1003 cookie.msg = msg; ··· 1011 &cookie, get_key_callback); 1012 1013 if (err) 1014 + goto free_msg; 1015 1016 if (cookie.error) 1017 goto nla_put_failure; ··· 1022 1023 nla_put_failure: 1024 err = -ENOBUFS; 1025 + free_msg: 1026 nlmsg_free(msg); 1027 out: 1028 cfg80211_put_dev(drv);
+1 -2
net/wireless/scan.c
··· 35 else 36 nl80211_send_scan_done(wiphy_to_dev(request->wiphy), dev); 37 38 - wiphy_to_dev(request->wiphy)->scan_req = NULL; 39 - 40 #ifdef CONFIG_WIRELESS_EXT 41 if (!aborted) { 42 memset(&wrqu, 0, sizeof(wrqu)); ··· 46 dev_put(dev); 47 48 out: 49 kfree(request); 50 } 51 EXPORT_SYMBOL(cfg80211_scan_done);
··· 35 else 36 nl80211_send_scan_done(wiphy_to_dev(request->wiphy), dev); 37 38 #ifdef CONFIG_WIRELESS_EXT 39 if (!aborted) { 40 memset(&wrqu, 0, sizeof(wrqu)); ··· 48 dev_put(dev); 49 50 out: 51 + wiphy_to_dev(request->wiphy)->scan_req = NULL; 52 kfree(request); 53 } 54 EXPORT_SYMBOL(cfg80211_scan_done);