#include "mali_osk_profiling.h"
#endif
+#include <mali_platform.h>
+
static struct mali_gp_core *mali_global_gp_core = NULL;
/* Interrupt handlers */
if (MALI_REG_POLL_COUNT_FAST == i) {
MALI_PRINT_ERROR(("Mali GP: Failed to stop bus on %s\n", core->hw_core.description));
+ if (mali_gp_reset_fail < 65533)
+ mali_gp_reset_fail++;
return _MALI_OSK_ERR_FAULT;
}
return _MALI_OSK_ERR_OK;
if (i == MALI_REG_POLL_COUNT_FAST) {
MALI_PRINT_ERROR(("Mali GP: Failed to reset core %s, rawstat: 0x%08x\n",
core->hw_core.description, rawstat));
+ if (mali_gp_reset_fail < 65533)
+ mali_gp_reset_fail++;
return _MALI_OSK_ERR_FAULT;
}
#include <trace/events/gpu.h>
#endif
+#include <mali_platform.h>
static void mali_group_bottom_half_mmu(void *data);
static void mali_group_bottom_half_gp(void *data);
group->core_timed_out = MALI_TRUE;
+ if (mali_core_timeout < 65533)
+ mali_core_timeout++;
if (NULL != group->gp_core) {
MALI_DEBUG_PRINT(2, ("Mali group: TIMEOUT on %s\n", mali_gp_get_hw_core_desc(group->gp_core)));
_mali_osk_wq_schedule_work(group->bottom_half_work_gp);
#include "mali_osk_profiling.h"
#endif
+#include <mali_platform.h>
+
/* Number of frame registers on Mali-200 */
#define MALI_PP_MALI200_NUM_FRAME_REGISTERS ((0x04C/4)+1)
/* Number of frame registers on Mali-300 and later */
if (MALI_REG_POLL_COUNT_FAST == i) {
MALI_PRINT_ERROR(("Mali PP: Failed to stop bus on %s. Status: 0x%08x\n", core->hw_core.description, mali_hw_core_register_read(&core->hw_core, MALI200_REG_ADDR_MGMT_STATUS)));
+ if (mali_gp_reset_fail < 65533)
+ mali_gp_reset_fail++;
return _MALI_OSK_ERR_FAULT;
}
return _MALI_OSK_ERR_OK;
#ifndef MALI_PLATFORM_H_
#define MALI_PLATFORM_H_
-
+extern u32 mali_gp_reset_fail;
+extern u32 mali_core_timeout;
#endif /* MALI_PLATFORM_H_ */
#include "common/mali_osk_profiling.h"
int mali_pm_statue = 0;
+u32 mali_gp_reset_fail = 0;
+module_param(mali_gp_reset_fail, int, S_IRUSR | S_IWUSR | S_IWGRP | S_IRGRP | S_IROTH); /* rw-rw-r-- */
+MODULE_PARM_DESC(mali_gp_reset_fail, "times of failed to reset GP");
+u32 mali_core_timeout = 0;
+module_param(mali_core_timeout, int, S_IRUSR | S_IWUSR | S_IWGRP | S_IRGRP | S_IROTH); /* rw-rw-r-- */
+MODULE_PARM_DESC(mali_core_timeout, "times of failed to reset GP");
static struct mali_gpu_device_data mali_gpu_data =
{
void mali_pdev_post_init(struct platform_device* pdev)
{
+ mali_gp_reset_fail = 0;
+ mali_core_timeout = 0;
#ifdef CONFIG_PM_RUNTIME
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37))
pm_runtime_set_autosuspend_delay(&(pdev->dev), 1000);