fix indentation
This commit is contained in:
+87
-87
@@ -407,101 +407,101 @@ int main(void)
|
||||
}
|
||||
|
||||
// Init time controller
|
||||
Status = TimeCtrl_Init(&tmcInstPtr, &tmcConfig);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_PRINT("TmcCtrl Init SUCCESS! \n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_PRINT("TmcCtrl Init FAILED! \n");
|
||||
return Status;
|
||||
}
|
||||
Status = TimeCtrl_Init(&tmcInstPtr, &tmcConfig);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_PRINT("TmcCtrl Init SUCCESS! \n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_PRINT("TmcCtrl Init FAILED! \n");
|
||||
return Status;
|
||||
}
|
||||
|
||||
/* Physical Layer Initialize */
|
||||
Status = Phy_InstInit(&phyInstPtr, &phyConfig);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_PRINT("Physical layer Init SUCCESS! \n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_PRINT("Physical layer FAILED! \n");
|
||||
return Status;
|
||||
}
|
||||
/* Physical Layer Initialize */
|
||||
Status = Phy_InstInit(&phyInstPtr, &phyConfig);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_PRINT("Physical layer Init SUCCESS! \n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_PRINT("Physical layer FAILED! \n");
|
||||
return Status;
|
||||
}
|
||||
|
||||
/* Link Layer Initialize */
|
||||
linkConfig.phyInstPtr = phyInstPtr;
|
||||
linkConfig.tmcInstPtr = tmcInstPtr;
|
||||
Status = Linklayer_Init(&linkInstPtr, &linkConfig);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_PRINT("LinkLayer Init SUCCESS! \n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_PRINT("Linklayer Init FAILED! \n");
|
||||
return Status;
|
||||
}
|
||||
/* Link Layer Initialize */
|
||||
linkConfig.phyInstPtr = phyInstPtr;
|
||||
linkConfig.tmcInstPtr = tmcInstPtr;
|
||||
Status = Linklayer_Init(&linkInstPtr, &linkConfig);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_PRINT("LinkLayer Init SUCCESS! \n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_PRINT("Linklayer Init FAILED! \n");
|
||||
return Status;
|
||||
}
|
||||
|
||||
// /* System Bus Initialize */
|
||||
// Status = SystemBus_Init(&sysbusDescPtr, &sysbusConfig);
|
||||
// if (Status != SUCCESS)
|
||||
// {
|
||||
// DBG_ERROR("Systembus init FAILED, with error code: %d\n", Status);
|
||||
// return Status;
|
||||
// }
|
||||
// /* System Bus Initialize */
|
||||
// Status = SystemBus_Init(&sysbusDescPtr, &sysbusConfig);
|
||||
// if (Status != SUCCESS)
|
||||
// {
|
||||
// DBG_ERROR("Systembus init FAILED, with error code: %d\n", Status);
|
||||
// return Status;
|
||||
// }
|
||||
|
||||
/* System Monitor log timer Initialize */
|
||||
Status = timer_init(&logTmPtr, &scutimer_init_param);
|
||||
if (Status != SUCCESS)
|
||||
{
|
||||
DBG_ERROR("SCU Timer init FAILED, with error code: %d\n", Status);
|
||||
return Status;
|
||||
}
|
||||
/* System Monitor log timer Initialize */
|
||||
Status = timer_init(&logTmPtr, &scutimer_init_param);
|
||||
if (Status != SUCCESS)
|
||||
{
|
||||
DBG_ERROR("SCU Timer init FAILED, with error code: %d\n", Status);
|
||||
return Status;
|
||||
}
|
||||
|
||||
/* interrupts Initialize */
|
||||
Status = SetupInterruptSystem(intcDescPtr);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_INFO("Interrupt system setup SUCCESS!\n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_ERROR("Interrupt system setup FAILED, ErrorCode: %d.\n", Status);
|
||||
return Status;
|
||||
}
|
||||
/* interrupts Initialize */
|
||||
Status = SetupInterruptSystem(intcDescPtr);
|
||||
if (Status == SUCCESS)
|
||||
{
|
||||
DBG_INFO("Interrupt system setup SUCCESS!\n");
|
||||
}
|
||||
else
|
||||
{
|
||||
DBG_ERROR("Interrupt system setup FAILED, ErrorCode: %d.\n", Status);
|
||||
return Status;
|
||||
}
|
||||
|
||||
// Start System Monitor logging.
|
||||
timer_start(logTmPtr);
|
||||
// Start System Monitor logging.
|
||||
timer_start(logTmPtr);
|
||||
|
||||
DBG_PRINT("Physical started...\n");
|
||||
Phy_Start(phyInstPtr);
|
||||
DBG_PRINT("Physical started...\n");
|
||||
Phy_Start(phyInstPtr);
|
||||
|
||||
Linklayer_Start(linkInstPtr);
|
||||
Linklayer_Start(linkInstPtr);
|
||||
|
||||
while (true);
|
||||
while (true);
|
||||
|
||||
// while (true)
|
||||
// {
|
||||
// // System bus handler
|
||||
// if (SystemBus_IsReqPendding(sysbusDescPtr))
|
||||
// {
|
||||
// Status = SystemBus_HandleCmd(sysbusDescPtr);
|
||||
// if (Status != SUCCESS)
|
||||
// {
|
||||
// DBG_ERROR("SystemBus_HandleCmd exit with ErrorCode: %d.\n", Status);
|
||||
// }
|
||||
// }
|
||||
// if (SystemBus_IsRsqPendding(sysbusDescPtr) && (!SystemBus_IsTxBusy(sysbusDescPtr)))
|
||||
// {
|
||||
// // FIXME: Required by 12 (CASC)
|
||||
// udelay(200);
|
||||
// Status = SystemBus_MakeResp(sysbusDescPtr);
|
||||
// if (Status != SUCCESS)
|
||||
// {
|
||||
// DBG_ERROR("SystemBus_HandleCmd exit with ErrorCode: %d.\n", Status);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// while (true)
|
||||
// {
|
||||
// // System bus handler
|
||||
// if (SystemBus_IsReqPendding(sysbusDescPtr))
|
||||
// {
|
||||
// Status = SystemBus_HandleCmd(sysbusDescPtr);
|
||||
// if (Status != SUCCESS)
|
||||
// {
|
||||
// DBG_ERROR("SystemBus_HandleCmd exit with ErrorCode: %d.\n", Status);
|
||||
// }
|
||||
// }
|
||||
// if (SystemBus_IsRsqPendding(sysbusDescPtr) && (!SystemBus_IsTxBusy(sysbusDescPtr)))
|
||||
// {
|
||||
// // FIXME: Required by 12 (CASC)
|
||||
// udelay(200);
|
||||
// Status = SystemBus_MakeResp(sysbusDescPtr);
|
||||
// if (Status != SUCCESS)
|
||||
// {
|
||||
// DBG_ERROR("SystemBus_HandleCmd exit with ErrorCode: %d.\n", Status);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
} // main
|
||||
|
||||
Reference in New Issue
Block a user