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>] [day] [month] [year] [list]
Message-ID: <CAM16m2koNcqMNMSW9r8bjS4SLBzNzh8P03npe0f6d3qr9ifzcA@mail.gmail.com>
Date:	Fri, 3 Aug 2012 01:13:03 +0800
From:	chpoph <chpoph@...il.com>
To:	linux-kernel@...r.kernel.org
Subject: In function cpu_stop_cpu_callback, BUG_ON(stopper->thread ||
 stopper->enabled || !list_empty(&stopper->works)) is triggered while
 restarting sometimes.

In function cpu_stop_cpu_callback, BUG_ON(stopper->thread ||
stopper->enabled || !list_empty(&stopper->works)) is triggered
sometimes.
/* manage stopper for a cpu, mostly lifted from sched migration thread mgmt */
static int __cpuinit cpu_stop_cpu_callback(struct notifier_block *nfb,
                                           unsigned long action, void *hcpu)
{
        ..................................
        switch (action & ~CPU_TASKS_FROZEN) {
        case CPU_UP_PREPARE:
                BUG_ON(stopper->thread || stopper->enabled ||
                       !list_empty(&stopper->works));
         .................................
}

Before actually hardware restarting, machine_restart(cmd) will be called.

void machine_restart(char *cmd)
{
        machine_shutdown();
        arm_pm_restart(reboot_mode, cmd);
        ......................
}

after machine_shutdown(), all other cpus are set offline only by
settting the cpumask. if userspace software which regulators cpu are
running before arm_pm_restart(), it may set set another cpu online and
cpu_up(cpu) is called. At this situation, BUG_ON(stopper->thread ||
stopper->enabled || !list_empty(&stopper->works)) is triggered in
cpu_stop_cpu_callback.

Is it needed to preempt disable before calling machine_shutdown()?
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ