ALT Linux kernel packages development
 help / color / mirror / Atom feed
From: Andrey Khavryuchenko <akhavr@kds.com.ua>
To: ALT Linux kernel packages development <devel-kernel@altlinux.ru>
Subject: [d-kernel] Re: ?????? oops
Date: Thu, 01 Apr 2004 19:35:57 +0300
Message-ID: <m3ptarhd02.fsf@netmaster.kds.com.ua> (raw)
In-Reply-To: <m3vfknbvoj.fsf@netmaster.kds.com.ua> (Andrey Khavryuchenko's message of "Mon, 29 Mar 2004 16:59:56 +0300")

[-- Attachment #1: Type: text/plain, Size: 1255 bytes --]

Hi!

"AVK" == Andrey Khavryuchenko wrote:

 AVK> "SV" == Sergey Vlasov wrote:

 SV> On Mon, Mar 29, 2004 at 04:09:35PM +0300, Andrey Khavryuchenko wrote:
 >>> Background: опакечиваю user-space поддержку Zyxel Prestige 630 EE (630-11)
 >>> Запускаемая ручками инициализация/прибитие работает без проблем.  При
 >>> попытке запустить то же из hotplug поймал oops:

 SV> static int br2684_regvcc(struct atm_vcc *atmvcc, unsigned long arg)
 SV> ...
 SV> skb_queue_head_init(&copy);
 SV> skb_migrate(&atmvcc->sk->receive_queue, &copy);
 SV> while ((skb = skb_dequeue(&copy))) {
 SV> BRPRIV(skb->dev)->stats.rx_bytes -= skb->len;
 SV> BRPRIV(skb->dev)->stats.rx_packets--;
 SV> br2684_push(atmvcc, skb);
 SV> }
 SV> ...

 SV> и вот в этом цикле поймали skb->dev == NULL.  Интересно, откуда
 SV> могли взяться такие пакеты?  Никогда не имел дела с ATM...

 AVK> А ХЗ!  Это не ATM, это aDSL, который у нас поддерживается через atm-ную
 AVK> байду. 

 AVK> br2684_regvcc - это в одноименном модуле?  И там IMO стооит поставить 
 AVK> if(skb->dev) 
 AVK> вокруг всего хозяйства...

Сделал.  Работает и не падает.

Патч приложен.  Каковы дальнейшие действия для того, чтобы он оказался в
сизифовых ядрах (и мне не нужно было бы раз за разом пересобирать для
себя)?


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: net/atm/br2684.c patch --]
[-- Type: text/x-patch, Size: 768 bytes --]

diff -ru kernel-source-2.4.25.orig/net/atm/br2684.c kernel-source-2.4.25/net/atm/br2684.c
--- kernel-source-2.4.25.orig/net/atm/br2684.c	
2004-04-01 14:17:51 +0300
+++ kernel-source-2.4.25/net/atm/br2684.c	
2004-04-01 15:05:58 +0300
@@ -559,11 +559,12 @@
 	atmvcc->push = br2684_push;
 	skb_queue_head_init(&copy);
 	skb_migrate(&atmvcc->sk->receive_queue, &copy);
-	while ((skb = skb_dequeue(&copy))) {
-		BRPRIV(skb->dev)->stats.rx_bytes -= skb->len;
-		BRPRIV(skb->dev)->stats.rx_packets--;
-		br2684_push(atmvcc, skb);
-	}
+	while ((skb = skb_dequeue(&copy))) 
+		if( skb->dev ) {
+			BRPRIV(skb->dev)->stats.rx_bytes -= skb->len;
+			BRPRIV(skb->dev)->stats.rx_packets--;
+			br2684_push(atmvcc, skb);
+		}
 	return 0;
     error:
 	write_unlock_irq(&devs_lock);

[-- Attachment #3: Type: text/plain, Size: 199 bytes --]


Теперь буду воевать дальше чтобы вся эта байда стартовала по hotplug.

-- 
Andrey V Khavryuchenko            http://www.kds.com.ua/
Silver Bullet Software Solutions  http://www.kds.com.ua/training/

  reply	other threads:[~2004-04-01 16:35 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-29 13:09 [d-kernel] ÓÌÏ×ÉÌ oops Andrey Khavryuchenko
2004-03-29 13:42 ` [d-kernel] ?????? oops Sergey Vlasov
2004-03-29 13:59   ` [d-kernel] " Andrey Khavryuchenko
2004-04-01 16:35     ` Andrey Khavryuchenko [this message]
2004-04-01 16:39       ` Anton Farygin
2004-04-01 17:27         ` Andrey Khavryuchenko
2004-04-02 10:09           ` Anton Farygin
2004-04-02 10:17             ` Andrey Khavryuchenko
2004-04-02 10:49               ` Anton Farygin
2004-04-02 11:11                 ` Andrey Khavryuchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3ptarhd02.fsf@netmaster.kds.com.ua \
    --to=akhavr@kds.com.ua \
    --cc=devel-kernel@altlinux.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux kernel packages development

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/devel-kernel/0 devel-kernel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 devel-kernel devel-kernel/ http://lore.altlinux.org/devel-kernel \
		devel-kernel@altlinux.org devel-kernel@altlinux.ru devel-kernel@altlinux.com
	public-inbox-index devel-kernel

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.devel-kernel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git