/* ************************************************************************************************************ * * function * * name : * * parmeters : * * return : * * note : * * ************************************************************************************************************ */ void sunxi_update_subsequent_processing(int next_work) { printf("next work %d\n", next_work); switch(next_work) { case SUNXI_UPDATE_NEXT_ACTION_REBOOT: //重启 case SUNXI_UPDATA_NEXT_ACTION_SPRITE_TEST: printf("SUNXI_UPDATE_NEXT_ACTION_REBOOT\n"); //do_reset(NULL, 0, 0, NULL); sunxi_board_restart(0); break; case SUNXI_UPDATE_NEXT_ACTION_SHUTDOWN: //关机 printf("SUNXI_UPDATE_NEXT_ACTION_SHUTDOWN\n"); //do_shutdown(NULL, 0, 0, NULL); sunxi_board_shutdown(); break; case SUNXI_UPDATE_NEXT_ACTION_REUPDATE: printf("SUNXI_UPDATE_NEXT_ACTION_REUPDATE\n"); sunxi_board_run_fel(); //进行量产 break; case SUNXI_UPDATE_NEXT_ACTION_BOOT: case SUNXI_UPDATE_NEXT_ACTION_NORMAL: default: printf("SUNXI_UPDATE_NEXT_ACTION_NULL\n"); break; } return ; }
s32 drv_disp_check_spec(void) { unsigned int lcd_used = 0; unsigned int lcd_x = 0, lcd_y = 0; int ret = 0; int value = 0; int limit_w = 0xffff, limit_h = 0xffff; #if defined(CONFIG_ARCH_SUN8IW6) limit_w = 2048; limit_h = 1536; #endif ret = disp_sys_script_get_item("lcd0_para", "lcd_used", &value, 1); if(ret == 1) { lcd_used = value; } if(1 == lcd_used) { ret = disp_sys_script_get_item("lcd0_para", "lcd_x", &value, 1); if(ret == 1) { lcd_x = value; } ret = disp_sys_script_get_item("lcd0_para", "lcd_y", &value, 1); if(ret == 1) { lcd_y = value; } if(((lcd_x > limit_w) && (lcd_y > limit_h)) || ((lcd_x > limit_h) && (lcd_y > limit_w))) { printf("fatal err: cannot support lcd with resolution(%d*%d) larger than %d*%d, the system will shut down!\n", lcd_x, lcd_y,limit_w,limit_h); sunxi_board_shutdown(); } } return 0; }