DEENESPTFRRUARHIKOZHNL
CLASSIC Modul: nvdatahandling Rolle: heuristic Konfidenz: 85%

SNIP_CLASSIC_NVDATAHANDLING_SECTION_4_1_3_2_Explicit_synchronization

Quelle: NVDataHandling.pdf (Seite 12) • Ziel-Anforderung: SWS_NvM_00837

Wortlaut

4.1.3.2 Explicit synchronization In Explicit synchronization, NvM defines a RAM mirror which is used to exchange data with the RAM block of Application. Application writes the data in RAM block and invokes NvM write API. NvM invokes API to read the RAM mirror and data is copied from RAM mirror to RAM block and finally to NV block. The data is transferred by the application in both directions via callback routines, called by the NvM module. NV Data Handling Guideline Figure 3: Overview of Explicit synchronization The advantage is that applications can control their RAM block in an efficient way. They are responsible for copying consistent data to and from the NvM module’s RAM mirror using ReadRamBlockFromNvM / WriteRamBlockToNvM. Application has to ensure data integrity of RAM block while copying data to/from RAM mirror. The drawbacks are the additional RAM that needs to have the same size as the largest NVRAM block that uses this mechanism and the necessity of an additional copy between two RAM locations for every operation. This mechanism especially enables the sharing of NVRAM blocks by different applications, if there is a module (e.g. NvBlockSwComponentType) that synchronizes these applications and is the owner of the NVRAM block from the NvM module’s perspective. Following steps need to considered while using Explicit synchronization  Write request: 1. The application fills a RAM block with the data that has to be written by the NvM module. 2. The application issues the NvM_WriteBlock or NvM_WritePRAMBlock request. 3. The application might modify the RAM block until the routine NvMWriteRamBlockToNvM is called by the NvM module. 4. If the routine NvMWriteRamBlockToNvM is called by the NvM module, then the application has to provide a consistent copy of the RAM block to the destination requested by the NvM module. The application can use the return value E_NOT_OK in order to signal that data was not consistent. The NvM module will accept this NvMRepeatMirrorOperations times and then postpones the request and continues with its next request. 5. Continuation only if data was copied to the NvM module: 6. From now on the application can read and write the RAM block again. 7. An application can use polling to get the status of the request or can be informed via a callback routine asynchronously. NV Data Handling Guideline  Multi block write request (NvM_WriteAll): 1. The ECU state manager issues the NvM_WriteAll request which transfers control to the NvM module. 2. During NvM_WriteAll job, if a synchronization callback (NvM_WriteRamBlockToNvM) is configured for a block it will be called by the NvM module. In this callback the application has to provide a consistent copy of the RAM block to the destination requested by the NvM module. The application can use the return value E_NOT_OK in order to signal that data was not consistent. The NvM module will accept this NvMRepeatMirrorOperations times and then report the write operation as failed. 3. Now the application can read and write the RAM block again. 4. The ECU state manager can use polling to get the status of the request or can be informed via a callback function.

Versionen & Provenienz · Zugeordnete Anforderungen

Diese Angaben zeigt der Versions-Explorer.

Begründung & Zuweisungs-Evidenz

NvMRepeatMirrorOperations retry on NvM_WriteAll.

Dokumenten-Herkunft & Rückverfolgbarkeit

Spezifikations-Dokument NVDataHandling.pdf
Dokumentseite Seite 12
Ziel-Modul nvdatahandling (classic)
Ziel-Anforderung SWS_NvM_00837
Semantische Rolle heuristic
Automatisierungs-Konfidenz 0.85