/*=========================================================================== FUNCTION diag_PRL_entrySet DESCRIPTION DEPENDENCIES None. RETURN VALUE Pointer to response packet. SIDE EFFECTS None. ===========================================================================*/ void diag_SRD_Init(udbp_req_type *req_pkt, udbp_rsp_type *rsp_pkt) { printk(KERN_INFO "[SRD] init run!! "); rsp_pkt->header.cmd_code = req_pkt->header.cmd_code; rsp_pkt->header.sub_cmd = req_pkt->header.sub_cmd; rsp_pkt->header.packet_version = req_pkt->header.packet_version; rsp_pkt->header.dwsize = req_pkt->header.dwsize; //rsp_pkt->header.err_code = UDBU_ERROR_SUCCESS; rsp_pkt->header.err_code = UDBU_ERROR_CANNOT_COMPLETE; lge_mmc_scan_partitions(); if(!userDataBackUpBadCalc()) goto Error; else printk(KERN_INFO "[SRD] badcalc success "); if(!userDataBackUpPartitionErase()) goto Error; else printk(KERN_INFO "[SRD] partition erase success "); // if(!userDataBackUpAndRecoverInit()) // goto Error; #ifdef LG_FW_SRD_EXTRA_NV if(!extraNvBackUpAndRecoverInit()) goto Error; #endif #ifdef LG_FW_SRD_PRL if(!PRLBackUpAndRecoverInit()) goto Error; #endif rsp_pkt->header.err_code = UDBU_ERROR_SUCCESS; printk(KERN_INFO "[SRD] srd_init err_code = %d ", (int)rsp_pkt->header.err_code); return; Error: rsp_pkt->header.err_code = UDBU_ERROR_CANNOT_COMPLETE; printk(KERN_INFO "[SRD] srd_init error!! err_code = %d ", (int)rsp_pkt->header.err_code); }
void diag_SRD_Init(udbp_req_type *req_pkt, udbp_rsp_type *rsp_pkt) { rsp_pkt->header.cmd_code = req_pkt->header.cmd_code; rsp_pkt->header.sub_cmd = req_pkt->header.sub_cmd; rsp_pkt->header.packet_version = req_pkt->header.packet_version; rsp_pkt->header.dwsize = req_pkt->header.dwsize; rsp_pkt->header.err_code = UDBU_ERROR_SUCCESS; //rsp_pkt->header.err_code = UDBU_ERROR_CANNOT_COMPLETE; lge_mmc_scan_partitions(); if(!userDataBackUpBadCalc()) goto Error; if(!userDataBackUpPartitionErase()) goto Error; // if(!userDataBackUpAndRecoverInit()) // goto Error; #ifdef LG_FW_SRD_EXTRA_NV if(!extraNvBackUpAndRecoverInit()) goto Error; #endif #ifdef LG_FW_SRD_PRL if(!PRLBackUpAndRecoverInit()) goto Error; #endif return; Error: rsp_pkt->header.err_code = UDBU_ERROR_CANNOT_COMPLETE; }