* [PATCH 2.6.35-rc1] net: vmxnet3 fixes [2/5] Interrupt control bitmap
From: Shreyas Bhatewara @ 2010-07-07 9:24 UTC (permalink / raw)
To: netdev; +Cc: linux-kernel, pv-drivers, ronghua
In-Reply-To: <alpine.LRH.2.00.1007070125440.4652@localhost.localdomain>
A new bit map 'intrCtrl' is introduced in the DriverShared area. The driver
should update VMXNET3_IC_DISABLE_ALL bit before writing IMR.
Signed-off-by: Ronghua Zang <ronghua@vmware.com>
Signed-off-by: Shreyas Bhatewara <sbhatewara@vmware.com>
---
diff --git a/drivers/net/vmxnet3/vmxnet3_defs.h b/drivers/net/vmxnet3/vmxnet3_defs.h
index b4889e6..ca7727b 100644
--- a/drivers/net/vmxnet3/vmxnet3_defs.h
+++ b/drivers/net/vmxnet3/vmxnet3_defs.h
@@ -464,6 +464,9 @@ enum vmxnet3_intr_type {
/* addition 1 for events */
#define VMXNET3_MAX_INTRS 25
+/* value of intrCtrl */
+#define VMXNET3_IC_DISABLE_ALL 0x1 /* bit 0 */
+
struct Vmxnet3_IntrConf {
bool autoMask;
@@ -471,7 +474,8 @@ struct Vmxnet3_IntrConf {
u8 eventIntrIdx;
u8 modLevels[VMXNET3_MAX_INTRS]; /* moderation level for
* each intr */
- __le32 reserved[3];
+ __le32 intrCtrl;
+ __le32 reserved[2];
};
/* one bit per VLAN ID, the size is in the units of u32 */
diff --git a/drivers/net/vmxnet3/vmxnet3_drv.c b/drivers/net/vmxnet3/vmxnet3_drv.c
index 1b2d467..29db294 100644
--- a/drivers/net/vmxnet3/vmxnet3_drv.c
+++ b/drivers/net/vmxnet3/vmxnet3_drv.c
@@ -72,6 +72,7 @@ vmxnet3_enable_all_intrs(struct vmxnet3_adapter *adapter)
for (i = 0; i < adapter->intr.num_intrs; i++)
vmxnet3_enable_intr(adapter, i);
+ adapter->shared->devRead.intrConf.intrCtrl &= ~VMXNET3_IC_DISABLE_ALL;
}
@@ -80,6 +81,7 @@ vmxnet3_disable_all_intrs(struct vmxnet3_adapter *adapter)
{
int i;
+ adapter->shared->devRead.intrConf.intrCtrl |= VMXNET3_IC_DISABLE_ALL;
for (i = 0; i < adapter->intr.num_intrs; i++)
vmxnet3_disable_intr(adapter, i);
}
@@ -1880,6 +1882,7 @@ vmxnet3_setup_driver_shared(struct vmxnet3_adapter *adapter)
devRead->intrConf.modLevels[i] = adapter->intr.mod_levels[i];
devRead->intrConf.eventIntrIdx = adapter->intr.event_intr_idx;
+ devRead->intrConf.intrCtrl |= VMXNET3_IC_DISABLE_ALL;
/* rx filter settings */
devRead->rxFilterConf.rxMode = 0;
diff --git a/drivers/net/vmxnet3/vmxnet3_int.h b/drivers/net/vmxnet3/vmxnet3_int.h
index 7985ba4..0ddfe3c 100644
--- a/drivers/net/vmxnet3/vmxnet3_int.h
+++ b/drivers/net/vmxnet3/vmxnet3_int.h
@@ -68,10 +68,10 @@
/*
* Version numbers
*/
-#define VMXNET3_DRIVER_VERSION_STRING "1.0.6.0-k"
+#define VMXNET3_DRIVER_VERSION_STRING "1.0.9.0-k"
/* a 32-bit int, each byte encode a verion number in VMXNET3_DRIVER_VERSION */
-#define VMXNET3_DRIVER_VERSION_NUM 0x01000600
+#define VMXNET3_DRIVER_VERSION_NUM 0x01000900
/*
^ permalink raw reply related
* [PATCH 2.6.35-rc1] net: vmxnet3 fixes [1/5] Spare skb to avoid starvation
From: Shreyas Bhatewara @ 2010-07-07 9:21 UTC (permalink / raw)
To: netdev; +Cc: pv-drivers
From: Shreyas Bhatewara <sbhatewara@vmware.com>
skb_alloc() failure can cause the recv ring to loose all packet reception.
Avoid this by introducing a spare buffer.
Signed-off-by: Michael Stolarchuk <stolarchuk@vmware.com>
Signed-off-by: Shreyas Bhatewara <sbhatewara@vmware.com>
---
diff --git a/drivers/net/vmxnet3/vmxnet3_drv.c b/drivers/net/vmxnet3/vmxnet3_drv.c
index 989b742..5a50d10 100644
--- a/drivers/net/vmxnet3/vmxnet3_drv.c
+++ b/drivers/net/vmxnet3/vmxnet3_drv.c
@@ -541,7 +541,12 @@ vmxnet3_rq_alloc_rx_buf(struct vmxnet3_rx_queue *rq, u32 ring_idx,
NET_IP_ALIGN);
if (unlikely(rbi->skb == NULL)) {
rq->stats.rx_buf_alloc_failure++;
- break;
+ /* starvation prevention */
+ if (vmxnet3_cmd_ring_desc_empty(
+ rq->rx_ring + ring_idx))
+ rbi->skb = rq->spare_skb;
+ else
+ break;
}
rbi->skb->dev = adapter->netdev;
@@ -611,6 +616,29 @@ vmxnet3_append_frag(struct sk_buff *skb, struct Vmxnet3_RxCompDesc *rcd,
}
+/*
+ * Free any pages which were attached to the frags of the spare skb. This can
+ * happen when the spare skb is attached to the rx ring to prevent starvation,
+ * but there was no issue with page allocation.
+ */
+
+static void
+vmxnet3_rx_spare_skb_free_frags(struct vmxnet3_adapter *adapter)
+{
+ struct sk_buff *skb = adapter->rx_queue.spare_skb;
+ int i;
+ for (i = 0; i < skb_shinfo(skb)->nr_frags; i++) {
+ struct skb_frag_struct *frag = &skb_shinfo(skb)->frags[i];
+ BUG_ON(frag->page != 0);
+ put_page(frag->page);
+ frag->page = 0;
+ frag->size = 0;
+ }
+ skb_shinfo(skb)->nr_frags = 0;
+ skb->data_len = 0;
+}
+
+
static void
vmxnet3_map_pkt(struct sk_buff *skb, struct vmxnet3_tx_ctx *ctx,
struct vmxnet3_tx_queue *tq, struct pci_dev *pdev,
@@ -1060,8 +1088,12 @@ vmxnet3_rx_error(struct vmxnet3_rx_queue *rq, struct Vmxnet3_RxCompDesc *rcd,
* ctx->skb may be NULL if this is the first and the only one
* desc for the pkt
*/
- if (ctx->skb)
- dev_kfree_skb_irq(ctx->skb);
+ if (ctx->skb) {
+ if (ctx->skb == rq->spare_skb)
+ vmxnet3_rx_spare_skb_free_frags(adapter);
+ else
+ dev_kfree_skb_irq(ctx->skb);
+ }
ctx->skb = NULL;
}
@@ -1159,6 +1191,12 @@ vmxnet3_rq_rx_complete(struct vmxnet3_rx_queue *rq,
skb = ctx->skb;
if (rcd->eop) {
+ if (skb == rq->spare_skb) {
+ rq->stats.drop_total++;
+ vmxnet3_rx_spare_skb_free_frags(adapter);
+ ctx->skb = NULL;
+ goto rcd_done;
+ }
skb->len += skb->data_len;
skb->truesize += skb->data_len;
@@ -1244,6 +1282,14 @@ vmxnet3_rq_cleanup(struct vmxnet3_rx_queue *rq,
rq->uncommitted[ring_idx] = 0;
}
+ /* free starvation prevention skb if allocated */
+ if (rq->spare_skb) {
+ vmxnet3_rx_spare_skb_free_frags(adapter);
+ dev_kfree_skb(rq->spare_skb);
+ rq->spare_skb = NULL;
+ }
+
+
rq->comp_ring.gen = VMXNET3_INIT_GEN;
rq->comp_ring.next2proc = 0;
}
@@ -1325,6 +1371,15 @@ vmxnet3_rq_init(struct vmxnet3_rx_queue *rq,
}
vmxnet3_rq_alloc_rx_buf(rq, 1, rq->rx_ring[1].size - 1, adapter);
+ /* allocate ring starvation protection */
+ rq->spare_skb = dev_alloc_skb(PAGE_SIZE);
+ if (rq->spare_skb == NULL) {
+ vmxnet3_rq_cleanup(rq, adapter);
+ return -ENOMEM;
+ }
+
+
+
/* reset the comp ring */
rq->comp_ring.next2proc = 0;
memset(rq->comp_ring.base, 0, rq->comp_ring.size *
diff --git a/drivers/net/vmxnet3/vmxnet3_int.h b/drivers/net/vmxnet3/vmxnet3_int.h
index 34f392f..7985ba4 100644
--- a/drivers/net/vmxnet3/vmxnet3_int.h
+++ b/drivers/net/vmxnet3/vmxnet3_int.h
@@ -68,10 +68,10 @@
/*
* Version numbers
*/
-#define VMXNET3_DRIVER_VERSION_STRING "1.0.5.0-k"
+#define VMXNET3_DRIVER_VERSION_STRING "1.0.6.0-k"
/* a 32-bit int, each byte encode a verion number in VMXNET3_DRIVER_VERSION */
-#define VMXNET3_DRIVER_VERSION_NUM 0x01000500
+#define VMXNET3_DRIVER_VERSION_NUM 0x01000600
/*
@@ -149,6 +149,13 @@ vmxnet3_cmd_ring_desc_avail(struct vmxnet3_cmd_ring *ring)
ring->next2comp - ring->next2fill - 1;
}
+static inline bool
+vmxnet3_cmd_ring_desc_empty(struct vmxnet3_cmd_ring *ring)
+{
+ return (ring->next2comp == ring->next2fill);
+}
+
+
struct vmxnet3_comp_ring {
union Vmxnet3_GenericDesc *base;
u32 size;
@@ -266,9 +273,10 @@ struct vmxnet3_rx_queue {
u32 qid2; /* rqID in RCD for buffer from 2nd ring */
u32 uncommitted[2]; /* # of buffers allocated since last RXPROD
* update */
- struct vmxnet3_rx_buf_info *buf_info[2];
- struct Vmxnet3_RxQueueCtrl *shared;
+ struct vmxnet3_rx_buf_info *buf_info[2];
+ struct Vmxnet3_RxQueueCtrl *shared;
struct vmxnet3_rq_driver_stats stats;
+ struct sk_buff *spare_skb; /* starvation skb */
} __attribute__((__aligned__(SMP_CACHE_BYTES)));
#define VMXNET3_LINUX_MAX_MSIX_VECT 1
^ permalink raw reply related
* [PATCH 2.6.35-rc1] net: vmxnet3 fixes [0/5]
From: Shreyas Bhatewara @ 2010-07-07 9:19 UTC (permalink / raw)
To: netdev; +Cc: linux-kernel, pv-drivers
This series of patches provide minor fixes to the vmxnet3 driver. Each
patch updates the driver version number. Let me know your comments /
feedback if any.
->Shreyas
^ permalink raw reply
* Re: Missing regression fix in 2.6.34.1
From: David Miller @ 2010-07-07 8:57 UTC (permalink / raw)
To: arno; +Cc: stable, brian.haley, netdev
In-Reply-To: <87lj9nkah1.fsf@small.ssi.corp>
I submitted this fix to Greg last night.
^ permalink raw reply
* [PATCH v3 9/9] usb/atm/ueagle-atm.c: call atm_dev_signal_change() when signal changes.
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Propagate signal changes to upper atm layer.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
drivers/usb/atm/ueagle-atm.c | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/drivers/usb/atm/ueagle-atm.c b/drivers/usb/atm/ueagle-atm.c
index e213d3f..ebae944 100644
--- a/drivers/usb/atm/ueagle-atm.c
+++ b/drivers/usb/atm/ueagle-atm.c
@@ -575,6 +575,13 @@ MODULE_PARM_DESC(annex,
sc->usbatm->atm_dev->type = val; \
} while (0)
+#define UPDATE_ATM_SIGNAL(val) \
+ do { \
+ if (sc->usbatm->atm_dev) \
+ atm_dev_signal_change(sc->usbatm->atm_dev, val); \
+ } while (0)
+
+
/* Firmware loading */
#define LOAD_INTERNAL 0xA0
#define F8051_USBCS 0x7f92
@@ -1359,7 +1366,7 @@ static int uea_stat_e1(struct uea_softc *sc)
/* always update it as atm layer could not be init when we switch to
* operational state
*/
- UPDATE_ATM_STAT(signal, ATM_PHY_SIG_FOUND);
+ UPDATE_ATM_SIGNAL(ATM_PHY_SIG_FOUND);
/* wake up processes waiting for synchronization */
wake_up(&sc->sync_q);
@@ -1498,7 +1505,7 @@ static int uea_stat_e4(struct uea_softc *sc)
/* always update it as atm layer could not be init when we switch to
* operational state
*/
- UPDATE_ATM_STAT(signal, ATM_PHY_SIG_FOUND);
+ UPDATE_ATM_SIGNAL(ATM_PHY_SIG_FOUND);
/* wake up processes waiting for synchronization */
wake_up(&sc->sync_q);
@@ -1825,7 +1832,7 @@ static int uea_start_reset(struct uea_softc *sc)
* So we will failed to wait Ready CMV.
*/
sc->cmv_ack = 0;
- UPDATE_ATM_STAT(signal, ATM_PHY_SIG_LOST);
+ UPDATE_ATM_SIGNAL(ATM_PHY_SIG_LOST);
/* reset statistics */
memset(&sc->stats, 0, sizeof(struct uea_stats));
--
1.7.1
^ permalink raw reply related
* [PATCH v3 8/9] usb/atm/speedtch.c: call atm_dev_signal_change() when signal changes.
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Propagate signal changes to upper atm layer.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
drivers/usb/atm/speedtch.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/usb/atm/speedtch.c b/drivers/usb/atm/speedtch.c
index 1335456..80f9617 100644
--- a/drivers/usb/atm/speedtch.c
+++ b/drivers/usb/atm/speedtch.c
@@ -525,7 +525,7 @@ static void speedtch_check_status(struct work_struct *work)
switch (status) {
case 0:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
if (instance->last_status)
atm_info(usbatm, "ADSL line is down\n");
/* It may never resync again unless we ask it to... */
@@ -533,12 +533,12 @@ static void speedtch_check_status(struct work_struct *work)
break;
case 0x08:
- atm_dev->signal = ATM_PHY_SIG_UNKNOWN;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_UNKNOWN);
atm_info(usbatm, "ADSL line is blocked?\n");
break;
case 0x10:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line is synchronising\n");
break;
@@ -554,7 +554,7 @@ static void speedtch_check_status(struct work_struct *work)
}
atm_dev->link_rate = down_speed * 1000 / 424;
- atm_dev->signal = ATM_PHY_SIG_FOUND;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_FOUND);
atm_info(usbatm,
"ADSL line is up (%d kb/s down | %d kb/s up)\n",
@@ -562,7 +562,7 @@ static void speedtch_check_status(struct work_struct *work)
break;
default:
- atm_dev->signal = ATM_PHY_SIG_UNKNOWN;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_UNKNOWN);
atm_info(usbatm, "unknown line state %02x\n", status);
break;
}
--
1.7.1
^ permalink raw reply related
* [PATCH v3 7/9] usb/atm/cxacru.c: call atm_dev_signal_change() when signal changes.
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Propagate signal changes to upper atm layer.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
drivers/usb/atm/cxacru.c | 18 +++++++++---------
1 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/drivers/usb/atm/cxacru.c b/drivers/usb/atm/cxacru.c
index c89990f..101ffc9 100644
--- a/drivers/usb/atm/cxacru.c
+++ b/drivers/usb/atm/cxacru.c
@@ -866,50 +866,50 @@ static void cxacru_poll_status(struct work_struct *work)
instance->line_status = buf[CXINF_LINE_STATUS];
switch (instance->line_status) {
case 0:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line: down\n");
break;
case 1:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line: attempting to activate\n");
break;
case 2:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line: training\n");
break;
case 3:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line: channel analysis\n");
break;
case 4:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line: exchange\n");
break;
case 5:
atm_dev->link_rate = buf[CXINF_DOWNSTREAM_RATE] * 1000 / 424;
- atm_dev->signal = ATM_PHY_SIG_FOUND;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_FOUND);
atm_info(usbatm, "ADSL line: up (%d kb/s down | %d kb/s up)\n",
buf[CXINF_DOWNSTREAM_RATE], buf[CXINF_UPSTREAM_RATE]);
break;
case 6:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line: waiting\n");
break;
case 7:
- atm_dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_LOST);
atm_info(usbatm, "ADSL line: initializing\n");
break;
default:
- atm_dev->signal = ATM_PHY_SIG_UNKNOWN;
+ atm_dev_signal_change(atm_dev, ATM_PHY_SIG_UNKNOWN);
atm_info(usbatm, "Unknown line state %02x\n", instance->line_status);
break;
}
--
1.7.1
^ permalink raw reply related
* [PATCH v3 6/9] atm/suni.c: call atm_dev_signal_change() when signal changes.
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Propagate changes to upper atm layer.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
drivers/atm/suni.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/atm/suni.c b/drivers/atm/suni.c
index da4b91f..41c56ea 100644
--- a/drivers/atm/suni.c
+++ b/drivers/atm/suni.c
@@ -291,8 +291,9 @@ static int suni_ioctl(struct atm_dev *dev,unsigned int cmd,void __user *arg)
static void poll_los(struct atm_dev *dev)
{
- dev->signal = GET(RSOP_SIS) & SUNI_RSOP_SIS_LOSV ? ATM_PHY_SIG_LOST :
- ATM_PHY_SIG_FOUND;
+ atm_dev_signal_change(dev,
+ GET(RSOP_SIS) & SUNI_RSOP_SIS_LOSV ?
+ ATM_PHY_SIG_LOST : ATM_PHY_SIG_FOUND);
}
--
1.7.1
^ permalink raw reply related
* [PATCH v3 5/9] atm/solos-pci: call atm_dev_signal_change() when signal changes.
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Propagate changes to upper atm layer, so userspace netmontor knows when DSL
showtime reached.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
drivers/atm/solos-pci.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/atm/solos-pci.c b/drivers/atm/solos-pci.c
index ded76c4..6174965 100644
--- a/drivers/atm/solos-pci.c
+++ b/drivers/atm/solos-pci.c
@@ -383,7 +383,7 @@ static int process_status(struct solos_card *card, int port, struct sk_buff *skb
/* Anything but 'Showtime' is down */
if (strcmp(state_str, "Showtime")) {
- card->atmdev[port]->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(card->atmdev[port], ATM_PHY_SIG_LOST);
release_vccs(card->atmdev[port]);
dev_info(&card->dev->dev, "Port %d: %s\n", port, state_str);
return 0;
@@ -401,7 +401,7 @@ static int process_status(struct solos_card *card, int port, struct sk_buff *skb
snr[0]?", SNR ":"", snr, attn[0]?", Attn ":"", attn);
card->atmdev[port]->link_rate = rate_down / 424;
- card->atmdev[port]->signal = ATM_PHY_SIG_FOUND;
+ atm_dev_signal_change(card->atmdev[port], ATM_PHY_SIG_FOUND);
return 0;
}
@@ -1246,7 +1246,7 @@ static int atm_init(struct solos_card *card)
card->atmdev[i]->ci_range.vci_bits = 16;
card->atmdev[i]->dev_data = card;
card->atmdev[i]->phy_data = (void *)(unsigned long)i;
- card->atmdev[i]->signal = ATM_PHY_SIG_UNKNOWN;
+ atm_dev_signal_change(card->atmdev[i], ATM_PHY_SIG_UNKNOWN);
skb = alloc_skb(sizeof(*header), GFP_ATOMIC);
if (!skb) {
--
1.7.1
^ permalink raw reply related
* [PATCH v3 4/9] atm/idt77105.c: call atm_dev_signal_change() when signal changes.
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Propagate changes to upper atm layer.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
drivers/atm/idt77105.c | 11 ++++++-----
1 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/drivers/atm/idt77105.c b/drivers/atm/idt77105.c
index dab5cf5..bca9cb8 100644
--- a/drivers/atm/idt77105.c
+++ b/drivers/atm/idt77105.c
@@ -126,7 +126,7 @@ static void idt77105_restart_timer_func(unsigned long dummy)
istat = GET(ISTAT); /* side effect: clears all interrupt status bits */
if (istat & IDT77105_ISTAT_GOODSIG) {
/* Found signal again */
- dev->signal = ATM_PHY_SIG_FOUND;
+ atm_dev_signal_change(dev, ATM_PHY_SIG_FOUND);
printk(KERN_NOTICE "%s(itf %d): signal detected again\n",
dev->type,dev->number);
/* flush the receive FIFO */
@@ -222,7 +222,7 @@ static void idt77105_int(struct atm_dev *dev)
/* Rx Signal Condition Change - line went up or down */
if (istat & IDT77105_ISTAT_GOODSIG) { /* signal detected again */
/* This should not happen (restart timer does it) but JIC */
- dev->signal = ATM_PHY_SIG_FOUND;
+ atm_dev_signal_change(dev, ATM_PHY_SIG_FOUND);
} else { /* signal lost */
/*
* Disable interrupts and stop all transmission and
@@ -235,7 +235,7 @@ static void idt77105_int(struct atm_dev *dev)
IDT77105_MCR_DRIC|
IDT77105_MCR_HALTTX
) & ~IDT77105_MCR_EIP, MCR);
- dev->signal = ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(dev, ATM_PHY_SIG_LOST);
printk(KERN_NOTICE "%s(itf %d): signal lost\n",
dev->type,dev->number);
}
@@ -272,8 +272,9 @@ static int idt77105_start(struct atm_dev *dev)
memset(&PRIV(dev)->stats,0,sizeof(struct idt77105_stats));
/* initialise dev->signal from Good Signal Bit */
- dev->signal = GET(ISTAT) & IDT77105_ISTAT_GOODSIG ? ATM_PHY_SIG_FOUND :
- ATM_PHY_SIG_LOST;
+ atm_dev_signal_change(dev,
+ GET(ISTAT) & IDT77105_ISTAT_GOODSIG ?
+ ATM_PHY_SIG_FOUND : ATM_PHY_SIG_LOST);
if (dev->signal == ATM_PHY_SIG_LOST)
printk(KERN_WARNING "%s(itf %d): no signal\n",dev->type,
dev->number);
--
1.7.1
^ permalink raw reply related
* [PATCH v3 3/9] atm/adummy: add syfs DEVICE_ATTR to change signal
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
drivers/atm/adummy.c | 39 +++++++++++++++++++++++++++++++++++++++
1 files changed, 39 insertions(+), 0 deletions(-)
diff --git a/drivers/atm/adummy.c b/drivers/atm/adummy.c
index 6d44f07..46b9476 100644
--- a/drivers/atm/adummy.c
+++ b/drivers/atm/adummy.c
@@ -40,6 +40,42 @@ struct adummy_dev {
static LIST_HEAD(adummy_devs);
+static ssize_t __set_signal(struct device *dev,
+ struct device_attribute *attr,
+ const char *buf, size_t len)
+{
+ struct atm_dev *atm_dev = container_of(dev, struct atm_dev, class_dev);
+ int signal;
+
+ if (sscanf(buf, "%d", &signal) == 1) {
+
+ if (signal < ATM_PHY_SIG_LOST || signal > ATM_PHY_SIG_FOUND)
+ signal = ATM_PHY_SIG_UNKNOWN;
+
+ atm_dev_signal_change(atm_dev, signal);
+ return 1;
+ }
+ return -EINVAL;
+}
+
+static ssize_t __show_signal(struct device *dev,
+ struct device_attribute *attr, char *buf)
+{
+ struct atm_dev *atm_dev = container_of(dev, struct atm_dev, class_dev);
+ return sprintf(buf, "%d\n", atm_dev->signal);
+}
+static DEVICE_ATTR(signal, 0644, __show_signal, __set_signal);
+
+static struct attribute *adummy_attrs[] = {
+ &dev_attr_signal.attr,
+ NULL
+};
+
+static struct attribute_group adummy_group_attrs = {
+ .name = NULL, /* We want them in dev's root folder */
+ .attrs = adummy_attrs
+};
+
static int __init
adummy_start(struct atm_dev *dev)
{
@@ -128,6 +164,9 @@ static int __init adummy_init(void)
adummy_dev->atm_dev = atm_dev;
atm_dev->dev_data = adummy_dev;
+ if (sysfs_create_group(&atm_dev->class_dev.kobj, &adummy_group_attrs))
+ dev_err(&atm_dev->class_dev, "Could not register attrs for adummy\n");
+
if (adummy_start(atm_dev)) {
printk(KERN_ERR DEV_LABEL ": adummy_start() failed\n");
err = -ENODEV;
--
1.7.1
^ permalink raw reply related
* [PATCH v3 2/9] atm/br2684: register notifier event for carrier signal changes.
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
When a signal change event occurs call netif_carrier_on/off.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
net/atm/br2684.c | 66 ++++++++++++++++++++++++++++++++++++++++++++++++++++-
1 files changed, 64 insertions(+), 2 deletions(-)
diff --git a/net/atm/br2684.c b/net/atm/br2684.c
index 6719af6..01a628d 100644
--- a/net/atm/br2684.c
+++ b/net/atm/br2684.c
@@ -139,6 +139,42 @@ static struct net_device *br2684_find_dev(const struct br2684_if_spec *s)
return NULL;
}
+static int atm_dev_event(struct notifier_block *this, unsigned long event,
+ void *arg)
+{
+ struct atm_dev *atm_dev = arg;
+ struct list_head *lh;
+ struct net_device *net_dev;
+ struct br2684_vcc *brvcc;
+ struct atm_vcc *atm_vcc;
+
+ pr_debug("event=%ld dev=%p\n", event, atm_dev);
+
+ read_lock_irq(&devs_lock);
+ list_for_each(lh, &br2684_devs) {
+ net_dev = list_entry_brdev(lh);
+
+ list_for_each_entry(brvcc, &BRPRIV(net_dev)->brvccs, brvccs) {
+ atm_vcc = brvcc->atmvcc;
+ if (atm_vcc && brvcc->atmvcc->dev == atm_dev) {
+
+ if (atm_vcc->dev->signal == ATM_PHY_SIG_LOST)
+ netif_carrier_off(net_dev);
+ else
+ netif_carrier_on(net_dev);
+
+ }
+ }
+ }
+ read_unlock_irq(&devs_lock);
+
+ return NOTIFY_DONE;
+}
+
+static struct notifier_block atm_dev_notifier = {
+ .notifier_call = atm_dev_event,
+};
+
/* chained vcc->pop function. Check if we should wake the netif_queue */
static void br2684_pop(struct atm_vcc *vcc, struct sk_buff *skb)
{
@@ -362,6 +398,12 @@ static void br2684_push(struct atm_vcc *atmvcc, struct sk_buff *skb)
unregister_netdev(net_dev);
free_netdev(net_dev);
}
+ read_lock_irq(&devs_lock);
+ if (list_empty(&br2684_devs)) {
+ /* last br2684 device */
+ unregister_atmdevice_notifier(&atm_dev_notifier);
+ }
+ read_unlock_irq(&devs_lock);
return;
}
@@ -530,6 +572,13 @@ static int br2684_regvcc(struct atm_vcc *atmvcc, void __user * arg)
br2684_push(atmvcc, skb);
}
+
+ /* initialize netdev carrier state */
+ if (atmvcc->dev->signal == ATM_PHY_SIG_LOST)
+ netif_carrier_off(net_dev);
+ else
+ netif_carrier_on(net_dev);
+
__module_get(THIS_MODULE);
return 0;
@@ -620,9 +669,16 @@ static int br2684_create(void __user *arg)
}
write_lock_irq(&devs_lock);
+
brdev->payload = payload;
- brdev->number = list_empty(&br2684_devs) ? 1 :
- BRPRIV(list_entry_brdev(br2684_devs.prev))->number + 1;
+
+ if (list_empty(&br2684_devs)) {
+ /* 1st br2684 device */
+ register_atmdevice_notifier(&atm_dev_notifier);
+ brdev->number = 1;
+ } else
+ brdev->number = BRPRIV(list_entry_brdev(br2684_devs.prev))->number + 1;
+
list_add_tail(&brdev->br2684_devs, &br2684_devs);
write_unlock_irq(&devs_lock);
return 0;
@@ -758,6 +814,7 @@ static int __init br2684_init(void)
return -ENOMEM;
#endif
register_atm_ioctl(&br2684_ioctl_ops);
+
return 0;
}
@@ -772,6 +829,11 @@ static void __exit br2684_exit(void)
remove_proc_entry("br2684", atm_proc_root);
#endif
+
+ /* if not already empty */
+ if (!list_empty(&br2684_devs))
+ unregister_atmdevice_notifier(&atm_dev_notifier);
+
while (!list_empty(&br2684_devs)) {
net_dev = list_entry_brdev(br2684_devs.next);
brdev = BRPRIV(net_dev);
--
1.7.1
^ permalink raw reply related
* [PATCH v3 1/9] atm: propagate signal changes via notifier
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
In-Reply-To: <1278492636-11094-1-git-send-email-karl@hiramoto.org>
Add notifier chain for changes in atm_dev.
Clients like br2684 will call register_atmdevice_notifier() to be notified of
changes. Drivers will call atm_dev_signal_change() to notify clients like
br2684 of the change.
On DSL and ATM devices it's usefull to have a know if you have a carrier
signal. netdevice LOWER_UP changes can be propagated to userspace via netlink
monitor.
Signed-off-by: Karl Hiramoto <karl@hiramoto.org>
---
include/linux/atmdev.h | 19 +++++++++++++++++++
net/atm/common.c | 30 ++++++++++++++++++++++++++++++
2 files changed, 49 insertions(+), 0 deletions(-)
diff --git a/include/linux/atmdev.h b/include/linux/atmdev.h
index 817b237..7c6dfd3 100644
--- a/include/linux/atmdev.h
+++ b/include/linux/atmdev.h
@@ -431,6 +431,15 @@ struct atm_dev *atm_dev_register(const char *type,const struct atmdev_ops *ops,
int number,unsigned long *flags); /* number == -1: pick first available */
struct atm_dev *atm_dev_lookup(int number);
void atm_dev_deregister(struct atm_dev *dev);
+
+/**
+* atm_dev_signal_change
+*
+* Propagate lower layer signal change in atm_dev->signal to netdevice.
+* The event will be sent via a notifier call chain.
+*/
+void atm_dev_signal_change(struct atm_dev *dev, char signal);
+
void vcc_insert_socket(struct sock *sk);
@@ -510,6 +519,16 @@ void register_atm_ioctl(struct atm_ioctl *);
*/
void deregister_atm_ioctl(struct atm_ioctl *);
+
+/**
+* register_atmdevice_notifier - register atm_dev notify events
+*
+* Clients like br2684 will register notify events
+* Currently we notify of signal found/lost
+*/
+int register_atmdevice_notifier(struct notifier_block *nb);
+void unregister_atmdevice_notifier(struct notifier_block *nb);
+
#endif /* __KERNEL__ */
#endif
diff --git a/net/atm/common.c b/net/atm/common.c
index b43feb1..940404a 100644
--- a/net/atm/common.c
+++ b/net/atm/common.c
@@ -37,6 +37,8 @@ EXPORT_SYMBOL(vcc_hash);
DEFINE_RWLOCK(vcc_sklist_lock);
EXPORT_SYMBOL(vcc_sklist_lock);
+static ATOMIC_NOTIFIER_HEAD(atm_dev_notify_chain);
+
static void __vcc_insert_socket(struct sock *sk)
{
struct atm_vcc *vcc = atm_sk(sk);
@@ -212,6 +214,22 @@ void vcc_release_async(struct atm_vcc *vcc, int reply)
}
EXPORT_SYMBOL(vcc_release_async);
+void atm_dev_signal_change(struct atm_dev *dev, char signal)
+{
+ pr_debug("%s signal=%d dev=%p number=%d dev->signal=%d\n",
+ __func__, signal, dev, dev->number, dev->signal);
+
+ /* atm driver sending invalid signal */
+ WARN_ON(signal < ATM_PHY_SIG_LOST || signal > ATM_PHY_SIG_FOUND);
+
+ if (dev->signal == signal)
+ return; /* no change */
+
+ dev->signal = signal;
+
+ atomic_notifier_call_chain(&atm_dev_notify_chain, signal, dev);
+}
+EXPORT_SYMBOL(atm_dev_signal_change);
void atm_dev_release_vccs(struct atm_dev *dev)
{
@@ -781,6 +799,18 @@ int vcc_getsockopt(struct socket *sock, int level, int optname,
return vcc->dev->ops->getsockopt(vcc, level, optname, optval, len);
}
+int register_atmdevice_notifier(struct notifier_block *nb)
+{
+ return atomic_notifier_chain_register(&atm_dev_notify_chain, nb);
+}
+EXPORT_SYMBOL_GPL(register_atmdevice_notifier);
+
+void unregister_atmdevice_notifier(struct notifier_block *nb)
+{
+ atomic_notifier_chain_unregister(&atm_dev_notify_chain, nb);
+}
+EXPORT_SYMBOL_GPL(unregister_atmdevice_notifier);
+
static int __init atm_init(void)
{
int error;
--
1.7.1
^ permalink raw reply related
* [PATCH v3 0/9] atm: propagate atm_dev signal carrier to LOWER_UP of netdevice
From: Karl Hiramoto @ 2010-07-07 8:50 UTC (permalink / raw)
To: linux-atm-general, netdev, chas; +Cc: Karl Hiramoto
Changes from v2:
* use atomic instead of blocking notifier
* use read_lock_irq() instead of read_lock() in atm/br2684
* clean up comments
* remove unused variable. I feel really bad about missing that last time.
Changes from v1:
Use atm_dev notifier chain instead of callback function pointer in struct vcc.
In drivers/usb/atm call atm_dev_signal_change().
In userspace it's helpful to know if a network device has a carrier signal.
Often it is monitored via netlink. This patchset allows a way for the
struct atm_dev drivers to pass carrier on/off to the netdevice.
For DSL, carrier is on when the line has reached showtime state.
Currently this patchset only propagates the changes to br2684 vccs,
as this is the only type of hardware I have to test.
If you prefer git you can pull from:
git://github.com/karlhiramoto/linux-2.6.git atm-v3
Karl Hiramoto (9):
atm: propagate signal changes via notifier
atm/br2684: register notifier event for carrier signal changes.
atm/adummy: add syfs DEVICE_ATTR to change signal
atm/idt77105.c: call atm_dev_signal_change() when signal changes.
atm/solos-pci: call atm_dev_signal_change() when signal changes.
atm/suni.c: call atm_dev_signal_change() when signal changes.
usb/atm/cxacru.c: call atm_dev_signal_change() when signal changes.
usb/atm/speedtch.c: call atm_dev_signal_change() when signal changes.
usb/atm/ueagle-atm.c: call atm_dev_signal_change() when signal
changes.
drivers/atm/adummy.c | 39 ++++++++++++++++++++++++
drivers/atm/idt77105.c | 11 ++++---
drivers/atm/solos-pci.c | 6 ++--
drivers/atm/suni.c | 5 ++-
drivers/usb/atm/cxacru.c | 18 ++++++------
drivers/usb/atm/speedtch.c | 10 +++---
drivers/usb/atm/ueagle-atm.c | 13 ++++++--
include/linux/atmdev.h | 19 ++++++++++++
net/atm/br2684.c | 66 ++++++++++++++++++++++++++++++++++++++++-
net/atm/common.c | 30 +++++++++++++++++++
10 files changed, 188 insertions(+), 29 deletions(-)
^ permalink raw reply
* Re: [PATCH v2 1/9] atm: propagate signal changes via notifier
From: Karl Hiramoto @ 2010-07-07 7:40 UTC (permalink / raw)
To: chas williams - CONTRACTOR; +Cc: linux-atm-general, netdev
In-Reply-To: <20100706154158.542551c7@thirdoffive.cmf.nrl.navy.mil>
On 07/06/2010 09:41 PM, chas williams - CONTRACTOR wrote:
> On Mon, 5 Jul 2010 10:45:53 +0200
> Karl Hiramoto<karl@hiramoto.org> wrote:
>
>> +void atm_dev_signal_change(struct atm_dev *dev, char signal)
>> +{
>> + int i;
>> + pr_debug("%s signal=%d dev=%p number=%d dev->signal=%d\n",
>> + __func__, signal, dev, dev->number, dev->signal);
>> +
>> + /* atm driver sending invalid signal */
>> + WARN_ON(signal< ATM_PHY_SIG_LOST || signal>
>> ATM_PHY_SIG_FOUND); +
>> + if (dev->signal == signal)
>> + return; /* no change */
>> +
>> + dev->signal = signal;
>> +
>> + &atm_dev_notify_chain, signal,
>> dev); +}
> i am not sure that you can use blocking_notifier_call_chain() here.
> atm_dev_signal_change() might be called from an interrupt context in
> some of the drivers.
>
> this implies that the notifier functions themselves must also not block.
> so in br2684 you probably want to use read_lock_irq() instead of just
> read_lock()
Chas,
I'll change to an atomic notifier, fix these issues, your other comments and send a new version of the patchset.
Thanks.
--
Karl
^ permalink raw reply
* Missing regression fix in 2.6.34.1
From: Arnaud Ebalard @ 2010-07-07 7:38 UTC (permalink / raw)
To: stable; +Cc: David Miller, brian.haley, netdev
Hi,
A regression was introduced after 2.6.34-rc5 (by f4f914b5: net: ipv6
bind to device issue) which breaks Mobile IPv6 support.
It has been noticed after 2.6.34 release and reported on netdev (see
http://thread.gmane.org/gmane.linux.network/162165).
A fix has been pushed upstream (commit 6057fd78 in linus tree) and David
queued it for stable but the fix is not in 2.6.34.1. I think the problem
is just a missing CC: stable@ in David's email.
Can you include it (6057fd78) in next round of stable patches for 2.6.34
(i.e. .2)?
Cheers,
a+
^ permalink raw reply
* Re: [PATCH 4/4] phylib: Allow reading and writing a mii bus from atomic context.
From: Richard Cochran @ 2010-07-07 7:18 UTC (permalink / raw)
To: Andy Fleming; +Cc: netdev
In-Reply-To: <AANLkTikEF3B-0JGvqosY5jMaChbpYctOmKW1jJKOWsQE@mail.gmail.com>
On Tue, Jul 06, 2010 at 12:09:10PM -0500, Andy Fleming wrote:
> allowed in interrupt context. *Certainly*, once you *do* allow MII
> transactions in interrupt context, you *cannot* use spin_lock(). You
> at least have to use spin_lock_irq[save].
Okay, I see. Before the change to mutexes the code used spin_lock_bh.
> Also, I agree with David's comments, and Grant's. There's got to be
> another way to do this.
I understand what troubles you about the proposed changes. However, I
cannot see a better way to get a PHY time stamp other than to read it
out during the napi poll and hard_xmit functions. It is a chicken and
egg problem.
Consider the receive path:
1. PTP Packet passed through PHY. PHY recognizes it and stores a time
stamp along with some UID from the packet.
2. Napi calls the MAC driver's poll function.
3. MAC driver acquires packet. At this point, if we want to have a
hardware time stamp, we must read it out over the mdio bus, before
handing the packet over to the stack via netif_receive_skb().
If we decide to defer the packet delivery (in step 3), we have to know
whether the PHY will have a time stamp for this packet. The only way
to do this is to compare the UIDs, but that requires reading it over
the mdio bus.
One could simply defer *all* packets, but that would really stink.
Possibly, we could defer all likely packets, for example all PTP
packets. Changing all the MAC driver to call a time stamping hook that
conditionally consumes the skbuffs would also stink. Could the packet
be deferred by the stack, early in netif_receive_skb? If so, a work
queue could read the PHY and then deliver the deferred packets at some
later time.
IMHO, it better just to check for a PHY time stamp immediately, and
live with the performance hit. I believe that PTP users will accept
this. Naturally, it requires allowing reading the mdio bus in two
non-sleeping contexts.
There are perhaps other ways to provide PHY time stamps, but I am
doubtful that they would work better, in general. The National
Semiconductor PHYTER can provide the time stamps as status frames, and
it can also insert time stamps directly into the incoming and
outgoing frames.
* Using status frames is an attractive idea, because it obviates the
need to read over the mdio bus. However, you still have the problem
of matching the status frames to the PTP packets.
* Inserting a time stamp into outgoing frames presents no problems
(this is the so called "PTP one step" operation). However, for
incoming frames the PHYTER inserts the time stamp into the PTP
message at a programmable offset. This invalidates the UDP checksum
for PTPv1 packets (PTPv2 checksums will be automatically corrected.)
Even if we implement one of these alternatives, I am not sure that
other PHYs will also offer the same capabilities as the PHYTER.
Well, there you have it. I welcome any ideas on how to go about
offering PHY time stamping.
Thanks,
Richard
^ permalink raw reply
* Re: [patch v2.3 3/4] IPVS: make FTP work with full NAT support
From: Simon Horman @ 2010-07-07 6:53 UTC (permalink / raw)
To: Patrick McHardy
Cc: lvs-devel, netdev, linux-kernel, netfilter, netfilter-devel,
Malcolm Turnbull, Wensong Zhang, Julius Volz, David S. Miller,
Hannes Eder
In-Reply-To: <4C3316F0.2030807@trash.net>
On Tue, Jul 06, 2010 at 01:43:44PM +0200, Patrick McHardy wrote:
> Simon Horman wrote:
> >@@ -219,19 +358,23 @@ static int ip_vs_ftp_out(struct ip_vs_ap
> > buf_len = strlen(buf);
> >+ ct = nf_ct_get(skb, &ctinfo);
> >+ ret = nf_nat_mangle_tcp_packet(skb,
> >+ ct,
> >+ ctinfo,
> >+ start-data,
> >+ end-start,
> >+ buf,
> >+ buf_len);
> >+
> >+ if (ct && ct != &nf_conntrack_untracked)
> This does not make sense, you're already using the conntrack above
> in the call to nf_nat_mangle_tcp_packet(), so the check should
> probably happen before that. You also should be checking the
> return value of nf_nat_mangle_tcp_packet() before setting up the
> expectation.
>
> >+ ip_vs_expect_related(skb, ct, n_cp,
> >+ IPPROTO_TCP, NULL, 0);
Good point. Is this better?
ct = nf_ct_get(skb, &ctinfo);
if (ct && !nf_ct_is_untracked()) {
ret = nf_nat_mangle_tcp_packet(skb, ct, ctinfo,
start-data, end-start,
buf, buf_len);
if (ret)
ip_vs_expect_related(skb, ct, n_cp,
IPPROTO_TCP, NULL, 0);
}
^ permalink raw reply
* Re: Report for 2.6.35-rc3-00262-g984bc96
From: Nico Schottelius @ 2010-07-07 6:25 UTC (permalink / raw)
To: Andrew Morton
Cc: Nico Schottelius, LKML, Rafael J. Wysocki, Maciej Rutecki,
dri-devel, netdev
In-Reply-To: <20100706194222.fcf16e13.akpm@linux-foundation.org>
[-- Attachment #1: Type: text/plain, Size: 855 bytes --]
Andrew Morton [Tue, Jul 06, 2010 at 07:42:22PM -0700]:
> On Thu, 1 Jul 2010 09:40:52 +0200 Nico Schottelius <nico-linux-2010-07-01@schottelius.org> wrote:
>
> > Good morning!
> >
> > A short report on what's broken in 2.6.35-rc3-00262-g984bc96 with
> > the Lenovo X201:
>
> So you see two post-2.6.34 regressions?
I'm not 100% sure whether the netdev issue was not already part of 2.6.34.
Just changed to 2.6.35-rc4, but noticed another issue on 2.6.35-rc3-00262-g984bc96:
After several (>=3) resumes, the system completly freezes. Used to happen with
2.6.33 very often (always?), vanished with 2.6.34-something
Cheers,
Nico
--
New PGP key: 7ED9 F7D3 6B10 81D7 0EC5 5C09 D7DC C8E4 3187 7DF0
Please resign, if you signed 9885188C or 8D0E27A4.
Currently moving *.schottelius.org to http://www.nico.schottelius.org/ ...
[-- Attachment #2: Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply
* linux-next: build warning after merge of the net tree
From: Stephen Rothwell @ 2010-07-07 4:30 UTC (permalink / raw)
To: David Miller, netdev; +Cc: linux-next, linux-kernel, Jonas Bonn
[-- Attachment #1: Type: text/plain, Size: 475 bytes --]
Hi Dave,
After merging the net tree, today's linux-next build (x86_64
allmodconfig) produced this warning:
drivers/net/ethoc.c: In function 'ethoc_init_ring':
drivers/net/ethoc.c:302: warning: assignment makes integer from pointer without a cast
Introduced by commit f8555ad0cfb0ba6cbc8729f337341fb11c82db89 ("ethoc:
Write bus addresses to registers").
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/
[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]
^ permalink raw reply
* Re: Report for 2.6.35-rc3-00262-g984bc96
From: Andrew Morton @ 2010-07-07 2:42 UTC (permalink / raw)
To: Nico Schottelius
Cc: Rafael J. Wysocki, netdev, LKML, dri-devel, Maciej Rutecki
In-Reply-To: <20100701074052.GA3501@schottelius.org>
On Thu, 1 Jul 2010 09:40:52 +0200 Nico Schottelius <nico-linux-2010-07-01@schottelius.org> wrote:
> Good morning!
>
> A short report on what's broken in 2.6.35-rc3-00262-g984bc96 with
> the Lenovo X201:
So you see two post-2.6.34 regressions?
> == xrandr ==
>
> After using xrandr several times in xorg, the screen gets
> "fancy": blue/white/black changing patterns.
> Getting even more weired when changing to a conosle.
>
> The only thing that keeps on working is the mouse cursor
> in xorg. This did not happen with 2.6.34-rcsomething, neither
> with 2.6.33 iirc.
>
> This is a Intel Corporation Core Processor Integrated Graphics Controller (rev 02),
> attached xorg.log.
(cc dri-devel)
> == netlink/carrier messag ==
>
> dhcpcd does not get updated when the link is established,
> need to restart it.
(cc netdev)
> == suspend/resume (to ram) ==
>
> So far no real crash! Only xorg is sometimes not coming up
> again, but this may be related to the first issue.
>
> == wifi / intel 6000 ==
>
> Works! Works! (Besides the netlink issue, which is annoying,
> but for all devices).
^ permalink raw reply
* Re: [PATCH 1/2] Export firmware assigned labels of network devices to sysfs
From: Greg KH @ 2010-07-06 23:22 UTC (permalink / raw)
To: Narendra K
Cc: netdev, linux-hotplug, linux-pci, matt_domsch, jordan_hargrave,
charles_rose, vijay_nijhawan
In-Reply-To: <20100706185218.GA19357@auslistsprd01.us.dell.com>
On Tue, Jul 06, 2010 at 01:52:18PM -0500, Narendra K wrote:
> > -----Original Message-----
> > From: Greg KH [mailto:greg@kroah.com]
> > Sent: Wednesday, June 30, 2010 9:12 PM
> > To: K, Narendra
> > Cc: Domsch, Matt; netdev@vger.kernel.org; linux-hotplug@vger.kernel.org;
> > linux-pci@vger.kernel.org; Hargrave, Jordan; Rose, Charles; Nijhawan,
> > Vijay
> > Subject: Re: [PATCH 1/2] Export firmware assigned labels of network
> > devices to sysfs
> >
> > On Tue, Jun 29, 2010 at 11:28:18AM -0500, Narendra K wrote:
> > > --- a/drivers/pci/Makefile
> > > +++ b/drivers/pci/Makefile
> > > @@ -4,7 +4,7 @@
> > >
> > > obj-y += access.o bus.o probe.o remove.o pci.o \
> > > pci-driver.o search.o pci-sysfs.o rom.o
> > setup-res.o \
> > > - irq.o vpd.o
> > > + irq.o vpd.o pci-label.o
> >
> > No, only build this if CONFIG_DMI is set.
>
> I have corrected this to build pci-label.o if only if CONFIG_DMI is set.
>
>
> > > +pci_create_smbiosname_file(struct pci_dev *pdev)
> > > +{
> > > + if (smbios_attr_label.test && smbios_attr_label.test(&pdev->dev,
> > NULL, NULL)) {
> > > + if (sysfs_create_file(&pdev->dev.kobj,
> > &smbios_attr_label.attr))
> > > + return -1;
> >
> > What's wrong with the 'device_create_file' calls?
>
> 'device_create_file' takes 'struct device_attribute *' as a param which
> we have not used here because 'struct device_attribute' does not have .test
> member which we needed in this patch.
Why do you need it? What is calling that function? What am I missing
here?
> Please find the patch with the above change here -
Please always run your patches through scripts/checkpatch.pl and fix up
the issues it finds before sending it out and having everyone else point
them out to you :)
Also, a new thread is nice at times for new versions of patches...
thanks,
greg k-h
^ permalink raw reply
* [PATCH] net/ipv4/ip_output.c: Removal of unused variable in ip_fragment()
From: George Kadianakis @ 2010-07-06 21:44 UTC (permalink / raw)
To: davem; +Cc: netdev, linux-kernel
From: George Kadianakis <desnacked@gmail.com>
Removal of unused integer variable in ip_fragment().
Signed-off-by: George Kadianakis <desnacked@gmail.com>
---
net/ipv4/ip_output.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c
index 041d41d..a83b876 100644
--- a/net/ipv4/ip_output.c
+++ b/net/ipv4/ip_output.c
@@ -442,7 +442,6 @@ static void ip_copy_metadata(struct sk_buff *to, struct sk_buff *from)
int ip_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *))
{
struct iphdr *iph;
- int raw = 0;
int ptr;
struct net_device *dev;
struct sk_buff *skb2;
@@ -580,7 +579,7 @@ int ip_fragment(struct sk_buff *skb, int (*output)(struct sk_buff *))
slow_path:
left = skb->len - hlen; /* Space per frame */
- ptr = raw + hlen; /* Where to start from */
+ ptr = hlen; /* Where to start from */
/* for bridged IP traffic encapsulated inside f.e. a vlan header,
* we need to make room for the encapsulating header
^ permalink raw reply related
* RE: [Bugme-new] [Bug 16293] New: 82545GM in newest kernel not working.
From: Tantilov, Emil S @ 2010-07-06 21:16 UTC (permalink / raw)
To: lukas.valach@zoznam.sk; +Cc: NetDev
In-Reply-To: <web-435085375@be3.mail.zoznam.sk>
>-----Original Message-----
>From: lukas.valach@zoznam.sk [mailto:lukas.valach@zoznam.sk]
>Sent: Tuesday, July 06, 2010 12:35 PM
>To: Tantilov, Emil S
>Subject: Re: [Bugme-new] [Bug 16293] New: 82545GM in newest kernel not
>working.
>
>Hi,
>
>ping has 100% packet loss. Link is up. Lspci --vvv is OK, when have kernel
>2.6.26.
Could you provide the information I asked in the previous email?
1. full lspci output (lspci -vvv)
2. ethtool -i ethX
3. ethtool -d ethX
4. ethtool -e ethX
5. dmesg - after loading the driver and configuring the interfaces
6. kernel config
Are you using a network adapter or is the interface on the motherboard?
Also please copy netdev to your replies.
Thanks,
Emil
^ permalink raw reply
* Re: [PATCH 1/2] Documentation/isdn: CAPI controller interface amendment
From: Tilman Schmidt @ 2010-07-06 20:38 UTC (permalink / raw)
To: David Miller; +Cc: isdn, hjlipp, keil, i4ldeveloper, netdev, linux-kernel
In-Reply-To: <20100705.192426.13754108.davem@davemloft.net>
[-- Attachment #1: Type: text/plain, Size: 357 bytes --]
Am 06.07.2010 04:24 schrieb David Miller:
> Please stop using "Impact: " tags, I just edit them out when
> I add your changes.
Gladly.
Thanks,
Tilman
--
Tilman Schmidt E-Mail: tilman@imap.cc
Bonn, Germany
Diese Nachricht besteht zu 100% aus wiederverwerteten Bits.
Ungeöffnet mindestens haltbar bis: (siehe Rückseite)
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 259 bytes --]
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox