Showing error 1604

User: Jiri Slaby
Error type: Leaving function in locked state
Error type description: Some lock is not unlocked on all paths of a function, so it is leaked
File location: kernel/sched.c
Line in file: 2004
Project: Linux Kernel
Project version: 2.6.28
Tools: Stanse (1.2)
Entered: 2012-05-29 20:11:37 UTC


Source:

1974                 *
1975                 * Oops. Go back and try again..
1976                 */
1977                if (unlikely(running)) {
1978                        cpu_relax();
1979                        continue;
1980                }
1981
1982                /*
1983                 * It's not enough that it's not actively running,
1984                 * it must be off the runqueue _entirely_, and not
1985                 * preempted!
1986                 *
1987                 * So if it wa still runnable (but just not actively
1988                 * running right now), it's preempted, and we should
1989                 * yield - it could be a while.
1990                 */
1991                if (unlikely(on_rq)) {
1992                        schedule_timeout_uninterruptible(1);
1993                        continue;
1994                }
1995
1996                /*
1997                 * Ahh, all good. It wasn't running, and it wasn't
1998                 * runnable, which means that it will never become
1999                 * running in the future either. We're all done!
2000                 */
2001                break;
2002        }
2003
2004        return ncsw;
2005}
2006
2007/***
2008 * kick_process - kick a running thread to enter/exit the kernel
2009 * @p: the to-be-kicked thread
2010 *
2011 * Cause a process which is running on another CPU to enter
2012 * kernel-mode, without any delay. (to get signals handled.)
2013 *
2014 * NOTE: this function doesnt have to take the runqueue lock,
Show full sources