AUTOSAR SWS EthernetSwitchDriver
AUTOSAR SWS EthernetSwitchDriver
AUTOSAR CP R20-11
Disclaimer
This work (specification and/or software implementation) and the material contained in
it, as released by AUTOSAR, is for the purpose of information only. AUTOSAR and the
companies that have contributed to it shall not be liable for any use of the work.
The material contained in this work is protected by copyright and other types of intel-
lectual property rights. The commercial exploitation of the material contained in this
work requires a license to such intellectual property rights.
This work may be utilized or reproduced without any modification, in any form or by
any means, for informational purposes only. For any other purpose, no part of the work
may be utilized or reproduced, in any form or by any means, without permission in
writing from the publisher.
The work has been developed for automotive applications only. It has neither been
developed, nor tested for non-automotive applications.
The word AUTOSAR and the AUTOSAR logo are registered trademarks.
Table of Contents
1 Introduction and functional overview 8
3 Related documentation 9
3.1 Input documents & related standards and norms . . . . . . . . . . . . 9
3.2 Related specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
4 Constraints and assumptions 10
4.1 Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
4.2 Applicability to car domains . . . . . . . . . . . . . . . . . . . . . . . . 10
5 Dependencies to other modules 11
6 Requirements Tracing 11
7 Functional specification 17
7.1 Ethernet BSW stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
7.1.1 Indexing scheme . . . . . . . . . . . . . . . . . . . . . . . . . 18
7.1.2 Ethernet Switch Port Mirroring . . . . . . . . . . . . . . . . . 19
7.1.3 State Handling . . . . . . . . . . . . . . . . . . . . . . . . . . 20
7.1.4 Handling of cable diagnostic . . . . . . . . . . . . . . . . . . 20
7.1.5 Functional Description . . . . . . . . . . . . . . . . . . . . . . 21
7.1.5.1 Learning Phase at Start-up . . . . . . . . . . . . . . 21
7.1.5.2 Configuration of Egress Port Structure . . . . . . . . 24
7.1.5.3 Vlan-Membership on Switch-ports . . . . . . . . . . 26
7.1.5.4 Rate Policing on Ingress Side . . . . . . . . . . . . . 27
7.1.5.5 VLAN-modification at ingress side . . . . . . . . . . 27
7.1.5.6 Priority-Code-Point-Regeneration . . . . . . . . . . . 28
7.1.5.7 Direct Traffic Class Assignement . . . . . . . . . . . 28
7.1.5.8 Behavior in case of untagged frames in a VLAN net-
work . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
7.1.5.9 Behavior in case of double tagged frames in a VLAN
network . . . . . . . . . . . . . . . . . . . . . . . . . 29
7.1.5.10 Switch Management support . . . . . . . . . . . . . 29
7.1.5.11 Global Time support . . . . . . . . . . . . . . . . . . 30
7.1.5.12 Counter synchronization of Ethernet switches which
are connected via uplink ports . . . . . . . . . . . . . 31
7.1.5.13 Verification of Configuration . . . . . . . . . . . . . . 31
7.1.5.14 Testing and Diagnostic of Switch Ports . . . . . . . . 32
7.1.5.15 Low Power Mode Support . . . . . . . . . . . . . . . 33
7.2 Error Classifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
7.2.1 Development Errors . . . . . . . . . . . . . . . . . . . . . . . 33
7.2.2 Runtime Errors . . . . . . . . . . . . . . . . . . . . . . . . . . 36
7.2.3 Transient Faults . . . . . . . . . . . . . . . . . . . . . . . . . 36
8.3.30 EthSwt_EthTxAdaptBufferLength . . . . . . . . . . . . . . . 69
8.3.31 EthSwt_SetMgmtInfo . . . . . . . . . . . . . . . . . . . . . . 70
8.3.32 EthSwt_EthTxProcessFrame . . . . . . . . . . . . . . . . . . 71
8.3.33 EthSwt_EthTxFinishedIndication . . . . . . . . . . . . . . . . 71
8.3.34 EthSwt_PortEnableTimeStamp . . . . . . . . . . . . . . . . . 72
8.3.35 EthSwt_VerifyConfig . . . . . . . . . . . . . . . . . . . . . . . 73
8.3.36 EthSwt_SetForwardingMode . . . . . . . . . . . . . . . . . . 73
8.3.37 EthSwt_GetPortSignalQuality . . . . . . . . . . . . . . . . . . 74
8.3.38 EthSwt_GetPortIdentifier . . . . . . . . . . . . . . . . . . . . 75
8.3.39 EthSwt_GetSwitchIdentifier . . . . . . . . . . . . . . . . . . . 76
8.3.40 EthSwt_WritePortMirrorConfiguration . . . . . . . . . . . . . 76
8.3.41 EthSwt_ReadPortMirrorConfiguration . . . . . . . . . . . . . 77
8.3.42 EthSwt_DeletePortMirrorConfiguration . . . . . . . . . . . . 78
8.3.43 EthSwt_GetPortMirrorState . . . . . . . . . . . . . . . . . . . 79
8.3.44 EthSwt_SetPortMirrorState . . . . . . . . . . . . . . . . . . . 80
8.3.45 EthSwt_SetPortTestMode . . . . . . . . . . . . . . . . . . . . 81
8.3.46 EthSwt_SetPortLoopbackMode . . . . . . . . . . . . . . . . 81
8.3.47 EthSwt_SetPortTxMode . . . . . . . . . . . . . . . . . . . . . 82
8.3.48 EthSwt_RunPortCableDiagnostic . . . . . . . . . . . . . . . 83
8.3.49 EthSwt_GetPortCableDiagnosticsResult . . . . . . . . . . . 84
8.3.50 EthSwt_GetCfgDataRaw . . . . . . . . . . . . . . . . . . . . 85
8.3.51 EthSwt_GetCfgDataInfo . . . . . . . . . . . . . . . . . . . . . 85
8.3.52 EthSwt_PortLinkStateRequest . . . . . . . . . . . . . . . . . 86
8.3.53 EthSwt_GetMaxFIFOBufferFillLevel . . . . . . . . . . . . . . 87
8.3.54 EthSwt_GetRxMgmtObject . . . . . . . . . . . . . . . . . . . 88
8.3.55 EthSwt_GetTxMgmtObject . . . . . . . . . . . . . . . . . . . 89
8.4 Callback notifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
8.4.1 EthSwtPersistentConfigurationResultCallback . . . . . . . . 89
8.5 Scheduled functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
8.5.1 EthSwt_MainFunction . . . . . . . . . . . . . . . . . . . . . . 90
8.5.2 EthSwt_BackgroundTask . . . . . . . . . . . . . . . . . . . . 90
8.6 Expected interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91
8.6.1 Mandatory Interfaces . . . . . . . . . . . . . . . . . . . . . . 91
8.6.2 Optional Interfaces . . . . . . . . . . . . . . . . . . . . . . . . 91
8.6.3 Configurable interfaces . . . . . . . . . . . . . . . . . . . . . 92
8.6.3.1 <EthSwtLinkDownCallout> . . . . . . . . . . . . . . 92
8.6.3.2 <EthSwtLinkUpCallout> . . . . . . . . . . . . . . . . 93
8.6.3.3 <GetCfgDataRawDone> . . . . . . . . . . . . . . . . 94
8.7 Service Interfaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
9 Sequence diagrams 94
9.1 Switch Management support . . . . . . . . . . . . . . . . . . . . . . . . 96
10 Configuration specification 98
10.1 Containers and configuration parameters . . . . . . . . . . . . . . . . . 98
10.1.1 EthSwt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
10.1.2 EthSwtConfig . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
3 Related documentation
4.1 Limitations
The Ethernet Switch Driver module is only able to handle a single thread of execution.
The execution must not be pre-empted by itself.
The implementation is limited to 10Mbit/s, 100MBit/s and 1000Mbit/s Ethernet and
transceivers connected via (gigabit) Media Independent Interface (xMII).
Depending on the Ethernet hardware, it may become necessary that implementations
deviate from API specifications in respect to the asynchronous/synchronous behavior.
The switch driver does not support the following features:
• MAC-based Ingress Filtering: No filtering options for Ethernet frames based on
MAC-addresses is supported.
6 Requirements Tracing
The following tables reference the requirements specified in [9] as well as [10] and
links to the fulfillment of these. Please note that if column “Satisfied by” is empty for a
specific requirement this means that this requirement is not fulfilled by this document.
Requirement Description Satisfied by
[SRS_BSW_00003] All software modules shall [SWS_EthSwt_00131]
provide version and identification
information
[SRS_BSW_00101] The Basic Software Module shall [SWS_EthSwt_00006]
be able to initialize variables and [SWS_EthSwt_00007]
hardware in a separate [SWS_EthSwt_00008]
initialization function [SWS_EthSwt_00011]
[SRS_BSW_00161] The AUTOSAR Basic Software [SWS_EthSwt_00099]
shall provide a microcontroller [SWS_EthSwt_00130]
abstraction layer which provides
a standardized interface to
higher software layers
[SRS_BSW_00162] The AUTOSAR Basic Software [SWS_EthSwt_00099]
shall provide a hardware [SWS_EthSwt_00130]
abstraction layer
7 Functional specification
Figure 7.1: Basic Structure of the Ethernet BSW stack.(Note: The different hardware
variants are alternative setups)
Users of the Ethernet Switch Driver identify switch resources using an indexing scheme
as depicted in Figure 7.2.
Ethernet switch port mirroring use the common established functionality of the Ethernet
switch hardware to mirror traffic of one or more Ethernet switch ports (mirrored port) to
a another Ethernet switch port (capture port). The mirroring configuration is given by
the port mirror configuration (see [SWS_EthSwt_91017]). The port mirror configuration
is set up per Ethernet switch. The configuration is stored persistently by the Ethernet
switch driver. Therefore a shadow buffer is used to store the port mirror configura-
tion during runtime and stored persistently according to the NvM storing strategy (e.g.
store the shadow buffer persistently upon ECU shutdown). The port mirror configu-
ration could be activated and de-activated, respectively, explicitly via dedicated APIs.
The port mirroring is controlled by a dedicated diagnostic CDD with receive diagnostic
request and forward them to the Ethernet switch driver.
[SWS_EthSwt_00416] dThe port mirror configuration (see [SWS_EthSwt_91017] )
shall be written to a shadow buffer of the Ethernet switch driver per Ethernet Switch by
calling EthSwt_WritePortMirrorConfiguration.c(SRS_ETH_00123)
Note: One port mirror configuration is maintained per Ethernet switch.
[SWS_EthSwt_00417] dThe port mirror configuration shall be enabled and disabled,
respectively, per Ethernet Switch by calling EthSwt_SetPortMirrorState. The
current state of the stored port mirror configuration shall be stored persistently, to out-
last an ECU reset and to restore the port mirroring activities after an ECU reset.c
(SRS_ETH_00123)
[SWS_EthSwt_00418] dThe stored port mirror configuration shall be marked as "to be
deleted" by calling EthSwt_DeletePortMirrorConfiguration, if the port mirror-
ing of the given Ethernet switch index is disabled (see [SWS_EthSwt_91022]. Other-
wise the request to delete the port mirror configuration shall be rejected.c(SRS_ETH_-
00123)
Note: The shadow buffer is stored persistently according to the NvM storing strategy,
e.g. store the shadow buffer persistently upon ECU shutdown.
Note: The upper layer is a CDD that triggers the cable diagnostic measurement and
maintains the cable diagnostic result. The EthSwt forwards the API calls to the EthTrcv
(see [SWS_EthSwt_00429] and [SWS_EthSwt_00346]).
[SWS_EthSwt_00226] dThe switch driver shall support a learning phase which can be
divided into several sequential steps.c(SRS_ETH_00087)
Note: After assembly and initial power-up of the network, three learning phases follow
which include MAC-Learning and IP-Address Assignment. Afterwards the learned pa-
rameters are stored to one or several non-volatile memories to make them available
for subsequent start-ups. This process is shown in Figure 7.3. As an example for
triggering this process, the DCM receives a diagnostic request via a bus system or a
broadcast message in the Ethernet network. This diagnostic request can be forwarded
to an SWC or CCD which triggers the auto-configuration process. However, the trigger
is not part of this specification.
MAC-Learning (Optional Step): In this phase, messages need to be sent through the
network and the switch will learn new MAC addresses (cf. Figure 7.4). These MAC-
addresses will be stored in addition to predefined addresses, e.g. multicast MAC ad-
dresses which are configured during the vehicle network design. If static learning is
executed, i.e. MAC address will be persistently stored, it might be possible to add
dynamically learned entries in the tables.
If software MAC learning is supported by switch hardware and the switch hardware
expects an external µC (see Variant 2 and 3 in Figure 7.1), packets with unknown MAC
Source Address will be routed to this µC. The MAC learning is done by integration code.
It is intentionally not defined where this algorithm is located within the AUTOSAR stack
as this might need a very time-optimized solution.
IP-Address Assignment: In this phase, ECUs without a predefined IP-address will start
to acquire an IP-address via DHCP (cf. Figure 7.5). Thus, these ECUs will run a
DHCP-client while the ECU with the switch will run a DHCP server. In order to be
able to assign always the same IP-address to a certain node, the DHCP server needs
the information at which port the MAC address has been received. This port infor-
mation can be interpreted as a "domain name" in the internet which is resolved to an
IP address using a domain name server (DNS). With this port information the DHCP-
server will assign the IP-address according to the IP-Assignment Table to the node.
As mentioned above, this allows the assignment of MAC addresses by the Tier 1 and
assignment of IP addresses by the OEM. With this mechanism it is also possible to
assign different IP addresses to several VLANs at the same port. For this purpose, the
IP-Assignment Table needs to be extended with a VLAN-column. Please note that the
MAC-Learning-Phase can be combined with this phase.
[SWS_EthSwt_00136] dThe Ethernet Switch driver shall support an API which allows
to store learned parameters like address resolution tables in a persistent manner by
using the API EthSwt_StoreConfiguration. This persistent storage can be done
in an NVRAM of the host CPU which runs the Ethernet Switch driver. Alternatively,
this can be done in a memory of the switch itself. The trigger for storing the learned
configuration or resetting the stored configuration can be done e.g. by a DCM.c(SRS_-
ETH_00122, SRS_ETH_00087)
[SWS_EthSwt_00181] dThe Ethernet Switch driver shall support an API which allows
to reset learned parameters like address resolution tables by using the API EthSwt_-
ResetConfiguration.c(SRS_ETH_00126, SRS_ETH_00087)
[SWS_EthSwt_00162] dThe switch driver shall provide APIs to read the MAC-address
to switch port mapping from the switch device to support the IP-address assignment
by using the API EthSwt_GetPortMacAddr.c(SRS_ETH_00087)
[SWS_EthSwt_00407] dUnused ARL table entries shall be removed from the ARL ta-
ble after the timeout configured via EthSwtArlTableEntryTimeout, if this parame-
ters is present in the configuration.c()
As shown in Figure 7.6, the switch consists of a certain number of ports. Each port
has its own set of egress FIFOs in which the incoming packets will be buffered. How
the messages in the FIFOs will be forwarded depends mainly on the shaping and port
scheduling mechanisms. Thus, the parameterization of the egress port influences the
latency of messages within the network. Please note that the egress port structures in
Figure 7.6 are meant as an example. Other structures with different FIFO numbers are
possible.
Considering the limitations of the hardware, such port structures shall be configurable
within e.g. an initialization phase of the Ethernet Switch (see Section 10.1.6ff.)
[SWS_EthSwt_00132] dThe configuration of the Ethernet switch driver shall support
different Ethernet egress port structures by the configuration EthSwtPortEgress.c
(SRS_ETH_00121)
Implementation note:
As Switch HW has very vendor specific structure a more specific description of the
applying algorithms is not feasible here. The Routing takes place inside the Switch
HW.
After mapping the packets to a traffic class, they will be mapped to a certain
FIFO at the egress side of the switch. This mapping can vary from egress port to
egress port.
3. Traffic Class to FIFO Mapping
Traffic Class FIFO (if 4 FIFOs available)
7 3
6 2
5-0 1
- 0
While the frame forwarding is a hardware mechanism of the switch, the tables
how the frames will be forwarded shall be configurable (see Section 10.1.12ff.).
Please note that the traffic class assignment is done after the priority regenera-
tion.
[SWS_EthSwt_00133] dThe switch configuration shall support to configure the Ether-
net frame forwarding mechanisms of a switch by the configuration parameters Eth-
SwtPortTrafficClassAssignment, EthSwtPriorityTrafficClassAssign-
ment, EthSwtPortFifoTrafficClassAssignment.c(SRS_ETH_00121)
[SWS_EthSwt_00234] dThe Parameter EthSwtPortFifoMinimumLength shall de-
fine the minimum length for one dedicated FIFO on one Switch.c(SRS_ETH_00121)
Note: The actual length can be longer. The decision on the length is very likely to be
taken by the Switch HW or fixed by the Switch design. To define the minimum in ECUC
is supposed to guarantee that some priorities have enough egress buffer.
Every Port holds the list of Vlan-Memberships. This Membership describe ingress and
egress behavior in terms of filtering, and rate policing and tagging or untagging.
For each VLAN identifier a table is necessary which stores at which egress port the
corresponding VLAN is tagged or untagged. For an 8-port switch, this table could look
like the following example where T stands for tagging and U for untagging:
Incoming packets which contain a VLAN-ID of e.g. 1 can be forwarded to the ports 1,
2, 4, and 8. At ports 1, 2, and 8 these packets will be transmitted with the VLAN tag
and at port 4 the tag will be removed. If a broadcast message with e.g. VLAN-ID 2
will be received at port 2. It will be forwarded to port 1, 4, and 8. The other ports 3,
5, 6, and 7 are not in the same VLAN. Thus, the packet will not be forwarded to these
egress ports. The table considers only messages, which contain a VLAN-ID within the
switch. (see also 10.1.12).
[SWS_EthSwt_00134] dThe switch configuration shall support the configuration how
packets will be forwarded with respect to configured VLANs by using the configuration
parameters of the subcontainer EthSwtPortVlanMembership.c(SRS_ETH_00121,
SRS_ETH_00114)
Note: VLAN-Memberships of a port are modeled with the container EthSwt-
PortVlanMembership where the EthSwtPortVlanDefaultPriority and Eth-
SwtPortVlanForwardingType are configured.
In this example, all incoming messages at port one will get the VLAN-ID 2 no matter
they already had one before. At port 4, all incoming messages will get a 6 as their
VLAN-ID. At the remaining ports, no VLAN-IDs will be inserted and an existing VLAN-
ID in the Ethernet-message will remain without modification.
[SWS_EthSwt_00135] dThe switch configuration shall support the configuration how
VLANs will be inserted into packets or existing VLANs will be modified by the configu-
ration EthSwtPortIngressVlanModification.c(SRS_ETH_00121)
7.1.5.6 Priority-Code-Point-Regeneration
Within the VLAN-tag, the PCP-field (priority code point) is another parameter which
can be modified at an ingress port of an Ethernet switch. For this purpose a so-called
priority regeneration table has to be defined:
Priority Regeneration Table
Ingress 0 1 2 3 4 5 6 7
PCP
Regener- 0 1 2 3 4 5 6 7
ated
PCP
Table 7.1: In this table, the "Ingress PCP" is mapped to the "Regenerated PCP".
• EthSwt_EthRxFinishedIndication
• EthSwt_EthTxAdaptBufferLength
• EthSwt_EthTxPrepareFrame
• EthSwt_SetMgmtInfo
• EthSwt_EthTxProcessFrame and
• EthSwt_EthTxFinishedIndication
if EthSwtManagementSupportApi is set to TRUE.c(SRS_BSW_00171, SRS_-
ETH_00125)
Note: Switch management APIs support the EthIf to gather / modify Switch-Port spe-
cific communication attributes.
[SWS_EthSwt_00241] dThe Switch Driver management APIs
• EthSwt_EthRxProcessFrame
• EthSwt_EthRxFinishedIndication
• EthSwt_EthTxAdaptBufferLength
• EthSwt_EthTxPrepareFrame
• EthSwt_SetMgmtInfo
• EthSwt_EthTxProcessFrame and
• EthSwt_EthTxFinishedIndication
shall support the Ethernet Driver to gather the Switch specific management information
out of an Ethernet frame for reception or to prepare an Ethernet frame for management
mode conformant frame transmission, e.g. the egress route of a frame.c(SRS_ETH_-
00125)
[SWS_EthSwt_00242] dThe Switch Driver management APIs EthSwt_EthTxPro-
cessFrame and EthSwt_EthTxFinishedIndication shall return immediately, if
EthSwt_SetMgmtInfo has not been called before a call of EthSwt_EthTxPro-
cessFrame.c(SRS_ETH_00125)
[SWS_EthSwt_00282] dIf the management information for reception will not be avail-
able within the time specified in the configuration parameter EthSwtMgmtInfoIndi-
cationTimeout, the pointer MgmtInfoPtr shall be set to NULL before calling the
function EthIf_SwitchMgmtInfoIndication.c(SRS_ETH_00125)
For more details regarding time measurement with Switches, please refer to [12,
SWS_TimeSyncOverEthernet].
[SWS_EthSwt_00243] dThe Switch driver shall access the port specific hardware
time stamps if EthSwtPortTimeStampSupport of the port is set to TRUE.c(SRS_BSW_-
00171, SRS_ETH_00125)
[SWS_EthSwt_00378] dIf EthSwt_PortEnableTimeStamp is called for a PortIdx,
the switch driver shall enable the time-stamping for this port if EthSwtPortTimeS-
tampSupport is set to TRUE for this port.c(SRS_ETH_00125)
[SWS_EthSwt_00245] dThe Switch driver shall inform the EthIf about
the availability of port specific ingress and egress timestamps us-
ing the APIs EthIf_SwitchIngressTimeStampIndication and
EthIf_SwitchEgressTimeStampIndication , if EthSwtGlobalTimeSup-
portApi is set to TRUE.c(SRS_ETH_00125)
Note: Global Time support typically requires the activation of the Switch management
support functionality within the Switch device.
Some Ethernet Switches provide the possibility to synchronize their internal clock. For
Ethernet switches which are connected via uplink ports it is not necessary to measure
the delay between the connected uplink ports, if the clock synchronization clock is
activated (EthSwtClockSynchronizationSupport set to TRUE).
[SWS_EthSwt_00408] dThe Switch driver shall enable clock synchronization with an-
other Ethernet switch to which it is connected via uplink port, if EthSwtClockSyn-
chronizationSupport is set to TRUE.c()
[SWS_EthSwt_CONSTR_00409] dThe port specific timestamping (EthSwtPortTime
StampSupport) can be set to TRUE, if clock synchronization for connected Ethernet
switches is deactivated (EthSwtClockSynchronizationSupport set to FALSE).c
()
[SWS_EthSwt_CONSTR_00410] dThe port specific timestamping (EthSwtPort-
TimeStampSupport) can be set to TRUE, if EthSwtClockSynchronization-
Support is activated and EthSwtPortRole is not ETHSWT_UP_LINK_PORT. Eth
SwtPorts with EthSwtPortRole ETHSWT_UP_LINK_PORT are connected to another
Ethernet switch and not considered for the time delay compensation, if EthSwt-
ClockSynchronizationSupport is activated.c()
There are some situations where the Host controller needs to verify the Switch config-
uration.
If configured, the Ethernet Switch Driver provides following interfaces to apply Testing
and diagnostic functionalities
• EthSwt_GetPortSignalQuality
• EthSwt_GetPortIdentifier
• EthSwt_GetSwitchIdentifier
• EthSwt_WritePortMirrorConfiguration
• EthSwt_ReadPortMirrorConfiguration
• EthSwt_GetPortMirrorState
• EthSwt_SetPortMirrorState
• EthSwt_SetPortTestMode
• EthSwt_SetPortLoopbackMode
• EthSwt_SetPortTxMode
• EthSwt_GetPortCableDiagnosticsResult
• EthSwt_GetCfgDataRaw
• EthSwt_GetCfgDataInfo
The Availabiliy of these functions is strongly depending on the possibilities of the used
Transceiver-(Phy)-HW.
[SWS_EthSwt_00001] d
Type of error Related error code Error value
Invalid switch index ETHSWT_E_INV_SWITCH_IDX 0x01
EthSwt module was not initialized ETHSWT_E_UNINIT 0x02
Invalid pointer in parameter list ETHSWT_E_PARAM_POINTER 0x03
5
4
Type of error Related error code Error value
Invalid API which is not available by another ETHSWT_E_INV_API 0x05
module
Invalid switch port index ETHSWT_E_INV_SWITCHPORT_IDX 0x06
Invalid Controller Index ETHSWT_E_INV_CTRL_IDX 0x07
Invalid input parameter ETHSWT_E_INV_PARAM 0x08
Invalid configuration ETHSWT_E_INIT_FAILED 0x09
c(SRS_BSW_00385)
[SWS_EthSwt_00009] dIf development error detection is enabled, the function Eth-
Swt_Init shall check the parameter CfgPtr for being valid. If the check fails,
EthSwt_Init shall raise the development error ETHSWT_E_INIT_FAILED.c(SRS_-
BSW_323, SRS_BSW_369)
Note: Please note that in case of variant pre-compile NULL_PTR is allowed.
[SWS_EthSwt_00164] dThe switch driver shall check whether the lower layer driver,
i.e. the EthTrcv provides the APIs which can be called by an upper layer module (Eth
If) of the switch driver and will be forwarded to the lower layer. In case of missing
APIs, the switch driver shall raise the development error ETHSWT_E_INV_API if APIs
are missing in the lower layer module.c(SRS_BSW_00369, SRS_BSW_00386, SRS_-
ETH_00118)
Note: This check will be performed upon calling a certain API. For this check the input
parameter SwitchPortIdx and a configuration table which needs to be derived from
the configuration of the Ethernet transceiver drivers which are attached to the Ethernet
switch driver are necessary. This functionality is necessary if development error tracing
is activated. This check is necessary because an Ethernet switch driver API can be
called by an upper layer module with the argument SwitchPortIdx. This value of
this SwitchPortIdx can be in a valid range, but some Ethernet transceiver driver
which are used by the switch driver support the API and some do not support this API.
In order to resolve this conflict, this check has been implemented.
[SWS_EthSwt_00156] dThe function EthSwt_SetSwitchPortMode shall check
whether the EthTrcv_SetTransceiverMode API of the indexed transceiver driver is
available by checking whether for this SwitchPortIdx the corresponding EthTrcv
API is available. If this is not the case, the function shall return E_NOT_OK and if
development error tracing is activated by EthSwtDevErrorDetect the ETHSWT_-
E_INV_API shall be raised.c(SRS_BSW_00413, SRS_BSW_323, SRS_BSW_369,
SRS_ETH_00118)
[SWS_EthSwt_00157] dThe function EthSwt_GetSwitchPortMode shall check
whether the EthTrcv_GetTransceiverMode API of the indexed transceiver driver
is available by checking whether for this SwitchPortIdx the corresponding EthTrcv
API is available. If this is not the case, the function shall return E_NOT_OK and if
development error tracing is activated by EthSwtDevErrorDetect the ETHSWT_-
[SWS_EthSwt_00434] d
Type of error Related error code Error value
Initialization of ports is not finished ETHSWT_INIT_NOT_COMPLETED 0x01
c()
[SWS_EthSwt_00113] d
Error Name: ETHSWT_E_ACCESS
Short Description: Ethernet Switch Access Failure
Long Description: This production error shall be issued when the switch is not accessible.
Recommended DTC: N/A
Detection Criteria: Fail When access to the Ethernet Switch
fails the module shall report the
extended production error with event
status DEM_EVENT_STATUS_
PREFAILED to DEM.
Pass When access to the Ethernet Switch
succeeds the module shall report the
extended production error with event
status DEM_EVENT_STATUS_
PREPASSED to DEM.
Secondary Parameters: N/A
Time Required: N/A
Monitor Frequency N/A
MIL illumination: N/A
c(SRS_BSW_00385)
[SWS_EthSwt_00395] d
c(SRS_BSW_00385)
8 API specification
4
Module Header File Imported Type
Eth_GeneralTypes.h Eth_RxStatsType
Eth_GeneralTypes.h Eth_TimeStampType
Eth_GeneralTypes.h Eth_TxErrorCounterValuesType
Eth_GeneralTypes.h Eth_TxStatsType
c()
8.2.1 EthSwt_StateType
[SWS_EthSwt_00123] d
Name EthSwt_StateType
Kind Enumeration
Range ETHSWT_STATE_UNINIT 0x00 Switch is not yet configured
ETHSWT_STATE_INIT 0x01 Switch driver is initialized
ETHSWT_STATE_ 0x02 Port initialization is completed
PORTINIT_COMPLETED
ETHSWT_STATE_ACTIVE 0x03 Switch is active
Description Status supervision used for Development Error Detection. The state shall be available for
debugging.
5
4
Available via Eth_GeneralTypes.h
c(SRS_BSW_00406)
8.2.2 EthSwt_ConfigType
[SWS_EthSwt_00165] d
Name EthSwt_ConfigType
Kind Structure
Elements implementation specific
Type –
Comment –
Description Implementation specific structure of the post build configuration.
Available via EthSwt.h
c(SRS_BSW_00395)
8.2.3 EthSwt_MacLearningType
[SWS_EthSwt_00227] d
Name EthSwt_MacLearningType
Kind Enumeration
Range ETHSWT_ – If hardware learning disabled, the switch must
MACLEARNING_ not learn new MAC addresses
HWDISABLED
ETHSWT_ – If hardware learning enabled, the switch
MACLEARNING_ learns new MAC addresses
HWENABLED
ETHSWT_ – If software learning enabled, the hardware
MACLEARNING_ learning is disabled and the switch forwards
SWENABLED packets with an unknown source address to a
host CPU
Description The interpretation of this value
Available via Eth_GeneralTypes.h
c(SRS_ETH_00087)
8.2.4 EthSwt_MgmtInfoType
[SWS_EthSwt_91002] d
Name EthSwt_MgmtInfoType
Kind Structure
Elements SwitchIdx
Type uint8
Comment Switch index
SwitchPortIdx
Type uint8
Comment Port index of the switch
Description Type for holding the management information received/transmitted on Switches (ports).
Available via Eth_GeneralTypes.h
c(SRS_Eth_00125)
8.2.5 EthSwt_PortMirrorCfgType
[SWS_EthSwt_91017] d
Name EthSwt_PortMirrorCfgType
Kind Structure
srcMacAddrFilter
Type Array of uint8
Size 6
Comment Specifies the source MAC address
[0..255,0..255,0..255,0..255,0..255,0..255] that should be mirrored. If
set to 0,0,0,0,0,0, no source MAC address filtering shall take place.
dstMacAddrFilter
Type Array of uint8
Size 6
Comment Specifies the destination MAC address
[0..255,0..255,0..255,0..255,0..255,0..255] that should be mirrored. If
set to 0,0,0,0,0,0, no destination MAC address filtering shall take place.
VlanIdFilter
Type uint16
Comment Specifies the VLAN address 0..4094 that should be mirrored. If set to
65535, no VLAN filtering shall take place.
MirroringPacketDivider
Type uint8
Comment Divider if only a subset of received frames should be mirrored. E.g.
MirroringPacketDivider = 2 means every second frames is mirrored
MirroringMode
Type uint8
Comment specifies the mode how the mirrored traffic should be tagged : 0x00 ==
No VLAN retagging; 0x01 == VLAN retagging; 0x02 == VLAN Double
tagging
5
4
TrafficDirectionIngressBitMask
Type uint32
Comment Specifies the bit mask of Ethernet switch ingress port traffic direction to
be mirrored. The bit mask is calculated depending of the values of Eth
SwtPortIdx. (e.g. set EthSwtPortIdx == 2 => TrafficDirectionIngressBit
Mask = 0b0000 0000 0000 0000 0000 0000 0000 0100). 0b0 ==
enable ingress port mirroring 0b1 == disable ingress port mirroring
Example: TrafficDirectionIngressBitMask = 0b0000 0000 0000 0000
0000 0000 0000 0100 => Ingress traffic mirroring is enabled of
Ethernet switch port with EthSwtPortIdx=2
TrafficDirectionEgressBitMask
Type uint32
Comment Specifies the bit mask of Ethernet switch egress port traffic direction to
be mirrored. The bit mask is calculated depending of the values of Eth
SwtPortIdx. (e.g. set EthSwtPortIdx == 2 => TrafficDirectionEgressBit
Mask = 0b0000 0000 0000 0000 0000 0000 0000 0100). 0b0 ==
enable egress port mirroring 0b1 == disable egress port mirroring
Example: TrafficDirectionEgressBitMask = 0b0000 0000 0000 0000
0000 0000 0000 0001 => Egress traffic mirroring is enabled of
Ethernet switch port with EthSwtPortIdx=0
CapturePortIdx
Type uint8
Comment Specifies the Ethernet switch port which capture the mirrored traffic
ReTaggingVlanId
Type uint16
Comment Specifies the VLAN address 0..4094 which shall be used for re-tagging
if MirroringMode is set to 0x01 (VLAN re-tagging). If the value is set to
65535, the value shall be ignored, because the VLAN address for
re-tagging is provided by the Ethernet switch configuration
DoubleTaggingVlanId
Type uint16
Comment Specifies the VLAN address 0..4094 which shall be used for
double-tagging if MirroringMode is set to 0x02 (VLAN double tagging).
If the value is set to 65535, the value shall be ignored, because the
VLAN address for double tagging is provided by the Ethernet switch
configuration
Description The EthSwt_PortMirrorCfgType specify the port mirror configuration which is set up per Ethernet
switch. The configuration is written to the Ethernet switch driver by calling EthSwt_WritePortMirror
Configuration. One port mirror configuration is maintained per Ethernet Switch.
Available via Eth_GeneralTypes.h
c(SRS_ETH_00123)
8.2.6 EthSwt_PortMirrorStateType
[SWS_EthSwt_91020] d
Name EthSwt_PortMirrorStateType
Kind Enumeration
Range PORT_MIRRORING_ 0x00 port mirroring disabled
DISABLED
PORT_MIRRORING_ 0x01 port mirroring enabled
ENABLED
Description Type to request or obtain the port mirroring state (enable/disable) for a particular port mirror
configuration per Ethernet switch.
Available via Eth_GeneralTypes.h
c(SRS_ETH_00123)
8.2.7 EthSwt_ReturnType
[SWS_EthSwt_91033] d
Range ETHSWT_PORT_MIRRORING_ 0x02 port mirroring configuration is not
CONFIGURATION_NOT_ supported by Ethernet switch
SUPPORTED driver or by the Ethernet switch
hardware
Description Overlayed return value of Std_ReturnType for Ethernet switch driver API EthSwt_WritePortMirror
Configuration, if the port mirroring configuration is not supported by Ethernet switch driver or by the
Ethernet switch hardware (e.g. the configured mirrored traffic direction (see SWS_EthSwt_91017
"TrafficDirectionIngressBitMask" and "TrafficDirectionEgressBitMask") for ingress and egress traffic
of the same port is not supported, or the addressed Ethernet switch ports within the port mirror
configuration are not accessible by the Ethernet switch driver)
Available via Eth_GeneralTypes.h
c()
8.2.8 EthSwt_MgmtOwner
[SWS_EthSwt_91035] d
Name EthSwt_MgmtOwner
Kind Enumeration
Range ETHSWT_MGMT_OBJ_ 0x00 Object unused
UNUSED
ETHSWT_MGMT_OBJ_ 0x01 Object used and EthSwt collects needed data
OWNED_BY_ETHSWT
ETHSWT_MGMT_OBJ_ 0x02 Object used and the upper layer does
OWNED_BY_UPPER_ calculations
LAYER
Description Holds information if upper layer or EthSwt is owner of mgmt_obj.
Available via Eth_GeneralTypes.h
c()
8.2.9 EthSwt_Mgmt_ObjectType
[SWS_EthSwt_91037] d
Name EthSwt_MgmtObjectType
Kind Structure
Validation
Elements
Type EthSwt_MgmtObjectValidType
Comment The validation information for the mgmt_obj.
IngressTimestamp
Type Eth_TimeStampType
Comment The ingress timestamp value out of the switch.
EgressTimestamp
Type Eth_TimeStampType
Comment The egress timestamp value out of the switch.
MgmtInfo
Type EthSwt_MgmtInfoType
Comment Received/Transmitted Management information of the switches.
Ownership
Type EthSwt_MgmtOwner
Comment The ownership of MgmtObj.
Description Provides information about all struct member elements. The ownership gives information whether
EthSwt has finished its activities in providing all struct member elements.
Available via Eth_GeneralTypes.h
c()
[SWS_EthSwt_00433] dA MgmtObject is just allowed to be owned between EthSwt
and only one <UPPER_LAYER>. The structure element can be identified unambigu-
ously using the DataPtr in Rx- and BufIdx in Tx-context, because both elements are
definitively unique within the RxIndication() / TxConfirmation() context.c()
8.2.10 EthSwt_MgmtObjectValidType
[SWS_EthSwt_91036] d
Name EthSwt_MgmtObjectValidType
Kind Structure
IngressTimestampValid
Type Std_ReturnType
Comment IngressTimestampValid shall be set to E_NOT_OK if ingress
timestamp is not available
EgressTimestampValid
5
4
Type Std_ReturnType
Comment EgressTimestampValid shall be set to E_NOT_OK if ingress
timestamp is not available.
MgmtInfoValid
Type Std_ReturnType
Comment MgmtInfoValid shall be set to E_NOT_OK if ingress timestamp is not
available(e.g. timeout).
Description Will be set from EthSwt and marks EthSwt_MgmtObject as valid or not. So the upper layer will be
able to detect inconsistencies.
Available via Eth_GeneralTypes.h
c()
8.3.1 EthSwt_Init
[SWS_EthSwt_00006] d
Service Name EthSwt_Init
Syntax void EthSwt_Init (
const EthSwt_ConfigType* CfgPtr
)
c(SRS_BSW_00101)
[SWS_EthSwt_00007] dThe function EthSwt_Init shall store the access to the con-
figuration structure for subsequent API calls.c(SRS_BSW_00101)
[SWS_EthSwt_00008] dThe function EthSwt_Init shall change the state of all
switches controlled by this Switch Driver from ETHSWT_STATE_UNINIT to ETHSWT_-
STATE_INIT.c(SRS_BSW_00101)
[SWS_EthSwt_00421] dThe EthSwt shall check for enabled port mirror configuration.
The enabled port mirror configuration shall be activated by reconfiguring the Ethernet
switch hardware according to the port mirror configuration, before frame forwarding is
being enabled.c(SRS_Eth_00123)
[SWS_EthSwt_00422] dIf the PortMirrorState is set to 0x01 (port mirroring enabled),
then the stored port mirror configuration for the given Ethernet switch shall be written
to hardware registers of the given Ethernet switch and enable port mirroring.c(SRS_-
Eth_00123)
[SWS_EthSwt_00423] dIf the PortMirrorState is set to 0x00 (port mirroring disabled)
the corresponding hardware registers of the given Ethernet switch shall be reset (to the
HW’s default values) and the port mirroring shall be disabled.c()
[SWS_EthSwt_00011] dAfter initialization of the Ethernet switch within the EthSwt_-
BackgroundTask, the Ethernet switch shall enter an inactive or low power mode if
EthSwtLowPowerModeSupport is set to TRUE. If EthSwtLowPowerModeSupport
is not defined or set to FALSE the Ethernet switch shall enter an active state.c(SRS_-
BSW_00101)
Note: The execution of this function may take a long time (e.g. port structure, VLAN
configuration, internal Ethernet switch engine ... a.s.o.) and therefore cannot be called
by EcuM or BswM. Instead it should be called e.g. by a background task (see Eth-
Swt_BackgroundTask).
[SWS_EthSwt_00374] dAll Ethernet switch HW ports which are not configured as a
EthSwtPort shall be switched off during initialization. This Ethernet switch HW ports
shall never be switched on during runtimec()
[SWS_EthSwt_00375] dAll EthSwtPorts shall be set to ETH_MODE_DOWN during ini-
tialization.c()
[SWS_EthSwt_00016] dThe Ethernet Switch Driver shall check the access to the Eth-
ernet Switch hardware, i.e. by trying to read or write registers during the configuration
of the switch. If the access to the registers fails, the function shall raise the extended
production error ETHSWT_E_ACCESS and return E_NOT_OK.c(SRS_BSW_00386)
Note: Access to the Ethernet Switch hardware is device dependent, e.g. access
through the Ethernet Controller Mii, access through SPI, ... etc.
8.3.2 EthSwt_SetSwitchPortMode
[SWS_EthSwt_00018] d
c(SRS_ETH_00118)
[SWS_EthSwt_00019] dThe function EthSwt_SetSwitchPortMode shall put the in-
dexed port of the switch into the specified mode. If EthSwtPort references an EthTrcv
then the function EthTrcv_SetTransceiverMode of the Ethernet Transceiver Driver
shall additionally be called with the corresponding transceiver mode.c(SRS_ETH_-
00118)
[SWS_EthSwt_00396] dWhen calling the function EthSwt_SetSwitchPortMode
with mode ETH_MODE_DOWN, the EthSwt shall disable the Ethernet switch port directly
for reduction of power consumption, if it is possible.c()
[SWS_EthSwt_00397] dWhen calling the function EthSwt_SetSwitchPortMode,
the function shall check the access to the Ethernet switch driver. If the check fails,
the function shall raise the extended production error ETHSWT_E_ACCESS and return
E_NOT_OK, otherwise pass the extended production error ETHSWT_E_ACCESS and re-
turn E_OK.c()
[SWS_EthSwt_00398] dIf EthSwtPort does not references an EthTrcv, EthSwt shall
indicate a mode of the port by the API EthIf_SwitchPortModeIndication latest
during the next EthSwt_MainFunction.c(SRS_ETH_00118)
8.3.3 EthSwt_GetSwitchPortMode
[SWS_EthSwt_00025] d
Service Name EthSwt_GetSwitchPortMode
Syntax Std_ReturnType EthSwt_GetSwitchPortMode (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
Eth_ModeType* SwitchModePtr
)
c(SRS_ETH_00118)
[SWS_EthSwt_00026] dThe function EthSwt_GetSwitchPortMode shall read the
mode of the indexed port of the switch. If EthSwtPort references an EthTrcv
then the function shall additionally call the corresponding function EthTrcv_Get-
TransceiverMode of the Ethernet Transceiver Driver.c(SRS_ETH_00118)
[SWS_EthSwt_00439]{DRAFT} dThe function shall report the active mode always as
ETH_MODE_ACTIVE, even though the previous requested (via EthSwt_SetSwitch-
PortMode) mode was ETH_MODE_ACTIVE_WITH_WAKEUP_REQUEST.c()
[SWS_EthSwt_00399] dIf the obtained modes of the EthSwtPort and the EthTrcv are
not aligned, the function EthSwt_GetSwitchPortMode shall raise the extended pro-
duction error ETHSWT_E_SYNCPORT2PHY and return E_NOT_OK.
If EthTrcv_GetTransceiverMode returns E_NOT_OK, the EthSwt_GetSwitch-
PortMode shall also return E_NOT_OK without raising an error.c()
8.3.4 EthSwt_StartSwitchPortAutoNegotiation
[SWS_EthSwt_00031] d
Service Name EthSwt_StartSwitchPortAutoNegotiation
Syntax Std_ReturnType EthSwt_StartSwitchPortAutoNegotiation (
uint8 SwitchIdx,
uint8 SwitchPortIdx
)
c(SRS_ETH_00087)
[SWS_EthSwt_00032] dThe function EthSwt_StartSwitchPortAutoNegotia-
tion shall restart the automatic negotiation of the used transmission parameters of
the referenced Ethernet transceiver driver by calling the function EthTrcv_StartAu-
toNegotiation.c(SRS_ETH_00087)
[SWS_EthSwt_00035] dThe function EthSwt_StartSwitchPortAutoNegotia-
tion shall be pre compile time configurable On/Off by the configuration parameter:
EthSwtStartSwitchPortAutoNegotiationApi.c(SRS_BSW_00171)
8.3.5 EthSwt_CheckWakeup
[SWS_EthSwt_91003]{DRAFT} d
c(SRS_Eth_00118)
[SWS_EthSwt_00440]{DRAFT} dThe function EthSwt_CheckWakeup shall iterate
over the Ethernet switch ports of the indexed Ethernet switch and forward the call to
EthTrcv_CheckWakeup for those Ethernet switch ports, which reference an EthTrcv.c
(SRS_ETH_00118)
[SWS_EthSwt_00441]{DRAFT} dThe function EthSwt_CheckWakeup shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtCheck-
WakeupApic(SRS_BSW_00171)
8.3.6 EthSwt_GetSwitchPortWakeupReason
[SWS_EthSwt_91040]{DRAFT} d
Service Name EthSwt_GetSwitchPortWakeupReason (draft)
Syntax Std_ReturnType EthSwt_GetSwitchPortWakeupReason (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
EthTrcv_WakeupReasonType Reason
)
4
Sync/Async Synchronous
Reentrancy Reentrant
Parameters (in) SwitchIdx Index of the Ethernet switch within the context of the Ethernet
Switch driver
SwitchPortIdx Index of the Ethernet switch port index in the context of the
Ethernet switch driver
Parameters (inout) None
Parameters (out) Reason Pointer to structure of least recent wakeup event, which was
detected by the Ethernet switch port
Return value Std_ReturnType E_OK: Ethernet switch port wake up reason request has
been accepted.
E_NOT_OK: Ethernet switch port wake up reason request has
not been accepted.
Description This function obtains the wake up reasons of the the indexed Ethernet switch port by calling Eth
Trcv_GetBusWuReason(...) of the referenced EthTrcv
Tags:atp.Status=draft
Available via EthSwt.h
c(SRS_Eth_00107)
[SWS_EthSwt_00442]{DRAFT} dThe function EthSwt_GetSwitchPortWake-
upReason shall read the current wake-up reason of the indexed Ethernet switch port
by forwarding the call to EthTrcv_GetBusWuReason of the referenced EthTrcv. If the
indexed Ethernet switch port has no reference to an EthTrcv, the function shall return
E_NOT_OK.c(SRS_Eth_00107)
[SWS_EthSwt_00443]{DRAFT} dThe function EthSwt_GetSwitchPortWake-
upReason shall be pre compile time configurable On/Off by the configuration parame-
ter: EthSwtGetSwitchPortWakeupReasonApic(SRS_BSW_00171)
8.3.7 EthSwt_GetLinkState
[SWS_EthSwt_00037] d
Service Name EthSwt_GetLinkState
Syntax Std_ReturnType EthSwt_GetLinkState (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
EthTrcv_LinkStateType* LinkStatePtr
)
4
Parameters (inout) None
Parameters (out) LinkStatePtr ETHTRCV_LINK_STATE_DOWN: Switch port is disconnected
ETHTRCV_LINK_STATE_ACTIVE: Switch port is connected
Return value Std_ReturnType E_OK: success
E_NOT_OK: Link state of the indexed switch port could not be
obtained, or the function is called in state ETHSWT_STATE_
UNINIT or ETHSWT_STATE_INIT.
Description Obtains the link state of the indexed switch port
Available via EthSwt.h
c(SRS_ETH_00119)
[SWS_EthSwt_00038] dThe function EthSwt_GetLinkState shall read the current
(link) state of the indexed switch port. If the indexed Ethernet port references an Eth-
ernet transceiver, the link state shall be obtained by calling the function EthTrcv_-
GetLinkState of the Ethernet Transceiver Driver. If the indexed Ethernet Switch port
does not reference an Ethernet transceiver, the state shall be obtained from the MAC
interface of the Switch port. If the MAC interface is not able to provide a link state (e.g.
Ethernet hardware does not support a link state of the MAC interface), the API shall
return the following state which is derived from the current mode:
• If the current mode of the indexed switch port is ETH_MODE_ACTIVE, then
ETHTRCV_LINK_STATE_ACTIVE shall be returned
• If the current mode of the indexed switch port is ETH_MODE_DOWN, then
ETHTRCV_LINK_STATE_DOWN shall be returned
c(SRS_ETH_00118, SRS_ETH_00119)
[SWS_EthSwt_00042] dThe function EthSwt_GetLinkState shall be pre
compile time configurable On/Off by the configuration parameter: EthSwt-
GetLinkStateApi.c(SRS_BSW_00171)
8.3.8 EthSwt_GetBaudRate
[SWS_EthSwt_00044] d
Service Name EthSwt_GetBaudRate
Syntax Std_ReturnType EthSwt_GetBaudRate (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
EthTrcv_BaudRateType* BaudRatePtr
)
4
Reentrancy Non Reentrant
Parameters (in) SwitchIdx Index of the switch within the context of the Ethernet Switch Driver
SwitchPortIdx Index of the port at the addressed switch
Parameters (inout) None
Parameters (out) BaudRatePtr ETHTRCV_BAUD_RATE_10MBIT: 10MBit connection
ETHTRCV_BAUD_RATE_100MBIT: 100MBit connection
ETHTRCV_BAUD_RATE_1000MBIT: 1000MBit connection
ETHTRCV_BAUD_RATE_2500MBIT: 2500MBit connection
Return value Std_ReturnType E_OK: success
E_NOT_OK: Baud rate of the indexed switch port could not be
obtained, or the function is called in state ETHSWT_STATE_
UNINIT or ETHSWT_STATE_INIT.
Description Obtains the baud rate of the indexed switch port
Available via EthSwt.h
c(SRS_ETH_00118)
[SWS_EthSwt_00045] dThe function EthSwt_GetBaudRate shall read the current
baud rate of the indexed switch port. If the indexed Ethernet port reference an Ethernet
transceiver, the baud rate shall be obtained by the function EthTrcv_GetBaudRate of
the Ethernet Transceiver Driver. If the indexed Ethernet Switch port does not reference
an Ethernet transceiver, the baud rate shall be obtained from the MAC interface of the
Switch port.c(SRS_ETH_00118)
[SWS_EthSwt_00049] dThe function EthSwt_GetBaudRate shall be pre compile
time configurable On/Off by the configuration parameter: EthSwtGetBaudRateApi.c
(SRS_BSW_00171)
8.3.9 EthSwt_GetDuplexMode
[SWS_EthSwt_00051] d
Service Name EthSwt_GetDuplexMode
Syntax Std_ReturnType EthSwt_GetDuplexMode (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
EthTrcv_DuplexModeType* DuplexModePtr
)
4
Return value Std_ReturnType E_OK: success
E_NOT_OK: duplex mode of the indexed switch port could not be
obtained, or the function is called in state ETHSWT_STATE_
UNINIT or ETHSWT_STATE_INIT.
Description Obtains the duplex mode of the indexed switch port
Available via EthSwt.h
c(SRS_ETH_00118)
[SWS_EthSwt_00052] dThe function EthSwt_GetDuplexMode shall read the cur-
rent duplex mode of the indexed switch port. If the indexed Ethernet port reference
an Ethernet transceiver, the duplex mode shall be obtained by calling the function
EthTrcv_ GetDuplexMode of the Ethernet Transceiver Driver. If the indexed Ether-
net Switch port does not reference an Ethernet transceiver, the duplex mode shall be
obtained from the MAC interface of the Switch port.c(SRS_ETH_00118)
[SWS_EthSwt_00056] dThe function EthSwt_GetDuplexMode shall be pre compile
time configurable On/Off by the configuration parameter: EthSwtGetDuplexMod-
eApi.c(SRS_BSW_00171)
8.3.10 EthSwt_GetPortMacAddr
[SWS_EthSwt_00060] d
Service Name EthSwt_GetPortMacAddr
Syntax Std_ReturnType EthSwt_GetPortMacAddr (
uint8 SwitchIdx,
const uint8* MacAddrPtr,
uint8* PortIdxPtr
)
c(SRS_ETH_00087)
8.3.11 EthSwt_GetArlTable
[SWS_EthSwt_00111] d
Service Name EthSwt_GetArlTable
Syntax Std_ReturnType EthSwt_GetArlTable (
uint8 switchIdx,
uint16* numberOfElements,
Eth_MacVlanType* arlTableListPointer
)
c(SRS_ETH_00087)
[SWS_EthSwt_00228] dThe function EthSwt_GetArlTable shall provide a list of
structs with MAC-address, VLAN-ID and port for the indexed switch.c(SRS_ETH_-
00087)
[SWS_EthSwt_00197] dIf the numberOfElements is greater 0x00, the arlTableList-
Pointer shall be filled with up to numberOfElements elements. numberOfElements
shall return the number of copied elements.c(SRS_ETH_00087)
[SWS_EthSwt_00235] dThe EthSwt_GetArlTable API shall return only the num-
berOfElements if the numberOfElements is set to 0x00. In this case no data will be
copied and a NULLPTR can be used for the arlTableListPointer.c(SRS_ETH_00087)
8.3.12 EthSwt_GetCounterValues
[SWS_EthSwt_00231] d
Service Name EthSwt_GetCounterValues
Syntax Std_ReturnType EthSwt_GetCounterValues (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
Eth_CounterType* CounterPtr
)
c(SRS_Eth_00128)
[SWS_EthSwt_00106] d EthSwt_GetCounterValues shall read a list with drop
counter values of the corresponding port of the switch. The meaning of these values is
described at Eth_CounterType.c(SRS_ETH_00128)
[SWS_EthSwt_00109] dThe function EthSwt_GetCounterValues shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtGetCoun-
terValuesApi.c(SRS_BSW_00171)
8.3.13 EthSwt_GetRxStats
[SWS_EthSwt_00198] d
c(SRS_Eth_00128)
[SWS_EthSwt_00199] dEthSwt_GetRxStats shall return a list of statistic counters
defined with Eth_RxStatsType. The majority of these Counters are derived from the
IETF RFC2819.c(SRS_ETH_00128)
[SWS_EthSwt_00202] dThe function EthSwt_GetRxStats shall be pre compile
time configurable On/Off by the configuration parameter: EthSwtGetRxStatsApi.c
(SRS_BSW_00171)
8.3.14 EthSwt_GetTxStats
[SWS_EthSwt_91001] d
Service Name EthSwt_GetTxStats
Syntax Std_ReturnType EthSwt_GetTxStats (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
Eth_TxStatsType* TxStats
)
4
Parameters (inout) None
Parameters (out) TxStats List of values to read statistic values for transmission.
Return value Std_ReturnType E_OK: success
E_NOTOK: Tx-statistics could not be obtained
Description Returns the list of Transmission Statistics out of IETF RFC1213 defined with Eth_TxStatsType,
where the maximal possible value shall denote an invalid value, e.g. this counter is not
available.
Available via EthSwt.h
c(SRS_Eth_00128)
[SWS_EthSwt_00372] dEthSwt_GetTxStats shall return the list of Transmission
Statistics out of IETF RFC1213 defined with Eth_TxStatsType, where the maxi-
mal possible value shall denote an invalid value, e.g. this counter is not available.c
(SRS_ETH_00128)
[SWS_EthSwt_00362] dThe function EthSwt_GetTxStats shall be pre compile
time configurable On/Off by the configuration parameter: EthSwtGetTxStatsApi.c
(SRS_BSW_00171)
8.3.15 EthSwt_GetTxErrorCounterValues
[SWS_EthSwt_91000] d
Service Name EthSwt_GetTxErrorCounterValues
Syntax Std_ReturnType EthSwt_GetTxErrorCounterValues (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
Eth_TxErrorCounterValuesType* TxStats
)
c(SRS_Eth_00128)
[SWS_EthSwt_00373] dEthSwt_GetTxErrorCounterValues returns the list of
Transmission Error Counters out of IETF RFC1213 and RFC1643 defined with Eth_-
8.3.16 EthSwt_GetSwitchReg
[SWS_EthSwt_00206] d
Service Name EthSwt_GetSwitchReg
Syntax Std_ReturnType EthSwt_GetSwitchReg (
uint8 SwitchIdx,
uint32 page,
uint32 register,
uint32* registerContent
)
c(SRS_Eth_00120)
[SWS_EthSwt_00207] dThe function EthSwt_GetSwitchReg shall read the content
of a switch register.c(SRS_Eth_00120)
[SWS_EthSwt_00210] dThe function EthSwt_GetSwitchReg shall be pre compile
time configurable On/Off by the configuration parameter: EthSwtGetSwitchRe-
gApi.c(SRS_BSW_00171)
8.3.17 EthSwt_SetSwitchReg
[SWS_EthSwt_00211] d
c(SRS_Eth_00120)
[SWS_EthSwt_00212] dThe function EthSwt_SetSwitchReg shall write the content
of a switch register.c(SRS_Eth_00120)
[SWS_EthSwt_00215] dThe function EthSwt_SetSwitchReg shall be pre compile
time configurable On/Off by the configuration parameter: EthSwtSetSwitchRe-
gApi.c(SRS_BSW_00171)
8.3.18 EthSwt_ReadTrcvRegister
[SWS_EthSwt_00216] d
Service Name EthSwt_ReadTrcvRegister
Syntax Std_ReturnType EthSwt_ReadTrcvRegister (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
uint8 RegIdx,
uint16* RegValPtr
)
4
SwitchPortIdx Index of the port at the addressed switch
RegIdx Index of the register
Parameters (inout) None
Parameters (out) RegValPtr Pointer to the register content
Return value Std_ReturnType E_OK: success
E_NOT_OK: Content of the transceiver could not be obtained, or
the function is called in state ETHSWT_STATE_UNINIT or
ETHSWT_STATE_INIT.
Description Generic API for reading the content of a transceiver register
Available via EthSwt.h
c(SRS_Eth_00120)
[SWS_EthSwt_00217] dThe function EthSwt_ReadTrcvRegister shall read the
specified transceiver register through the MII or SPI of the indexed switch port.c(SRS_-
ETH_00118, SRS_ETH_00120)
[SWS_EthSwt_00220] dThe function EthSwt_ReadTrcvRegister shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtReadTr-
cvRegisterApi.c(SRS_BSW_00171)
8.3.19 EthSwt_WriteTrcvRegister
[SWS_EthSwt_00221] d
Service Name EthSwt_WriteTrcvRegister
Syntax Std_ReturnType EthSwt_WriteTrcvRegister (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
uint8 RegIdx,
uint16 RegVal
)
4
Description Generic API for writing the content of a transceiver register
Available via EthSwt.h
c(SRS_Eth_00120)
[SWS_EthSwt_00222] dThe function EthSwt_WriteTrcvRegister shall write the
specified transceiver register through the MII or SPI of the indexed switch port.c(SRS_-
ETH_00118, SRS_ETH_00120)
[SWS_EthSwt_00225] dThe function EthSwt_WriteTrcvRegister shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtWriteTr-
cvRegisterApi.c(SRS_BSW_00171)
8.3.20 EthSwt_EnableVlan
[SWS_EthSwt_00172] d
Service Name EthSwt_EnableVlan
Syntax Std_ReturnType EthSwt_EnableVlan (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
uint16 VlanId,
boolean Enable
)
c(SRS_ETH_00121, SRS_ETH_00114)
[SWS_EthSwt_00173] dThe function EthSwt_EnableVlan shall enable or disable
a pre-configured VLAN at a certain port of a switch.c(SRS_ETH_00121, SRS_ETH_-
00114)
8.3.21 EthSwt_StoreConfiguration
[SWS_EthSwt_00086] d
Service Name EthSwt_StoreConfiguration
Syntax Std_ReturnType EthSwt_StoreConfiguration (
uint8 SwitchIdx
)
c(SRS_ETH_00087, SRS_ETH_00122)
[SWS_EthSwt_00087] dThe function EthSwt_StoreConfiguration shall request
to store the configuration of the learned MAC/Port tables of a switch in a persistent
manner. This can be done in two ways: 1.) Reading out the parameters and storing
them in the NV-RAM of the host CPU using the NV-RAM manager. 2.) Advising the
switch to store the configuration data in its local NV-RAM.
In both alternatives <EthSwtPersistentConfigurationResultCallback> shall be invoked
if EthSwtPersistentConfigurationResultCallback is configured. In case of
storage to switch local NV-RAM, JobResult shall be set to NVM_REQ_OK to indicate
success or to NVM_REQ_NOT_OK to indicate failure.c(SRS_ETH_00087, SRS_ETH_-
00122)
[SWS_EthSwt_00090] dThe function EthSwt_StoreConfiguration shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtStoreCon-
figurationApi.c(SRS_BSW_00171)
8.3.22 EthSwt_ResetConfiguration
[SWS_EthSwt_00091] d
c(SRS_ETH_00087, SRS_ETH_00122)
[SWS_EthSwt_00092] dThe function EthSwt_ResetConfiguration shall request
to reset the configuration of the learned MAC/Port tables of a switch in a persistent
manner. This can be done in two ways: 1.) Overwriting the learned parameters in the
NV-RAM of the host CPU with preconfigured default values. 2.) Advising the switch to
reset the learned configuration data in its local NV-RAM.
In both alternatives <EthSwtPersistentConfigurationResultCallback> shall be invoked
if EthSwtPersistentConfigurationResultCallback is configured. In case of
storage to switch local NV-RAM, JobResult shall be set to NVM_REQ_OK to indicate
success or to NVM_REQ_NOT_OK to indicate failure.c(SRS_ETH_00122, SRS_ETH_-
00087)
[SWS_EthSwt_00095] dThe function EthSwt_ResetConfiguration shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtResetCon-
figurationApi.c(SRS_BSW_00171)
8.3.23 EthSwt_SetMacLearningMode
[SWS_EthSwt_00182] d
Service Name EthSwt_SetMacLearningMode
5
4
Syntax Std_ReturnType EthSwt_SetMacLearningMode (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
EthSwt_MacLearningType MacLearningMode
)
c(SRS_ETH_00087, SRS_ETH_00122)
[SWS_EthSwt_00183] dThe function EthSwt_SetMacLearningMode shall set the
MAC learning mode according to EthSwt_MacLearningType.c(SRS_ETH_00122,
SRS_ETH_00087)
Note: This feature is hardware dependent, i.e. the switch hardware needs to support
the different modes.
[SWS_EthSwt_00186] dThe function EthSwt_SetMacLearningMode shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtSet-
MacLearningModeApi.c(SRS_BSW_00171)
8.3.24 EthSwt_GetMacLearningMode
[SWS_EthSwt_00187] d
Service Name EthSwt_GetMacLearningMode
Syntax Std_ReturnType EthSwt_GetMacLearningMode (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
EthSwt_MacLearningType* MacLearningMode
)
4
Sync/Async Synchronous /Asynchronous
Reentrancy Non Reentrant
Parameters (in) SwitchIdx Index of the switch within the context of the Ethernet Switch Driver
SwitchPortIdx Index of the port at the addressed switch
Parameters (inout) None
Parameters (out) MacLearningMode Defines whether MAC addresses shall be learned and if they
shall be learned in software or hardware.
Return value Std_ReturnType E_OK: success
E_NOT_OK: configuration could be persistently reset
Description Returns the MAC learning mode, i.e. 1.) HW learning enabled, 2.) Hardware learning disabled,
3.) Software learning enabled. Note: This feature is hardware dependent, i.e. the switch
hardware needs to support the different learning modes
Available via EthSwt.h
c(SRS_ETH_00087)
[SWS_EthSwt_00188] dThe function EthSwt_GetMacLearningMode shall return
the MAC learning mode according to EthSwt_MacLearningType.c(SRS_ETH_-
00087)
Note: This feature is hardware dependent, i.e. the switch hardware needs to support
the different learning modes.
[SWS_EthSwt_00191] dThe function EthSwt_GetMacLearningMode shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtGet-
MacLearningModeApi.c(SRS_BSW_00171)
8.3.25 EthSwt_NvmSingleBlockCallback
[SWS_EthSwt_00125] d
Service Name EthSwt_NvmSingleBlockCallback
Syntax Std_ReturnType EthSwt_NvmSingleBlockCallback (
NvM_BlockRequestType BlockRequest,
NvM_RequestResultType JobResult
)
4
Return value Std_ReturnType E_OK: success
E_NOT_OK: Callback function has not been processed
successfully
Description Function will be called by the NVRAMManager after the switch configuration has been stored or
resetted.
Available via EthSwt_NvM.h
c(SRS_ETH_00087, SRS_ETH_00122)
[SWS_EthSwt_00126] dThe function EthSwt_NvmSingleBlockCallback shall be
called by the NVRAMManager [13] after the switch configuration has been stored or
reset in the the NV RAM.c(SRS_ETH_00122, SRS_ETH_00087)
[SWS_EthSwt_00196] dThe function EthSwt_NvmSingleBlockCallback shall call
the function <user>_PersistentConfigurationResult to provide the JobResult to
the caller of EthSwt_StoreConfiguration or EthSwt_ResetConfiguration.c
(SRS_ETH_00122, SRS_ETH_00087)
[SWS_EthSwt_00127] dThe function EthSwt_NvmSingleBlockCallback shall al-
ways return E_OK according to SWS_NvM_00368.c(SRS_ETH_00122, SRS_ETH_-
00087)
[SWS_EthSwt_00128] dThe function EthSwt_NvmSingleBlockCallback shall
raise a development error if the JobResult equals NVM_REQ_NOT_OK, i.e. the write
request has been finished unsuccessfully.c(SRS_BSW_00369, SRS_ETH_00458)
Note: Please note that a production error at this point is not necessary because the
NvM will raise also a production error if the write to NV RAM was not successful.
[SWS_EthSwt_00129] dThe function EthSwt_NvmSingleBlockCallback shall be
pre compile time configurable On/Off by the existence of the container EthSwtNvm.c
(SRS_BSW_00171)
8.3.26 EthSwt_GetVersionInfo
[SWS_EthSwt_00058] d
Service Name EthSwt_GetVersionInfo
Syntax void EthSwt_GetVersionInfo (
Std_VersionInfoType* VersionInfoPtr
)
4
Parameters (in) None
Parameters (inout) None
Parameters (out) VersionInfoPtr Pointer to where to store the version information of this module.
Return value None
Description Returns the version information of this module.
Available via EthSwt.h
c(SRS_BSW_00171)
[SWS_EthSwt_00124] dThe function EthSwt_GetVersionInfo shall be pre com-
pile time configurable On/Off by the configuration parameter: EthSwtVersionIn-
foApi.c(SRS_BSW_00171)
8.3.27 EthSwt_EthRxProcessFrame
[SWS_EthSwt_91004] d
Service Name EthSwt_EthRxProcessFrame
Syntax Std_ReturnType EthSwt_EthRxProcessFrame (
uint8 CtrlIdx,
Eth_BufIdxType BufIdx,
uint8** DataPtr,
uint16* LengthPtr,
boolean* IsMgmtFrameOnlyPtr
)
4
Available via EthSwt_Eth.h
c(SRS_Eth_00125)
[SWS_EthSwt_00249] dThe function EthSwt_EthRxProcessFrame shall be pre
compile time configurable ON/OFF by the configuration parameter: EthSwtManage-
mentSupportApi .c(SRS_BSW_00171)
8.3.28 EthSwt_EthRxFinishedIndication
[SWS_EthSwt_91005] d
Service Name EthSwt_EthRxFinishedIndication
Syntax Std_ReturnType EthSwt_EthRxFinishedIndication (
uint8 CtrlIdx,
Eth_BufIdxType BufIdx
)
c(SRS_Eth_00125)
[SWS_EthSwt_00253] dThe function EthSwt_EthRxFinishedIndication shall
be pre compile time configurable ON/OFF by the configuration parameter: EthSwt-
ManagementSupportApi .c(SRS_BSW_00171)
8.3.29 EthSwt_EthTxPrepareFrame
[SWS_EthSwt_91006] d
c(SRS_Eth_00125)
[SWS_EthSwt_00257] dThe function EthSwt_EthTxPrepareFrame shall be pre
compile time configurable ON/OFF by the configuration parameter: EthSwtManage-
mentSupportApi .c(SRS_BSW_00171)
8.3.30 EthSwt_EthTxAdaptBufferLength
[SWS_EthSwt_91007] d
Service Name EthSwt_EthTxAdaptBufferLength
Syntax void EthSwt_EthTxAdaptBufferLength (
uint16* LengthPtr
)
4
Parameters (inout) LengthPtr IN: Pointer to the length of the buffer without management
information.
OUT: Pointer to the modified length needed for buffer and
management information.
Parameters (out) None
Return value None
Description Modifies the buffer length to be able to insert management information.
Available via EthSwt_Eth.h
c(SRS_Eth_00125)
[SWS_EthSwt_00261] dThe function EthSwt_EthTxAdaptBufferLength shall be
pre compile time configurable ON/OFF by the configuration parameter: EthSwtMan-
agementSupportApi .c(SRS_BSW_00171)
8.3.31 EthSwt_SetMgmtInfo
[SWS_EthSwt_91008] d
Service Name EthSwt_SetMgmtInfo
Syntax Std_ReturnType EthSwt_SetMgmtInfo (
uint8 CtrlIdx,
Eth_BufIdxType BufIdx,
const EthSwt_MgmtInfoType* MgmtInfoPtr
)
c(SRS_Eth_00125)
[SWS_EthSwt_00264] dThe function EthSwt_SetMgmtInfo shall be pre compile
time configurable ON/OFF by the configuration parameter: EthSwtManagementSup-
portApi .c(SRS_BSW_00171)
8.3.32 EthSwt_EthTxProcessFrame
[SWS_EthSwt_91009] d
Service Name EthSwt_EthTxProcessFrame
Syntax Std_ReturnType EthSwt_EthTxProcessFrame (
uint8 CtrlIdx,
Eth_BufIdxType BufIdx,
uint8** DataPtr,
uint16* LengthPtr
)
c(SRS_Eth_00125)
[SWS_EthSwt_00268] dThe function EthSwt_EthTxProcessFrame shall be pre
compile time configurable ON/OFF by the configuration parameter: EthSwtManage-
mentSupportApi .c(SRS_BSW_00171)
8.3.33 EthSwt_EthTxFinishedIndication
[SWS_EthSwt_91010] d
Service Name EthSwt_EthTxFinishedIndication
Syntax Std_ReturnType EthSwt_EthTxFinishedIndication (
uint8 CtrlIdx,
Eth_BufIdxType BufIdx
)
4
Reentrancy Non Reentrant
Parameters (in) CtrlIdx Ethernet Controller index
BufIdx Ethernet Rx Buffer index
Parameters (inout) None
Parameters (out) None
Return value Std_ReturnType E_OK: Frame successfully processed
E_NOT_OK: Frame processing failed
Description Indication for a finished transmit process for a specific Ethernet frame.
Available via EthSwt_Eth.h
c(SRS_Eth_00125)
[SWS_EthSwt_00273] dThe function EthSwt_EthTxFinishedIndication shall
be pre compile time configurable ON/OFF by the configuration parameter: EthSwt-
ManagementSupportApi .c(SRS_BSW_00171)
8.3.34 EthSwt_PortEnableTimeStamp
[SWS_EthSwt_91028] d
Service Name EthSwt_PortEnableTimeStamp
Syntax Std_ReturnType EthSwt_PortEnableTimeStamp (
uint8 CtrlIdx,
Eth_BufIdxType BufIdx,
EthSwt_MgmtInfoType* MgmtInfoPtr
)
c(SRS_Eth_00125)
[SWS_EthSwt_00379] dThe function EthSwt_PortEnableTimeStamp shall be pre
compile time configurable ON/OFF by the configuration parameter: EthSwtGlobal-
TimeSupportApi .c(SRS_BSW_00171)
8.3.35 EthSwt_VerifyConfig
[SWS_EthSwt_91012] d
Service Name EthSwt_VerifyConfig
Syntax Std_ReturnType EthSwt_VerifyConfig (
uint8 SwitchIdx,
boolean* Result
)
c(SRS_ETH_00126)
[SWS_EthSwt_00287] dThe function EthSwt_VerifyConfig shall be compile time
configurable On/Off by the configuration parameter: EthSwtVerifyConfigApi.c
(SRS_BSW_00171)
8.3.36 EthSwt_SetForwardingMode
[SWS_EthSwt_91013] d
Service Name EthSwt_SetForwardingMode
Syntax Std_ReturnType EthSwt_SetForwardingMode (
uint8 SwitchIdx,
boolean mode
)
4
Description Configures switch to start or stop forwarding for all ports. This API call may be used during
switch configuration verification.
Available via EthSwt.h
c(SRS_ETH_00126)
[SWS_EthSwt_00291] dThe function EthSwt_SetForwardingMode shall be com-
pile time configurable On/Off by the configuration parameter: EthSwtSetForward-
ingModeApi.c(SRS_BSW_00171)
8.3.37 EthSwt_GetPortSignalQuality
[SWS_EthSwt_91014] d
Service Name EthSwt_GetPortSignalQuality
Syntax Std_ReturnType EthSwt_GetPortSignalQuality (
uint8 SwitchIdx,
uint8 PortIdx,
uint32* SignalQualityPtr
)
c(SRS_Eth_00123)
[SWS_EthSwt_00293] dThe function EthSwt_GetPortSignalQuality shall obtain
the signal quality by calling the function EthTrcv_GetPhySignalQuality of the
referenced Ethernet Transceiver Driver. If the current signal quality is not available, the
signal quality shall be set to 0xFFFFFFFF.c(SRS_Eth_00123)
[SWS_EthSwt_00297] dThe function EthSwt_GetPortSignalQuality shall be
pre compile time configurable On/Off by the configuration parameter: EthSwtGet-
PortSignalQualityApi.c(SRS_BSW_00171)
8.3.38 EthSwt_GetPortIdentifier
[SWS_EthSwt_91015] d
Service Name EthSwt_GetPortIdentifier
Syntax Std_ReturnType EthSwt_GetPortIdentifier (
uint8 SwitchIdx,
uint8 PortIdx,
uint32* OrgUniqueIdPtr,
uint8* ModelNrPtr,
uint8* RevisionNrPtr
)
c(SRS_Eth_00123)
[SWS_EthSwt_00299] dThe function EthSwt_GetPortIdentifier shall return the
value of the organizationally unique identifier (OUI 24 bit) of the indexed Ethernet switch
port that is connected to the indexed Ethernet switch. It shall set the 8 most significant
bits of the OUI to 0xFFxxxxxx. If the Ethernet switch port references an Ethernet
transceiver, the function shall obtain the OUI by calling the function EthTrcv_Get-
PhyIdentifier and set the 8 most significant bits of the OUI to 0x00xxxxxx.c(SRS_-
Eth_00123)
[SWS_EthSwt_00394] dIf neither the Ethernet switch port nor the Ethernet Transceiver
Driver can provide an OUI the function EthSwt_GetPortIdentifier shall return
E_NOT_OK.c()
[SWS_EthSwt_00303] dThe function EthSwt_GetPortIdentifier shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtGetPor-
tIdentifierApi.c(SRS_BSW_00171)
8.3.39 EthSwt_GetSwitchIdentifier
[SWS_EthSwt_91016] d
Service Name EthSwt_GetSwitchIdentifier
Syntax Std_ReturnType EthSwt_GetSwitchIdentifier (
uint8 SwitchIdx,
uint32* OrgUniqueIdPtr
)
c(SRS_Eth_00123)
[SWS_EthSwt_00305] dThe function EthSwt_GetSwitchIdentifier shall return
the value of the organizationally unique identifier of the indexed Ethernet switch.c
(SRS_Eth_00123)
[SWS_EthSwt_00308] dThe function EthSwt_GetSwitchIdentifier shall be
pre compile time configurable On/Off by the configuration parameter: EthSwt-
GetSwitchIdentifierApi.c(SRS_BSW_00171)
8.3.40 EthSwt_WritePortMirrorConfiguration
[SWS_EthSwt_91018] d
Service Name EthSwt_WritePortMirrorConfiguration
Syntax Std_ReturnType EthSwt_WritePortMirrorConfiguration (
uint8 MirroredSwitchIdx,
const EthSwt_PortMirrorCfgType* PortMirrorConfigurationPtr
)
5
4
Service ID [hex] 0x36
Sync/Async Synchronous
Reentrancy Non Reentrant
Parameters (in) MirroredSwitchIdx Index of the switch within the context of the Ethernet Switch
Driver, where the Ethernet switch port is located, that has to be
mirrored
PortMirrorConfiguration Pointer of the port configuration, which shall be stored in a
Ptr shadow buffer in the Ethernet switch driver
Parameters (inout) None
Parameters (out) None
Return value Std_ReturnType E_OK: the port mirror configuration for the indexed Ethernet
switch port was written.
E_NOT_OK: the port mirror configuration for the indexed
Ethernet switch port was not written. (i.e. indexed ethernet switch
is not available)
ETHSWT_PORT_MIRRORING_CONFIGURATION_NOT_
SUPPORTED: port mirroring configuration is not supported by
Ethernet switch driver or by the Ethernet switch hardware
Description Store the given port mirror configuration in a shadow buffer in the Ethernet switch driver for the
given MirroredSwitchIdx.
Available via EthSwt.h
c(SRS_Eth_00123)
[SWS_EthSwt_00309] dThe function EthSwt_WritePortMirrorConfiguration
shall store the port mirror configuration of the given MirroredSwitchIdx in a shadow
buffer. The MirroredSwitchIdx shall be used to identify the port mirror configura-
tion within the Ethernet switch driver.c(SRS_Eth_00123)
[SWS_EthSwt_00312] dThe function EthSwt_WritePortMirrorConfiguration
shall be pre compile time configurable On/Off by the configuration parameter: Eth-
SwtWritePortMirrorConfigurationApi.c(SRS_BSW_00171)
[SWS_EthSwt_00424] dThe function shall return with ETH-
SWT_PORT_MIRRORING_CONFIGURATION_NOT_SUPPORTED, if the port mirroring
configuration is not supported by the Ethernet switch driver or by the Ethernet switch
hardware, e.g.:
• the configured mirrored traffic direction (see [SWS_EthSwt_91017] "TrafficDirec-
tionIngressBitMask" and "TrafficDirectionEgressBitMask") for ingress and egress
traffic of the same port is not supported
• mirrored ports and capture ports, respectively, are not available within the Ether-
net switch driver
c(SRS_Eth_00123)
8.3.41 EthSwt_ReadPortMirrorConfiguration
[SWS_EthSwt_91019] d
c(SRS_Eth_00123)
[SWS_EthSwt_00313] dThe function EthSwt_ReadPortMirrorConfiguration
shall return the port mirror configuration identified by the given MirroredSwitchIdx. If
no port mirror configuration is found for the MirroredSwitchIdx, the function shall return
E_NOT_OK.c(SRS_Eth_00123)
[SWS_EthSwt_00317] dThe function EthSwt_ReadPortMirrorConfiguration
shall be pre compile time configurable On/Off by the configuration parameter: Eth-
SwtReadPortMirrorConfigurationApi.c(SRS_BSW_00171)
8.3.42 EthSwt_DeletePortMirrorConfiguration
[SWS_EthSwt_91034] d
Service Name EthSwt_DeletePortMirrorConfiguration
Syntax Std_ReturnType EthSwt_DeletePortMirrorConfiguration (
uint8 MirroredSwitchIdx
)
4
Parameters (inout) None
Parameters (out) None
Return value Std_ReturnType E_OK: Port mirror configuration was deleted successfully
E_NOT_OK: Port mirror configuration was not deleted
successfully. (e.g. the port mirroring is enabled)
Description Delete the stored port mirror configuration of the given MirroredSwitchIdx. If no port mirror
configuration was found for the given MirroredSwitchIdx, the return value shall be E_OK.
Available via EthSwt.h
c()
[SWS_EthSwt_00425] dThe function EthSwt_DeletePortMirrorConfigura-
tion shall mark the stored port mirror configuration in the shadow buffer of the given
MirroredSwitchIdx as "to be deleted".c(SRS_Eth_00123)
[SWS_EthSwt_00426] dIf a port mirroring for the given MirroredSwitchIdx is enabled,
the request to delete the configuration shall be rejected by returning E_NOT_OK. Only
those port configurations are allowed to be deleted, where the port mirroring of the
given MirroredSwitchIdx is disabled.c(SRS_Eth_00123)
[SWS_EthSwt_00427] dThe function EthSwt_DeletePortMirrorConfigura-
tion shall be pre compile time configurable On/Off by the configuration parameter:
EthSwtDeletePortMirrorConfigurationApi.c(SRS_BSW_00171)
8.3.43 EthSwt_GetPortMirrorState
[SWS_EthSwt_91021] d
Service Name EthSwt_GetPortMirrorState
Syntax Std_ReturnType EthSwt_GetPortMirrorState (
uint8 SwitchIdx,
uint8 PortIdx,
EthSwt_PortMirrorStateType* PortMirrorStatePtr
)
4
Return value Std_ReturnType E_OK: the port mirroring state for the indexed Ethernet switch
port returned successfully.
E_NOT_OK: the port mirror configuration for the indexed
Ethernet switch returned not successfully. (i.e. indexed ethernet
switch port is not available)
Description Obtain the current status of the port mirroring for the indexed Ethernet switch port
Available via EthSwt.h
c(SRS_Eth_00123)
[SWS_EthSwt_00318] dThe function EthSwt_GetPortMirrorState shall return
the port mirroring state of the indexed ethernet switch port.c(SRS_Eth_00123)
[SWS_EthSwt_00322] dThe function EthSwt_GetPortMirrorState shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtGetPort-
MirrorStateApi.c(SRS_BSW_00171)
8.3.44 EthSwt_SetPortMirrorState
[SWS_EthSwt_91022] d
Service Name EthSwt_SetPortMirrorState
Syntax Std_ReturnType EthSwt_SetPortMirrorState (
uint8 MirroredSwitchIdx,
EthSwt_PortMirrorStateType PortMirrorState
)
c(SRS_Eth_00123)
[SWS_EthSwt_00323] dThe function EthSwt_SetPortMirrorState shall request
the given port mirroring state for the port mirroring configuration of the indexed Ethernet
switch, and store the requested port mirror state in a shadow buffer.c(SRS_Eth_00123)
8.3.45 EthSwt_SetPortTestMode
[SWS_EthSwt_91029] d
Service Name EthSwt_SetPortTestMode
Syntax Std_ReturnType EthSwt_SetPortTestMode (
uint8 SwitchIdx,
uint8 PortIdx,
EthTrcv_PhyTestModeType Mode
)
c(SRS_Eth_00123)
[SWS_EthSwt_00328] dThe function EthSwt_SetPortTestMode shall forward the
call with the given test mode by calling the function EthTrcv_SetPhyTestMode of
the referenced Ethernet Transceiver Driver.c(SRS_Eth_00123)
[SWS_EthSwt_00332] dThe function EthSwt_SetPortTestMode shall be pre com-
pile time configurable On/Off by the configuration parameter: EthSwtSetPortTest-
ModeApi.c(SRS_BSW_00171)
8.3.46 EthSwt_SetPortLoopbackMode
[SWS_EthSwt_91023] d
c(SRS_Eth_00123)
[SWS_EthSwt_00334] dThe function EthSwt_SetPortLoopbackMode shall forward
the call with the given loop-back mode by calling the function EthTrcv_SetPhyLoop-
backMode of the referenced Ethernet Transceiver Driver.c(SRS_Eth_00123)
[SWS_EthSwt_00338] dThe function EthSwt_SetPortLoopbackMode shall be pre
compile time configurable On/Off by the configuration parameter: EthSwtSetPort-
LoopbackModeApi.c(SRS_BSW_00171)
8.3.47 EthSwt_SetPortTxMode
[SWS_EthSwt_91024] d
Service Name EthSwt_SetPortTxMode
Syntax Std_ReturnType EthSwt_SetPortTxMode (
uint8 SwitchIdx,
uint8 PortIdx,
EthTrcv_PhyTxModeType Mode
)
4
Parameters (in) SwitchIdx Index of the switch within the context of the Ethernet Switch Driver
PortIdx Index of the port at the addressed switch
Mode Transmission mode to be activated
Parameters (inout) None
Parameters (out) None
Return value Std_ReturnType E_OK: the port Tx mode for the indexed Ethernet switch port was
activated successfully.
E_NOT_OK: the port Tx mode for the indexed Ethernet switch
port was not activated successfully. (i.e. indexed Ethernet switch
port is not available)
Description Activates a given transmission mode of the indexed Ethernet switch port.
Available via EthSwt.h
c(SRS_Eth_00123)
[SWS_EthSwt_00340] dThe function EthSwt_SetPortTxMode shall forward the call
with the given transmission mode by calling the function EthTrcv_SetPhyTxMode of
the referenced Ethernet Transceiver Driver.c(SRS_Eth_00123)
[SWS_EthSwt_00344] dThe function EthSwt_SetPortTxMode shall be pre compile
time configurable On/Off by the configuration parameter: EthSwtSetPortTxMod-
eApi.c(SRS_BSW_00171)
8.3.48 EthSwt_RunPortCableDiagnostic
[SWS_EthSwt_91011] d
Service Name EthSwt_RunPortCableDiagnostic
Syntax Std_ReturnType EthSwt_RunPortCableDiagnostic (
uint8 SwitchIdxIdx,
uint8 PortIdx
)
4
Available via EthSwt.h
c()
[SWS_EthSwt_00429] dThe function EthSwt_RunPortCableDiagnostic shall for-
ward the call by calling EthTrcv_RunCableDiagnostic of the referenced Ethernet
Transceiver Driver.c()
8.3.49 EthSwt_GetPortCableDiagnosticsResult
[SWS_EthSwt_91025] d
Service Name EthSwt_GetPortCableDiagnosticsResult
Syntax Std_ReturnType EthSwt_GetPortCableDiagnosticsResult (
uint8 SwitchIdx,
uint8 PortIdx,
EthTrcv_CableDiagResultType* ResultPtr
)
c(SRS_Eth_00123)
[SWS_EthSwt_00346] dThe function EthSwt_GetPortCableDiagnosticsRe-
sult shall obtain the cable diagnostics result by calling the function EthTrcv_Get-
CableDiagnosticsResult of the referenced Ethernet Transceiver Driver.c(SRS_-
Eth_00123)
[SWS_EthSwt_00350] dThe function EthSwt_GetPortCableDiagnosticsRe-
sult shall be pre compile time configurable On/Off by the configuration parameter:
EthSwtGetPortCableDiagnosticsResultApi.c(SRS_BSW_00171)
8.3.50 EthSwt_GetCfgDataRaw
[SWS_EthSwt_91030] d
Service Name EthSwt_GetCfgDataRaw
Syntax Std_ReturnType EthSwt_GetCfgDataRaw (
uint8 SwitchIdx,
uint32 Offset,
uint16 Length,
uint8* BufferPtr
)
c(SRS_Eth_00123)
[SWS_EthSwt_00403] dThe function EthSwt_GetCfgDataRaw shall only be avail-
able if parameter EthSwtGetCfgRaw is set to TRUE.c(SRS_BSW_00171)
[SWS_EthSwt_00404] dWhen calling the function EthSwt_GetCfgDataRaw, the
function shall check the access to the Ethernet switch driver. If the check fails,
the function shall raise the extended production error ETHSWT_E_ACCESS and return
E_NOT_OK, otherwise pass the extended production error ETHSWT_E_ACCESS and re-
turn E_OK.c()
8.3.51 EthSwt_GetCfgDataInfo
[SWS_EthSwt_91031] d
Service Name EthSwt_GetCfgDataInfo
5
4
Syntax Std_ReturnType EthSwt_GetCfgDataInfo (
uint8 SwitchIdx,
uint32* DataSizePtr,
uint32* DataAdressPtr
)
c(SRS_Eth_00123)
[SWS_EthSwt_00405] dThe function EthSwt_GetCfgDataInfo shall only be avail-
able if parameter EthSwtGetCfgRaw is set to TRUE.c(SRS_BSW_00171)
[SWS_EthSwt_00406] dWhen calling the function EthSwt_GetCfgDataInfo, the
function shall check the access to the Ethernet switch driver. If the check fails,
the function shall raise the extended production error ETHSWT_E_ACCESS and return
E_NOT_OK, otherwise pass the extended production error ETHSWT_E_ACCESS and re-
turn E_OK.c()
8.3.52 EthSwt_PortLinkStateRequest
[SWS_EthSwt_91123] d
Service Name EthSwt_PortLinkStateRequest
Syntax Std_ReturnType EthSwt_PortLinkStateRequest (
uint8 SwitchIdx,
uint8 PortIdx,
EthTrcv_LinkStateType PortLinkState
)
4
Parameters (in) SwitchIdx Index of the switch within the context of the Ethernet Switch
Driver.
PortIdx Index of the port at the addressed switch.
PortLinkState The Ethernet link state of a physical Ethernet connection.
Parameters (inout) None
Parameters (out) None
Return value Std_ReturnType E_OK: Request has been accepted and if the function call is in
state ETHSWT_STATE_PORTINIT_COMPLETED or ETHSWT_
STATE_ACTIVE
E_NOT_OK: Request has not been accepted. (e.g. the indexed
Ethernet switch port does not reference an EthTrcv)
Description Request a link state by calling EthTrcv_TransceiverLinkStateRequest with the TrcvIdx of the
Ethernet transceiver which is referenced by the Ethernet Switch port (PortIdx).
Available via EthSwt.h
c()
[SWS_EthSwt_00415] dThe function EthSwt_PortLinkStateRequest shall re-
quest the given link state for the indexed Ethernet switch port of the switch by call-
ing the EthTrcv_TransceiverLinkStateRequest with the given EthTrcv_-
LinkStateType. If the EthSwtPort does not reference an EthTrcv, then the function
shall return E_NOT_OK.c()
8.3.53 EthSwt_GetMaxFIFOBufferFillLevel
[SWS_EthSwt_91050] d
Service Name EthSwt_GetMaxFIFOBufferFillLevel
Syntax Std_ReturnType EthSwt_GetMaxFIFOBufferFillLevel (
uint8 SwitchIdx,
uint8 SwitchPortIdx,
uint8 SwitchPortEgressFifoIdx,
uint32* SwitchPortEgressFifoBufferLevelPtr
)
4
Return value Std_ReturnType E_OK: success
E_NOT_OK: The maximal FIFO buffer level could not be obtained
Description The function retrieves the maximum amount of allocated FIFO buffer of the indexed Ethernet
switch egress port. If the Ethernet switch hardware does not support Ethernet switch port
based maximal FIFO buffer level, the content of SwitchPortEgressFifoBufferLevelPtr shall be
set to 0xFFFFFFFF. This API may be called by e.g. a CDD.
Available via EthSwt.h
c()
[SWS_EthSwt_00430] dThe function EthSwt_GetMaxFIFOBufferFillLevel
shall read out the maximum amount of allocated FIFO buffer since the last read out.c
(SRS_ETH_00119)
[SWS_EthSwt_00431] dWhen the maximum amount of allocated FIFO buffer is read
out, the value shall be reset to 0x00000000 explicitly, if it is not done by the hardware.c
(SRS_ETH_00119)
[SWS_EthSwt_00432] dThe function EthSwt_GetMaxFIFOBufferFillLevel
shall be pre compile time configurable On/Off by the configuration parameter: Eth-
SwtGetMaxFIFOBufferFillLevelApi.c(SRS_BSW_00171)
8.3.54 EthSwt_GetRxMgmtObject
[SWS_EthSwt_91038] d
Service Name EthSwt_GetRxMgmtObject
Syntax Std_ReturnType EthSwt_GetRxMgmtObject (
uint8 CtrlIdx,
Eth_DataType* DataPtr,
EthSwt_MgmtObjectType** MgmtObjectPtr
)
c()
8.3.55 EthSwt_GetTxMgmtObject
[SWS_EthSwt_91039] d
Service Name EthSwt_GetTxMgmtObject
Syntax Std_ReturnType EthSwt_GetTxMgmtObject (
uint8 CtrlIdx,
Eth_BufIdxType BufIdx,
EthSwt_MgmtObjectType** MgmtObjectPtr
)
c()
8.4.1 EthSwtPersistentConfigurationResultCallback
[SWS_EthSwt_00193] d
Service Name <EthSwtPersistentConfigurationResultCallback>
Syntax void <EthSwtPersistentConfigurationResultCallback> (
NvM_RequestResultType JobResult
)
c(SRS_ETH_00122, SRS_ETH_00087)
8.5.1 EthSwt_MainFunction
[SWS_EthSwt_00114] d
Service Name EthSwt_MainFunction
Syntax void EthSwt_MainFunction (
void
)
c(SRS_BSW_00433)
[SWS_EthSwt_00115] dThe EthSwt_MainFunction support asynchronous behav-
ior of API calls. This function is directly called by Basic Software Scheduler.c(SRS_-
BSW_00433)
8.5.2 EthSwt_BackgroundTask
[SWS_EthSwt_91104] d
Service Name EthSwt_BackgroundTask
Syntax void EthSwt_BackgroundTask (
void
)
4
Available via EthSwt.h
c()
This chapter defines all external interfaces which are required to fulfill the core func-
tionality of the module.
No mandatory Interfaces defined.
This chapter defines all external interfaces which are required to fulfill an optional func-
tionality of the module.
[SWS_EthSwt_00098] d
API Function Header File Description
Dem_SetEventStatus Dem.h Called by SW-Cs or BSW modules to report monitor
status information to the Dem. BSW modules calling
Dem_SetEventStatus can safely ignore the return
value. This API will be available only if ({Dem/Dem
ConfigSet/DemEventParameter/DemEvent
ReportingType} == STANDARD_REPORTING)
Det_ReportError Det.h Service to report development errors.
Eth_ReadMii Eth.h Reads a transceiver register
Eth_WriteMii Eth.h Configures a transceiver register or triggers a
function offered by the receiver
EthTrcv_GetBaudRate EthTrcv.h Obtains the baud rate of the indexed transceiver
EthTrcv_GetDuplexMode EthTrcv.h Obtains the duplex mode of the indexed transceiver
EthTrcv_GetLinkState EthTrcv.h Obtains the link state of the indexed transceiver
EthTrcv_GetTransceiverMode EthTrcv.h Obtains the state of the indexed transceiver
EthTrcv_SetTransceiverMode EthTrcv.h Enables / disables the indexed transceiver
EthTrcv_StartAutoNegotiation EthTrcv.h Restarts the negotiation of the transmission
parameters used by the indexed transceiver
NvM_GetErrorStatus NvM.h Service to read the block dependent error/status
information.
5
4
API Function Header File Description
NvM_ReadBlock NvM.h Service to copy the data of the NV block to its
corresponding RAM block.
NvM_WriteBlock NvM.h Service to copy the data of the RAM block to its
corresponding NV block.
Spi_AsyncTransmit Spi.h Service to transmit data on the SPI bus.
Spi_Cancel Spi.h Service cancels the specified on-going sequence
transmission.
Spi_ReadIB Spi.h Service for reading synchronously one or more data
from an IB SPI Handler/Driver Channel specified by
parameter.
Spi_SetAsyncMode Spi.h Service to set the asynchronous mechanism mode
for SPI busses handled asynchronously.
Spi_SetupEB Spi.h Service to setup the buffers and the length of data
for the EB SPI Handler/Driver Channel specified.
Spi_SyncTransmit Spi.h Service to transmit data on the SPI bus
Spi_WriteIB Spi.h Service for writing one or more data to an IB SPI
Handler/Driver Channel specified by parameter.
In this chapter all interfaces are listed where the target function could be configured.
The names of these kind of interfaces are not fixed because they are configurable.
8.6.3.1 <EthSwtLinkDownCallout>
[SWS_EthSwt_00117] d
Service Name <EthSwtLinkDownCallout>
Syntax void <EthSwtLinkDownCallout> (
uint8 SwitchIdx,
uint8 PortIdx
)
4
PortIdx Index of the port at the addressed switch
Parameters (inout) None
Parameters (out) None
Return value None
Description Is called, if a link which is configured goes down.
Available via EthSwt_Externals.h
c(SRS_ETH_00119, SRS_ETH_00087)
[SWS_EthSwt_00118] dThe function <EthSwtLinkDownCallout> shall be called
if a link, which is configured, goes down (link loss). The function provides the Switch
index and the Port index, such that the port which went down can be identified.c(SRS_-
ETH_00119, SRS_ETH_00087)
8.6.3.2 <EthSwtLinkUpCallout>
[SWS_EthSwt_00203] d
Service Name <EthSwtLinkUpCallout>
Syntax void <EthSwtLinkUpCallout> (
uint8 SwitchIdx,
uint8 PortIdx
)
c(SRS_ETH_00119, SRS_ETH_00087)
[SWS_EthSwt_00204] dThe function <EthSwtLinkUpCallout> shall be called if a
link, which is configured, goes up. The function provides the Switch index and the
Port index, such that the port which went up can be identified.c(SRS_ETH_00119,
SRS_ETH_00087)
Note: If the hardware cannot signal a link up with an interrupt, the status of the link
has to be determined in polling mode by checking the state of the link.
8.6.3.3 <GetCfgDataRawDone>
[SWS_EthSwt_91032] d
Service Name <GetCfgDataRawDone>
Syntax void <GetCfgDataRawDone> (
uint8 SwitchIdx
)
c(SRS_Eth_00123)
9 Sequence diagrams
The following sequence diagram shows the interaction between the DHCP-Server in
the TCP/IP-module and the Ethernet Switch Driver:
DHCP-Server in «module» «module»
TCPIP Module EthIf EthSwt
EthIf_GetPhysAddr(uint8, uint8**)
EthSwt_GetPortMacAddr(Std_ReturnType, uint8, const uint8*,
uint8**)
!
Figure 9.1
The following sequence diagram shows the interaction between the EthIf, EthSwt and
the EthTrcv for API calls to the EthIf:
«module» «module» «module»
EthIf EthSwt EthTrcv
EthSwt_SetSwitchPortMode or
EthSwt_GetSwitchPortMode
EthTrcv_SetTransceiverMode or
EthTrcv_GetTransceiverMode
Figure 9.2
The following sequence diagram shows the interaction between the EthIf, EthSwt, and
the EthTrcv for API calls which are initiated by the EthIf:
«module» «module» «module»
EthIf EthSwt EthTrcv
EthSwt_GetDuplexMode,
EthSwt_GetLinkState,
EthTrcv_GetDuplexMode,
EthSwt_GetBaudRate,
EthTrdv_GetLinkState,
EthSwt_StartSwitchPortAutoNegotiation
EthTrcv_GetBaudRate,
EthTrcv_StartAutoNegotiation
Figure 9.3
[EthSwtSwitchManagementSupport == ON]
EthSwt_EthTxAdaptBufferLength(uint16**)
TxMgmtObject.Ownership ==
ETHSWT_MGMT_OBJ_OWNED_BY_ETHSWT
EthSwt_MainFunction()
[(TxMgmtObject.Ownership ==
ETHSWT_MGMT_OBJ_OWNED_BY_ETHSWT) &&
(Management Info Available)]:
TxMgmtObject.Ownership =
ETHSWT_MGMT_OBJ_OWNED_BY_<UPPER_LAYER>
Eth Rx frame()
[IsMgmtFrameOnly == FALSE]:
[EthSwtSwitchManagementSupport == ON]
EthSwt_EthRxFinishedIndication
(Std_ReturnType, uint8, Eth_BufIdxType)
EthSwt_MainFunction()
[(RxMgmtObject.Ownership ==
ETHSWT_MGMT_OBJ_OWNED_BY_ETHSWT) &&
(Management Info Available)]:
RxMgmtObject.Ownership =
ETHSWT_MGMT_OBJ_OWNED_BY_<UPPER_LAYER>
10 Configuration specification
section 10.2 specifies the structure (containers) and the parameters of the module Eth
Swt.
10.1.1 EthSwt
10.1.2 EthSwtConfig
Included Containers
Container Name Multiplicity Scope / Dependency
EthSwtDemEvent 0..1 Container for the references to DemEventParameter
ParameterRefs elements which shall be invoked using the API
Dem_SetEventStatus in case the corresponding error
occurs. The EventId is taken from the referenced
DemEventParameter’s DemEventId symbolic value. The
standardized errors are provided in this container and
can be extended by vendor-specific error references.
EthSwtNvm 0..1 Configuration of one Ethernet Switch Nvm usage in
case the module requires non volatile memory in the
Ecu to store switch configuration.
EthSwtPort 1..* Configuration of one Ethernet Switch Port.
EthSwtSpi 0..1 Configuration of one Ethernet Switch SPI access (if SPI
is used).
10.1.3 EthSwtDemEventParameterRefs
No Included Containers
min = 0
EthSwtConfig: +parameter max = 255
EcucParamConfContainerDef
symbolicNameValue = true
lowerMultiplicity = 1
EthSwtDropDoubleTagged:
upperMultiplicity = * +parameter
EcucBooleanParamDef
defaultValue = false
EthSwtManagementEthCtrlRef: EthCtrlConfig:
EcucReferenceDef +destination EcucParamConfContainerDef
+reference
lowerMultiplicity = 0 lowerMultiplicity = 1
upperMultiplicity = 1 upperMultiplicity = *
requiresSymbolicNameValue = true
EthSwtManagementPortRef:
+reference EcucReferenceDef
lowerMultiplicity = 0
upperMultiplicity = 1
+destination
EthSwtPort:
+subContainer EcucParamConfContainerDef
lowerMultiplicity = 1
upperMultiplicity = * EthSwtClockSynchronizationSupport:
+parameter EcucBooleanParamDef
defaultValue = false
EthSwtSpi:
+subContainer EcucParamConfContainerDef
EthSwtArlTableEntryTimeout:
lowerMultiplicity = 0
EcucFloatParamDef
upperMultiplicity = 1
+parameter min = 1
max = 65535
defaultValue = 300
EthSwtNvm: lowerMultiplicity = 0
+subContainer EcucParamConfContainerDef upperMultiplicity = 1
lowerMultiplicity = 0
upperMultiplicity = 1
+destination
EthSwtConfigEcucPartitionRef:
+reference +destination EcucPartition:
EcucReferenceDef
EcucParamConfContainerDef
lowerMultiplicity = 0
lowerMultiplicity = 0
upperMultiplicity = 1
upperMultiplicity = *
+subContainer
ETHSWT_E_ACCESS: DemEventParameter:
EthSwtDemEventParameterRefs:
EcucReferenceDef
EcucParamConfContainerDef +reference +destination EcucParamConfContainerDef
lowerMultiplicity = 0 upperMultiplicity = 65535
lowerMultiplicity = 0
upperMultiplicity = 1 lowerMultiplicity = 1
upperMultiplicity = 1
requiresSymbolicNameValue = true
ETHSWT_E_SYNCPORT2PHY:
+reference EcucReferenceDef +destination
lowerMultiplicity = 0
upperMultiplicity = 1
requiresSymbolicNameValue = true
10.1.4 EthSwtGeneral
Tags:
atp.Status=draft
Multiplicity 1
Type EcucBooleanParamDef
Default Value
Post-Build Variant false
Value
Value Configuration Pre-compile time X All Variants
Class
Link time –
Post-build time –
Scope / Dependency scope: local
Multiplicity 1
Type EcucBooleanParamDef
Default Value false
Post-Build Variant false
Value
Tags:
atp.Status=draft
Multiplicity 1
Type EcucBooleanParamDef
Default Value
Post-Build Variant false
Value
Value Configuration Pre-compile time X All Variants
Class
Link time –
Post-build time –
Scope / Dependency scope: local
Unit: seconds
Multiplicity 1
Type EcucFloatParamDef
Range [0 .. INF[
Default Value
Post-Build Variant false
Value
Value Configuration Pre-compile time X All Variants
Class
Link time –
Post-build time –
Scope / Dependency scope: local
No Included Containers
defaultValue = false
+parameter
EthSwtStoreConfigurationApi:
EcucBooleanParamDef
+parameter EthSwtVersionInfoApi:
EcucBooleanParamDef
defaultValue = false
+parameter EthSwtGetPortMacAddrApi:
EcucBooleanParamDef
+parameter
EthSwtGetMaxFIFOBufferFillLevelApi:
EcucBooleanParamDef
+parameter
EthSwtGetCounterValuesApi:
EcucBooleanParamDef
+parameter
EthSwtGetArlTableApi:
EcucBooleanParamDef
+parameter
EthSwtEnableVlanApi:
EcucBooleanParamDef
+parameter
EthSwtSetMacLearningModeApi:
EcucBooleanParamDef
+parameter
EthSwtGetMacLearningModeApi:
EcucBooleanParamDef
+parameter
EthSwtPersistentConfigurationResult:
EcucBooleanParamDef
+parameter EthSwtGetRxStatsApi:
EcucBooleanParamDef
+parameter
EthSwtGetSwitchRegApi:
EcucBooleanParamDef
+parameter EthSwtSetSwitchRegApi:
EcucBooleanParamDef
+parameter
EthSwtReadTrcvRegisterApi:
EcucBooleanParamDef
+parameter EthSwtWriteTrcvRegisterApi:
EcucBooleanParamDef
EthSwtLinkDownCallout:
+parameter EcucFunctionNameDef
lowerMultiplicity = 0
upperMultiplicity = 1
+parameter
EthSwtDeletePortMirrorConfigurationApi:
EcucBooleanParamDef
+parameter EthSwtLinkUpCallout: EcucFunctionNameDef
lowerMultiplicity = 0 EthSwtPersistentConfigurationResultCallback:
upperMultiplicity = 1 EcucFunctionNameDef
+parameter
lowerMultiplicity = 0
upperMultiplicity = 1
EthSwtMainFunctionPeriod:
+parameter EcucFloatParamDef
min = 0 EthSwtPublicCddHeaderFile:
max = INF EcucStringParamDef
+parameter
lowerMultiplicity = 0
upperMultiplicity = *
minLength = 1
maxLength = 32
+parameter
EthSwtGeneral: EthSwtGetPortSignalQualityApi:
EcucParamConfContainerDef EcucBooleanParamDef +parameter
EthSwtGetPortIdentifierApi:
EcucBooleanParamDef
+parameter
EthSwtGetSwitchIdentifierApi:
EcucBooleanParamDef
+parameter
EthSwtWritePortMirrorConfigurationApi:
EcucBooleanParamDef
+parameter
EthSwtReadPortMirrorConfigurationApi:
EcucBooleanParamDef
+parameter
EthSwtGetPortMirrorStateApi:
EcucBooleanParamDef
+parameter
EthSwtSetPortMirrorStateApi:
EcucBooleanParamDef
+parameter
EthSwtSetPortTestModeApi:
EcucBooleanParamDef
+parameter
EthSwtSetPortLoopbackModeApi:
EcucBooleanParamDef
+parameter
EthSwtSetPortTxModeApi:
EcucBooleanParamDef
+parameter
EthSwtGetPortCableDiagnosticsResultApi:
EcucBooleanParamDef
+parameter EthSwtGetTxErrorCounterValuesApi:
EcucBooleanParamDef
defaultValue = false
+parameter EthSwtSetForwardingModeApi:
EcucBooleanParamDef
defaultValue = false
lowerMultiplicity = 0
upperMultiplicity = 1 +parameter
EthSwtGlobalTimeSupportApi:
EcucBooleanParamDef
+parameter EthSwtVerifyConfigApi:
EcucBooleanParamDef
+parameter min = 0
EthSwtManagementSupportApi: max = INF
EcucBooleanParamDef
+parameter
EthSwtGetSwitchPortModeApi:
+parameter EcucBooleanParamDef
EthSwtSetSwitchPortModeApi:
EcucBooleanParamDef
+parameter
EthSwtGetLinkStateApi:
EcucBooleanParamDef
+parameter
EthSwtStartSwitchPortAutoNegotiationApi:
EcucBooleanParamDef
+parameter
EthSwtGetDuplexModeApi:
EcucBooleanParamDef
+parameter
EthSwtGetBaudRateApi:
EcucBooleanParamDef
+parameter EthSwtGetCfgDataRawDone:
EcucFunctionNameDef
+parameter lowerMultiplicity = 0
EthSwtGetCfgRaw: EcucBooleanParamDef
upperMultiplicity = 1
EthSwtEcucPartitionRef: EcucReferenceDef
+reference +destination EcucPartition: EcucParamConfContainerDef
lowerMultiplicity = 0
lowerMultiplicity = 0
upperMultiplicity = *
upperMultiplicity = *
(from EcucPartition)
EthSwtEnableCableDiagnosticApi:
+parameter EcucBooleanParamDef
lowerMultiplicity = 1
upperMultiplicity = 1
+parameter EthSwtCheckWakeupApi:
EcucBooleanParamDef
+parameter
EthSwtGetSwitchPortWakeupReasonApi:
EcucBooleanParamDef
10.1.5 EthSwtPort
A master switch shall be connected by one host port with the host ecu.
Included Containers
Container Name Multiplicity Scope / Dependency
EthSwtPortEgress 1 Configuration of one Ethernet Switch Port Egress
behavior.
EthSwtPortIngress 1 Configuration of one Ethernet Switch Port ingress
behavior.
EthSwtPortVlan 0..4095 Description Determines the membership of this port to
Membership the virtual network, i.e. frames with this VID can be
received and transmitted via this port.
EthSwtConfig:
EcucParamConfContainerDef EthTrcvIdx:
EcucIntegerParamDef
lowerMultiplicity = 1
upperMultiplicity = * min = 0
EthSwtPortIdx:
EcucIntegerParamDef max = 255
symbolicNameValue = true
+subContainer
min = 0
+parameter max = 255 +parameter
EthSwtPort:
symbolicNameValue = true
EcucParamConfContainerDef
EthTrcvConfig:
lowerMultiplicity = 1 EcucParamConfContainerDef
upperMultiplicity = * EthSwtPortTrcvRef: EcucReferenceDef +destination
+reference lowerMultiplicity = 1
lowerMultiplicity = 0 upperMultiplicity = *
upperMultiplicity = 1
requiresSymbolicNameValue = true
EthSwtPortPredefinedMacAddresses:
+parameter EcucStringParamDef
lowerMultiplicity = 0
upperMultiplicity = *
regularExpression = [0-9a-fA-F]{2}[[:-][0-9a-fA-F]{2}]{5}
EthSwtPortVlanMembership: EthSwtPortVlanMembershipId:
EcucParamConfContainerDef +parameter EcucIntegerParamDef
lowerMultiplicity = 0 min = 0
+subContainer upperMultiplicity = 4095 max = 4094
EthSwtPortVlanDefaultPriority:
+parameter
EcucIntegerParamDef
min = 0
max = 7
+parameter
+literal ETHSWT_NOT_SENT:
EthSwtPortVlanForwardingType: EcucEnumerationLiteralDef
EcucEnumerationParamDef
+literal
ETHSWT_SENT_UNTAGGED:
EcucEnumerationLiteralDef
+literal
ETHSWT_SENT_TAGGED:
EcucEnumerationLiteralDef
+literal ETHSWT_HOST_PORT:
EthSwtPortRole:
+parameter EcucEnumerationLiteralDef
EcucEnumerationParamDef
lowerMultiplicity = 0 +literal
upperMultiplicity = 1 ETHSWT_UP_LINK_PORT:
EcucEnumerationLiteralDef
+subContainer EthSwtPortIngress:
EcucParamConfContainerDef
+subContainer EthSwtPortEgress:
EcucParamConfContainerDef
+parameter EthSwtPortTimeStampSupport:
EcucBooleanParamDef
EthSwtConfig:
EcucParamConfContainerDef
lowerMultiplicity = 1
upperMultiplicity = * +literal ETHSWT_PORT_100BASE_TX:
EthSwtPortPhysicalLayerType: EcucEnumerationLiteralDef
EcucEnumerationParamDef
+subContainer +literal
lowerMultiplicity = 0 ETHSWT_PORT_1000BASE_T:
+parameter upperMultiplicity = 1 EcucEnumerationLiteralDef
EthSwtPort:
EcucParamConfContainerDef
+literal
ETHSWT_PORT_100BASE_T1:
lowerMultiplicity = 1
EcucEnumerationLiteralDef
upperMultiplicity = *
+literal
ETHSWT_PORT_1000BASE_T1:
EcucEnumerationLiteralDef
EthSwtPortMacLayerType: +literal
ETHSWT_PORT_MAC_LAYER_TYPE_XMII:
EcucEnumerationParamDef EcucEnumerationLiteralDef
lowerMultiplicity = 0
+parameter upperMultiplicity = 1 +literal
ETHSWT_PORT_MAC_LAYER_TYPE_XGMII:
EcucEnumerationLiteralDef
+literal
ETHSWT_PORT_MAC_LAYER_TYPE_XXGMII:
EcucEnumerationLiteralDef
lowerMultiplicity = 0 +literal
REDUCED: EcucEnumerationLiteralDef
upperMultiplicity = 1
+parameter +literal
REVERSED: EcucEnumerationLiteralDef
+literal
SERIAL: EcucEnumerationLiteralDef
+literal
UNIVERSAL_SERIAL: EcucEnumerationLiteralDef
+literal ETH_MAC_LAYER_SPEED_10M:
EthSwtPortMacLayerSpeed:
EcucEnumerationLiteralDef
EcucEnumerationParamDef
lowerMultiplicity = 0 +literal
ETH_MAC_LAYER_SPEED_100M:
upperMultiplicity = 1
EcucEnumerationLiteralDef
+parameter
+literal
ETH_MAC_LAYER_SPEED_1G:
EcucEnumerationLiteralDef
+literal
ETH_MAC_LAYER_SPEED_10G:
EcucEnumerationLiteralDef
+literal
ETH_MAC_LAYER_SPEED_2500M:
EcucEnumerationLiteralDef
Please note that the functional behavior of the ingress and egress port of a switch is
implemented in hardware in the switch devices (see [11]). Thus, the configuration of
EthSwtPort and described in the following has to be written to the switch device or is
related to the switch configuration.
10.1.6 EthSwtPortIngress
Configuration Parameters
If EthSwtPortIngressDefaultVlan is configured
EthSwtPortIngressDropUntagged shall be set to FALSE.
If EthSwtPortIngressDefaultVlan is configured
EthSwtPortIngressDropUntagged shall be set to FALSE.
Included Containers
Container Name Multiplicity Scope / Dependency
EthSwtPortPolicer 0..32760 Definition of Rate Policing parameters.
EthSwtPriority 0..8 Defines a priority regeneration where the
Regeneration EthSwtPriorityRegenerationIngressPriority is replaced
by EthSwtPriorityRegenerationRegeneratedPriority.
+subContainer
EthSwtPort: EthSwtPortVlanMembership:
EcucParamConfContainerDef EcucParamConfContainerDef
lowerMultiplicity = 1 lowerMultiplicity = 0
upperMultiplicity = * upperMultiplicity = 4095
+destination
+subContainer
EthSwtPortPolicer:
EcucParamConfContainerDef +parameter EthSwtPortRatePolicedByteCount:
EthSwtPortIngress: EcucIntegerParamDef
EcucParamConfContainerDef lowerMultiplicity = 0
upperMultiplicity = 32760 min = 1
EthSwtPortRateVlanMembershipRef:
+reference EcucReferenceDef
lowerMultiplicity = 0
upperMultiplicity = 4095
EthSwtPortRatePolicedTimeInterval:
+parameter EcucFloatParamDef
+subContainer
min = 0
max = INF
EthSwtPortRatePolicedPriority:
EcucIntegerParamDef
+parameter
min = 0
max = 7
lowerMultiplicity = 0
upperMultiplicity = 1
+literal DROP_FRAME:
EcucEnumerationLiteralDef
+parameter EthSwtPortRateViolationAction:
EcucEnumerationParamDef +literal
BLOCK_SOURCE:
EcucEnumerationLiteralDef
EthSwtPriorityRegeneration: EthSwtPriorityRegenerationIngressPriority:
+parameter EcucIntegerParamDef
EcucParamConfContainerDef
+subContainer lowerMultiplicity = 0 min = 0
upperMultiplicity = 8 max = 7
+parameter EthSwtPriorityRegenerationRegeneratedPriority:
EcucIntegerParamDef
min = 0
max = 7
EthSwtPortIngressVlanModification:
EcucIntegerParamDef
+parameter
min = 0 EthSwtPortIngressDefaultVlan: EcucIntegerParamDef
max = 4095
lowerMultiplicity = 0 min = 0
upperMultiplicity = 1 +parameter max = 4094
lowerMultiplicity = 0
upperMultiplicity = 1
EthSwtPortTrafficClassAssignment: defaultValue = 1
EcucIntegerParamDef
+parameter
min = 0
max = 7 EthSwtPortIngressDefaultPriority:
lowerMultiplicity = 0 EcucIntegerParamDef
upperMultiplicity = 1 +parameter
min = 0
max = 7
+parameter EthSwtPortIngressDropUntagged: lowerMultiplicity = 0
EcucBooleanParamDef upperMultiplicity = 1
defaultValue = 0
defaultValue = FALSE
EthSwtPriorityTrafficClassAssignmentPriority:
EcucIntegerParamDef
+parameter min = 0
EthSwtPriorityTrafficClassAssignment:
+subContainer max = 7
EcucParamConfContainerDef
lowerMultiplicity = 0 +parameter
upperMultiplicity = 8 EthSwtPriorityTrafficClassAssignmentTrafficClass:
EcucIntegerParamDef
min = 0
max = 7
10.1.7 EthSwtPortPolicer
Name EthSwtPriorityRegenerationRegeneratedPriority
[ECUC_EthSwt_00059]
Parent Container EthSwtPriorityRegeneration
Description Message priority the incoming message will be tagged with.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 7
Default Value
Post-Build Variant true
Value
Value Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU
No Included Containers
No Included Containers
10.1.8 EthSwtPriorityTrafficClassAssignment
Default Value
Post-Build Variant true
Value
Value Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU
Name EthSwtPriorityTrafficClassAssignmentTrafficClass
[ECUC_EthSwt_00029]
Parent Container EthSwtPriorityTrafficClassAssignment
Description Traffic Class value.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 7
Default Value
Post-Build Variant true
Value
Value Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU
No Included Containers
10.1.9 EthSwtPortEgress
Included Containers
Container Name Multiplicity Scope / Dependency
EthSwtPortFifo 1..* Represents a Fifo in the egress port.
EthSwtPortScheduler 1..* Represents a Scheduler in the egress port.
EthSwtPortShaper 0..* Represents a Shaper in the egress port.
EthSwtPortEgress: +reference
EthSwtPortEgressLastSchedulerRef:
EcucParamConfContainerDef EcucReferenceDef
+destination
lowerMultiplicity = 1 lowerMultiplicity = 1
upperMultiplicity = * upperMultiplicity = *
+subContainer
+reference
+destination EthSwtPortEgressPredecessorRef:
EcucChoiceReferenceDef
+destination
EthSwtPortShaper:
EcucParamConfContainerDef
lowerMultiplicity = 0
+subContainer upperMultiplicity = *
+reference EthSwtPortEgressPredecessorFifoRef:
EcucReferenceDef
+destination
EthSwtPortFifo:
+subContainer EcucParamConfContainerDef
lowerMultiplicity = 1
upperMultiplicity = * +destination
lowerMultiplicity = 1
upperMultiplicity = * +literal
+subContainer
ETHSWT_SCHEDULER_DEFICIT_ROUND_ROBIN:
EcucEnumerationLiteralDef
+literal
ETHSWT_SCHEDULER_WEIGHTED_ROUND_ROBIN:
EcucEnumerationLiteralDef
+literal
ETHSWT_SCHEDULER_STRICT_PRIORITY:
EcucEnumerationLiteralDef
+subContainer
EthSwtPortSchedulerPredecessor:
EcucParamConfContainerDef +parameter EthSwtPortSchedulerPredecessorOrder:
EcucIntegerParamDef
lowerMultiplicity = 1
upperMultiplicity = *
EthSwtPortShaper: EthSwtPortShaperIdleSlope:
+subContainer EcucParamConfContainerDef +parameter EcucIntegerParamDef
lowerMultiplicity = 0 lowerMultiplicity = 0
upperMultiplicity = * upperMultiplicity = 1
EthSwtPortFifo: EthSwtPortFifoTrafficClassAssignment:
EcucParamConfContainerDef EcucIntegerParamDef
+parameter
lowerMultiplicity = 1 min = 0
upperMultiplicity = * max = 7
lowerMultiplicity = 0
upperMultiplicity = 8
+subContainer
EthSwtPortFifoMinimumLength:
+parameter EcucIntegerParamDef
min = 0
lowerMultiplicity = 0
upperMultiplicity = 1
EthSwtPortEgressFifoIdx:
+parameter
EcucIntegerParamDef
min = 0
lowerMultiplicity = 1
upperMultiplicity = 1
10.1.10 EthSwtPortScheduler
Included Containers
Container Name Multiplicity Scope / Dependency
EthSwtPortScheduler 1..* Defines an ordered list of predecessors for this
Predecessor scheduler.
10.1.11 EthSwtPortSchedulerPredecessor
No Included Containers
10.1.12 EthSwtPortShaper
No Included Containers
10.1.13 EthSwtPortFifo
No Included Containers
10.1.14 EthSwtPortVlanMembership
No Included Containers
10.1.15 EthSwtSpi
Included Containers
Container Name Multiplicity Scope / Dependency
EthSwtSpiSequence 1..* Container gives EthSwt driver information about one SPI
sequence. One SPI sequence used by EthSwt driver is
in exclusive use for it. No other driver is allowed to
access this sequence. EthSwt driver may use one
sequence to access n EthSwt hardware chips of the
same type or n sequences are used to access one
single EthSwt hardware chip. If a EthSwt hardware has
no SPI interface, there is no instance of this container.
No Included Containers
EthSwtConfig: EthSwtSpi:
EcucParamConfContainerDef +subContainer EcucParamConfContainerDef
lowerMultiplicity = 1 lowerMultiplicity = 0
upperMultiplicity = * upperMultiplicity = 1
+subContainer
EthSwtSpiSequenceName: SpiSequence:
EthSwtSpiSequence: EcucReferenceDef +destination EcucParamConfContainerDef
EcucParamConfContainerDef +reference
lowerMultiplicity = 0 upperMultiplicity = *
lowerMultiplicity = 1 upperMultiplicity = * lowerMultiplicity = 1
upperMultiplicity = * requiresSymbolicNameValue = true
+parameter EthSwtSpiAccessSynchronous:
EcucBooleanParamDef +parameter
lowerMultiplicity = 0 SpiSequenceId:
upperMultiplicity = 1 EcucIntegerParamDef
symbolicNameValue = true
max = 255
10.1.17 EthSwtNvm
No Included Containers
EthSwtConfig: NvMNvramBlockIdentifier:
EcucParamConfContainerDef EcucIntegerParamDef
+parameter
+subContainer
requiresSymbolicNameValue = true
10.2 Constraints
[SWS_EthSwt_CONSTR_00413] dThe module will operate as an independent in-
stance in each of the partitions (see EthSwtEcucPartitionRef), means the called
API will only target the partition it is called in.c()
[SWS_EthSwt_CONSTR_00411] dThe ECUC partitions referenced by EthSwtCon-
figEcucPartitionRef shall be a subset of the ECUC partitions referenced by Eth-
SwtEcucPartitionRef.c()
[SWS_EthSwt_CONSTR_00412] dEthSwtConfig, EthCtrlConfig and EthTr-
cvConfig of one communication channel shall all reference the same ECUC parti-
tion.c()
[SWS_EthSwt_CONSTR_00438] dIf EthSwtEcucPartitionRef references one or
more ECUC partitions, EthSwtConfigEcucPartitionRef shall have a multiplicity
of one and reference one of these ECUC partitions as well.c()