Skip to content

Conversation

@Yogeshwaran-bs
Copy link
Contributor

No description provided.

casting in Enet_Osal layer

-Enet_Osal layer code implementation contains function pointers, void
pointers and type castings from one object type to other, which violates
the functional safety standards. Changes are made in the Enet_Osal layer
to make the code functionally safe.

The following changes aims to improve the overall code quality and meet
functional safety standards by reducing the use of potentially error-prone
constructs,

-replaced function pointers with direct function calls
-removed void pointers (exception - address)
-eliminated type casting between objects

Signed-off-by: Yogeshwaran B S <y-s1@ti.com>
-Underlying Enet peripheral modules like mdio, stats, hostport are
abstarcted by the enet module layer, which introduces function pointers,
void pointers and type castings from one object type to other in enet
mod layer, which violates the functional safety standards. Enet module
layer is completely removed to make the code functionally safe.

The following changes aims to improve the overall code quality and meet
functional safety standards by reducing the use of potentially error-prone
constructs,

-added common parameters to all the module objects (existing implementation
had enet_mod object which is shared across all module objects)
-replaced function pointers with direct function calls
-removed void pointers (exception - address)
-eliminated type casting between objects

Signed-off-by: Yogeshwaran B S <y-s1@ti.com>
partially

-Underlying Enet peripheral CPSW and ICSSG are abstarcted by the enet
peripheral and enet layer, which introduces function pointers,void pointers
and type castings from one object type to other in enet per and enet layer,
which violates the functional safety standards. Enet peripheral layer
(except IOCTL related functionalities) and enet layer (except IOCTL and
common functionalities) is removed to make the code functionally safe.

The following changes aims to improve the overall code quality and meet
functional safety standards by reducing the use of potentially error-prone
constructs,

-added common parameters to all the peripheral objects (existing
implementation had enet_per object which is shared across all module
objects)
-replaced function pointers with direct function calls
-removed void pointers (exception - address)
-eliminated type casting between objects
-Modified Enet_Handle type from Enet_Obj * to hEnet (hEnet contains the
Enet_Type and instId encoded in it)
-ENET_IOCTL macro definition is included based on the peripheral (Since,
enet_ioctl is removed as part of Enet layer removal, ioctl call should be
peripheral specific)

Signed-off-by: Yogeshwaran B S <y-s1@ti.com>
-Enet module layer, Enet peripheral layer(partial) and Enet layer(partial)
are removed to make the code functionally safe. the purpose of removing
the layers are to remove function pointers, void pointers, type casting
and abstraction. the sysconfig templates for the CPSW and ICSSG should be
modified in order to incorporate those changes

The following changes aims to improve the overall code quality and meet
functional safety standards by reducing the use of potentially error-prone
constructs,

-removed enet module object in peripheral's module object
-removed enet peripheral object in CPSW and ICSSG object
-replaced Enet_Obj * with integer type
-encoded enet type and instId in hEnet

Signed-off-by: Yogeshwaran s <y-s1@ti.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant