Skip to content

Commit 5983fe2

Browse files
committed
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (73 commits) netfilter: Remove ADVANCED dependency from NF_CONNTRACK_NETBIOS_NS ipv4: flush route cache after change accept_local sch_red: fix red_change Revert "udp: remove redundant variable" bridge: master device stuck in no-carrier state forever when in user-stp mode ipv4: Perform peer validation on cached route lookup. net/core: fix rollback handler in register_netdevice_notifier sch_red: fix red_calc_qavg_from_idle_time bonding: only use primary address for ARP ipv4: fix lockdep splat in rt_cache_seq_show sch_teql: fix lockdep splat net: fec: Select the FEC driver by default for i.MX SoCs isdn: avoid copying too long drvid isdn: make sure strings are null terminated netlabel: Fix build problems when IPv6 is not enabled sctp: better integer overflow check in sctp_auth_create_key() sctp: integer overflow in sctp_auth_create_key() ipv6: Set mcast_hops to IPV6_DEFAULT_MCASTHOPS when -1 was given. net: Fix corruption in /proc/*/net/dev_mcast mac80211: fix race between the AGG SM and the Tx data path ...
2 parents 5611cc4 + 3ced1be commit 5983fe2

77 files changed

Lines changed: 589 additions & 280 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎drivers/isdn/divert/divert_procfs.c‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,12 @@ static int isdn_divert_ioctl_unlocked(struct file *file, uint cmd, ulong arg)
242242
case IIOCDOCFINT:
243243
if (!divert_if.drv_to_name(dioctl.cf_ctrl.drvid))
244244
return (-EINVAL); /* invalid driver */
245+
if (strnlen(dioctl.cf_ctrl.msn, sizeof(dioctl.cf_ctrl.msn)) ==
246+
sizeof(dioctl.cf_ctrl.msn))
247+
return -EINVAL;
248+
if (strnlen(dioctl.cf_ctrl.fwd_nr, sizeof(dioctl.cf_ctrl.fwd_nr)) ==
249+
sizeof(dioctl.cf_ctrl.fwd_nr))
250+
return -EINVAL;
245251
if ((i = cf_command(dioctl.cf_ctrl.drvid,
246252
(cmd == IIOCDOCFACT) ? 1 : (cmd == IIOCDOCFDIS) ? 0 : 2,
247253
dioctl.cf_ctrl.cfproc,

‎drivers/isdn/i4l/isdn_net.c‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2756,6 +2756,9 @@ isdn_net_setcfg(isdn_net_ioctl_cfg * cfg)
27562756
char *c,
27572757
*e;
27582758

2759+
if (strnlen(cfg->drvid, sizeof(cfg->drvid)) ==
2760+
sizeof(cfg->drvid))
2761+
return -EINVAL;
27592762
drvidx = -1;
27602763
chidx = -1;
27612764
strcpy(drvid, cfg->drvid);

‎drivers/net/arcnet/Kconfig‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
menuconfig ARCNET
66
depends on NETDEVICES && (ISA || PCI || PCMCIA)
7-
bool "ARCnet support"
7+
tristate "ARCnet support"
88
---help---
99
If you have a network card of this type, say Y and check out the
1010
(arguably) beautiful poetry in

‎drivers/net/bonding/bond_main.c‎

Lines changed: 6 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2553,30 +2553,6 @@ void bond_mii_monitor(struct work_struct *work)
25532553
}
25542554
}
25552555

2556-
static __be32 bond_glean_dev_ip(struct net_device *dev)
2557-
{
2558-
struct in_device *idev;
2559-
struct in_ifaddr *ifa;
2560-
__be32 addr = 0;
2561-
2562-
if (!dev)
2563-
return 0;
2564-
2565-
rcu_read_lock();
2566-
idev = __in_dev_get_rcu(dev);
2567-
if (!idev)
2568-
goto out;
2569-
2570-
ifa = idev->ifa_list;
2571-
if (!ifa)
2572-
goto out;
2573-
2574-
addr = ifa->ifa_local;
2575-
out:
2576-
rcu_read_unlock();
2577-
return addr;
2578-
}
2579-
25802556
static int bond_has_this_ip(struct bonding *bond, __be32 ip)
25812557
{
25822558
struct vlan_entry *vlan;
@@ -3322,14 +3298,18 @@ static int bond_inetaddr_event(struct notifier_block *this, unsigned long event,
33223298
struct bonding *bond;
33233299
struct vlan_entry *vlan;
33243300

3301+
/* we only care about primary address */
3302+
if(ifa->ifa_flags & IFA_F_SECONDARY)
3303+
return NOTIFY_DONE;
3304+
33253305
list_for_each_entry(bond, &bn->dev_list, bond_list) {
33263306
if (bond->dev == event_dev) {
33273307
switch (event) {
33283308
case NETDEV_UP:
33293309
bond->master_ip = ifa->ifa_local;
33303310
return NOTIFY_OK;
33313311
case NETDEV_DOWN:
3332-
bond->master_ip = bond_glean_dev_ip(bond->dev);
3312+
bond->master_ip = 0;
33333313
return NOTIFY_OK;
33343314
default:
33353315
return NOTIFY_DONE;
@@ -3345,8 +3325,7 @@ static int bond_inetaddr_event(struct notifier_block *this, unsigned long event,
33453325
vlan->vlan_ip = ifa->ifa_local;
33463326
return NOTIFY_OK;
33473327
case NETDEV_DOWN:
3348-
vlan->vlan_ip =
3349-
bond_glean_dev_ip(vlan_dev);
3328+
vlan->vlan_ip = 0;
33503329
return NOTIFY_OK;
33513330
default:
33523331
return NOTIFY_DONE;

‎drivers/net/can/sja1000/peak_pci.c‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
*/
2121

2222
#include <linux/kernel.h>
23-
#include <linux/version.h>
2423
#include <linux/module.h>
2524
#include <linux/interrupt.h>
2625
#include <linux/netdevice.h>

‎drivers/net/ethernet/broadcom/b44.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,7 @@ static void b44_tx(struct b44 *bp)
608608
skb->len,
609609
DMA_TO_DEVICE);
610610
rp->skb = NULL;
611-
dev_kfree_skb(skb);
611+
dev_kfree_skb_irq(skb);
612612
}
613613

614614
bp->tx_cons = cons;

‎drivers/net/ethernet/broadcom/bnx2x/bnx2x_link.c‎

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10327,6 +10327,43 @@ static int bnx2x_54618se_config_init(struct bnx2x_phy *phy,
1032710327
return 0;
1032810328
}
1032910329

10330+
10331+
static void bnx2x_5461x_set_link_led(struct bnx2x_phy *phy,
10332+
struct link_params *params, u8 mode)
10333+
{
10334+
struct bnx2x *bp = params->bp;
10335+
u16 temp;
10336+
10337+
bnx2x_cl22_write(bp, phy,
10338+
MDIO_REG_GPHY_SHADOW,
10339+
MDIO_REG_GPHY_SHADOW_LED_SEL1);
10340+
bnx2x_cl22_read(bp, phy,
10341+
MDIO_REG_GPHY_SHADOW,
10342+
&temp);
10343+
temp &= 0xff00;
10344+
10345+
DP(NETIF_MSG_LINK, "54618x set link led (mode=%x)\n", mode);
10346+
switch (mode) {
10347+
case LED_MODE_FRONT_PANEL_OFF:
10348+
case LED_MODE_OFF:
10349+
temp |= 0x00ee;
10350+
break;
10351+
case LED_MODE_OPER:
10352+
temp |= 0x0001;
10353+
break;
10354+
case LED_MODE_ON:
10355+
temp |= 0x00ff;
10356+
break;
10357+
default:
10358+
break;
10359+
}
10360+
bnx2x_cl22_write(bp, phy,
10361+
MDIO_REG_GPHY_SHADOW,
10362+
MDIO_REG_GPHY_SHADOW_WR_ENA | temp);
10363+
return;
10364+
}
10365+
10366+
1033010367
static void bnx2x_54618se_link_reset(struct bnx2x_phy *phy,
1033110368
struct link_params *params)
1033210369
{
@@ -11103,7 +11140,7 @@ static struct bnx2x_phy phy_54618se = {
1110311140
.config_loopback = (config_loopback_t)bnx2x_54618se_config_loopback,
1110411141
.format_fw_ver = (format_fw_ver_t)NULL,
1110511142
.hw_reset = (hw_reset_t)NULL,
11106-
.set_link_led = (set_link_led_t)NULL,
11143+
.set_link_led = (set_link_led_t)bnx2x_5461x_set_link_led,
1110711144
.phy_specific_func = (phy_specific_func_t)NULL
1110811145
};
1110911146
/*****************************************************************/

‎drivers/net/ethernet/broadcom/bnx2x/bnx2x_reg.h‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6990,6 +6990,7 @@ Theotherbitsarereservedandshouldbezero*/
69906990
#define MDIO_REG_INTR_MASK 0x1b
69916991
#define MDIO_REG_INTR_MASK_LINK_STATUS (0x1 << 1)
69926992
#define MDIO_REG_GPHY_SHADOW 0x1c
6993+
#define MDIO_REG_GPHY_SHADOW_LED_SEL1 (0x0d << 10)
69936994
#define MDIO_REG_GPHY_SHADOW_LED_SEL2 (0x0e << 10)
69946995
#define MDIO_REG_GPHY_SHADOW_WR_ENA (0x1 << 15)
69956996
#define MDIO_REG_GPHY_SHADOW_AUTO_DET_MED (0x1e << 10)

‎drivers/net/ethernet/davicom/dm9000.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -613,7 +613,7 @@ static int dm9000_set_wol(struct net_device *dev, struct ethtool_wolinfo *w)
613613

614614
if (!dm->wake_state)
615615
irq_set_irq_wake(dm->irq_wake, 1);
616-
else if (dm->wake_state & !opts)
616+
else if (dm->wake_state && !opts)
617617
irq_set_irq_wake(dm->irq_wake, 0);
618618
}
619619

‎drivers/net/ethernet/freescale/Kconfig‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ config FEC
2424
bool "FEC ethernet controller (of ColdFire and some i.MX CPUs)"
2525
depends on (M523x || M527x || M5272 || M528x || M520x || M532x || \
2626
ARCH_MXC || ARCH_MXS)
27+
default ARCH_MXC || ARCH_MXS if ARM
2728
select PHYLIB
2829
---help---
2930
Say Y here if you want to use the built-in 10/100 Fast ethernet

0 commit comments

Comments
 (0)