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 for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAGZFCEHrzDDtO8HGaUhuUb_vNddKyiXPzasnkvTqLOqS9SwaDw@mail.gmail.com>
Date:	Wed, 6 Mar 2013 09:38:03 +0530
From:	ratheesh kannoth <ratheesh.ksz@...il.com>
To:	e1000-devel@...ts.sourceforge.net, netdev@...r.kernel.org,
	linux-newbie <linux-newbie@...r.kernel.org>
Cc:	Alexander Duyck <alexander.h.duyck@...el.com>
Subject: igb_down from bottom half context

I  have kernel timer which  check for flag.

if(flag ) {
          igb_down(adapter);
 } else {
         igb_up(adapter);
 }


I could see a kernel crash; because  there are a lot of  msleep() in
igb_down function.

#define msleep(x)    do { set_current_state(TASK_UNINTERRUPTIBLE); \
                                schedule_timeout((x * HZ)/1000 + 2); \
                              } while (0)

sleep() is called from bottom half context; this is the cause of kernel crash.

1) Since timer call back dont have process context associated with it;
i think , "current" points to the last preempted task ?
2) How can i introduce delays in interrupt context to avoid the kernel
crash. mdelay()  will work ?
3) is there any better mechanism to do this job ?

Thanks,
Ratheesh
--
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