Commit 7c1f8b81 authored by Marcus Nordenberg's avatar Marcus Nordenberg Committed by Esteban Blanc

profibus: propagate state on shutdown

(cherry picked from commit 10a36c8aa94849ba8b8fa94a69cd102ffca037fb)
parent 970b5281
......@@ -96,7 +96,7 @@ static pwr_tStatus IoRackInit(io_tCtx ctx, io_sAgent* ap, io_sRack* rp)
local->dp = 1;
sts = gdh_ObjidToName(rp->Objid, (char*)&name, sizeof(name), cdh_mNName);
errh_Info("Init of Profibus DP Slave and Modules %s", name);
errh_Info("PROFIBUS: Init of DP slave and modules %s", name);
op = (pwr_sClass_Pb_DP_Slave*)rp->op;
......@@ -203,7 +203,7 @@ static pwr_tStatus IoRackInit(io_tCtx ctx, io_sAgent* ap, io_sRack* rp)
GetChanSize(((pwr_sClass_ChanIi*)chanp->cop)->Representation);
break;
default:
errh_Error("Diagnostic channel class, card %s", cardp->Name);
errh_Error("PROFIBUS: Diagnostic channel class, card %s", cardp->Name);
}
continue;
}
......@@ -366,13 +366,13 @@ static pwr_tStatus IoRackRead(io_tCtx ctx, io_sAgent* ap, io_sRack* rp)
if (sp->ErrorCount == sp->ErrorSoftLimit)
{
errh_Error("IO Error soft limit reached on card '%s'", rp->Name);
errh_Error("PROFIBUS: IO Error soft limit reached on device '%s'", rp->Name);
ctx->IOHandler->CardErrorSoftLimit = 1;
ctx->IOHandler->ErrorSoftLimitObject = cdh_ObjidToAref(rp->Objid);
}
if (sp->ErrorCount == sp->ErrorHardLimit)
{
errh_Error("IO Error hard limit reached on card '%s', stall action %d",
errh_Error("PROFIBUS: IO Error hard limit reached on device '%s', stall action %d",
rp->Name, sp->StallAction);
ctx->IOHandler->CardErrorHardLimit = 1;
ctx->IOHandler->ErrorHardLimitObject = cdh_ObjidToAref(rp->Objid);
......
......@@ -225,7 +225,7 @@ static pwr_tStatus IoCardInit(io_tCtx ctx, io_sAgent* ap, io_sRack* rp,
if (local->output_area_size > 0)
local->output_area = calloc(1, local->output_area_size);
errh_Info("Init of Profibus FDL Data transfer '%s'", cp->Name);
errh_Info("PROFIBUS: Init of FDL Data transfer '%s'", cp->Name);
op->Status = PB__NORMAL;
......
......@@ -63,7 +63,7 @@ static pwr_tStatus IoRackInit(io_tCtx ctx, io_sAgent* ap, io_sRack* rp)
pwr_tStatus sts;
sts = gdh_ObjidToName(rp->Objid, (char*)&name, sizeof(name), cdh_mNName);
errh_Info("Init of Profibus FDL SAP %s", name);
errh_Info("PROFIBUS: Init of FDL SAP %s", name);
local = calloc(1, sizeof(*local));
rp->Local = local;
......
......@@ -62,12 +62,12 @@ static pwr_tStatus IoCardInit(io_tCtx ctx, io_sAgent* ap, io_sRack* rp,
if (rp->Class != pwr_cClass_Pb_DP_Slave)
{
errh_Info("Illegal object type %s", cp->Name);
errh_Info("PROFIBUS: Illegal object type %s", cp->Name);
return IO__SUCCESS;
}
if (op->Status < PB_MODULE_STATE_OPERATE)
errh_Info("Error initializing Pb module Ii %s", cp->Name);
errh_Info("PROFIBUS: Error initializing Pb module Ii %s", cp->Name);
return IO__SUCCESS;
}
......
......@@ -60,13 +60,13 @@ static pwr_tStatus IoCardInit(io_tCtx ctx, io_sAgent* ap, io_sRack* rp,
if (rp->Class != pwr_cClass_Pb_DP_Slave)
{
errh_Info("Illegal object type %s", cp->Name);
errh_Info("PROFIBUS: Illegal object type %s", cp->Name);
return IO__SUCCESS;
}
if (op->Status < PB_MODULE_STATE_OPERATE)
{
errh_Info("Error initializing Pb module Io %s", cp->Name);
errh_Info("PROFIBUS: Error initializing Pb module Io %s", cp->Name);
}
return IO__SUCCESS;
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment