lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 24 Aug 2012 11:50:39 +0200
From:	Sylvain Munaut <s.munaut@...tever-company.com>
To:	Cong Wang <xiyou.wangcong@...il.com>
Cc:	netdev@...r.kernel.org
Subject: Re: NULL deref in bnx2 / crashes ? ( was: netconsole leads to stalled
 CPU task )

Hi,

>>
>> Could you test the following patch?
>>
>> diff --git a/net/core/netpoll.c b/net/core/netpoll.c
>> index ddc453b..ed4d1e4 100644
>> --- a/net/core/netpoll.c
>> +++ b/net/core/netpoll.c
>> @@ -166,11 +166,18 @@ static int poll_one_napi(struct netpoll_info *npinfo,
>>  static void poll_napi(struct net_device *dev)
>>  {
>>       struct napi_struct *napi;
>> +     LIST_HEAD(napi_list);
>>       int budget = 16;
>>
>>       WARN_ON_ONCE(!irqs_disabled());
>>
>> -     list_for_each_entry(napi, &dev->napi_list, dev_list) {
>> +     /* After we enable the IRQ, new entries could be added
>> +      * to this list, we need to save it before re-enable
>> +      * IRQ.
>> +      */
>> +     list_splice_tail(&dev->napi_list, &napi_list);
>> +
>
> This one should be list_splice_init()...
>
>
>> +     list_for_each_entry(napi, &napi_list, dev_list) {
>>               local_irq_enable();
>>               if (napi->poll_owner != smp_processor_id() &&
>>                   spin_trylock(&napi->poll_lock)) {
>> @@ -187,6 +194,7 @@ static void poll_napi(struct net_device *dev)
>>               }
>>               local_irq_disable();
>>       }
>> +     list_splice_tail(&napi_list, &dev->napi_list);
>>  }
>>
>>  static void service_arp_queue(struct netpoll_info *npi)

I've just tested this patch on the intel machine and the behavior didn't change.
When I do the netconsole modprobe, it sends a couple of line, the
modprobe hangs and then a couple of second later the whole machine
hangs, with nothing printed on the screen or anything.

Cheers,

    Sylvain
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ