···96969797// Rx and Tx buffer descriptor format9898typedef struct {9999- WORD m_wStatus; // control / status --- used by edrv, do not change in application100100- WORD m_wLength; // transfer length9999+ u16 m_wStatus; // control / status --- used by edrv, do not change in application100100+ u16 m_wLength; // transfer length101101 u8 *m_pbData; // buffer address102102} tBufferDescr;103103
···146146 // Offset 21147147 u8 m_le_bRes2; // reserved148148 // Offset 22149149- WORD m_le_wSize;149149+ u16 m_le_wSize;150150 // Offset 24151151 u8 m_le_abPayload[256 /*D_NMT_IsochrRxMaxPayload_U16 */ ];152152···164164 // Offset 21165165 u8 m_le_bRes2; // reserved166166 // Offset 22167167- WORD m_le_wSize;167167+ u16 m_le_wSize;168168 // Offset 24169169 u8 m_le_abPayload[256 /*D_NMT_IsochrRxMaxPayload_U16170170 / D_NMT_IsochrTxMaxPayload_U16 */ ];···188188} PACK_STRUCT tEplSoaFrame;189189190190typedef struct {191191- WORD m_wEntryType;192192- WORD m_wErrorCode;191191+ u16 m_wEntryType;192192+ u16 m_wErrorCode;193193 tEplNetTime m_TimeStamp;194194 u8 m_abAddInfo[8];195195···215215 u8 m_le_bEplProfileVersion;216216 u8 m_le_bRes1;217217 u32 m_le_dwFeatureFlags; // NMT_FeatureFlags_U32218218- WORD m_le_wMtu; // NMT_CycleTiming_REC.AsyncMTU_U16: C_IP_MIN_MTU - C_IP_MAX_MTU219219- WORD m_le_wPollInSize; // NMT_CycleTiming_REC.PReqActPayload_U16220220- WORD m_le_wPollOutSize; // NMT_CycleTiming_REC.PResActPayload_U16218218+ u16 m_le_wMtu; // NMT_CycleTiming_REC.AsyncMTU_U16: C_IP_MIN_MTU - C_IP_MAX_MTU219219+ u16 m_le_wPollInSize; // NMT_CycleTiming_REC.PReqActPayload_U16220220+ u16 m_le_wPollOutSize; // NMT_CycleTiming_REC.PResActPayload_U16221221 u32 m_le_dwResponseTime; // NMT_CycleTiming_REC.PResMaxLatency_U32222222- WORD m_le_wRes2;222222+ u16 m_le_wRes2;223223 u32 m_le_dwDeviceType; // NMT_DeviceType_U32224224 u32 m_le_dwVendorId; // NMT_IdentityObject_REC.VendorId_U32225225 u32 m_le_dwProductCode; // NMT_IdentityObject_REC.ProductCode_U32···251251 u8 m_le_bTransactionId;252252 u8 m_le_bFlags;253253 u8 m_le_bCommandId;254254- WORD m_le_wSegmentSize;255255- WORD m_le_wReserved;254254+ u16 m_le_wSegmentSize;255255+ u16 m_le_wReserved;256256 u8 m_le_abCommandData[8]; // just reserve a minimum number of bytes as a placeholder257257258258} PACK_STRUCT tEplAsySdoCom;···310310 // Offset 6311311 u8 m_be_abSrcMac[6]; // MAC address of the transmitting node312312 // Offset 12313313- WORD m_be_wEtherType; // Ethernet message type (big endian)313313+ u16 m_be_wEtherType; // Ethernet message type (big endian)314314 // Offset 14315315 u8 m_le_bMessageType; // EPL message type316316 // Offset 15
+1-1
drivers/staging/epl/EplNmt.h
···185185typedef struct {186186 unsigned int m_uiNodeId; // NodeId187187 tEplNmtState m_NmtState; // NMT state (remember distinguish between MN / CN)188188- WORD m_wErrorCode; // EPL error code in case of NMT state NotActive188188+ u16 m_wErrorCode; // EPL error code in case of NMT state NotActive189189190190} tEplHeartbeatEvent;191191
+10-10
drivers/staging/epl/EplNmtMnu.c
···212212 tEplTimerHdl m_TimerHdlLonger; // 2nd timer for NMT command EnableReadyToOp and CheckCommunication213213 tEplNmtMnuNodeState m_NodeState; // internal node state (kind of sub state of NMT state)214214 u32 m_dwNodeCfg; // subindex from 0x1F81215215- WORD m_wFlags; // flags: CN is being accessed isochronously215215+ u16 m_wFlags; // flags: CN is being accessed isochronously216216217217} tEplNmtMnuNodeInfo;218218···224224 unsigned long m_ulStatusRequestDelay; // in [ms] (object 0x1006 * EPL_C_NMT_STATREQ_CYCLE)225225 unsigned long m_ulTimeoutReadyToOp; // in [ms] (object 0x1F89/5)226226 unsigned long m_ulTimeoutCheckCom; // in [ms] (object 0x1006 * MultiplexedCycleCount)227227- WORD m_wFlags; // global flags227227+ u16 m_wFlags; // global flags228228 u32 m_dwNmtStartup; // object 0x1F80 NMT_StartUp_U32229229 tEplNmtMnuCbNodeEvent m_pfnCbNodeEvent;230230 tEplNmtMnuCbBootEvent m_pfnCbBootEvent;···252252static tEplKernel EplNmtMnuCheckNmtState(unsigned int uiNodeId_p,253253 tEplNmtMnuNodeInfo * pNodeInfo_p,254254 tEplNmtState NodeNmtState_p,255255- WORD wErrorCode_p,255255+ u16 wErrorCode_p,256256 tEplNmtState LocalNmtState_p);257257258258static tEplKernel EplNmtMnuStartBootStep1(void);···271271272272static tEplKernel EplNmtMnuProcessInternalEvent(unsigned int uiNodeId_p,273273 tEplNmtState NodeNmtState_p,274274- WORD wErrorCode_p,274274+ u16 wErrorCode_p,275275 tEplNmtMnuIntNodeEvent276276 NodeEvent_p);277277···573573 tEplNmtMnuIntNodeEvent NodeEvent;574574 tEplObdSize ObdSize;575575 u8 bNmtState;576576- WORD wErrorCode = EPL_E_NO_ERROR;576576+ u16 wErrorCode = EPL_E_NO_ERROR;577577578578 if ((uiNodeId_p == 0) || (uiNodeId_p >= EPL_C_ADR_BROADCAST)) {579579 Ret = kEplInvalidNodeId;···1257125712581258tEplKernel EplNmtMnuGetDiagnosticInfo(unsigned int *puiMandatorySlaveCount_p,12591259 unsigned int *puiSignalSlaveCount_p,12601260- WORD *pwFlags_p)12601260+ u16 *pwFlags_p)12611261{12621262 tEplKernel Ret = kEplSuccessful;12631263···13771377 } else { // node answered IdentRequest13781378 tEplObdSize ObdSize;13791379 u32 dwDevType;13801380- WORD wErrorCode = EPL_E_NO_ERROR;13801380+ u16 wErrorCode = EPL_E_NO_ERROR;13811381 tEplNmtState NmtState =13821382 (tEplNmtState) (AmiGetByteFromLe13831383 (&pIdentResponse_p->···1909190919101910static tEplKernel EplNmtMnuProcessInternalEvent(unsigned int uiNodeId_p,19111911 tEplNmtState NodeNmtState_p,19121912- WORD wErrorCode_p,19121912+ u16 wErrorCode_p,19131913 tEplNmtMnuIntNodeEvent19141914 NodeEvent_p)19151915{···26232623static tEplKernel EplNmtMnuCheckNmtState(unsigned int uiNodeId_p,26242624 tEplNmtMnuNodeInfo * pNodeInfo_p,26252625 tEplNmtState NodeNmtState_p,26262626- WORD wErrorCode_p,26262626+ u16 wErrorCode_p,26272627 tEplNmtState LocalNmtState_p)26282628{26292629 tEplKernel Ret = kEplSuccessful;···26992699 } else if ((ExpNmtState != NodeNmtState_p)27002700 && !((ExpNmtState == kEplNmtCsPreOperational1)27012701 && (NodeNmtState_p == kEplNmtCsPreOperational2))) { // CN is not in expected NMT state (without the exceptions above)27022702- WORD wbeErrorCode;27022702+ u16 wbeErrorCode;2703270327042704 if ((pNodeInfo_p->27052705 m_wFlags & EPL_NMTMNU_NODE_FLAG_NOT_SCANNED) != 0) {
+3-3
drivers/staging/epl/EplObd.c
···10801080 case kEplObdTypInt16:10811081 case kEplObdTypUInt16:10821082 {10831083- AmiSetWordToLe(pDstData_p, *((WORD *) pSrcData));10831083+ AmiSetWordToLe(pDstData_p, *((u16 *) pSrcData));10841084 break;10851085 }10861086···12301230 case kEplObdTypInt16:12311231 case kEplObdTypUInt16:12321232 {12331233- *((WORD *) pBuffer) = AmiGetWordFromLe(pSrcData_p);12331233+ *((u16 *) pBuffer) = AmiGetWordFromLe(pSrcData_p);12341234 break;12351235 }12361236···20942094// Function: EplObdGetObjectSize()20952095//20962096// Description: function to get size of object20972097-// The function determines if an object type an fixed data type (u8, WORD, ...)20972097+// The function determines if an object type an fixed data type (u8, u16, ...)20982098// or non fixed object (string, domain). This information is used to decide20992099// if download data are stored temporary or not. For objects with fixed data length21002100// and types a value range checking can process.
+2-2
drivers/staging/epl/EplObd.h
···206206// -------------------------------------------------------------------------207207208208// types of objects in object dictionary209209-// DS-301 defines these types as WORD209209+// DS-301 defines these types as u16210210typedef enum {211211// types which are always supported212212 kEplObdTypBool = 0x0001,···431431 unsigned int m_uiUpperObjIndex; // upper limit of ObjIndex432432 tInitTabEntryCallback m_fpInitTabEntry; // will be called if ObjIndex was found433433 void *m_pTabBase; // base address of table434434- unsigned int m_uiEntrySize; // size of table entry // 25-feb-2005 r.d.: expansion from u8 to WORD necessary for PDO bit mapping434434+ unsigned int m_uiEntrySize; // size of table entry // 25-feb-2005 r.d.: expansion from u8 to u16 necessary for PDO bit mapping435435 unsigned int m_uiMaxEntries; // max. tabel entries436436437437} tEplObdModulTabParam;
+2-2
drivers/staging/epl/EplPdo.h
···90909191typedef struct {9292 void *m_pVar;9393- WORD m_wOffset; // in Bits9494- WORD m_wSize; // in Bits9393+ u16 m_wOffset; // in Bits9494+ u16 m_wSize; // in Bits9595 BOOL m_fNumeric; // numeric value -> use AMI functions96969797} tEplPdoMapping;
···237237 tEplObdAccess AccessType;238238 u8 bMappSubindex;239239 unsigned int uiCurPdoSize;240240- WORD wMaxPdoSize;240240+ u16 wMaxPdoSize;241241 unsigned int uiSubIndex;242242243243 // fetch PDO ID
···120120} tEdrvRxBuffer;121121122122//typedef void (*tEdrvRxHandler) (u8 bBufferInFrame_p, tBufferDescr * pbBuffer_p);123123-//typedef void (*tEdrvRxHandler) (u8 bBufferInFrame_p, u8 * pbEthernetData_p, WORD wDataLen_p);123123+//typedef void (*tEdrvRxHandler) (u8 bBufferInFrame_p, u8 * pbEthernetData_p, u16 wDataLen_p);124124typedef void (*tEdrvRxHandler) (tEdrvRxBuffer * pRxBuffer_p);125125typedef void (*tEdrvTxHandler) (tEdrvTxBuffer * pTxBuffer_p);126126···130130131131// u8 m_bNoOfRxBuffDescr; // number of entries in rx bufferdescriptor table132132// tBufferDescr * m_pRxBuffDescrTable; // rx bufferdescriptor table133133-// WORD m_wRxBufferSize; // size of the whole rx buffer133133+// u16 m_wRxBufferSize; // size of the whole rx buffer134134135135 tEdrvRxHandler m_pfnRxHandler;136136 tEdrvTxHandler m_pfnTxHandler;
-3
drivers/staging/epl/global.h
···2626#define TRACE printk27272828// --- logic types ---2929-#ifndef WORD3030-#define WORD unsigned short int3131-#endif3229#ifndef BOOL3330#define BOOL unsigned char3431#endif
+1-1
drivers/staging/epl/kernel/EplDllk.h
···9999 u32 m_dwPresTimeout;100100 unsigned long m_ulDllErrorEvents;101101 tEplNmtState m_NmtState;102102- WORD m_wPresPayloadLimit;102102+ u16 m_wPresPayloadLimit;103103 u8 m_be_abMacAddr[6];104104 u8 m_bSoaFlag1;105105 BOOL m_fSoftDelete; // delete node after error and ignore error
+2-2
drivers/staging/epl/proc_fs.c
···263263 // ---- EPL state ----264264 nSize += snprintf(pcBuffer_p + nSize, nBufferSize_p - nSize,265265 "NMT state: 0x%04X\n",266266- (WORD) EplNmtkGetNmtState());266266+ (u16) EplNmtkGetNmtState());267267268268 EplDllkCalGetStatistics(&pDllkCalStats);269269···286286 {287287 unsigned int uiMandatorySlaveCount;288288 unsigned int uiSignalSlaveCount;289289- WORD wFlags;289289+ u16 wFlags;290290291291 EplNmtMnuGetDiagnosticInfo(&uiMandatorySlaveCount,292292 &uiSignalSlaveCount, &wFlags);
+1-1
drivers/staging/epl/user/EplCfgMau.h
···148148 u32 m_dwCntObjectInDcf; // number of Objects in DCF149149 tEplCfgMaIndexType m_SkipCfg; // TRUE if a adsitional Configurationprocess150150 // have to insert e.g. PDO-mapping151151- WORD m_wTimeOutCnt; // Timeout Counter, break configuration is151151+ u16 m_wTimeOutCnt; // Timeout Counter, break configuration is152152 // m_wTimeOutCnt == CFGMA_MAX_TIMEOUT153153154154} tEplCfgMaNode;
+3-3
drivers/staging/epl/user/EplNmtMnu.h
···8484typedef tEplKernel(* tEplNmtMnuCbNodeEvent) (unsigned int uiNodeId_p,8585 tEplNmtNodeEvent NodeEvent_p,8686 tEplNmtState NmtState_p,8787- WORD wErrorCode_p,8787+ u16 wErrorCode_p,8888 BOOL fMandatory_p);89899090typedef tEplKernel(* tEplNmtMnuCbBootEvent) (tEplNmtBootEvent BootEvent_p,9191 tEplNmtState NmtState_p,9292- WORD wErrorCode_p);9292+ u16 wErrorCode_p);93939494//---------------------------------------------------------------------------9595// function prototypes···122122 *puiMandatorySlaveCount_p,123123 unsigned int124124 *puiSignalSlaveCount_p,125125- WORD * pwFlags_p);125125+ u16 * pwFlags_p);126126127127#endif128128