static int riva_ramdump(int enable, const struct subsys_desc *subsys)
{
	/* Terry Cheng, 20120807, notify logmaster riva crash { */
	int rc = -1;
	pr_info("%s: enable[%d]\n", MODULE_NAME, enable);
	if (enable)
	{

		rc = do_ramdump(riva_ramdump_dev,
				riva_segments,
				ARRAY_SIZE(riva_segments));
		if(!rc)
			kevent_trigger(KEVENT_RIVA_CRASH);
		return rc;
	}
	else
		return 0;
	/* } Terry Cheng, 20120807, notify logmaster riva crash  */
}
Esempio n. 2
0
void q6audio_dsp_not_responding(void)
{

	if (atomic_add_return(1, &dsp_crash_count) != 1) {
		pr_err("q6audio_dsp_not_responding() - parking additional crasher...\n");
		for (;;)
			msleep(1000);
	}
	if (dsp_wait_count) {
		dsp_has_crashed = 1;
		wake_up(&dsp_wait);

		while (dsp_has_crashed != 2)
			wait_event(dsp_wait, dsp_has_crashed == 2);
	} else {
		pr_err("q6audio_dsp_not_responding() - no waiter?\n");
	}
	pr_err("Notify AP to show dialog\n");
	kevent_trigger(KEVENT_ADSP_CRASH);
	
	
}