File tree Expand file tree Collapse file tree 1 file changed +29
-0
lines changed
Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -411,6 +411,35 @@ Inputs:
411411
412412 #. `void_te.size ` = `te.data_size + te.hdr_size - 0x8 `
413413
414+ Overwriting a TE
415+ ^^^^^^^^^^^^^^^^
416+
417+ Inputs:
418+
419+ - `tl_base_addr `: Base address of the TL from which TE to be overwritten
420+ - `te_base_addr `: Base address of the TE to be overwritten
421+ - `new_data_size `: Size in bytes of the data to be encapsulated in the TE
422+ - [data]: Data to be copied into the TE
423+
424+ #. If `te.data_size ` is smaller than `new_data_size `, abort this operation here and instead first
425+ follow `Adding a void TE `_ with `te_base_addr ` and `te.data_size `, then follow `Adding a new TE `_
426+ with `tl_base_addr `, `tag_id `, `new_data_size ` and `[data] `
427+
428+ #. If `has_checksum `, xor the `te.data_size ` bytes starting at `te_base_addr + te.hdr_size ` with `tl.checksum `
429+
430+ #. Set `te.data_size ` (`te_base_addr + 0x4 `) to `align8(new_data_size) `
431+
432+ #. Copy or generate the new TE data into `te_base_addr + te.hdr_size `
433+
434+ #. If `has_checksum `, xor the `te.hdr_size + new_data_size ` bytes starting at `te_base_addr ` with `tl.checksum `
435+
436+ #. If `te.data_size - new_data_size ` is greater or equal to `0x8 ` then call
437+ `Adding a void TE `_ with following arguments:
438+
439+ #. `void.te.base_addr ` = `te_base_addr + te.hdr_size + align8(new_data_size) `
440+
441+ #. `void.te.size ` = `te.data_size - align8(new_data_size) - 0x8 `
442+
414443Adding a new TE with special data alignment requirement
415444^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
416445
You can’t perform that action at this time.
0 commit comments