* RE: [PATCH 2.6.25 1/1]S2io: Multiqueue network device support implementation
From: Ramkrishna Vepa @ 2008-01-23 20:48 UTC (permalink / raw)
To: Andi Kleen, Sreenivasa Honnur; +Cc: netdev, jeff, support
In-Reply-To: <p73odbclsft.fsf@crumb.suse.de>
> Sreenivasa Honnur <Sreenivasa.Honnur@neterion.com> writes:
>
> > Multiqueue netwrok device support implementation.
> > - Added a loadable parameter "multiq" to enable/disable multiqueue
> support,
> > by default it is disabled.
> > - skb->queue_mapping is not used for queue/fifo selection. FIFO
> iselection is
> > based on IP-TOS value, 0x0-0xF TOS values are mapped to 8 FIFOs.
>
> Standard way to use that would be using skb->priority
[Ram] Thanks. We can use this field to determine the priority. It should
simplify the code.
>
> But I'm surprised you bother with TOS for multi queues at all. TOS
> isn't a too important mechanism.
[Ram] Agreed TOS is not too important. The purpose of this patch was to
add the multiqueue functionality with a feature that can use it. With
multiple transmit fifos enabled, a whole new set of features that can be
enabled.
>
> I would have thought the primary use case would be per CPU TX
completion
> interrupts. With that the queue should be selected based on
> the the current CPU.
>
[Ram] I am assuming that this is with regards to msi-x interrupts. We
have done away with handling tx completion in the interrupt handler, and
are instead handling them in the context of the transmit. The slow path,
straggling transmit completions will be handled in the timer context.
This patch (along with other new features) will be sent soon.
Ram
> -Andi
^ permalink raw reply
* arping
From: Michaelian Ennis @ 2008-01-23 22:03 UTC (permalink / raw)
To: netdev
Someone filed a bug at bugs.gentoo.org reflecting a possible
enhancement to arping. In short the patches author felt that select
should be used instead of signals to avoid missing a timeout.
The bug is located at:
http://bugs.gentoo.org/show_bug.cgi?id=144526
The diff follows:
--- arping.c 2006-08-20 19:14:39.000000000 -0500
+++ /var/tmp/portage/iputils-021109-r3/work/iputils/arping.c 2006-08-20
19:17:40.000000000 -0500
@@ -7,9 +7,6 @@
* 2 of the License, or (at your option) any later version.
*
* Authors: Alexey Kuznetsov, <kuznet@ms2.inr.ac.ru>
- * 2006.08.18 erik quanstrom <quanstro@quanstro.net>
- * use select instead of signals so timeouts will work.
- *
*/
#include <stdlib.h>
@@ -18,6 +15,7 @@
#include <linux/sockios.h>
#include <sys/file.h>
#include <sys/time.h>
+#include <sys/signal.h>
#include <sys/ioctl.h>
#include <linux/if.h>
#include <linux/if_arp.h>
@@ -31,12 +29,12 @@
#include <string.h>
#include <netinet/in.h>
#include <arpa/inet.h>
-#include <stdarg.h>
#include "SNAPSHOT.h"
static void usage(void) __attribute__((noreturn));
+int quit_on_reply=0;
char *device="eth0";
int ifindex;
char *source;
@@ -45,10 +43,7 @@
int dad, unsolicited, advert;
int quiet;
int count=-1;
-int ntosend=-1;
-int ntorecv=-1;
int timeout;
-struct timeval timeouttv;
int unicasting;
int s;
int broadcast_only;
@@ -64,19 +59,6 @@
#define MS_TDIFF(tv1,tv2) ( ((tv1).tv_sec-(tv2).tv_sec)*1000 + \
((tv1).tv_usec-(tv2).tv_usec)/1000 )
-#define pkttrace(...) /* fprintf(stderr, __VA_ARGS__) */
-
-void
-errexit(int err, const char* fmt, ...)
-{
- va_list ap;
-
- va_start(ap, fmt);
- vfprintf(stderr, fmt, ap);
- va_end(ap);
- exit(err);
-}
-
void usage(void)
{
fprintf(stderr,
@@ -97,6 +79,16 @@
exit(2);
}
+void set_signal(int signo, void (*handler)(void))
+{
+ struct sigaction sa;
+
+ memset(&sa, 0, sizeof(sa));
+ sa.sa_handler = (void (*)(int))handler;
+ sa.sa_flags = SA_RESTART;
+ sigaction(signo, &sa, NULL);
+}
+
int send_pack(int s, struct in_addr src, struct in_addr dst,
struct sockaddr_ll *ME, struct sockaddr_ll *HE)
{
@@ -130,9 +122,7 @@
p+=4;
gettimeofday(&now, NULL);
- pkttrace("sendto->\n");
err = sendto(s, buf, p-buf, 0, (struct sockaddr*)HE, sizeof(*HE));
- pkttrace("sendto<-\n");
if (err == p-buf) {
last = now;
sent++;
@@ -145,20 +135,20 @@
void finish(void)
{
if (!quiet) {
- fflush(stdout);
- fprintf(stderr, "Sent %d probes (%d broadcast(s))\n", sent, brd_sent);
- fprintf(stderr, "Received %d response(s)", received);
+ printf("Sent %d probes (%d broadcast(s))\n", sent, brd_sent);
+ printf("Received %d response(s)", received);
if (brd_recv || req_recv) {
- fprintf(stderr, " (");
+ printf(" (");
if (req_recv)
- fprintf(stderr, "%d request(s)", req_recv);
+ printf("%d request(s)", req_recv);
if (brd_recv)
- fprintf(stderr, "%s%d broadcast(s)",
+ printf("%s%d broadcast(s)",
req_recv ? ", " : "",
brd_recv);
- fprintf(stderr, ")");
+ printf(")");
}
- fprintf(stderr, "\n");
+ printf("\n");
+ fflush(stdout);
}
if (dad)
exit(!!received);
@@ -167,13 +157,34 @@
exit(!received);
}
+void catcher(void)
+{
+ struct timeval tv;
+
+ gettimeofday(&tv, NULL);
+
+ if (start.tv_sec==0)
+ start = tv;
+
+ if (count-- == 0 || (timeout && MS_TDIFF(tv,start) > timeout*1000 + 500))
+ finish();
+
+ if (last.tv_sec==0 || MS_TDIFF(tv,last) > 500) {
+ send_pack(s, src, dst, &me, &he);
+ if (count == 0 && unsolicited)
+ finish();
+ }
+ alarm(1);
+}
+
void print_hex(unsigned char *p, int len)
{
int i;
- for (i=0; i<len-1; i++)
- printf("%02X:", p[i]);
- if(len)
+ for (i=0; i<len; i++) {
printf("%02X", p[i]);
+ if (i != len-1)
+ printf(":");
+ }
}
int recv_pack(unsigned char *buf, int len, struct sockaddr_ll *FROM)
@@ -274,6 +285,8 @@
brd_recv++;
if (ah->ar_op == htons(ARPOP_REQUEST))
req_recv++;
+ if (quit_on_reply)
+ finish();
if(!broadcast_only) {
memcpy(he.sll_addr, p, me.sll_halen);
unicasting=1;
@@ -281,75 +294,26 @@
return 1;
}
-
-unsigned char packet[4096]; // too big for stack on some arch.
-
-void
-pktloop(void)
-{
- struct sockaddr_ll from;
- socklen_t alen = sizeof(from);
- fd_set rset;
- struct timeval tmo;
- int cc, i;
-
- for(;;){
- if(ntosend-- == 0)
- break;
- send_pack(s, src, dst, &me, &he);
-
- gettimeofday(&tmo, 0);
- if(timeout)
- i = MS_TDIFF(timeouttv, tmo) ;
- else
- i = 1000;
- if(i < 0)
- break;
- if(i > 1000)
- i = 1000; // maximum select 1s.
- tmo.tv_sec = i/1000;
- tmo.tv_usec = (i%1000)*1000;
-
- FD_ZERO(&rset);
- FD_SET(s, &rset);
- pkttrace("select %d ; %d\n", (int)tmo.tv_sec, (int)tmo.tv_usec);
- i = select(s+1, &rset, 0, 0, &tmo);
- pkttrace("<- select\n");
- if(i == -1){
- perror("arping: select");
- exit(1);
- }
- if(i == 0){
- gettimeofday(&tmo, 0);
- i = MS_TDIFF(timeouttv, tmo);
- if(timeout && i <= 0)
- break;
- continue;
- }
- if ((cc = recvfrom(s, packet, sizeof(packet), 0,
- (struct sockaddr *)&from, &alen)) < 0) {
- perror("arping: recvfrom");
- continue;
- }
- if(recv_pack(packet, cc, &from))
- if(--ntorecv == 0)
- break;
- }
-}
-
int
main(int argc, char **argv)
{
- int ch, onereply;
+ int socket_errno;
+ int ch;
+ uid_t uid = getuid();
+
+ s = socket(PF_PACKET, SOCK_DGRAM, 0);
+ socket_errno = errno;
+
+ setuid(uid);
while ((ch = getopt(argc, argv, "h?bfDUAqc:w:s:I:V")) != EOF) {
switch(ch) {
case 'b':
- broadcast_only = 1;
+ broadcast_only=1;
break;
case 'D':
dad++;
- onereply = 1;
+ quit_on_reply=1;
break;
case 'U':
unsolicited++;
@@ -365,15 +329,13 @@
count = atoi(optarg);
break;
case 'w':
- gettimeofday(&timeouttv, 0);
- timeouttv.tv_sec += atoi(optarg);
- timeout = 1;
+ timeout = atoi(optarg);
break;
case 'I':
device = optarg;
break;
case 'f':
- onereply = 1;
+ quit_on_reply=1;
break;
case 's':
source = optarg;
@@ -392,26 +354,19 @@
if (argc != 1)
usage();
- target = *argv;
- if(onereply)
- ntorecv = 1;
- if(timeout) // strange ping compatability.
- ntorecv = count;
- else
- ntosend = count;
+ target = *argv;
- if (device == 0) {
+ if (device == NULL) {
fprintf(stderr, "arping: device (option -I) is required\n");
usage();
}
- s = socket(PF_PACKET, SOCK_DGRAM, 0);
if (s < 0) {
+ errno = socket_errno;
perror("arping: socket");
exit(2);
}
- setuid(getuid());
if (1) {
struct ifreq ifr;
@@ -424,13 +379,19 @@
ifindex = ifr.ifr_ifindex;
if (ioctl(s, SIOCGIFFLAGS, (char*)&ifr)) {
- perror("arping: ioctl(SIOCGIFFLAGS)");
+ perror("ioctl(SIOCGIFFLAGS)");
exit(2);
}
- if (!(ifr.ifr_flags&IFF_UP))
- errexit(2, "Interface \"%s\" is down\n", device);
- if (ifr.ifr_flags&(IFF_NOARP|IFF_LOOPBACK))
- errexit(dad ? 0 : 2, "Interface \"%s\" is not ARPable\n", device);
+ if (!(ifr.ifr_flags&IFF_UP)) {
+ if (!quiet)
+ printf("Interface \"%s\" is down\n", device);
+ exit(2);
+ }
+ if (ifr.ifr_flags&(IFF_NOARP|IFF_LOOPBACK)) {
+ if (!quiet)
+ printf("Interface \"%s\" is not ARPable\n", device);
+ exit(dad?0:2);
+ }
}
if (inet_aton(target, &dst) != 1) {
@@ -456,7 +417,7 @@
int probe_fd = socket(AF_INET, SOCK_DGRAM, 0);
if (probe_fd < 0) {
- perror("arping: socket");
+ perror("socket");
exit(2);
}
if (device) {
@@ -468,7 +429,7 @@
if (src.s_addr) {
saddr.sin_addr = src;
if (bind(probe_fd, (struct sockaddr*)&saddr, sizeof(saddr)) == -1) {
- perror("arping: bind");
+ perror("bind");
exit(2);
}
} else if (!dad) {
@@ -481,11 +442,11 @@
if (setsockopt(probe_fd, SOL_SOCKET, SO_DONTROUTE, (char*)&on,
sizeof(on)) == -1)
perror("WARNING: setsockopt(SO_DONTROUTE)");
if (connect(probe_fd, (struct sockaddr*)&saddr, sizeof(saddr)) == -1) {
- perror("arping: connect");
+ perror("connect");
exit(2);
}
if (getsockname(probe_fd, (struct sockaddr*)&saddr, &alen) == -1) {
- perror("arping: getsockname");
+ perror("getsockname");
exit(2);
}
src = saddr.sin_addr;
@@ -497,34 +458,60 @@
me.sll_ifindex = ifindex;
me.sll_protocol = htons(ETH_P_ARP);
if (bind(s, (struct sockaddr*)&me, sizeof(me)) == -1) {
- perror("arping: bind");
+ perror("bind");
exit(2);
}
if (1) {
socklen_t alen = sizeof(me);
if (getsockname(s, (struct sockaddr*)&me, &alen) == -1) {
- perror("arping: getsockname");
+ perror("getsockname");
exit(2);
}
}
- if (me.sll_halen == 0)
- errexit(dad ? 0 : 2, "Interface \"%s\" is not ARPable (no ll
address)\n", device);
+ if (me.sll_halen == 0) {
+ if (!quiet)
+ printf("Interface \"%s\" is not ARPable (no ll address)\n", device);
+ exit(dad?0:2);
+ }
he = me;
memset(he.sll_addr, -1, he.sll_halen);
if (!quiet) {
- fprintf(stderr, "ARPING %s ", inet_ntoa(dst));
- fprintf(stderr, "from %s %s\n", inet_ntoa(src), device ? : "");
+ printf("ARPING %s ", inet_ntoa(dst));
+ printf("from %s %s\n", inet_ntoa(src), device ? : "");
}
- if (!src.s_addr && !dad)
- errexit(2, "arping: no source address in not-DAD mode\n");
+ if (!src.s_addr && !dad) {
+ fprintf(stderr, "arping: no source address in not-DAD mode\n");
+ exit(2);
+ }
+
+ set_signal(SIGINT, finish);
+ set_signal(SIGALRM, catcher);
+
+ catcher();
- pktloop();
- finish();
- return 1; // shut up gcc.
+ while(1) {
+ sigset_t sset, osset;
+ unsigned char packet[4096];
+ struct sockaddr_ll from;
+ socklen_t alen = sizeof(from);
+ int cc;
+
+ if ((cc = recvfrom(s, packet, sizeof(packet), 0,
+ (struct sockaddr *)&from, &alen)) < 0) {
+ perror("arping: recvfrom");
+ continue;
+ }
+ sigemptyset(&sset);
+ sigaddset(&sset, SIGALRM);
+ sigaddset(&sset, SIGINT);
+ sigprocmask(SIG_BLOCK, &sset, &osset);
+ recv_pack(packet, cc, &from);
+ sigprocmask(SIG_SETMASK, &osset, NULL);
+ }
}
^ permalink raw reply
* Re: [PATCH] BUG_ON() bad input to request_irq
From: Andrew Morton @ 2008-01-23 22:04 UTC (permalink / raw)
To: Rusty Russell; +Cc: jeff, netdev, linux-kernel
In-Reply-To: <200801171759.59029.rusty@rustcorp.com.au>
> On Thu, 17 Jan 2008 17:59:58 +1100 Rusty Russell <rusty@rustcorp.com.au> wrote:
> Is there any reason why these bugs should be treated gently? The
> caller might not want to check NR_IRQS and IRQ_NOREQUEST cases, but
> a NULL handler or NULL dev_id w/ shared are coding bugs.
>
> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
> ---
> kernel/irq/manage.c | 7 +++----
> 1 file changed, 3 insertions(+), 4 deletions(-)
>
> diff -r c2eb8ef5a0be kernel/irq/manage.c
> --- a/kernel/irq/manage.c Thu Jan 17 15:48:03 2008 +1100
> +++ b/kernel/irq/manage.c Thu Jan 17 15:49:33 2008 +1100
> @@ -532,13 +532,12 @@ int request_irq(unsigned int irq, irq_ha
> * which interrupt is which (messes up the interrupt freeing
> * logic etc).
> */
> - if ((irqflags & IRQF_SHARED) && !dev_id)
> - return -EINVAL;
> + BUG_ON((irqflags & IRQF_SHARED) && !dev_id);
> + BUG_ON(!handler);
> +
> if (irq >= NR_IRQS)
> return -EINVAL;
> if (irq_desc[irq].status & IRQ_NOREQUEST)
> - return -EINVAL;
> - if (!handler)
> return -EINVAL;
>
> action = kmalloc(sizeof(struct irqaction), GFP_ATOMIC);
If no driver is passing in args which will trigger this BUG, we presumably
don't need the patch.
If some driver _is_ passing in ags which will trigger these BUGs then it is
presumably working OK anyway. Taking a working system and making it go BUG
is likely to upset people.
IOW: WARN_ON, please.
^ permalink raw reply
* Re: [PATCH] bluetooth : move children of connection device to NULL before connection down
From: Andrew Morton @ 2008-01-23 22:06 UTC (permalink / raw)
To: Marcel Holtmann
Cc: davem, hidave.darkstar, netdev, linux-kernel, bluez-devel,
cornelia.huck, gombasg, htejun, viro, kay.sievers, greg
In-Reply-To: <1200982696.7978.148.camel@aeonflux>
> On Tue, 22 Jan 2008 07:18:16 +0100 Marcel Holtmann <marcel@holtmann.org> wrote:
> Hi Dave,
>
> > > Add people missed in cc-list.
> >
> > Thanks Dave for your continued efforts on Bluetooth bugs like this.
> >
> > Marcel, are you going to review/ACK/integrate/push-upstream/whatever
> > any of these Bluetooth patches?
> >
> > It hasn't been getting much love from you as of late, you are one of
> > the listed maintainers, and I don't want to lose any of Dave's
> > valuable bug fixing work.
>
> I will be fully back in business next week. Just got stuck in a project
> that needed 200% of my time to get it going.
>
These patches in -mm:
bluetooth-hidp_process_hid_control-remove-unnecessary-parameter-dealing.patch
bluetooth-uninlining.patch
drivers-bluetooth-bpa10xc-fix-memleak.patch
drivers-bluetooth-btsdioc-fix-double-free.patch
bluetooth-blacklist-another-broadcom-bcm2035-device.patch
bluetooth-rfcomm-tty_close-before-destruct.patch
hci_ldisc-fix-null-pointer-deref.patch
could benefit from some attention please.
^ permalink raw reply
* Re: [PATCH] BUG_ON() bad input to request_irq
From: Rusty Russell @ 2008-01-23 22:15 UTC (permalink / raw)
To: Andrew Morton; +Cc: jeff, netdev, linux-kernel
In-Reply-To: <20080123140414.e1ff2263.akpm@linux-foundation.org>
On Thursday 24 January 2008 09:04:14 Andrew Morton wrote:
> > On Thu, 17 Jan 2008 17:59:58 +1100 Rusty Russell <rusty@rustcorp.com.au>
> If no driver is passing in args which will trigger this BUG, we presumably
> don't need the patch.
You're only thinking of current code. The BUG catches future changes, too.
> If some driver _is_ passing in args which will trigger these BUGs then it is
> presumably working OK anyway. Taking a working system and making it go BUG
> is likely to upset people.
That's why I did the audit. See patch below which preceeded it, which Jeff
hasn't responded to. Breaking his drivers might make him notice :)
> IOW: WARN_ON, please.
At end of cycles, sure, but not for 2.6.25: they're even more invisible than
deprecated warnings :(
Rusty.
===
request_irq() always returns -EINVAL with a NULL handler.
I assume that these ancient network drivers were trying to find out if
an irq is available. eepro.c expecting +EBUSY was doubly wrong.
Request_irq should BUG() on bad input, and these would have been found
earlier.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
---
drivers/net/3c503.c | 2 +-
drivers/net/e2100.c | 2 +-
drivers/net/eepro.c | 2 +-
drivers/net/hp.c | 2 +-
kernel/irq/manage.c | 1 +
5 files changed, 5 insertions(+), 4 deletions(-)
diff -r 0b7e4fbb6238 drivers/net/3c503.c
--- a/drivers/net/3c503.c Thu Jan 17 15:49:34 2008 +1100
+++ b/drivers/net/3c503.c Thu Jan 17 16:40:28 2008 +1100
@@ -379,7 +379,7 @@ el2_open(struct net_device *dev)
outb(EGACFR_NORM, E33G_GACFR); /* Enable RAM and interrupts. */
do {
- if (request_irq (*irqp, NULL, 0, "bogus", dev) != -EBUSY) {
+ if (can_request_irq(*irqp, 0)) {
/* Twinkle the interrupt, and check if it's seen. */
unsigned long cookie = probe_irq_on();
outb_p(0x04 << ((*irqp == 9) ? 2 : *irqp), E33G_IDCFR);
diff -r 0b7e4fbb6238 drivers/net/e2100.c
--- a/drivers/net/e2100.c Thu Jan 17 15:49:34 2008 +1100
+++ b/drivers/net/e2100.c Thu Jan 17 16:40:28 2008 +1100
@@ -202,7 +202,7 @@ static int __init e21_probe1(struct net_
if (dev->irq < 2) {
int irqlist[] = {15,11,10,12,5,9,3,4}, i;
for (i = 0; i < 8; i++)
- if (request_irq (irqlist[i], NULL, 0, "bogus", NULL) != -EBUSY) {
+ if (can_request_irq(irqlist[i], 0)) {
dev->irq = irqlist[i];
break;
}
diff -r 0b7e4fbb6238 drivers/net/eepro.c
--- a/drivers/net/eepro.c Thu Jan 17 15:49:34 2008 +1100
+++ b/drivers/net/eepro.c Thu Jan 17 16:40:28 2008 +1100
@@ -914,7 +914,7 @@ static int eepro_grab_irq(struct net_dev
eepro_sw2bank0(ioaddr); /* Switch back to Bank 0 */
- if (request_irq (*irqp, NULL, IRQF_SHARED, "bogus", dev) != EBUSY) {
+ if (can_request_irq(*irqp, IRQF_SHARED)) {
unsigned long irq_mask;
/* Twinkle the interrupt, and check if it's seen */
irq_mask = probe_irq_on();
diff -r 0b7e4fbb6238 drivers/net/hp.c
--- a/drivers/net/hp.c Thu Jan 17 15:49:34 2008 +1100
+++ b/drivers/net/hp.c Thu Jan 17 16:40:28 2008 +1100
@@ -170,7 +170,7 @@ static int __init hp_probe1(struct net_d
int *irqp = wordmode ? irq_16list : irq_8list;
do {
int irq = *irqp;
- if (request_irq (irq, NULL, 0, "bogus", NULL) != -EBUSY) {
+ if (can_request_irq(irq, 0)) {
unsigned long cookie = probe_irq_on();
/* Twinkle the interrupt, and check if it's seen. */
outb_p(irqmap[irq] | HP_RUN, ioaddr + HP_CONFIGURE);
diff -r 0b7e4fbb6238 kernel/irq/manage.c
--- a/kernel/irq/manage.c Thu Jan 17 15:49:34 2008 +1100
+++ b/kernel/irq/manage.c Thu Jan 17 16:40:28 2008 +1100
@@ -252,6 +252,7 @@ int can_request_irq(unsigned int irq, un
return !action;
}
+EXPORT_SYMBOL(can_request_irq);
void compat_irq_chip_set_default_handler(struct irq_desc *desc)
{
^ permalink raw reply
* [IPV4 2/5] fib_trie: remove unneeded NULL check
From: Stephen Hemminger @ 2008-01-23 22:48 UTC (permalink / raw)
To: David Miller; +Cc: netdev
In-Reply-To: <20080123224844.610730277@linux-foundation.org>
[-- Attachment #1: trie-already-hlist.patch --]
[-- Type: text/plain, Size: 535 bytes --]
Since fib_route_seq_show now uses hlist_for_each_entry(), the
leaf info can not be NULL.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
--- a/net/ipv4/fib_trie.c 2008-01-22 17:50:44.000000000 -0800
+++ b/net/ipv4/fib_trie.c 2008-01-22 17:50:58.000000000 -0800
@@ -2474,9 +2474,6 @@ static int fib_route_seq_show(struct seq
struct fib_alias *fa;
__be32 mask, prefix;
- if (!li)
- continue;
-
mask = inet_make_mask(li->plen);
prefix = htonl(l->key);
--
Stephen Hemminger <stephen.hemminger@vyatta.com>
^ permalink raw reply
* [IPV4 1/5] fib_trie: more whitespace cleanup
From: Stephen Hemminger @ 2008-01-23 22:48 UTC (permalink / raw)
To: David Miller; +Cc: netdev
In-Reply-To: <20080123224844.610730277@linux-foundation.org>
[-- Attachment #1: trie-whitespace.patch --]
[-- Type: text/plain, Size: 1454 bytes --]
Remove extra blank lines.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
--- a/net/ipv4/fib_trie.c 2008-01-22 17:46:28.000000000 -0800
+++ b/net/ipv4/fib_trie.c 2008-01-22 17:50:44.000000000 -0800
@@ -447,7 +447,6 @@ static void tnode_put_child_reorg(struct
BUG_ON(i >= 1<<tn->bits);
-
/* update emptyChildren */
if (n == NULL && chi != NULL)
tn->empty_children++;
@@ -1303,7 +1302,6 @@ err:
return err;
}
-
/* should be called with rcu_read_lock */
static int check_leaf(struct trie *t, struct leaf *l,
t_key key, const struct flowi *flp,
@@ -1718,7 +1716,6 @@ static struct leaf *leaf_walk_rcu(struct
return NULL; /* Root of trie */
}
-
static struct leaf *trie_firstleaf(struct trie *t)
{
struct tnode *n = (struct tnode *) rcu_dereference(t->trie);
@@ -1846,7 +1843,6 @@ static int fn_trie_dump_fa(t_key key, in
{
int i, s_i;
struct fib_alias *fa;
-
__be32 xkey = htonl(key);
s_i = cb->args[4];
@@ -1879,7 +1875,6 @@ static int fn_trie_dump_fa(t_key key, in
return skb->len;
}
-
static int fn_trie_dump_leaf(struct leaf *l, struct fib_table *tb,
struct sk_buff *skb, struct netlink_callback *cb)
{
@@ -2385,7 +2380,6 @@ static int fib_trie_seq_show(struct seq_
struct leaf *l = (struct leaf *) n;
struct leaf_info *li;
struct hlist_node *node;
-
__be32 val = htonl(l->key);
seq_indent(seq, iter->depth);
--
Stephen Hemminger <stephen.hemminger@vyatta.com>
^ permalink raw reply
* [IPV4 5/5] fib_semantics: sparse warnings
From: Stephen Hemminger @ 2008-01-23 22:48 UTC (permalink / raw)
To: David Miller; +Cc: netdev
In-Reply-To: <20080123224844.610730277@linux-foundation.org>
[-- Attachment #1: fib-semantic-sparse.patch --]
[-- Type: text/plain, Size: 1824 bytes --]
The magic macro change_nexthops introduces a variable nh which overlaps
previous declaration of nh.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
--- a/net/ipv4/fib_semantics.c 2008-01-23 11:03:55.000000000 -0800
+++ b/net/ipv4/fib_semantics.c 2008-01-23 11:05:12.000000000 -0800
@@ -1059,14 +1059,14 @@ int fib_sync_down(__be32 local, struct n
unsigned int hash = fib_devindex_hashfn(dev->ifindex);
struct hlist_head *head = &fib_info_devhash[hash];
struct hlist_node *node;
- struct fib_nh *nh;
+ struct fib_nh *nh1;
- hlist_for_each_entry(nh, node, head, nh_hash) {
- struct fib_info *fi = nh->nh_parent;
+ hlist_for_each_entry(nh1, node, head, nh_hash) {
+ struct fib_info *fi = nh1->nh_parent;
int dead;
BUG_ON(!fi->fib_nhs);
- if (nh->nh_dev != dev || fi == prev_fi)
+ if (nh1->nh_dev != dev || fi == prev_fi)
continue;
prev_fi = fi;
dead = 0;
@@ -1091,6 +1091,7 @@ int fib_sync_down(__be32 local, struct n
}
#endif
} endfor_nexthops(fi)
+
if (dead == fi->fib_nhs) {
fi->fib_flags |= RTNH_F_DEAD;
ret++;
@@ -1114,7 +1115,7 @@ int fib_sync_up(struct net_device *dev)
unsigned int hash;
struct hlist_head *head;
struct hlist_node *node;
- struct fib_nh *nh;
+ struct fib_nh *nh1;
int ret;
if (!(dev->flags&IFF_UP))
@@ -1125,12 +1126,12 @@ int fib_sync_up(struct net_device *dev)
head = &fib_info_devhash[hash];
ret = 0;
- hlist_for_each_entry(nh, node, head, nh_hash) {
- struct fib_info *fi = nh->nh_parent;
+ hlist_for_each_entry(nh1, node, head, nh_hash) {
+ struct fib_info *fi = nh1->nh_parent;
int alive;
BUG_ON(!fi->fib_nhs);
- if (nh->nh_dev != dev || fi == prev_fi)
+ if (nh1->nh_dev != dev || fi == prev_fi)
continue;
prev_fi = fi;
--
Stephen Hemminger <stephen.hemminger@vyatta.com>
^ permalink raw reply
* [IPV4 4/5] fib_trie: version 0.410
From: Stephen Hemminger @ 2008-01-23 22:48 UTC (permalink / raw)
To: David Miller; +Cc: netdev
In-Reply-To: <20080123224844.610730277@linux-foundation.org>
[-- Attachment #1: fib-trie-minor.patch --]
[-- Type: text/plain, Size: 450 bytes --]
Increase version to reflect recent changes.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
--- a/net/ipv4/fib_trie.c 2008-01-22 17:50:58.000000000 -0800
+++ b/net/ipv4/fib_trie.c 2008-01-22 17:51:02.000000000 -0800
@@ -50,7 +50,7 @@
* Patrick McHardy <kaber@trash.net>
*/
-#define VERSION "0.408"
+#define VERSION "0.410"
#include <asm/uaccess.h>
#include <asm/system.h>
--
Stephen Hemminger <stephen.hemminger@vyatta.com>
^ permalink raw reply
* [IPV4 3/5] fib_trie: dump doesnt use RCU
From: Stephen Hemminger @ 2008-01-23 22:48 UTC (permalink / raw)
To: David Miller; +Cc: netdev
In-Reply-To: <20080123224844.610730277@linux-foundation.org>
[-- Attachment #1: fib-dump-rtnl.patch --]
[-- Type: text/plain, Size: 3261 bytes --]
Since fib dump (via netlink) holds the RTNL mutex, it is unnecessary
to use RCU, and it is impossible to get truncated (-EBUSY) result.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
--- a/net/ipv4/fib_trie.c 2008-01-23 13:55:12.000000000 -0800
+++ b/net/ipv4/fib_trie.c 2008-01-23 14:00:35.000000000 -0800
@@ -1684,7 +1684,7 @@ static int trie_flush_leaf(struct trie *
* Scan for the next right leaf starting at node p->child[idx]
* Since we have back pointer, no recursion necessary.
*/
-static struct leaf *leaf_walk_rcu(struct tnode *p, struct node *c)
+static struct leaf *leaf_walk(struct tnode *p, struct node *c)
{
do {
t_key idx;
@@ -1695,7 +1695,7 @@ static struct leaf *leaf_walk_rcu(struct
idx = 0;
while (idx < 1u << p->bits) {
- c = tnode_get_child_rcu(p, idx++);
+ c = tnode_get_child(p, idx++);
if (!c)
continue;
@@ -1711,14 +1711,14 @@ static struct leaf *leaf_walk_rcu(struct
/* Node empty, walk back up to parent */
c = (struct node *) p;
- } while ( (p = node_parent_rcu(c)) != NULL);
+ } while ( (p = node_parent(c)) != NULL);
return NULL; /* Root of trie */
}
static struct leaf *trie_firstleaf(struct trie *t)
{
- struct tnode *n = (struct tnode *) rcu_dereference(t->trie);
+ struct tnode *n = (struct tnode *) t->trie;
if (!n)
return NULL;
@@ -1726,7 +1726,7 @@ static struct leaf *trie_firstleaf(struc
if (IS_LEAF(n)) /* trie is just a leaf */
return (struct leaf *) n;
- return leaf_walk_rcu(n, NULL);
+ return leaf_walk(n, NULL);
}
static struct leaf *trie_nextleaf(struct leaf *l)
@@ -1737,7 +1737,7 @@ static struct leaf *trie_nextleaf(struct
if (!p)
return NULL; /* trie with just one leaf */
- return leaf_walk_rcu(p, c);
+ return leaf_walk(p, c);
}
/*
@@ -1848,9 +1848,7 @@ static int fn_trie_dump_fa(t_key key, in
s_i = cb->args[4];
i = 0;
- /* rcu_read_lock is hold by caller */
-
- list_for_each_entry_rcu(fa, fah, fa_list) {
+ list_for_each_entry(fa, fah, fa_list) {
if (i < s_i) {
i++;
continue;
@@ -1885,8 +1883,7 @@ static int fn_trie_dump_leaf(struct leaf
s_i = cb->args[3];
i = 0;
- /* rcu_read_lock is hold by caller */
- hlist_for_each_entry_rcu(li, node, &l->list, hlist) {
+ hlist_for_each_entry(li, node, &l->list, hlist) {
if (i < s_i) {
i++;
continue;
@@ -1916,35 +1913,25 @@ static int fn_trie_dump(struct fib_table
struct trie *t = (struct trie *) tb->tb_data;
t_key key = cb->args[2];
- rcu_read_lock();
+ ASSERT_RTNL();
+
/* Dump starting at last key.
* Note: 0.0.0.0/0 (ie default) is first key.
*/
if (!key)
l = trie_firstleaf(t);
- else {
+ else
l = fib_find_node(t, key);
- if (!l) {
- /* The table changed during the dump, rather than
- * giving partial data, just make application retry.
- */
- rcu_read_unlock();
- return -EBUSY;
- }
- }
while (l) {
cb->args[2] = l->key;
- if (fn_trie_dump_leaf(l, tb, skb, cb) < 0) {
- rcu_read_unlock();
+ if (fn_trie_dump_leaf(l, tb, skb, cb) < 0)
return -1;
- }
l = trie_nextleaf(l);
memset(&cb->args[3], 0,
sizeof(cb->args) - 3*sizeof(cb->args[0]));
}
- rcu_read_unlock();
return skb->len;
}
--
Stephen Hemminger <stephen.hemminger@vyatta.com>
^ permalink raw reply
* [PATCH] ppp: sparse warning fixes
From: Stephen Hemminger @ 2008-01-23 23:40 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linux-ppp, netdev
Fix a bunch of warnings in PPP and related drivers. Mostly because
sparse doesn't like it when the the function is only marked private
in the forward declaration.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
---
drivers/net/ppp_deflate.c | 4 ++--
drivers/net/ppp_generic.c | 2 +-
drivers/net/ppp_synctty.c | 2 +-
drivers/net/pppoe.c | 2 ++
drivers/net/slhc.c | 4 ++--
5 files changed, 8 insertions(+), 6 deletions(-)
--- a/drivers/net/ppp_deflate.c 2008-01-23 15:35:22.000000000 -0800
+++ b/drivers/net/ppp_deflate.c 2008-01-23 15:35:40.000000000 -0800
@@ -206,7 +206,7 @@ static void z_comp_reset(void *arg)
* Returns the length of the compressed packet, or 0 if the
* packet is incompressible.
*/
-int z_compress(void *arg, unsigned char *rptr, unsigned char *obuf,
+static int z_compress(void *arg, unsigned char *rptr, unsigned char *obuf,
int isize, int osize)
{
struct ppp_deflate_state *state = (struct ppp_deflate_state *) arg;
@@ -435,7 +435,7 @@ static void z_decomp_reset(void *arg)
* bug, so we return DECOMP_FATALERROR for them in order to turn off
* compression, even though they are detected by inspecting the input.
*/
-int z_decompress(void *arg, unsigned char *ibuf, int isize,
+static int z_decompress(void *arg, unsigned char *ibuf, int isize,
unsigned char *obuf, int osize)
{
struct ppp_deflate_state *state = (struct ppp_deflate_state *) arg;
--- a/drivers/net/ppp_generic.c 2008-01-23 15:34:40.000000000 -0800
+++ b/drivers/net/ppp_generic.c 2008-01-23 15:34:45.000000000 -0800
@@ -1871,7 +1871,7 @@ ppp_mp_insert(struct ppp *ppp, struct sk
* complete packet, or we get to the sequence number for a fragment
* which hasn't arrived but might still do so.
*/
-struct sk_buff *
+static struct sk_buff *
ppp_mp_reconstruct(struct ppp *ppp)
{
u32 seq = ppp->nextseq;
--- a/drivers/net/ppp_synctty.c 2008-01-23 15:35:04.000000000 -0800
+++ b/drivers/net/ppp_synctty.c 2008-01-23 15:35:08.000000000 -0800
@@ -560,7 +560,7 @@ static void ppp_sync_process(unsigned lo
* Procedures for encapsulation and framing.
*/
-struct sk_buff*
+static struct sk_buff*
ppp_sync_txmunge(struct syncppp *ap, struct sk_buff *skb)
{
int proto;
--- a/drivers/net/pppoe.c 2008-01-23 15:35:52.000000000 -0800
+++ b/drivers/net/pppoe.c 2008-01-23 15:36:16.000000000 -0800
@@ -989,6 +989,7 @@ out:
}
static void *pppoe_seq_start(struct seq_file *seq, loff_t *pos)
+ __acquires(pppoe_hash_lock)
{
loff_t l = *pos;
@@ -1022,6 +1023,7 @@ out:
}
static void pppoe_seq_stop(struct seq_file *seq, void *v)
+ __releases(pppoe_hash_lock)
{
read_unlock_bh(&pppoe_hash_lock);
}
--- a/drivers/net/slhc.c 2008-01-23 15:36:45.000000000 -0800
+++ b/drivers/net/slhc.c 2008-01-23 15:37:22.000000000 -0800
@@ -174,7 +174,7 @@ put16(unsigned char *cp, unsigned short
/* Encode a number */
-unsigned char *
+static unsigned char *
encode(unsigned char *cp, unsigned short n)
{
if(n >= 256 || n == 0){
@@ -199,7 +199,7 @@ pull16(unsigned char **cpp)
}
/* Decode a number */
-long
+static long
decode(unsigned char **cpp)
{
register int x;
^ permalink raw reply
* Re: [IPV4 0/9] TRIE performance patches
From: Stephen Hemminger @ 2008-01-23 23:49 UTC (permalink / raw)
To: Robert Olsson; +Cc: David Miller, netdev
In-Reply-To: <18327.18935.137799.285515@robur.slu.se>
On Wed, 23 Jan 2008 15:06:47 +0100
Robert Olsson <Robert.Olsson@data.slu.se> wrote:
>
> Stephen Hemminger writes:
>
> > Time to handle a full BGP load (163K of routes).
> >
> > Before: Load Dump Flush
> >
> > kmem_cache 3.8 13.0 7.2
> > iter 3.9 12.3 6.9
> > unordered 3.1 11.9 4.9
> > find_node 3.1 0.3 1.2
>
> I certainly like the speed but what will we brake when
> we don't return in longest prefix order?
>
> labb:/# ip r
> default via 10.10.10.1 dev eth0
> 5.0.0.0/8 via 192.168.2.2 dev eth3
> 10.10.10.0/24 dev eth0 proto kernel scope link src 10.10.10.2
> 10.10.11.0/24 dev eth1 proto kernel scope link src 10.10.11.1
> 11.0.0.0/8 via 10.10.11.2 dev eth1
> 192.168.1.0/24 dev eth2 proto kernel scope link src 192.168.1.2
> 192.168.2.0/24 dev eth3 proto kernel scope link src 192.168.2.1
>
> labb:/# ip route list match 10.10.10.1
> default via 10.10.10.1 dev eth0
> 10.10.10.0/24 dev eth0 proto kernel scope link src 10.10.10.2
> labb:/#
>
> Maybe the unordered dump can be ordered cheaply...
Dumping by prefix is possible, but unless 32x slower. Dumping in
address order is just as logical. Like I said, I'm investigating what
quagga handles.
--
Stephen Hemminger <stephen.hemminger@vyatta.com>
^ permalink raw reply
* Re: [PATCH] bluetooth : move children of connection device to NULL before connection down
From: Dave Young @ 2008-01-24 1:19 UTC (permalink / raw)
To: Andrew Morton
Cc: Marcel Holtmann, davem, netdev, linux-kernel, bluez-devel,
cornelia.huck, gombasg, htejun, viro, kay.sievers, greg
In-Reply-To: <20080123140629.c24d4d68.akpm@linux-foundation.org>
On Wed, Jan 23, 2008 at 02:06:29PM -0800, Andrew Morton wrote:
> > On Tue, 22 Jan 2008 07:18:16 +0100 Marcel Holtmann <marcel@holtmann.org> wrote:
> > Hi Dave,
> >
> > > > Add people missed in cc-list.
> > >
> > > Thanks Dave for your continued efforts on Bluetooth bugs like this.
> > >
> > > Marcel, are you going to review/ACK/integrate/push-upstream/whatever
> > > any of these Bluetooth patches?
> > >
> > > It hasn't been getting much love from you as of late, you are one of
> > > the listed maintainers, and I don't want to lose any of Dave's
> > > valuable bug fixing work.
> >
> > I will be fully back in business next week. Just got stuck in a project
> > that needed 200% of my time to get it going.
> >
>
> These patches in -mm:
>
> bluetooth-hidp_process_hid_control-remove-unnecessary-parameter-dealing.patch
> bluetooth-uninlining.patch
> drivers-bluetooth-bpa10xc-fix-memleak.patch
> drivers-bluetooth-btsdioc-fix-double-free.patch
> bluetooth-blacklist-another-broadcom-bcm2035-device.patch
> bluetooth-rfcomm-tty_close-before-destruct.patch
> hci_ldisc-fix-null-pointer-deref.patch
>
> could benefit from some attention please.
Hi, andrew
For the patch bluetooth-rfcomm-tty_close-before-destruct.patch I have to rethinkabout it.
1. The subject is not correct, should be rfcomm-tty-destroy-before-tty_close.
2. Don't know what I was thinking that time, could you replace it with the following better one? Sorry for that.
---
rfcomm dev could be deleted in tty_hangup, so we must not call rfcomm_dev_del again to prevent from destroying rfcomm dev before tty close.
Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
---
net/bluetooth/rfcomm/tty.c | 2 ++
1 file changed, 2 insertions(+)
diff -upr a/net/bluetooth/rfcomm/tty.c b/net/bluetooth/rfcomm/tty.c
--- a/net/bluetooth/rfcomm/tty.c 2008-01-24 09:03:59.000000000 +0800
+++ b/net/bluetooth/rfcomm/tty.c 2008-01-24 09:03:59.000000000 +0800
@@ -429,6 +429,8 @@ static int rfcomm_release_dev(void __use
if (dev->tty)
tty_vhangup(dev->tty);
+ if (!test_bit(RFCOMM_RELEASE_ONHUP, &dev->flags))
+ rfcomm_dev_del(dev);
rfcomm_dev_del(dev);
rfcomm_dev_put(dev);
return 0;
^ permalink raw reply
* Re: [PATCH] bluetooth : move children of connection device to NULL before connection down
From: Dave Young @ 2008-01-24 1:26 UTC (permalink / raw)
To: Andrew Morton
Cc: Marcel Holtmann, davem, netdev, linux-kernel, bluez-devel,
cornelia.huck, gombasg, htejun, viro, kay.sievers, greg
In-Reply-To: <20080124011926.GA2950@darkstar.te-china.tietoenator.com>
On Thu, Jan 24, 2008 at 09:19:26AM +0800, Dave Young wrote:
> On Wed, Jan 23, 2008 at 02:06:29PM -0800, Andrew Morton wrote:
> > > On Tue, 22 Jan 2008 07:18:16 +0100 Marcel Holtmann <marcel@holtmann.org> wrote:
> > > Hi Dave,
> > >
> > > > > Add people missed in cc-list.
> > > >
> > > > Thanks Dave for your continued efforts on Bluetooth bugs like this.
> > > >
> > > > Marcel, are you going to review/ACK/integrate/push-upstream/whatever
> > > > any of these Bluetooth patches?
> > > >
> > > > It hasn't been getting much love from you as of late, you are one of
> > > > the listed maintainers, and I don't want to lose any of Dave's
> > > > valuable bug fixing work.
> > >
> > > I will be fully back in business next week. Just got stuck in a project
> > > that needed 200% of my time to get it going.
> > >
> >
> > These patches in -mm:
> >
> > bluetooth-hidp_process_hid_control-remove-unnecessary-parameter-dealing.patch
> > bluetooth-uninlining.patch
> > drivers-bluetooth-bpa10xc-fix-memleak.patch
> > drivers-bluetooth-btsdioc-fix-double-free.patch
> > bluetooth-blacklist-another-broadcom-bcm2035-device.patch
> > bluetooth-rfcomm-tty_close-before-destruct.patch
> > hci_ldisc-fix-null-pointer-deref.patch
> >
> > could benefit from some attention please.
>
> Hi, andrew
>
> For the patch bluetooth-rfcomm-tty_close-before-destruct.patch I have to rethinkabout it.
>
> 1. The subject is not correct, should be rfcomm-tty-destroy-before-tty_close.
> 2. Don't know what I was thinking that time, could you replace it with the following better one? Sorry for that.
>
> ---
> rfcomm dev could be deleted in tty_hangup, so we must not call rfcomm_dev_del again to prevent from destroying rfcomm dev before tty close.
>
> Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
>
> ---
> net/bluetooth/rfcomm/tty.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff -upr a/net/bluetooth/rfcomm/tty.c b/net/bluetooth/rfcomm/tty.c
> --- a/net/bluetooth/rfcomm/tty.c 2008-01-24 09:03:59.000000000 +0800
> +++ b/net/bluetooth/rfcomm/tty.c 2008-01-24 09:03:59.000000000 +0800
> @@ -429,6 +429,8 @@ static int rfcomm_release_dev(void __use
> if (dev->tty)
> tty_vhangup(dev->tty);
>
> + if (!test_bit(RFCOMM_RELEASE_ONHUP, &dev->flags))
> + rfcomm_dev_del(dev);
> rfcomm_dev_del(dev);
~~~~~~~~~~~~~~~~~
> rfcomm_dev_put(dev);
> return 0;
Please ignore the previous silly one, now resubmit :
----------
rfcomm dev could be deleted in tty_hangup, so we must not call rfcomm_dev_del again to prevent from destroying rfcomm dev before tty close.
Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
---
net/bluetooth/rfcomm/tty.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff -upr a/net/bluetooth/rfcomm/tty.c b/net/bluetooth/rfcomm/tty.c
--- a/net/bluetooth/rfcomm/tty.c 2008-01-24 09:21:56.000000000 +0800
+++ b/net/bluetooth/rfcomm/tty.c 2008-01-24 09:21:56.000000000 +0800
@@ -429,7 +429,8 @@ static int rfcomm_release_dev(void __use
if (dev->tty)
tty_vhangup(dev->tty);
- rfcomm_dev_del(dev);
+ if (!test_bit(RFCOMM_RELEASE_ONHUP, &dev->flags))
+ rfcomm_dev_del(dev);
rfcomm_dev_put(dev);
return 0;
}
^ permalink raw reply
* Re: [PATCH] [POWERPC] Add fixed-phy support for fs_enet
From: Kumar Gala @ 2008-01-24 1:51 UTC (permalink / raw)
To: Jochen Friedrich
Cc: Kernel, Linux, linuxppc-dev, Paul Mackerras, netdev, Scott Wood,
Garzik, Jeff
In-Reply-To: <4767E677.7010200@scram.de>
On Tue, 18 Dec 2007, Jochen Friedrich wrote:
> This patch adds support to use the fixed-link property
> of an ethernet node to fs_enet for the
> CONFIG_PPC_CPM_NEW_BINDING case.
>
> Signed-off-by: Jochen Friedrich <jochen@scram.de>
> Acked-by: Jeff Garzik <jeff@garzik.org>
> Acked-by: Vitali Bordug <vitb@kernel.crashing.org>
> ---
> drivers/net/fs_enet/fs_enet-main.c | 9 ++++++++-
> 1 files changed, 8 insertions(+), 1 deletions(-)
>
applied.
- k
^ permalink raw reply
* Re: [PATCH 0/6] PS3: gelic: gelic updates for 2.6.25
From: John W. Linville @ 2008-01-24 2:36 UTC (permalink / raw)
To: Geoff Levand
Cc: Geert.Uytterhoeven, Paul Mackerras, Linux/PPC Development, netdev
In-Reply-To: <4796B0AC.5060205@am.sony.com>
On Tue, Jan 22, 2008 at 07:12:44PM -0800, Geoff Levand wrote:
> On 01/22/2008 04:58 PM, John W. Linville wrote:
> > I thought Geert's had been applied, but I guess I was looking at
> > it wrong. Is there a powerpc tree that has them?
>
> Not yet, they are now only in ps3-linux.git. I sent them out to
> Paul last Friday the 18th for inclusion in 2.6.25. Here is a link
> to the message:
>
> http://ozlabs.org/pipermail/linuxppc-dev/2008-January/050213.html
>
> > Perhaps 1-6 above
> > and the wireless patch should just be applied to that tree (if there
> > is one) and all merged together?
>
> I think Paul will accept them if they have the Sign-off-by's of
> the proper network maintainers.
Feel free to add:
Signed-off-by: John W. Linville <linville@tuxdriver.com>
(Or Acked-by if you would prefer) to the wireless bits. FWIW, the
wired bits seemed OK to me as well, but I didn't look too closely...
Thanks,
John
--
John W. Linville
linville@tuxdriver.com
^ permalink raw reply
* Re: 2.6.24-rc8-mm1 : net tcp_input.c warnings
From: Dave Young @ 2008-01-24 2:42 UTC (permalink / raw)
To: Ilpo Järvinen; +Cc: LKML, Netdev, Andrew Morton
In-Reply-To: <Pine.LNX.4.64.0801231256360.31652@kivilampi-30.cs.helsinki.fi>
On Jan 23, 2008 7:01 PM, Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> wrote:
> On Wed, 23 Jan 2008, Ilpo Järvinen wrote:
>
> > On Wed, 23 Jan 2008, Dave Young wrote:
> >
> > > On Jan 23, 2008 3:41 PM, Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> wrote:
> > > >
> > > > On Tue, 22 Jan 2008, David Miller wrote:
> > > >
> > > > > From: "Dave Young" <hidave.darkstar@gmail.com>
> > > > > Date: Wed, 23 Jan 2008 09:44:30 +0800
> > > > >
> > > > > > On Jan 22, 2008 6:47 PM, Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> wrote:
> > > > > > > [PATCH] [TCP]: debug S+L
> > > > > >
> > > > > > Thanks, If there's new findings I will let you know.
> > > > >
> > > > > Thanks for helping with this bug Dave.
> > > >
> > > > I noticed btw that there thing might (is likely to) spuriously trigger at
> > > > WARN_ON(sacked != tp->sacked_out); because those won't be equal when SACK
> > > > is not enabled. If that does happen too often, I send a fixed patch for
> > > > it, yet, the fact that I print print tp->rx_opt.sack_ok allows
> > > > identification of those cases already as it's zero when SACK is not
> > > > enabled.
> > > >
> > > > Just ask if you need the updated debug patch.
> > >
> > > Thanks, please send, I would like to get it.
> >
> > There you go. I fixed non-SACK case by adding tcp_is_sack checks there and
> > also added two verifys to tcp_ack to see if there's corruption outside of
> > TCP.
>
> There's some discussion about a problem that is very likely the same as in
> here (sorry for not remembering to cc you in there due to rapid progress):
>
> http://marc.info/?t=120107174200003&r=1&w=2
Thanks.
New warning trigged with your debug patch:
ACPI: PCI Interrupt 0000:00:1b.0[A] -> GSI 16 (level, low) -> IRQ 16
PCI: Setting latency timer of device 0000:00:1b.0 to 64
e100: Intel(R) PRO/100 Network Driver, 3.5.23-k4-NAPI
e100: Copyright(c) 1999-2006 Intel Corporation
ACPI: PCI Interrupt 0000:03:08.0[A] -> GSI 20 (level, low) -> IRQ 20
e100: eth1: e100_probe: addr 0xefaff000, irq 20, MAC addr 00:13:72:e7:4d:66
eth0: setting full-duplex.
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0150030>] ? timer_list_show_tickdevices+0xf0/0x110
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c0153251>] ? put_lock_stats+0x21/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c0186af4>] ? check_bytes_and_report+0x24/0xc0
[<c0186af4>] ? check_bytes_and_report+0x24/0xc0
[<c0186bf1>] ? check_pad_bytes+0x61/0x80
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03f7509>] ? tcp_clean_rtx_queue+0x2d9/0x5b0
[<c03f5540>] tcp_add_reno_sack+0x30/0x50
[<c03f6d72>] tcp_fastretrans_alert+0x3d2/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 1 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s1 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0250030>] ? generic_make_request+0x1c0/0x2e0
[<c0132128>] ? printk+0x18/0x20
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c03f674e>] tcp_try_to_open+0x2e/0x160
[<c03f6e9e>] tcp_fastretrans_alert+0x4fe/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 1 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s1 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c0186af4>] ? check_bytes_and_report+0x24/0xc0
[<c0186bf1>] ? check_pad_bytes+0x61/0x80
[<c0186dbd>] ? check_object+0xad/0x1e0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c015561c>] ? trace_hardirqs_on+0x7c/0x130
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fcf03>] tcp_write_xmit+0x63/0x290
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fd147>] __tcp_push_pending_frames+0x17/0x80
[<c03fa23e>] tcp_rcv_established+0x40e/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 1 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s1 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0132128>] ? printk+0x18/0x20
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c025f9e4>] ? vsnprintf+0x2d4/0x4f0
[<c0132128>] ? printk+0x18/0x20
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c0186bf1>] ? check_pad_bytes+0x61/0x80
[<c03f7509>] tcp_clean_rtx_queue+0x2d9/0x5b0
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c03f7dd2>] tcp_ack+0x122/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 1 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s1 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0132438>] ? vprintk+0x308/0x320
[<c025f9e4>] ? vsnprintf+0x2d4/0x4f0
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03f7509>] ? tcp_clean_rtx_queue+0x2d9/0x5b0
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c03f6a93>] tcp_fastretrans_alert+0xf3/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 1 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s1 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0250030>] ? generic_make_request+0x1c0/0x2e0
[<c0132128>] ? printk+0x18/0x20
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c03f5540>] tcp_add_reno_sack+0x30/0x50
[<c03f6d72>] tcp_fastretrans_alert+0x3d2/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 2 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s2 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0250030>] ? generic_make_request+0x1c0/0x2e0
[<c0132128>] ? printk+0x18/0x20
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c03f674e>] tcp_try_to_open+0x2e/0x160
[<c03f6e9e>] tcp_fastretrans_alert+0x4fe/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 2 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s2 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c0186af4>] ? check_bytes_and_report+0x24/0xc0
[<c0132438>] ? vprintk+0x308/0x320
[<c0186bf1>] ? check_pad_bytes+0x61/0x80
[<c0186dbd>] ? check_object+0xad/0x1e0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c015561c>] ? trace_hardirqs_on+0x7c/0x130
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fcf03>] tcp_write_xmit+0x63/0x290
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fd147>] __tcp_push_pending_frames+0x17/0x80
[<c03fa23e>] tcp_rcv_established+0x40e/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f3e>] ? __do_softirq+0x6e/0x120
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 2 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s2 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0132128>] ? printk+0x18/0x20
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c025f9e4>] ? vsnprintf+0x2d4/0x4f0
[<c0132128>] ? printk+0x18/0x20
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c0186bf1>] ? check_pad_bytes+0x61/0x80
[<c03f7509>] tcp_clean_rtx_queue+0x2d9/0x5b0
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c03f7dd2>] tcp_ack+0x122/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 2 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s2 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0132438>] ? vprintk+0x308/0x320
[<c025f9e4>] ? vsnprintf+0x2d4/0x4f0
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03f7509>] ? tcp_clean_rtx_queue+0x2d9/0x5b0
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c03f6a93>] tcp_fastretrans_alert+0xf3/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 2 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s2 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0250030>] ? generic_make_request+0x1c0/0x2e0
[<c0132128>] ? printk+0x18/0x20
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c03f5540>] tcp_add_reno_sack+0x30/0x50
[<c03f6d72>] tcp_fastretrans_alert+0x3d2/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 0 vs 0 S: 0 vs 3 w: 2044790889-2044796616 (0)
TCP wq(s) <
TCP wq(h) +++h+<
l0 s3 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_input.c:2169 tcp_mark_head_lost+0x122/0x150()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c03f6052>] tcp_mark_head_lost+0x122/0x150
[<c03f60ca>] tcp_update_scoreboard+0x4a/0x190
[<c03f6e7a>] tcp_fastretrans_alert+0x4da/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c03ffe54>] ? tcp_print_queue+0x1a4/0x230
[<c0132438>] ? vprintk+0x308/0x320
[<c0132438>] ? vprintk+0x308/0x320
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c03f5ffc>] tcp_mark_head_lost+0xcc/0x150
[<c03f60ca>] tcp_update_scoreboard+0x4a/0x190
[<c03f6e7a>] tcp_fastretrans_alert+0x4da/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 5 vs 5 S: 0 vs 3 w: 2044790889-2044796616 (0)
TCP wq(s) LLLLl<
TCP wq(h) +++h+<
l5 s3 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_output.c:1977 tcp_xmit_retransmit_queue+0x388/0x420()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c03f5ffc>] ? tcp_mark_head_lost+0xcc/0x150
[<c03fdf38>] tcp_xmit_retransmit_queue+0x388/0x420
[<c03f6c27>] tcp_fastretrans_alert+0x287/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c0132438>] ? vprintk+0x308/0x320
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03f5ffc>] ? tcp_mark_head_lost+0xcc/0x150
[<c03fdea4>] tcp_xmit_retransmit_queue+0x2f4/0x420
[<c03f6c27>] tcp_fastretrans_alert+0x287/0x700
[<c03f7e63>] tcp_ack+0x1b3/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 5 vs 5 S: 0 vs 3 w: 2044790889-2044796616 (0)
TCP wq(s) LLLLl<
TCP wq(h) +++h+<
l5 s3 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_output.c:1467 tcp_write_xmit+0x288/0x290()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0186af4>] ? check_bytes_and_report+0x24/0xc0
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0186bf1>] ? check_pad_bytes+0x61/0x80
[<c0186dbd>] ? check_object+0xad/0x1e0
[<c0155539>] ? mark_held_locks+0x39/0x80
[<c01880ac>] ? __slab_free+0xac/0x150
[<c015561c>] ? trace_hardirqs_on+0x7c/0x130
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fd128>] tcp_write_xmit+0x288/0x290
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fd147>] __tcp_push_pending_frames+0x17/0x80
[<c03fa23e>] tcp_rcv_established+0x40e/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c0186af4>] ? check_bytes_and_report+0x24/0xc0
[<c03ffff6>] ? tcp_verify_wq+0x116/0x1c0
[<c0186bf1>] ? check_pad_bytes+0x61/0x80
[<c0186dbd>] ? check_object+0xad/0x1e0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c015561c>] ? trace_hardirqs_on+0x7c/0x130
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fcf03>] tcp_write_xmit+0x63/0x290
[<c03c1578>] ? kfree_skbmem+0x98/0xc0
[<c03fd147>] __tcp_push_pending_frames+0x17/0x80
[<c03fa23e>] tcp_rcv_established+0x40e/0x710
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c04021fb>] tcp_v4_rcv+0x5db/0x660
[<c0401fa7>] ? tcp_v4_rcv+0x387/0x660
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c03e5f44>] ip_local_deliver_finish+0x84/0x1d0
[<c03e5eed>] ? ip_local_deliver_finish+0x2d/0x1d0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03e6147>] ip_local_deliver+0xb7/0xc0
[<c03e6202>] ip_rcv_finish+0xb2/0x3c0
[<c03c01d8>] ? sock_def_readable+0x48/0xa0
[<c03be061>] ? sock_queue_rcv_skb+0xb1/0x1a0
[<c03be0a7>] ? sock_queue_rcv_skb+0xf7/0x1a0
[<c03e669f>] ip_rcv+0x18f/0x290
[<c042fb10>] ? packet_rcv_spkt+0xd0/0x130
[<c03c8da6>] netif_receive_skb+0x2b6/0x330
[<c03c8c17>] ? netif_receive_skb+0x127/0x330
[<c03c8ea3>] ? process_backlog+0x83/0x100
[<c03c8eae>] process_backlog+0x8e/0x100
[<c03c90bc>] net_rx_action+0x13c/0x230
[<c03c8fd9>] ? net_rx_action+0x59/0x230
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c01078b1>] do_IRQ+0x41/0x80
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c01059ca>] common_interrupt+0x2e/0x34
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 5 vs 5 S: 0 vs 3 w: 2044790889-2044796616 (0)
TCP wq(s) LLLLl<
TCP wq(h) +++h+<
l5 s3 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_input.c:1767 tcp_enter_frto+0x28c/0x2a0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0156244>] ? __lock_acquire+0x1e4/0x730
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c03f58dc>] tcp_enter_frto+0x28c/0x2a0
[<c03ff612>] tcp_retransmit_timer+0x102/0x400
[<c043675b>] ? _spin_lock+0x4b/0x80
[<c03ff924>] ? tcp_write_timer+0x14/0x110
[<c03ffa03>] tcp_write_timer+0xf3/0x110
[<c013b95b>] run_timer_softirq+0xbb/0x190
[<c03ff910>] ? tcp_write_timer+0x0/0x110
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c011a91d>] smp_apic_timer_interrupt+0x2d/0x40
[<c0105aab>] apic_timer_interrupt+0x33/0x38
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 0, comm: swapper Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c03f5748>] tcp_enter_frto+0xf8/0x2a0
[<c03ff612>] tcp_retransmit_timer+0x102/0x400
[<c043675b>] ? _spin_lock+0x4b/0x80
[<c03ff924>] ? tcp_write_timer+0x14/0x110
[<c03ffa03>] tcp_write_timer+0xf3/0x110
[<c013b95b>] run_timer_softirq+0xbb/0x190
[<c03ff910>] ? tcp_write_timer+0x0/0x110
[<c0136f63>] __do_softirq+0x93/0x120
[<c013706a>] do_softirq+0x7a/0x80
[<c0137135>] irq_exit+0x65/0x90
[<c011a91d>] smp_apic_timer_interrupt+0x2d/0x40
[<c0105aab>] apic_timer_interrupt+0x33/0x38
[<c0103390>] ? mwait_idle_with_hints+0x40/0x50
[<c01033a0>] ? mwait_idle+0x0/0x20
[<c01033b2>] mwait_idle+0x12/0x20
[<c0103141>] cpu_idle+0x61/0x110
[<c04339fd>] rest_init+0x5d/0x60
[<c05a47fa>] start_kernel+0x1fa/0x260
[<c05a4190>] ? unknown_bootoption+0x0/0x130
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 5 vs 5 S: 0 vs 3 w: 2044790889-2044796616 (0)
TCP wq(s) LLLLl<
TCP wq(h) +++h+<
l5 s3 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_output.c:1467 tcp_write_xmit+0x288/0x290()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 2987, comm: ssmtp Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0156244>] ? __lock_acquire+0x1e4/0x730
[<c0155567>] ? mark_held_locks+0x67/0x80
[<c03fd128>] tcp_write_xmit+0x288/0x290
[<c03fd147>] __tcp_push_pending_frames+0x17/0x80
[<c03f1130>] tcp_sendmsg+0x760/0xb40
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c03bb85c>] sock_sendmsg+0xdc/0x110
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0147420>] ? autoremove_wake_function+0x0/0x50
[<c0156244>] ? __lock_acquire+0x1e4/0x730
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c03bb5ff>] ? sockfd_lookup_light+0x2f/0x70
[<c03bcfe1>] sys_sendto+0xd1/0x120
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c015323d>] ? put_lock_stats+0xd/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c01413f1>] ? sys_times+0x81/0xe0
[<c03bd062>] sys_send+0x32/0x40
[<c03bd8e6>] sys_socketcall+0x136/0x230
[<c010501b>] ? restore_nocheck+0x12/0x15
[<c0104fba>] syscall_call+0x7/0xb
=======================
---[ end trace 14b601818e6903ac ]---
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 2987, comm: ssmtp Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0156244>] ? __lock_acquire+0x1e4/0x730
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c03fcf03>] tcp_write_xmit+0x63/0x290
[<c03fd147>] __tcp_push_pending_frames+0x17/0x80
[<c03f1130>] tcp_sendmsg+0x760/0xb40
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c03bb85c>] sock_sendmsg+0xdc/0x110
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0147420>] ? autoremove_wake_function+0x0/0x50
[<c0156244>] ? __lock_acquire+0x1e4/0x730
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c03bb5ff>] ? sockfd_lookup_light+0x2f/0x70
[<c03bcfe1>] sys_sendto+0xd1/0x120
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c015323d>] ? put_lock_stats+0xd/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c01413f1>] ? sys_times+0x81/0xe0
[<c03bd062>] sys_send+0x32/0x40
[<c03bd8e6>] sys_socketcall+0x136/0x230
[<c010501b>] ? restore_nocheck+0x12/0x15
[<c0104fba>] syscall_call+0x7/0xb
=======================
---[ end trace 14b601818e6903ac ]---
P: 5 L: 5 vs 5 S: 0 vs 3 w: 2044790889-2044796616 (0)
TCP wq(s) LLLLl<
TCP wq(h) +++h+<
l5 s3 f0 p5 seq: su2044790889 hs2044795029 sn2044796616
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_input.c:2855 tcp_clean_rtx_queue+0x552/0x5b0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 2987, comm: ssmtp Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c0186dbd>] ? check_object+0xad/0x1e0
[<c0155539>] ? mark_held_locks+0x39/0x80
[<c01880ac>] ? __slab_free+0xac/0x150
[<c015561c>] ? trace_hardirqs_on+0x7c/0x130
[<c03c1534>] ? kfree_skbmem+0x54/0xc0
[<c01881e7>] ? kmem_cache_free+0x97/0xe0
[<c03c1534>] ? kfree_skbmem+0x54/0xc0
[<c03c1534>] ? kfree_skbmem+0x54/0xc0
[<c03c1534>] ? kfree_skbmem+0x54/0xc0
[<c03f7782>] tcp_clean_rtx_queue+0x552/0x5b0
[<c03f7dd2>] tcp_ack+0x122/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0147420>] ? autoremove_wake_function+0x0/0x50
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c03f17e3>] tcp_prequeue_process+0x73/0xa0
[<c03f1dae>] tcp_recvmsg+0x42e/0x830
[<c03c0873>] sock_common_recvmsg+0x43/0x60
[<c03bbacf>] sock_recvmsg+0xef/0x120
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0147420>] ? autoremove_wake_function+0x0/0x50
[<c03bb5ff>] ? sockfd_lookup_light+0x2f/0x70
[<c03bd0f7>] sys_recvfrom+0x87/0xf0
[<c015323d>] ? put_lock_stats+0xd/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c015323d>] ? put_lock_stats+0xd/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c013601f>] ? do_setitimer+0x1ef/0x2e0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03bd192>] sys_recv+0x32/0x40
[<c03bd905>] sys_socketcall+0x155/0x230
[<c010501b>] ? restore_nocheck+0x12/0x15
[<c0104fba>] syscall_call+0x7/0xb
=======================
---[ end trace 14b601818e6903ac ]---
------------[ cut here ]------------
WARNING: at net/ipv4/tcp_ipv4.c:197 tcp_verify_wq+0x1b6/0x1c0()
Modules linked in: snd_seq_dummy snd_seq_oss snd_seq_midi_event
snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss eeprom e100 psmouse
snd_hda_intel snd_pcm snd_timer btusb bluetooth serio_raw snd 3c59x sg
evdev thermal soundcore rtc_cmos snd_page_alloc rtc_core rtc_lib
i2c_i801 processor button intel_agp dcdbas pcspkr agpgart
Pid: 2987, comm: ssmtp Not tainted 2.6.24-rc8-mm1 #8
[<c0132100>] ? have_callable_console+0x20/0x30
[<c0131844>] warn_on_slowpath+0x54/0x80
[<c01317da>] ? print_oops_end_marker+0x2a/0x30
[<c0131849>] ? warn_on_slowpath+0x59/0x80
[<c0186dbd>] ? check_object+0xad/0x1e0
[<c0155539>] ? mark_held_locks+0x39/0x80
[<c01880ac>] ? __slab_free+0xac/0x150
[<c015561c>] ? trace_hardirqs_on+0x7c/0x130
[<c03c1534>] ? kfree_skbmem+0x54/0xc0
[<c0400096>] tcp_verify_wq+0x1b6/0x1c0
[<c01881e7>] ? kmem_cache_free+0x97/0xe0
[<c03c1534>] ? kfree_skbmem+0x54/0xc0
[<c03c1534>] ? kfree_skbmem+0x54/0xc0
[<c03f7509>] tcp_clean_rtx_queue+0x2d9/0x5b0
[<c03f7dd2>] tcp_ack+0x122/0x3a0
[<c03fa21b>] tcp_rcv_established+0x3eb/0x710
[<c0147420>] ? autoremove_wake_function+0x0/0x50
[<c0401c05>] tcp_v4_do_rcv+0xe5/0x100
[<c03f17e3>] tcp_prequeue_process+0x73/0xa0
[<c03f1dae>] tcp_recvmsg+0x42e/0x830
[<c03c0873>] sock_common_recvmsg+0x43/0x60
[<c03bbacf>] sock_recvmsg+0xef/0x120
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0154982>] ? validate_chain+0x1d2/0x320
[<c0147420>] ? autoremove_wake_function+0x0/0x50
[<c03bb5ff>] ? sockfd_lookup_light+0x2f/0x70
[<c03bd0f7>] sys_recvfrom+0x87/0xf0
[<c015323d>] ? put_lock_stats+0xd/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c010af95>] ? native_sched_clock+0x85/0xe0
[<c015323d>] ? put_lock_stats+0xd/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c013601f>] ? do_setitimer+0x1ef/0x2e0
[<c0156b97>] ? __lock_release+0x47/0x70
[<c03bd192>] sys_recv+0x32/0x40
[<c03bd905>] sys_socketcall+0x155/0x230
[<c010501b>] ? restore_nocheck+0x12/0x15
[<c0104fba>] syscall_call+0x7/0xb
=======================
---[ end trace 14b601818e6903ac ]---
P: 4 L: 4 vs 4 S: 0 vs 3 w: 2044792269-2044796616 (0)
TCP wq(s) LLLl<
TCP wq(h) ++h+<
l4 s3 f0 p4 seq: su2044792269 hs2044795029 sn2044796616
^ permalink raw reply
* bluetooth : lockdep warning on rfcomm
From: Dave Young @ 2008-01-24 3:02 UTC (permalink / raw)
To: LKML; +Cc: Netdev, Marcel Holtmann, David Miller, bluez-devel
=============================================
[ INFO: possible recursive locking detected ]
2.6.24-rc8-mm1 #8
---------------------------------------------
bluepush/3213 is trying to acquire lock:
(sk_lock-AF_BLUETOOTH){--..}, at: [<f8978c80>]
l2cap_sock_bind+0x40/0x100 [l2cap]
but task is already holding lock:
(sk_lock-AF_BLUETOOTH){--..}, at: [<f894a31e>]
rfcomm_sock_connect+0x3e/0xe0 [rfcomm]
other info that might help us debug this:
2 locks held by bluepush/3213:
#0: (sk_lock-AF_BLUETOOTH){--..}, at: [<f894a31e>]
rfcomm_sock_connect+0x3e/0xe0 [rfcomm]
#1: (rfcomm_mutex){--..}, at: [<f8947556>] rfcomm_dlc_open+0x26/0x60 [rfcomm]
stack backtrace:
Pid: 3213, comm: bluepush Not tainted 2.6.24-rc8-mm1 #8
[<c0132128>] ? printk+0x18/0x20
[<c0154437>] print_deadlock_bug+0xc7/0xe0
[<c01544bc>] check_deadlock+0x6c/0x80
[<c01548fc>] validate_chain+0x14c/0x320
[<c0156221>] __lock_acquire+0x1c1/0x730
[<c0156d89>] lock_acquire+0x79/0xb0
[<f8978c80>] ? l2cap_sock_bind+0x40/0x100 [l2cap]
[<c03c05f5>] lock_sock_nested+0x55/0x70
[<f8978c80>] ? l2cap_sock_bind+0x40/0x100 [l2cap]
[<f8978c80>] l2cap_sock_bind+0x40/0x100 [l2cap]
[<c03bdb4a>] kernel_bind+0xa/0x10
[<f8947afc>] rfcomm_session_create+0x4c/0x110 [rfcomm]
[<f8947509>] __rfcomm_dlc_open+0x129/0x150 [rfcomm]
[<f8947568>] rfcomm_dlc_open+0x38/0x60 [rfcomm]
[<f894a396>] rfcomm_sock_connect+0xb6/0xe0 [rfcomm]
[<c03bcd39>] sys_connect+0x99/0xd0
[<c010f509>] ? cache_add_dev+0x39/0x1a0
[<c015323d>] ? put_lock_stats+0xd/0x30
[<c01532c0>] ? lock_release_holdtime+0x60/0x80
[<c018e86c>] ? fget+0x7c/0x100
[<c0156b97>] ? __lock_release+0x47/0x70
[<c018e86c>] ? fget+0x7c/0x100
[<c02611b7>] ? copy_from_user+0x37/0x70
[<c03bd855>] sys_socketcall+0xa5/0x230
[<c0155659>] ? trace_hardirqs_on+0xb9/0x130
[<c010501b>] ? restore_nocheck+0x12/0x15
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
^ permalink raw reply
* [PATCH 2/2] sky2: fix Wake On Lan interaction with BIOS
From: Stephen Hemminger @ 2008-01-24 3:16 UTC (permalink / raw)
To: Jeff Garzik; +Cc: netdev
In-Reply-To: <20080123191151.1423a045@deepthought>
This patch disables config mode access after clearing PCI settings.
Some BIOS's seem to not do WOL if config bit still set.
Fixes: http://bugzilla.kernel.org/show_bug.cgi?id=9721
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
---
Please get this into 2.6.24.
--- a/drivers/net/sky2.c 2008-01-23 16:31:13.000000000 -0800
+++ b/drivers/net/sky2.c 2008-01-23 16:31:16.000000000 -0800
@@ -621,6 +621,7 @@ static void sky2_phy_power(struct sky2_h
static const u32 phy_power[] = { PCI_Y2_PHY1_POWD, PCI_Y2_PHY2_POWD };
static const u32 coma_mode[] = { PCI_Y2_PHY1_COMA, PCI_Y2_PHY2_COMA };
+ sky2_write8(hw, B2_TST_CTRL1, TST_CFG_WRITE_ON);
reg1 = sky2_pci_read32(hw, PCI_DEV_REG1);
/* Turn on/off phy power saving */
if (onoff)
@@ -632,7 +633,8 @@ static void sky2_phy_power(struct sky2_h
reg1 |= coma_mode[port];
sky2_pci_write32(hw, PCI_DEV_REG1, reg1);
- reg1 = sky2_pci_read32(hw, PCI_DEV_REG1);
+ sky2_write8(hw, B2_TST_CTRL1, TST_CFG_WRITE_OFF);
+ sky2_pci_read32(hw, PCI_DEV_REG1);
udelay(100);
}
@@ -2427,6 +2429,7 @@ static void sky2_hw_intr(struct sky2_hw
if (status & (Y2_IS_MST_ERR | Y2_IS_IRQ_STAT)) {
u16 pci_err;
+ sky2_write8(hw, B2_TST_CTRL1, TST_CFG_WRITE_ON);
pci_err = sky2_pci_read16(hw, PCI_STATUS);
if (net_ratelimit())
dev_err(&pdev->dev, "PCI hardware error (0x%x)\n",
@@ -2434,12 +2437,14 @@ static void sky2_hw_intr(struct sky2_hw
sky2_pci_write16(hw, PCI_STATUS,
pci_err | PCI_STATUS_ERROR_BITS);
+ sky2_write8(hw, B2_TST_CTRL1, TST_CFG_WRITE_OFF);
}
if (status & Y2_IS_PCI_EXP) {
/* PCI-Express uncorrectable Error occurred */
u32 err;
+ sky2_write8(hw, B2_TST_CTRL1, TST_CFG_WRITE_ON);
err = sky2_read32(hw, Y2_CFG_AER + PCI_ERR_UNCOR_STATUS);
sky2_write32(hw, Y2_CFG_AER + PCI_ERR_UNCOR_STATUS,
0xfffffffful);
@@ -2447,6 +2452,7 @@ static void sky2_hw_intr(struct sky2_hw
dev_err(&pdev->dev, "PCI Express error (0x%x)\n", err);
sky2_read32(hw, Y2_CFG_AER + PCI_ERR_UNCOR_STATUS);
+ sky2_write8(hw, B2_TST_CTRL1, TST_CFG_WRITE_OFF);
}
if (status & Y2_HWE_L1_MASK)
@@ -2812,6 +2818,7 @@ static void sky2_reset(struct sky2_hw *h
}
sky2_power_on(hw);
+ sky2_write8(hw, B2_TST_CTRL1, TST_CFG_WRITE_OFF);
for (i = 0; i < hw->ports; i++) {
sky2_write8(hw, SK_REG(i, GMAC_LINK_CTRL), GMLC_RST_SET);
^ permalink raw reply
* [PATCH 1/2] sky2: restore multicast addresses after recovery
From: Stephen Hemminger @ 2008-01-24 3:11 UTC (permalink / raw)
To: Jeff Garzik; +Cc: netdev
If the sky2 deadman timer forces a recovery, the multicast hash
list is lost. Move the call to sky2_set_multicast to the end
of sky2_up() so all paths that bring device up will restore multicast.
Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>
---
Please apply for 2.6.24
--- a/drivers/net/sky2.c 2008-01-23 16:00:34.000000000 -0800
+++ b/drivers/net/sky2.c 2008-01-23 16:04:20.000000000 -0800
@@ -1412,6 +1412,7 @@ static int sky2_up(struct net_device *de
imask |= portirq_msk[port];
sky2_write32(hw, B0_IMSK, imask);
+ sky2_set_multicast(dev);
return 0;
err_out:
@@ -3533,8 +3534,6 @@ static int sky2_set_ringparam(struct net
err = sky2_up(dev);
if (err)
dev_close(dev);
- else
- sky2_set_multicast(dev);
}
return err;
@@ -4368,8 +4367,6 @@ static int sky2_resume(struct pci_dev *p
dev_close(dev);
goto out;
}
-
- sky2_set_multicast(dev);
}
}
^ permalink raw reply
* [PATCH UCC TDM 0/3] UCC based TDM driver for QE based MPC83xx platforms
From: Aggrwal Poonam @ 2008-01-24 4:13 UTC (permalink / raw)
To: Kumar Gala, akpm, linux-kernel, netdev, rubini, linuxppc-dev
Cc: Barkowski Michael, Phillips Kim, Kalra Ashish, Tabi Timur,
Cutler Richard
Reworked patches after incorporating comments of Andrew, Stephen and
Tabi and Kumar.
Kumar could you please consider them for linux-2.6.25.
There are three patches
[PATCH 1/3] drivers/misc : UCC TDM driver for mpc83xx platforms. This
driver is usable in VoIP iind of applications to interface with SLIC
kind of devices to exchange TDM voice samples.
The driver is right now in misc category and exposes a kind of non
standard interface to the clients.
TDM Driver Interface Details
The TDM driver right now is a misc driver with no subsystem as such.
The dts file keeps a track of the TDM devices present on the board.
Depending on them the TDM driver initializes those many driver instances
while coming up.
The driver on the upper level can plug to more than one tdm clients
depending on the availablity of TDM devices.
At every new request of the TDM client to bind with a TDM device, a free
driver instance is allocated to the client.
The interface can be described as follows.
tdm_register_client(struct tdm_client *)
This API returns a pointer to the structure tdm_client which is
of type
struct tdm_client {
u32 client_id;
u32 (*tdm_read)(u32 client_id, short chn_id, short
*pcm_buffer, short len);
u32 (*tdm_write)(u32 client_id, short chn_id, short
*pcm_buffer, short len);
wait_queue_head_t *wakeup_event;
}
It consists of:
- driver_handle: It is basically to identify the particular TDM
device/driver instance.
- tdm_read: It is a function pointer returned by the TDM driver to be
used to read TDM data from a particular TDM channel.
- tdm_write: It is a function pointer returned by the TDM driver to
be used to write TDM data to a particular TDM channel.
- wakeup_event: It is address of a wait_queue event on which the
client keeps on sleeping, and the TDM driver wakes it up periodically.
The driver is configured to wake up the client after every 10ms.
Once the TDM client gets registered to a TDM driver instance and a TDM
device, it interfaces with the driver using tdm_read, tdm_write and
wakeup_event.
Note: The TDM driver can be used by only kernel level modules. The
driver does not expose any file interface for User Applications. Can be
compared to the spi driver which interfaces with the SPI clients(kernel
mode clients) through some APIs.
This interface can be improved by writing a platform independent TDM
layer. Then all the TDM platforms can be supported below this wrapper
layer. This is planned to be done later.
[PATCH 2/3] arch/ : Platform changes
- device tree entries for UCC TDM driver for MPC8323ERDB platform.
- QE changes related to TDM , like,
1) Modified ucc_fast_init so that it can be used by fast UCC
based TDM driver. Mainly changes have been made to configure TDM clocks
and Fsyncs.
2) Modified get_brg_clk so that it can return the input frequncy
and input source of any BRG by reading the corresponding entries from
device tree.
3) Added new nodes brg and clocks in the device tree which
represent input clocks for different BRGs.
4) Modified qe_setbrg accordingly.
- new device tree entries added for "clocks" and "brg"
[PATCH 3/3] Documentation
- Modified Documentation to explain the device tree entries related to
UCC TDM driver and the new nodes added("clocks" and "brg")
The patch applies over a merge of galak's for-2.6.25 plus for-2.6.24
plus of_doc_update branches.
In brief the steps were
git clone
git://git.kernel.org/pub/scm/linux/kernel/git/galak/powerpc.git
powerpc-galak
git checkout -b for-2.6.25 origin/for-2.6.25 git checkout -b for-2.6.24
origin/for-2.6.24 git checkout -b of_doc_update origin/of_doc_update
git pull . for-2.6.24 # merge the other two
git pull . for-2.6.25
git checkout -b tdm # clean slate for tdm rebase work
Also after applying the patches changes have to be made corresponding to
Tabi's patch "qe: add function qe_clock_source".
The driver has been tested with a VoIP stack and application on
MPC8323ERDB.
With Regards
Poonam
^ permalink raw reply
* Re: [NET_SCHED 00/15]: Make use of new netlink API features
From: David Miller @ 2008-01-24 4:37 UTC (permalink / raw)
To: kaber; +Cc: netdev
In-Reply-To: <20080123163555.6459.69501.sendpatchset@localhost.localdomain>
From: Patrick McHardy <kaber@trash.net>
Date: Wed, 23 Jan 2008 17:36:35 +0100 (MET)
> these patches change the packet schedulers/classifers/actions to make use
> of the features of the new netlink API, like typeful attribute dumping and
> parsing, automatic basic attribute validation etc. The also fix a bug and
> a warning introduced by my last set of patches.
>
> Please apply, thanks.
All applied, thanks for doing this work Patrick.
^ permalink raw reply
* Re: [IPV4 1/5] fib_trie: more whitespace cleanup
From: David Miller @ 2008-01-24 4:37 UTC (permalink / raw)
To: shemminger; +Cc: netdev
In-Reply-To: <20080123224858.767903581@linux-foundation.org>
From: Stephen Hemminger <shemminger@linux-foundation.org>
Date: Wed, 23 Jan 2008 14:48:45 -0800
> Remove extra blank lines.
>
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Applied.
^ permalink raw reply
* Re: [IPV4 2/5] fib_trie: remove unneeded NULL check
From: David Miller @ 2008-01-24 4:38 UTC (permalink / raw)
To: shemminger; +Cc: netdev
In-Reply-To: <20080123224858.844259513@linux-foundation.org>
From: Stephen Hemminger <shemminger@linux-foundation.org>
Date: Wed, 23 Jan 2008 14:48:46 -0800
> Since fib_route_seq_show now uses hlist_for_each_entry(), the
> leaf info can not be NULL.
>
> Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Applied.
^ permalink raw reply
* [PATCH] UCC TDM driver for QE based MPC83xx platforms.
From: Poonam_Aggrwal-b10812 @ 2008-01-24 4:46 UTC (permalink / raw)
To: kumar.gala, akpm, linux-kernel, netdev, rubini, linuxppc-dev
Cc: michael.barkowski, kim.phillips, ashish.kalra, timur, rich.cutler
From: Poonam Agarwal-b10812 <b10812@freescale.com>
The UCC TDM driver basically multiplexes and demultiplexes data from
different channels. It can interface with for example SLIC kind of devices
to receive TDM data demultiplex it and send to upper modules. At the
transmit end it receives data for different channels multiplexes it and
sends them on the TDM channel. It internally uses TSA( Time Slot Assigner)
which does multiplexing and demultiplexing, UCC to perform SDMA between
host buffers and the TSA, CMX to connect TSA to UCC.
It can be used by a kernel module which can call tdm_register_client to
get access to a TDM device.
The driver is right now a misc driver with no subsystem as such.
There can be a platform independent TDM layer which is planned to be
done after this. TDM bus sort of thing.
The dts file keeps a track of the TDM devices present on the board.
Depending on them the TDM driver initializes those many driver instances
while coming up.
The driver on the upper level can plug to more than one tdm clients
depending on the availablity of TDM devices. At every new request of a TDM
client to bind with a TDM device, a free driver instance is allocated to
the client.
The interface can be described as follows.
tdm_register_client(struct tdm_client *)
This API returns a pointer to the structure tdm_client which is of
type
struct tdm_client {
u32 client_id;
u32 (*tdm_read)(u32 client_id, short chn_id, short
*pcm_buffer, short len);
u32 (*tdm_write)(u32 client_id, short chn_id, short
*pcm_buffer, short len);
wait_queue_head_t *wakeup_event;
}
It consists of:
- client_id: It is basically to identify the particular TDM
device/driver instance.
- tdm_read: It is a function pointer returned by the TDM driver to be
used to read TDM data from a particular TDM channel.
- tdm_write: It is a function pointer returned by the TDM driver to be
used to write TDM data to a particular TDM channel.
- wakeup_event: It is address of a wait_queue event on which the client
keeps on sleeping, and the TDM driver wakes it up periodically. The driver
is configured to
wake up the client after every 10ms.
Once the TDM client gets registered to a TDM driver instance and a TDM
device, it interfaces with the driver using tdm_read, tdm_write and
wakeup_event.
This driver will run on MPC8323E-RDB platforms.
Signed-off-by: Poonam Aggrwal <b10812@freescale.com>
Signed-off-by: Ashish Kalra <ashish.kalra@freescale.com>
Signed-off-by: Kim Phillips <Kim.Phillips@freescale.com>
Signed-off-by: Michael Barkowski <michael.barkowski@freescale.com>
---
drivers/misc/Kconfig | 14 +
drivers/misc/Makefile | 1 +
drivers/misc/ucc_tdm.c | 1000 ++++++++++++++++++++++++++++++++++++++++++++++++
drivers/misc/ucc_tdm.h | 221 +++++++++++
4 files changed, 1236 insertions(+), 0 deletions(-)
create mode 100644 drivers/misc/ucc_tdm.c
create mode 100644 drivers/misc/ucc_tdm.h
diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig
index b5e67c0..628b14b 100644
--- a/drivers/misc/Kconfig
+++ b/drivers/misc/Kconfig
@@ -232,4 +232,18 @@ config ATMEL_SSC
If unsure, say N.
+config UCC_TDM
+ bool "Freescale UCC TDM Driver"
+ depends on QUICC_ENGINE && UCC_FAST
+ default n
+ ---help---
+ The TDM driver is for UCC based TDM devices for example, TDM device on
+ MPC832x RDB. Select it to run PowerVoIP on MPC832x RDB board.
+ The TDM driver can interface with SLIC kind of devices to transmit
+ and receive TDM samples. The TDM driver receives Time Division
+ multiplexed samples(for different channels) from the SLIC device,
+ demutiplexes them and sends them to the upper layers. At the transmit
+ end the TDM drivers receives samples for different channels, it
+ multiplexes them and sends them to the SLIC device.
+
endif # MISC_DEVICES
diff --git a/drivers/misc/Makefile b/drivers/misc/Makefile
index 87f2685..6f0c49d 100644
--- a/drivers/misc/Makefile
+++ b/drivers/misc/Makefile
@@ -17,3 +17,4 @@ obj-$(CONFIG_SONY_LAPTOP) += sony-laptop.o
obj-$(CONFIG_THINKPAD_ACPI) += thinkpad_acpi.o
obj-$(CONFIG_FUJITSU_LAPTOP) += fujitsu-laptop.o
obj-$(CONFIG_EEPROM_93CX6) += eeprom_93cx6.o
+obj-$(CONFIG_UCC_TDM) += ucc_tdm.o
diff --git a/drivers/misc/ucc_tdm.c b/drivers/misc/ucc_tdm.c
new file mode 100644
index 0000000..98e7c72
--- /dev/null
+++ b/drivers/misc/ucc_tdm.c
@@ -0,0 +1,1000 @@
+/*
+ * drivers/misc/ucc_tdm.c
+ *
+ * UCC Based Linux TDM Driver
+ * This driver is designed to support UCC based TDM for PowerPC processors.
+ * This driver can interface with SLIC device to run VOIP kind of
+ * applications.
+ *
+ * Author: Ashish Kalra & Poonam Aggrwal
+ *
+ * Copyright (c) 2007 Freescale Semiconductor, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the
+ * Free Software Foundation; either version 2 of the License, or (at your
+ * option) any later version.
+ */
+
+#include <linux/autoconf.h>
+#include <linux/module.h>
+#include <linux/sched.h>
+#include <linux/kernel.h>
+#include <linux/slab.h>
+#include <linux/errno.h>
+#include <linux/types.h>
+#include <linux/interrupt.h>
+#include <linux/time.h>
+#include <linux/skbuff.h>
+#include <linux/proc_fs.h>
+#include <linux/delay.h>
+#include <linux/dma-mapping.h>
+#include <linux/string.h>
+#include <linux/irq.h>
+#include <linux/of_platform.h>
+#include <linux/io.h>
+#include <linux/wait.h>
+#include <linux/timer.h>
+
+#include <asm/immap_qe.h>
+#include <asm/qe.h>
+#include <asm/ucc.h>
+#include <asm/ucc_fast.h>
+#include <asm/ucc_slow.h>
+
+#include "ucc_tdm.h"
+#define DRV_DESC "Freescale QE UCC TDM Driver"
+#define DRV_NAME "ucc_tdm"
+
+
+/*
+ * define the following #define if snooping or hardware-based cache coherency
+ * is disabled on the UCC transparent controller.This flag enables
+ * software-based cache-coherency support by explicitly flushing data cache
+ * contents after setting up the TDM output buffer(s) and invalidating the
+ * data cache contents before the TDM input buffer(s) are read.
+ */
+#undef UCC_CACHE_SNOOPING_DISABLED
+
+#define MAX_NUM_TDM_DEVICES 8
+
+static struct tdm_ctrl *tdm_ctrl[MAX_NUM_TDM_DEVICES];
+
+static int num_tdm_devices;
+static int num_tdm_clients;
+
+static struct ucc_tdm_info utdm_primary_info = {
+ .uf_info = {
+ .tsa = 1,
+ .cdp = 1,
+ .cds = 1,
+ .ctsp = 1,
+ .ctss = 1,
+ .revd = 1,
+ .urfs = 0x128,
+ .utfs = 0x128,
+ .utfet = 0,
+ .utftt = 0x128,
+ .ufpt = 256,
+ .ttx_trx = UCC_FAST_GUMR_TRANSPARENT_TTX_TRX_TRANSPARENT,
+ .tenc = UCC_FAST_TX_ENCODING_NRZ,
+ .renc = UCC_FAST_RX_ENCODING_NRZ,
+ .tcrc = UCC_FAST_16_BIT_CRC,
+ .synl = UCC_FAST_SYNC_LEN_NOT_USED,
+ },
+ .ucc_busy = 0,
+};
+
+static struct ucc_tdm_info utdm_info[8];
+
+static void dump_siram(struct tdm_ctrl *tdm_c)
+{
+#ifdef DEBUG
+ int i;
+ u16 phy_num_ts;
+
+ phy_num_ts = tdm_c->physical_num_ts;
+
+ pr_debug("SI TxRAM dump\n");
+ /* each slot entry in SI RAM is of 2 bytes */
+ for (i = 0; i < phy_num_ts * 2; i++)
+ pr_debug("%x ", in_8(&qe_immr->sir.tx[i]));
+ pr_debug("\nSI RxRAM dump\n");
+ for (i = 0; i < phy_num_ts * 2; i++)
+ pr_debug("%x ", in_8(&qe_immr->sir.rx[i]));
+ pr_debug("\n");
+#endif
+}
+
+static void dump_ucc(struct tdm_ctrl *tdm_c)
+{
+#ifdef DEBUG
+ struct ucc_transparent_pram *ucc_pram;
+
+ ucc_pram = tdm_c->ucc_pram;
+
+ pr_debug("%s Dumping UCC Registers\n", __FUNCTION__);
+ ucc_fast_dump_regs(tdm_c->uf_private);
+ pr_debug("%s Dumping UCC Parameter RAM\n", __FUNCTION__);
+ pr_debug("rbase = 0x%x\n", in_be32(&ucc_pram->rbase));
+ pr_debug("rbptr = 0x%x\n", in_be32(&ucc_pram->rbptr));
+ pr_debug("mrblr = 0x%x\n", in_be16(&ucc_pram->mrblr));
+ pr_debug("rbdlen = 0x%x\n", in_be16(&ucc_pram->rbdlen));
+ pr_debug("rbdstat = 0x%x\n", in_be16(&ucc_pram->rbdstat));
+ pr_debug("rstate = 0x%x\n", in_be32(&ucc_pram->rstate));
+ pr_debug("rdptr = 0x%x\n", in_be32(&ucc_pram->rdptr));
+ pr_debug("tbase = 0x%x\n", in_be32(&ucc_pram->tbase));
+ pr_debug("tbptr = 0x%x\n", in_be32(&ucc_pram->tbptr));
+ pr_debug("tbdlen = 0x%x\n", in_be16(&ucc_pram->tbdlen));
+ pr_debug("tbdstat = 0x%x\n", in_be16(&ucc_pram->tbdstat));
+ pr_debug("tstate = 0x%x\n", in_be32(&ucc_pram->tstate));
+ pr_debug("tdptr = 0x%x\n", in_be32(&ucc_pram->tdptr));
+#endif
+}
+
+/*
+ * For use when a framing bit is not present
+ * Program current-route SI ram
+ * Set SIxRAM TDMx
+ * Entries must be in units of 8.
+ * SIR_UCC -> Channel Select
+ * SIR_CNT -> Number of bits or bytes
+ * SIR_BYTE -> Byte or Bit resolution
+ * SIR_LAST -> Indicates last entry in SIxRAM
+ * SIR_IDLE -> The Tx data pin is Tri-stated and the Rx data pin is
+ * ignored
+ */
+static void set_siram(struct tdm_ctrl *tdm_c, enum comm_dir dir)
+{
+ const u16 *mask;
+ u16 temp_mask = 1;
+ u16 siram_code = 0;
+ u32 i, j, k;
+ u32 ucc;
+ u32 phy_num_ts;
+
+ phy_num_ts = tdm_c->physical_num_ts;
+ ucc = tdm_c->ut_info->uf_info.ucc_num;
+
+ if (dir == COMM_DIR_RX)
+ mask = tdm_c->rx_mask;
+ else
+ mask = tdm_c->tx_mask;
+ k = 0;
+ j = 0;
+ for (i = 0; i < phy_num_ts; i++) {
+ if ((mask[k] & temp_mask) == temp_mask)
+ siram_code = SIR_UCC(ucc) | SIR_CNT(0) | SIR_BYTE;
+ else
+ siram_code = SIR_IDLE | SIR_CNT(0) | SIR_BYTE;
+ if (dir == COMM_DIR_RX)
+ out_be16((u16 *)&qe_immr->sir.rx[i * 2], siram_code);
+ else
+ out_be16((u16 *)&qe_immr->sir.tx[i * 2], siram_code);
+ temp_mask = temp_mask << 1;
+ j++;
+ if (j >= 16) {
+ j = 0;
+ temp_mask = 0x0001;
+ k++;
+ }
+ }
+ siram_code = siram_code | SIR_LAST;
+
+ if (dir == COMM_DIR_RX)
+ out_be16((u16 *)&qe_immr->sir.rx[(phy_num_ts - 1) * 2],
+ siram_code);
+ else
+ out_be16((u16 *)&qe_immr->sir.tx[(phy_num_ts - 1) * 2],
+ siram_code);
+}
+
+static void config_si(struct tdm_ctrl *tdm_c)
+{
+ u8 rxsyncdelay, txsyncdelay, tdm_port;
+ u16 sixmr_val = 0;
+ u32 tdma_mode_off;
+ u16 *si1_tdm_mode_reg;
+
+ tdm_port = tdm_c->tdm_port;
+
+ set_siram(tdm_c, COMM_DIR_RX);
+
+ set_siram(tdm_c, COMM_DIR_TX);
+
+ rxsyncdelay = tdm_c->cfg_ctrl.rx_fr_sync_delay;
+ txsyncdelay = tdm_c->cfg_ctrl.tx_fr_sync_delay;
+ if (tdm_c->cfg_ctrl.com_pin)
+ sixmr_val |= SIMODE_CRT;
+ if (tdm_c->cfg_ctrl.fr_sync_level == 1)
+ sixmr_val |= SIMODE_SL;
+ if (tdm_c->cfg_ctrl.clk_edge == 1)
+ sixmr_val |= SIMODE_CE;
+ if (tdm_c->cfg_ctrl.fr_sync_edge == 1)
+ sixmr_val |= SIMODE_FE;
+ sixmr_val |= (SIMODE_TFSD(txsyncdelay) | SIMODE_RFSD(rxsyncdelay));
+
+ tdma_mode_off = SI_TDM_MODE_REGISTER_OFFSET * tdm_c->tdm_port;
+
+ si1_tdm_mode_reg = (u8 *)&qe_immr->si1 + tdma_mode_off;
+ out_be16(si1_tdm_mode_reg, sixmr_val);
+
+ dump_siram(tdm_c);
+}
+
+static int tdm_init(struct tdm_ctrl *tdm_c)
+{
+ u32 tdm_port, ucc, act_num_ts;
+ int ret, i, err;
+ u32 cecr_subblock;
+ u32 pram_offset;
+ u32 rxbdt_offset;
+ u32 txbdt_offset;
+ u32 rx_ucode_buf_offset, tx_ucode_buf_offset;
+ u16 bd_status, bd_len;
+ enum qe_clock clock;
+ struct qe_bd __iomem *rx_bd, *tx_bd;
+
+ tdm_port = tdm_c->tdm_port;
+ ucc = tdm_c->ut_info->uf_info.ucc_num;
+ act_num_ts = tdm_c->cfg_ctrl.active_num_ts;
+
+ /*
+ * TDM Tx and Rx CLKs = 2048 KHz.
+ */
+ if (strstr(tdm_c->ut_info->uf_info.tdm_tx_clk, "BRG")) {
+ clock = qe_clock_source(tdm_c->ut_info->uf_info.tdm_tx_clk);
+ err = qe_setbrg(clock, 2048000, 1);
+ if (err < 0) {
+ printk(KERN_ERR "%s: Failed to set %s\n", __FUNCTION__,
+ tdm_c->ut_info->uf_info.tdm_tx_clk);
+ return err;
+ }
+ }
+ if (strstr(tdm_c->ut_info->uf_info.tdm_rx_clk, "BRG")) {
+ clock = qe_clock_source(tdm_c->ut_info->uf_info.tdm_rx_clk);
+ err = qe_setbrg(clock, 2048000, 1);
+ if (err < 0) {
+ printk(KERN_ERR "%s: Failed to set %s\n", __FUNCTION__,
+ tdm_c->ut_info->uf_info.tdm_rx_clk);
+ return err;
+ }
+ }
+ /*
+ * TDM FSyncs = 4 KHz.
+ */
+ if (strstr(tdm_c->ut_info->uf_info.tdm_tx_sync, "BRG")) {
+ clock = qe_clock_source(tdm_c->ut_info->uf_info.tdm_tx_sync);
+ err = qe_setbrg(clock, 4000, 1);
+ if (err < 0) {
+ printk(KERN_ERR "%s: Failed to set %s\n", __FUNCTION__,
+ tdm_c->ut_info->uf_info.tdm_tx_sync);
+ return err;
+ }
+ }
+ if (strstr(tdm_c->ut_info->uf_info.tdm_rx_sync, "BRG")) {
+ clock = qe_clock_source(tdm_c->ut_info->uf_info.tdm_rx_sync);
+ err = qe_setbrg(clock, 4000, 1);
+ if (err < 0) {
+ printk(KERN_ERR "%s: Failed to set %s\n", __FUNCTION__,
+ tdm_c->ut_info->uf_info.tdm_rx_sync);
+ return err;
+ }
+ }
+
+ tdm_c->ut_info->uf_info.uccm_mask = (u32)
+ ((UCC_TRANS_UCCE_RXB | UCC_TRANS_UCCE_BSY) << 16);
+
+ if (ucc_fast_init(&(tdm_c->ut_info->uf_info), &tdm_c->uf_private)) {
+ printk(KERN_ERR "%s: Failed to init uccf\n", __FUNCTION__);
+ return -ENOMEM;
+ }
+
+ ucc_fast_disable(tdm_c->uf_private, COMM_DIR_RX | COMM_DIR_TX);
+
+ /* Write to QE CECR, UCCx channel to Stop Transmission */
+ cecr_subblock = ucc_fast_get_qe_cr_subblock(ucc);
+ qe_issue_cmd(QE_STOP_TX, cecr_subblock,
+ (u8) QE_CR_PROTOCOL_UNSPECIFIED, 0);
+
+ pram_offset = qe_muram_alloc(UCC_TRANSPARENT_PRAM_SIZE,
+ ALIGNMENT_OF_UCC_SLOW_PRAM);
+ if (IS_ERR_VALUE(pram_offset)) {
+ printk(KERN_ERR "%s: Cannot allocate MURAM memory for"
+ " transparent UCC\n", __FUNCTION__);
+ ret = -ENOMEM;
+ goto pram_alloc_error;
+ }
+
+ cecr_subblock = ucc_fast_get_qe_cr_subblock(ucc);
+ qe_issue_cmd(QE_ASSIGN_PAGE_TO_DEVICE, cecr_subblock,
+ QE_CR_PROTOCOL_UNSPECIFIED, pram_offset);
+
+ tdm_c->ucc_pram = qe_muram_addr(pram_offset);
+ tdm_c->ucc_pram_offset = pram_offset;
+
+ /*
+ * zero-out pram, this will also ensure RSTATE, TSTATE are cleared, also
+ * DISFC & CRCEC counters will be initialized.
+ */
+ memset(tdm_c->ucc_pram, 0, sizeof(struct ucc_transparent_pram));
+
+ /* rbase, tbase alignment is 8. */
+ rxbdt_offset = qe_muram_alloc(NR_BUFS * sizeof(struct qe_bd),
+ QE_ALIGNMENT_OF_BD);
+ if (IS_ERR_VALUE(rxbdt_offset)) {
+ printk(KERN_ERR "%s: Cannot allocate MURAM memory for RxBDs\n",
+ __FUNCTION__);
+ ret = -ENOMEM;
+ goto rxbd_alloc_error;
+ }
+ txbdt_offset = qe_muram_alloc(NR_BUFS * sizeof(struct qe_bd),
+ QE_ALIGNMENT_OF_BD);
+ if (IS_ERR_VALUE(txbdt_offset)) {
+ printk(KERN_ERR "%s: Cannot allocate MURAM memory for TxBDs\n",
+ __FUNCTION__);
+ ret = -ENOMEM;
+ goto txbd_alloc_error;
+ }
+ tdm_c->tx_bd = qe_muram_addr(txbdt_offset);
+ tdm_c->rx_bd = qe_muram_addr(rxbdt_offset);
+
+ tdm_c->tx_bd_offset = txbdt_offset;
+ tdm_c->rx_bd_offset = rxbdt_offset;
+
+ rx_bd = tdm_c->rx_bd;
+ tx_bd = tdm_c->tx_bd;
+
+ out_be32(&tdm_c->ucc_pram->rbase, (u32) immrbar_virt_to_phys(rx_bd));
+ out_be32(&tdm_c->ucc_pram->tbase, (u32) immrbar_virt_to_phys(tx_bd));
+
+ for (i = 0; i < NR_BUFS - 1; i++) {
+ bd_status = (u16) ((R_E | R_CM | R_I) >> 16);
+ bd_len = 0;
+ out_be16(&rx_bd->length, bd_len);
+ out_be16(&rx_bd->status, bd_status);
+ out_be32(&rx_bd->buf,
+ tdm_c->dma_input_addr + i * SAMPLE_DEPTH * act_num_ts);
+ rx_bd += 1;
+
+ bd_status = (u16) ((T_R | T_CM) >> 16);
+ bd_len = SAMPLE_DEPTH * act_num_ts;
+ out_be16(&tx_bd->length, bd_len);
+ out_be16(&tx_bd->status, bd_status);
+ out_be32(&tx_bd->buf,
+ tdm_c->dma_output_addr + i * SAMPLE_DEPTH * act_num_ts);
+ tx_bd += 1;
+ }
+
+ bd_status = (u16) ((R_E | R_CM | R_I | R_W) >> 16);
+ bd_len = 0;
+ out_be16(&rx_bd->length, bd_len);
+ out_be16(&rx_bd->status, bd_status);
+ out_be32(&rx_bd->buf,
+ tdm_c->dma_input_addr + i * SAMPLE_DEPTH * act_num_ts);
+
+ bd_status = (u16) ((T_R | T_CM | T_W) >> 16);
+ bd_len = SAMPLE_DEPTH * act_num_ts;
+ out_be16(&tx_bd->length, bd_len);
+ out_be16(&tx_bd->status, bd_status);
+ out_be32(&tx_bd->buf,
+ tdm_c->dma_output_addr + i * SAMPLE_DEPTH * act_num_ts);
+
+ config_si(tdm_c);
+
+ setbits32(&qe_immr->ic.qimr, (0x80000000UL >> ucc));
+
+ rx_ucode_buf_offset = qe_muram_alloc(32, 32);
+ if (IS_ERR_VALUE(rx_ucode_buf_offset)) {
+ printk(KERN_ERR "%s: Cannot allocate MURAM mem for Rx"
+ " ucode buf\n", __FUNCTION__);
+ ret = -ENOMEM;
+ goto rxucode_buf_alloc_error;
+ }
+
+ tx_ucode_buf_offset = qe_muram_alloc(32, 32);
+ if (IS_ERR_VALUE(tx_ucode_buf_offset)) {
+ printk(KERN_ERR "%s: Cannot allocate MURAM mem for Tx"
+ " ucode buf\n", __FUNCTION__);
+ ret = -ENOMEM;
+ goto txucode_buf_alloc_error;
+ }
+ out_be16(&tdm_c->ucc_pram->riptr, (u16) rx_ucode_buf_offset);
+ out_be16(&tdm_c->ucc_pram->tiptr, (u16) tx_ucode_buf_offset);
+
+ tdm_c->rx_ucode_buf_offset = rx_ucode_buf_offset;
+ tdm_c->tx_ucode_buf_offset = tx_ucode_buf_offset;
+
+ /*
+ * set the receive buffer descriptor maximum size to be
+ * SAMPLE_DEPTH * number of active RX channels
+ */
+ out_be16(&tdm_c->ucc_pram->mrblr, (u16) SAMPLE_DEPTH * act_num_ts);
+
+ /*
+ * enable snooping and BE byte ordering on the UCC pram's
+ * tstate & rstate registers.
+ */
+ out_be32(&tdm_c->ucc_pram->tstate, 0x30000000UL);
+ out_be32(&tdm_c->ucc_pram->rstate, 0x30000000UL);
+
+ /*Put UCC transparent controller into serial interface mode. */
+ out_be32(&tdm_c->uf_regs->upsmr, 0);
+
+ /* Reset TX and RX for UCCx */
+ cecr_subblock = ucc_fast_get_qe_cr_subblock(ucc);
+ qe_issue_cmd(QE_INIT_TX_RX, cecr_subblock,
+ (u8) QE_CR_PROTOCOL_UNSPECIFIED, 0);
+
+ return 0;
+
+txucode_buf_alloc_error:
+ qe_muram_free(rx_ucode_buf_offset);
+rxucode_buf_alloc_error:
+ qe_muram_free(txbdt_offset);
+txbd_alloc_error:
+ qe_muram_free(rxbdt_offset);
+rxbd_alloc_error:
+ qe_muram_free(pram_offset);
+pram_alloc_error:
+ ucc_fast_free(tdm_c->uf_private);
+ return ret;
+}
+
+static void tdm_deinit(struct tdm_ctrl *tdm_c)
+{
+ qe_muram_free(tdm_c->rx_ucode_buf_offset);
+ qe_muram_free(tdm_c->tx_ucode_buf_offset);
+
+ if (tdm_c->rx_bd_offset) {
+ qe_muram_free(tdm_c->rx_bd_offset);
+ tdm_c->rx_bd = NULL;
+ tdm_c->rx_bd_offset = 0;
+ }
+ if (tdm_c->tx_bd_offset) {
+ qe_muram_free(tdm_c->tx_bd_offset);
+ tdm_c->tx_bd = NULL;
+ tdm_c->tx_bd_offset = 0;
+ }
+ if (tdm_c->ucc_pram_offset) {
+ qe_muram_free(tdm_c->ucc_pram_offset);
+ tdm_c->ucc_pram = NULL;
+ tdm_c->ucc_pram_offset = 0;
+ }
+}
+
+
+static irqreturn_t tdm_isr(int irq, void *dev_id)
+{
+ u8 *input_tdm_buffer, *output_tdm_buffer;
+ u32 txb, rxb;
+ u32 ucc;
+ register u32 ucce = 0;
+ struct tdm_ctrl *tdm_c;
+ tdm_c = (struct tdm_ctrl *)dev_id;
+
+ tdm_c->tdm_icnt++;
+ ucc = tdm_c->ut_info->uf_info.ucc_num;
+ input_tdm_buffer = tdm_c->tdm_input_data;
+ output_tdm_buffer = tdm_c->tdm_output_data;
+
+ if (in_be32(tdm_c->uf_private->p_ucce) &
+ (UCC_TRANS_UCCE_BSY << 16)) {
+ out_be32(tdm_c->uf_private->p_ucce,
+ (UCC_TRANS_UCCE_BSY << 16));
+ pr_info("%s: From tdm isr busy interrupt\n",
+ __FUNCTION__);
+ dump_ucc(tdm_c);
+
+ return IRQ_HANDLED;
+ }
+
+ if (tdm_c->tdm_flag == 1) {
+ /* track phases for Rx/Tx */
+ tdm_c->phase_rx += 1;
+ if (tdm_c->phase_rx == MAX_PHASE)
+ tdm_c->phase_rx = 0;
+
+ tdm_c->phase_tx += 1;
+ if (tdm_c->phase_tx == MAX_PHASE)
+ tdm_c->phase_tx = 0;
+
+#ifdef CONFIG_TDM_HW_LB_TSA_SLIC
+ {
+ u32 temp_rx, temp_tx, phase_tx, phase_rx;
+ int i;
+ phase_rx = tdm_c->phase_rx;
+ phase_tx = tdm_c->phase_tx;
+ if (phase_rx == 0)
+ phase_rx = MAX_PHASE;
+ else
+ phase_rx -= 1;
+ if (phase_tx == 0)
+ phase_tx = MAX_PHASE;
+ else
+ phase_tx -= 1;
+ temp_rx = phase_rx * SAMPLE_DEPTH * ACTIVE_CH;
+ temp_tx = phase_tx * SAMPLE_DEPTH * ACTIVE_CH;
+
+ /*check if loopback received data on TS0 is correct. */
+ pr_debug("%s: check if loopback received data on TS0"
+ " is correct\n", __FUNCTION__);
+ pr_debug("%d,%d ", phase_rx, phase_tx);
+ for (i = 0; i < 8; i++)
+ pr_debug("%1d,%1d ",
+ input_tdm_buffer[temp_rx + i],
+ output_tdm_buffer[temp_tx + i]);
+ pr_debug("\n");
+ }
+#endif
+
+ /* schedule BH */
+ wake_up_interruptible(&tdm_c->wakeup_event);
+ } else {
+ if (tdm_c->tdm_icnt == STUTTER_INT_CNT) {
+ txb = in_be32(&tdm_c->ucc_pram->tbptr) -
+ in_be32(&tdm_c->ucc_pram->tbase);
+ rxb = in_be32(&tdm_c->ucc_pram->rbptr) -
+ in_be32(&tdm_c->ucc_pram->rbase);
+ tdm_c->phase_tx = txb / sizeof(struct qe_bd);
+ tdm_c->phase_rx = rxb / sizeof(struct qe_bd);
+
+#ifdef CONFIG_TDM_HW_LB_TSA_SLIC
+ tdm_c->phase_tx = tdm_c->phase_rx;
+#endif
+
+ /* signal "stuttering" period is over */
+ tdm_c->tdm_flag = 1;
+
+ pr_debug("%s: stuttering period is over\n",
+ __FUNCTION__);
+
+ if (in_be32(tdm_c->uf_private->p_ucce) &
+ (UCC_TRANS_UCCE_TXE << 16)) {
+ u32 cecr_subblock;
+ out_be32(tdm_c->uf_private->p_ucce,
+ (UCC_TRANS_UCCE_TXE << 16));
+ pr_debug("%s: From tdm isr txe interrupt\n",
+ __FUNCTION__);
+
+ cecr_subblock =
+ ucc_fast_get_qe_cr_subblock(ucc);
+ qe_issue_cmd(QE_RESTART_TX, cecr_subblock,
+ (u8) QE_CR_PROTOCOL_UNSPECIFIED,
+ 0);
+ }
+ }
+ }
+
+ ucce = (in_be32(tdm_c->uf_private->p_ucce)
+ & in_be32(tdm_c->uf_private->p_uccm));
+
+ out_be32(tdm_c->uf_private->p_ucce, ucce);
+
+ return IRQ_HANDLED;
+}
+
+static int tdm_start(struct tdm_ctrl *tdm_c)
+{
+ if (request_irq(tdm_c->ut_info->uf_info.irq, tdm_isr,
+ 0, "tdm", tdm_c)) {
+ printk(KERN_ERR "%s: request_irq for tdm_isr failed\n",
+ __FUNCTION__);
+ return -ENODEV;
+ }
+
+ ucc_fast_enable(tdm_c->uf_private, COMM_DIR_RX | COMM_DIR_TX);
+
+ pr_info("%s 16-bit linear pcm mode active with"
+ " slots 0 & 2\n", __FUNCTION__);
+
+ dump_siram(tdm_c);
+ dump_ucc(tdm_c);
+
+ setbits8(&(qe_immr->si1.siglmr1_h), (0x1 << tdm_c->tdm_port));
+ pr_info("%s UCC based TDM enabled\n", __FUNCTION__);
+
+ return 0;
+}
+
+static void tdm_stop(struct tdm_ctrl *tdm_c)
+{
+ u32 port, si;
+ u32 ucc;
+ u32 cecr_subblock;
+
+ port = tdm_c->tdm_port;
+ si = tdm_c->si;
+ ucc = tdm_c->ut_info->uf_info.ucc_num;
+ cecr_subblock = ucc_fast_get_qe_cr_subblock(ucc);
+
+ qe_issue_cmd(QE_GRACEFUL_STOP_TX, cecr_subblock,
+ (u8) QE_CR_PROTOCOL_UNSPECIFIED, 0);
+ qe_issue_cmd(QE_CLOSE_RX_BD, cecr_subblock,
+ (u8) QE_CR_PROTOCOL_UNSPECIFIED, 0);
+
+ clrbits8(&qe_immr->si1.siglmr1_h, (0x1 << port));
+ ucc_fast_disable(tdm_c->uf_private, COMM_DIR_RX);
+ ucc_fast_disable(tdm_c->uf_private, COMM_DIR_TX);
+ free_irq(tdm_c->ut_info->uf_info.irq, tdm_c);
+}
+
+
+static void config_tdm(struct tdm_ctrl *tdm_c)
+{
+ u32 i, j, k;
+
+ j = 0;
+ k = 0;
+
+ /* Set Mask Bits */
+ for (i = 0; i < ACTIVE_CH; i++) {
+ tdm_c->tx_mask[k] |= (1 << j);
+ tdm_c->rx_mask[k] |= (1 << j);
+ j++;
+ if (j >= 16) {
+ j = 0;
+ k++;
+ }
+ }
+ /* physical number of slots in a frame */
+ tdm_c->physical_num_ts = NUM_TS;
+
+ /* common receive and transmit pins */
+ tdm_c->cfg_ctrl.com_pin = 1;
+
+ /* L1R/TSYNC active logic "1" */
+ tdm_c->cfg_ctrl.fr_sync_level = 0;
+
+ /*
+ * TX data on rising edge of clock
+ * RX data on falling edge
+ */
+ tdm_c->cfg_ctrl.clk_edge = 0;
+
+ /* Frame sync sampled on falling edge */
+ tdm_c->cfg_ctrl.fr_sync_edge = 0;
+
+ /* no bit delay */
+ tdm_c->cfg_ctrl.rx_fr_sync_delay = 0;
+
+ /* no bit delay */
+ tdm_c->cfg_ctrl.tx_fr_sync_delay = 0;
+
+#ifndef CONFIG_TDM_HW_LB_TSA_SLIC
+ if (tdm_c->leg_slic) {
+ /* Need 1 bit delay for Legrity SLIC */
+ tdm_c->cfg_ctrl.rx_fr_sync_delay = 1;
+ tdm_c->cfg_ctrl.tx_fr_sync_delay = 1;
+ pr_info("%s Delay for Legerity!\n", __FUNCTION__);
+ }
+#endif
+
+ tdm_c->cfg_ctrl.active_num_ts = ACTIVE_CH;
+}
+
+static void tdm_read(u32 client_id, short chn_id, short *pcm_buffer,
+ short len)
+{
+ int i;
+ u32 phase_rx;
+ /* point to where to start for the current phase data processing */
+ u32 temp_rx;
+
+ struct tdm_ctrl *tdm_c = tdm_ctrl[client_id];
+
+ u16 *input_tdm_buffer =
+ (u16 *)tdm_c->tdm_input_data;
+
+ phase_rx = tdm_c->phase_rx;
+ if (phase_rx == 0)
+ phase_rx = MAX_PHASE;
+ else
+ phase_rx -= 1;
+
+ temp_rx = phase_rx * SAMPLE_DEPTH * EFF_ACTIVE_CH;
+
+#ifdef UCC_CACHE_SNOOPING_DISABLED
+ flush_dcache_range((size_t) &input_tdm_buffer[temp_rx],
+ (size_t) &input_tdm_buffer[temp_rx +
+ SAMPLE_DEPTH * ACTIVE_CH]);
+#endif
+ for (i = 0; i < len; i++)
+ pcm_buffer[i] =
+ input_tdm_buffer[i * EFF_ACTIVE_CH + temp_rx + chn_id];
+
+}
+
+static void tdm_write(u32 client_id, short chn_id, short *pcm_buffer,
+ short len)
+{
+ int i;
+ int phase_tx;
+ u32 txb;
+ /* point to where to start for the current phase data processing */
+ int temp_tx;
+ struct tdm_ctrl *tdm_c = tdm_ctrl[client_id];
+
+ u16 *output_tdm_buffer;
+ output_tdm_buffer = (u16 *)tdm_c->tdm_output_data;
+ txb = in_be32(&tdm_c->ucc_pram->tbptr) -
+ in_be32(&tdm_c->ucc_pram->tbase);
+ phase_tx = txb / sizeof(struct qe_bd);
+
+ if (phase_tx == 0)
+ phase_tx = MAX_PHASE;
+ else
+ phase_tx -= 1;
+
+ temp_tx = phase_tx * SAMPLE_DEPTH * EFF_ACTIVE_CH;
+
+ for (i = 0; i < len; i++)
+ output_tdm_buffer[i * EFF_ACTIVE_CH + temp_tx + chn_id] =
+ pcm_buffer[i];
+
+#ifdef UCC_CACHE_SNOOPING_DISABLED
+ flush_dcache_range((size_t) &output_tdm_buffer[temp_tx],
+ (size_t) &output_tdm_buffer[temp_tx + SAMPLE_DEPTH *
+ ACTIVE_CH]);
+#endif
+}
+
+
+static int tdm_register_client(struct tdm_client *tdm_client)
+{
+ u32 i;
+ if (num_tdm_clients == num_tdm_devices) {
+ printk(KERN_ERR "all TDM devices busy\n");
+ return -EBUSY;
+ }
+
+ for (i = 0; i < num_tdm_devices; i++) {
+ if (!tdm_ctrl[i]->device_busy) {
+ tdm_ctrl[i]->device_busy = 1;
+ break;
+ }
+ }
+ num_tdm_clients++;
+ tdm_client->client_id = i;
+ tdm_client->tdm_read = tdm_read;
+ tdm_client->tdm_write = tdm_write;
+ tdm_client->wakeup_event =
+ &(tdm_ctrl[i]->wakeup_event);
+ return 0;
+}
+EXPORT_SYMBOL_GPL(tdm_register_client);
+
+static int tdm_deregister_client(struct tdm_client *tdm_client)
+{
+ num_tdm_clients--;
+ tdm_ctrl[tdm_client->client_id]->device_busy = 0;
+ return 0;
+}
+EXPORT_SYMBOL_GPL(tdm_deregister_client);
+
+static int ucc_tdm_probe(struct of_device *ofdev,
+ const struct of_device_id *match)
+{
+ struct device_node *np = ofdev->node;
+ struct resource res;
+ const unsigned int *prop;
+ u32 ucc_num, device_num, err, ret = 0;
+ struct device_node *np_tmp = NULL;
+ dma_addr_t physaddr;
+ void *tdm_buff;
+ struct ucc_tdm_info *ut_info;
+
+ prop = of_get_property(np, "device-id", NULL);
+ ucc_num = *prop - 1;
+ if ((ucc_num < 0) || (ucc_num > 7))
+ return -ENODEV;
+
+ ut_info = &utdm_info[ucc_num];
+ if (ut_info == NULL) {
+ printk(KERN_ERR "additional data missing\n");
+ return -ENODEV;
+ }
+ if (ut_info->ucc_busy) {
+ printk(KERN_ERR "UCC in use by another TDM driver instance\n");
+ return -EBUSY;
+ }
+ if (num_tdm_devices == MAX_NUM_TDM_DEVICES) {
+ printk(KERN_ERR "All TDM devices already initialized\n");
+ return -ENODEV;
+ }
+
+ ut_info->ucc_busy = 1;
+ tdm_ctrl[num_tdm_devices++] =
+ kzalloc(sizeof(struct tdm_ctrl), GFP_KERNEL);
+ if (!tdm_ctrl[num_tdm_devices - 1]) {
+ printk(KERN_ERR "%s: no memory to allocate for"
+ " tdm control structure\n", __FUNCTION__);
+ num_tdm_devices--;
+ return -ENOMEM;
+ }
+ device_num = num_tdm_devices - 1;
+
+ tdm_ctrl[device_num]->device = &ofdev->dev;
+ tdm_ctrl[device_num]->ut_info = ut_info;
+
+ tdm_ctrl[device_num]->ut_info->uf_info.ucc_num = ucc_num;
+
+ prop = of_get_property(np, "fsl,tdm-num", NULL);
+ if (prop == NULL) {
+ ret = -EINVAL;
+ goto get_property_error;
+ }
+
+ tdm_ctrl[device_num]->tdm_port = *prop - 1;
+
+ if (tdm_ctrl[device_num]->tdm_port > 3) {
+ ret = -EINVAL;
+ goto get_property_error;
+ }
+
+ prop = of_get_property(np, "fsl,si-num", NULL);
+ if (prop == NULL) {
+ ret = -EINVAL;
+ goto get_property_error;
+ }
+
+ tdm_ctrl[device_num]->si = *prop - 1;
+
+ tdm_ctrl[device_num]->ut_info->uf_info.tdm_tx_clk =
+ (char *) of_get_property(np, "fsl,tdm-tx-clk", NULL);
+ if (tdm_ctrl[device_num]->ut_info->uf_info.tdm_tx_clk == NULL) {
+ ret = -EINVAL;
+ goto get_property_error;
+ }
+
+ tdm_ctrl[device_num]->ut_info->uf_info.tdm_rx_clk =
+ (char *) of_get_property(np, "fsl,tdm-rx-clk", NULL);
+ if (tdm_ctrl[device_num]->ut_info->uf_info.tdm_rx_clk == NULL) {
+ ret = -EINVAL;
+ goto get_property_error;
+ }
+
+ tdm_ctrl[device_num]->ut_info->uf_info.tdm_tx_sync =
+ (char *) of_get_property(np, "fsl,tdm-tx-sync", NULL);
+ if (tdm_ctrl[device_num]->ut_info->uf_info.tdm_tx_sync == NULL) {
+ ret = -EINVAL;
+ goto get_property_error;
+ }
+
+ tdm_ctrl[device_num]->ut_info->uf_info.tdm_rx_sync =
+ (char *) of_get_property(np, "fsl,tdm-rx-sync", NULL);
+ if (tdm_ctrl[device_num]->ut_info->uf_info.tdm_rx_sync == NULL) {
+ ret = -EINVAL;
+ goto get_property_error;
+ }
+
+ tdm_ctrl[device_num]->ut_info->uf_info.irq =
+ irq_of_parse_and_map(np, 0);
+ err = of_address_to_resource(np, 0, &res);
+ if (err) {
+ ret = EINVAL;
+ goto get_property_error;
+ }
+ tdm_ctrl[device_num]->ut_info->uf_info.regs = res.start;
+ tdm_ctrl[device_num]->uf_regs = of_iomap(np, 0);
+
+ np_tmp = of_find_compatible_node(np_tmp, "slic", "legerity-slic");
+ if (np_tmp != NULL)
+ tdm_ctrl[device_num]->leg_slic = 1;
+ else
+ tdm_ctrl[device_num]->leg_slic = 0;
+
+ config_tdm(tdm_ctrl[device_num]);
+
+ tdm_buff = dma_alloc_coherent(NULL, 2 * NR_BUFS * SAMPLE_DEPTH *
+ tdm_ctrl[device_num]->cfg_ctrl.active_num_ts,
+ &physaddr, GFP_KERNEL);
+ if (!tdm_buff) {
+ printk(KERN_ERR "ucc-tdm: could not allocate buffer"
+ "descriptors\n");
+ ret = -ENOMEM;
+ goto get_property_error;
+ }
+
+ tdm_ctrl[device_num]->tdm_input_data = tdm_buff;
+ tdm_ctrl[device_num]->dma_input_addr = physaddr;
+
+ tdm_ctrl[device_num]->tdm_output_data = tdm_buff + NR_BUFS *
+ SAMPLE_DEPTH * tdm_ctrl[device_num]->cfg_ctrl.active_num_ts;
+ tdm_ctrl[device_num]->dma_output_addr = physaddr + NR_BUFS *
+ SAMPLE_DEPTH * tdm_ctrl[device_num]->cfg_ctrl.active_num_ts;
+
+ init_waitqueue_head(&(tdm_ctrl[device_num]->wakeup_event));
+
+ ret = tdm_init(tdm_ctrl[device_num]);
+ if (ret != 0)
+ goto tdm_init_error;
+
+ ret = tdm_start(tdm_ctrl[device_num]);
+ if (ret != 0)
+ goto tdm_start_error;
+
+ dev_set_drvdata(&(ofdev->dev), tdm_ctrl[device_num]);
+
+ pr_info("%s UCC based tdm module installed\n", __FUNCTION__);
+ return 0;
+
+tdm_start_error:
+ tdm_deinit(tdm_ctrl[device_num]);
+tdm_init_error:
+ dma_free_coherent(NULL, 2 * NR_BUFS * SAMPLE_DEPTH *
+ tdm_ctrl[device_num]->cfg_ctrl.active_num_ts,
+ tdm_ctrl[device_num]->tdm_input_data,
+ tdm_ctrl[device_num]->dma_input_addr);
+
+get_property_error:
+ kfree(tdm_ctrl[device_num]);
+ return ret;
+}
+
+static int ucc_tdm_remove(struct of_device *ofdev)
+{
+ struct tdm_ctrl *tdm_c;
+ struct ucc_tdm_info *ut_info;
+ u32 ucc_num;
+
+ tdm_c = dev_get_drvdata(&(ofdev->dev));
+ ucc_num = tdm_c->ut_info->uf_info.ucc_num;
+ ut_info = &utdm_info[ucc_num];
+ tdm_stop(tdm_c);
+ tdm_deinit(tdm_c);
+
+ ucc_fast_free(tdm_c->uf_private);
+
+ dma_free_coherent(NULL, 2 * NR_BUFS * SAMPLE_DEPTH *
+ tdm_c->cfg_ctrl.active_num_ts,
+ tdm_c->tdm_input_data,
+ tdm_c->dma_input_addr);
+
+ num_tdm_devices--;
+ kfree(tdm_c);
+
+ ut_info->ucc_busy = 0;
+
+ pr_info("%s UCC based tdm module uninstalled\n", __FUNCTION__);
+ return 0;
+}
+
+static struct of_device_id ucc_tdm_match[] = {
+ {
+ .type = "tdm",
+ .compatible = "fsl,ucc-tdm",
+ }, {},
+};
+
+MODULE_DEVICE_TABLE(of, ucc_tdm_match);
+
+static struct of_platform_driver ucc_tdm_driver = {
+ .name = DRV_NAME,
+ .match_table = ucc_tdm_match,
+ .probe = ucc_tdm_probe,
+ .remove = ucc_tdm_remove,
+};
+
+static int __init ucc_tdm_init(void)
+{
+ u32 i;
+
+ pr_info("ucc_tdm: " DRV_DESC "\n");
+ for (i = 0; i < 8; i++)
+ memcpy(&(utdm_info[i]), &utdm_primary_info,
+ sizeof(utdm_primary_info));
+
+ return of_register_platform_driver(&ucc_tdm_driver);
+}
+
+static void __exit ucc_tdm_exit(void)
+{
+ of_unregister_platform_driver(&ucc_tdm_driver);
+}
+
+module_init(ucc_tdm_init);
+module_exit(ucc_tdm_exit);
+MODULE_AUTHOR("Freescale Semiconductor, Inc");
+MODULE_DESCRIPTION(DRV_DESC);
+MODULE_LICENSE("GPL");
diff --git a/drivers/misc/ucc_tdm.h b/drivers/misc/ucc_tdm.h
new file mode 100644
index 0000000..eaf2848
--- /dev/null
+++ b/drivers/misc/ucc_tdm.h
@@ -0,0 +1,221 @@
+/*
+ * drivers/misc/ucc_tdm.h
+ *
+ * UCC Based Linux TDM Driver
+ * This driver is designed to support UCC based TDM for PowerPC processors.
+ * This driver can interface with SLIC device to run VOIP kind of
+ * applications.
+ *
+ * Author: Ashish Kalra & Poonam Aggrwal
+ *
+ * Copyright (c) 2007 Freescale Semiconductor, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the
+ * Free Software Foundation; either version 2 of the License, or (at your
+ * option) any later version.
+ */
+
+#ifndef TDM_H
+#define TDM_H
+
+#define NUM_TS 8
+#define ACTIVE_CH 8
+
+/* SAMPLE_DEPTH is the sample depth is the number of frames before
+ * an interrupt. Must be a multiple of 4
+ */
+#define SAMPLE_DEPTH 80
+
+/* define the number of Rx interrupts to go by for initial stuttering */
+#define STUTTER_INT_CNT 1
+
+/* BMRx Field Descriptions to specify tstate and rstate in UCC parameter RAM*/
+#define EN_BUS_SNOOPING 0x20
+#define BE_BO 0x10
+
+/* UPSMR Register for Transparent UCC controller Bit definitions*/
+#define NBO 0x00000000 /* Normal Mode 1 bit of data per clock */
+
+/* SI Mode register bit definitions */
+#define NORMAL_OPERATION 0x0000
+#define AUTO_ECHO 0x0400
+#define INTERNAL_LB 0x0800
+#define CONTROL_LB 0x0c00
+#define SIMODE_CRT (0x8000 >> 9)
+#define SIMODE_SL (0x8000 >> 10)
+#define SIMODE_CE (0x8000 >> 11)
+#define SIMODE_FE (0x8000 >> 12)
+#define SIMODE_GM (0x8000 >> 13)
+#define SIMODE_TFSD(val) (val)
+#define SIMODE_RFSD(val) ((val) << 8)
+
+#define SI_TDM_MODE_REGISTER_OFFSET 0
+
+#define R_CM 0x02000000
+#define T_CM 0x02000000
+
+#define SET_RX_SI_RAM(n, val) \
+ out_be16((u16 *)&qe_immr->sir.rx[(n)*2], (u16)(val))
+
+#define SET_TX_SI_RAM(n, val) \
+ out_be16((u16 *)&qe_immr->sir.tx[(n)*2], (u16)(val))
+
+/* SI RAM entries */
+#define SIR_LAST 0x0001
+#define SIR_CNT(n) ((n) << 2)
+#define SIR_BYTE 0x0002
+#define SIR_BIT 0x0000
+#define SIR_IDLE 0
+#define SIR_UCC(uccx) (((uccx+9)) << 5)
+
+/* BRGC Register Bit definitions */
+#define BRGC_RESET (0x1<<17)
+#define BRGC_EN (0x1<<16)
+#define BRGC_EXTC_QE (0x00<<14)
+#define BRGC_EXTC_CLK3 (0x01<<14)
+#define BRGC_EXTC_CLK5 (0x01<<15)
+#define BRGC_EXTC_CLK9 (0x01<<14)
+#define BRGC_EXTC_CLK11 (0x01<<14)
+#define BRGC_EXTC_CLK13 (0x01<<14)
+#define BRGC_EXTC_CLK15 (0x01<<15)
+#define BRGC_ATB (0x1<<13)
+#define BRGC_DIV16 (0x1)
+
+/* structure representing UCC transparent parameter RAM */
+struct ucc_transparent_pram {
+ __be16 riptr;
+ __be16 tiptr;
+ __be16 res0;
+ __be16 mrblr;
+ __be32 rstate;
+ __be32 rbase;
+ __be16 rbdstat;
+ __be16 rbdlen;
+ __be32 rdptr;
+ __be32 tstate;
+ __be32 tbase;
+ __be16 tbdstat;
+ __be16 tbdlen;
+ __be32 tdptr;
+ __be32 rbptr;
+ __be32 tbptr;
+ __be32 rcrc;
+ __be32 res1;
+ __be32 tcrc;
+ __be32 res2;
+ __be32 res3;
+ __be32 c_mask;
+ __be32 c_pres;
+ __be16 disfc;
+ __be16 crcec;
+ __be32 res4[4];
+ __be16 ts_tmp;
+ __be16 tmp_mb;
+};
+
+#define UCC_TRANSPARENT_PRAM_SIZE 0x100
+
+struct tdm_cfg {
+ u8 com_pin; /* Common receive and transmit pins
+ * 0 = separate pins
+ * 1 = common pins
+ */
+
+ u8 fr_sync_level; /* SLx bit Frame Sync Polarity
+ * 0 = L1R/TSYNC active logic "1"
+ * 1 = L1R/TSYNC active logic "0"
+ */
+
+ u8 clk_edge; /* CEx bit Tx Rx Clock Edge
+ * 0 = TX data on rising edge of clock
+ * RX data on falling edge
+ * 1 = TX data on falling edge of clock
+ * RX data on rising edge
+ */
+
+ u8 fr_sync_edge; /* FEx bit Frame sync edge
+ * Determine when the sync pulses are sampled
+ * 0 = Falling edge
+ * 1 = Rising edge
+ */
+
+ u8 rx_fr_sync_delay; /* TFSDx/RFSDx bits Frame Sync Delay
+ * 00 = no bit delay
+ * 01 = 1 bit delay
+ * 10 = 2 bit delay
+ * 11 = 3 bit delay
+ */
+
+ u8 tx_fr_sync_delay; /* TFSDx/RFSDx bits Frame Sync Delay
+ * 00 = no bit delay
+ * 01 = 1 bit delay
+ * 10 = 2 bit delay
+ * 11 = 3 bit delay
+ */
+
+ u8 active_num_ts; /* Number of active time slots in TDM
+ * assume same active Rx/Tx time slots
+ */
+};
+
+struct ucc_tdm_info {
+ struct ucc_fast_info uf_info;
+ u32 ucc_busy;
+};
+
+struct tdm_ctrl {
+ u32 device_busy;
+ struct device *device;
+ struct ucc_fast_private *uf_private;
+ struct ucc_tdm_info *ut_info;
+ u32 tdm_port; /* port for this tdm:TDMA,TDMB,TDMC,TDMD */
+ u32 si; /* serial interface: 0 or 1 */
+ struct ucc_fast __iomem *uf_regs; /* UCC Fast registers */
+ u16 rx_mask[8]; /* Active Receive channels LSB is ch0 */
+ u16 tx_mask[8]; /* Active Transmit channels LSB is ch0 */
+ /* Only channels less than the number of FRAME_SIZE are implemented */
+ struct tdm_cfg cfg_ctrl; /* Signaling controls configuration */
+ u8 *tdm_input_data; /* buffer used for Rx by the tdm */
+ u8 *tdm_output_data; /* buffer used for Tx by the tdm */
+
+ dma_addr_t dma_input_addr; /* dma mapped buffer for TDM Rx */
+ dma_addr_t dma_output_addr; /* dma mapped buffer for TDM Tx */
+ u16 physical_num_ts; /* physical number of timeslots in the tdm
+ frame */
+ u32 phase_rx; /* cycles through 0, 1, 2 */
+ u32 phase_tx; /* cycles through 0, 1, 2 */
+ /*
+ * the following two variables are for dealing with "stutter" problem
+ * "stutter" period is about 20 frames or so, varies depending active
+ * channel num depending on the sample depth, the code should let a
+ * few Rx interrupts go by
+ */
+ u32 tdm_icnt;
+ u32 tdm_flag;
+ struct ucc_transparent_pram __iomem *ucc_pram;
+ struct qe_bd __iomem *tx_bd;
+ struct qe_bd __iomem *rx_bd;
+ u32 ucc_pram_offset;
+ u32 tx_bd_offset;
+ u32 rx_bd_offset;
+ u32 rx_ucode_buf_offset;
+ u32 tx_ucode_buf_offset;
+ bool leg_slic;
+ wait_queue_head_t wakeup_event;
+};
+
+struct tdm_client {
+ u32 client_id;
+ void (*tdm_read)(u32 client_id, short chn_id,
+ short *pcm_buffer, short len);
+ void (*tdm_write)(u32 client_id, short chn_id,
+ short *pcm_buffer, short len);
+ wait_queue_head_t *wakeup_event;
+ };
+
+#define MAX_PHASE 1
+#define NR_BUFS 2
+#define EFF_ACTIVE_CH ACTIVE_CH / 2
+
+#endif
--
1.5.2.4
^ permalink raw reply related
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