Changes between Version 1 and Version 2 of kernel_paddr


Ignore:
Timestamp:
Dec 20, 2016, 4:36:57 PM (8 years ago)
Author:
alain
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • kernel_paddr

    v1 v2  
    33[[PageOutline]]
    44
    5 The [source:soft/giet_vm/giet_common/utils.c utils.c] and [source:soft/giet_vm/giet_common/utils.h util.h] files define the functions supporting physical addressing, using the CP2_PADDR_EXT register.
     5The [source:soft/giet_vm/giet_common/utils.c utils.c] and [source:soft/giet_vm/giet_common/utils.h util.h] files define the functions related to physical addressing, using the CP2_PADDR_EXT register, or functions used for software L2/L3 cache coherence.
    66Physical addresses can have up to 64 bits.
    77
    88They are prefixed by "_" to remind that they can only be executed by a processor in kernel mode.
    99
    10  === unsigned int _physical_read( unsigned long long paddr ) ===
     10 === 1) unsigned int '''_physical_read'''( unsigned long long paddr ) ===
    1111Returns the 32 bits word stored at physical address ''paddr'', after a temporary DTLB deactivation.
    1212It uses the CP2_PADDR_EXT register.
    1313
    14  === void _physical_write( unsigned long long paddr, unsigned int value )
     14 === 2) void '''_physical_write'''( unsigned long long paddr, unsigned int value )
    1515Writes the 32 bits word ''value'' at physical address ''paddr'', after a temporary DTLB deactivation.
    1616It uses the CP2_PADDR_EXT register.
    1717
    18  === unsigned long long _physical_read_ull( unsigned long long paddr ) ===
     18 === 3) unsigned long long '''_physical_read_ull'''( unsigned long long paddr ) ===
    1919Returns the 64 bits word stored at physical address ''paddr'', after a temporary DTLB deactivation.
    2020It uses the CP2_PADDR_EXT register.
    2121
    22  === void _physical_write_ull( unsigned long long paddr, unsigned long long value ) ===
     22 === 4) void '''_physical_write_ull'''( unsigned long long paddr, unsigned long long value ) ===
    2323Writes the 64 bits word ''value'' at physical address ''paddr'', after a temporary DTLB deactivation.
    2424It uses the CP2_PADDR_EXT register.
    2525
    26  === void _physical_memcpy( unsigned long long dst_paddr, unsigned long long src paddr, unsigned int size ) ===
     26 === 5) void '''_physical_memcpy'''( unsigned long long dst_paddr, unsigned long long src paddr, unsigned int size ) ===
    2727This function makes a memcpy from a source buffer to a destination buffer, using physical addresses, after a temporary DTLB de-activation. The ''src_paddr'', ''dst_paddr'' and ''size'' arguments must be multiple of 4 bytes.
    2828
    29  === unsigned int _io_extended_read( unsigned int* vaddr ) ===
     29 === 6) unsigned int '''_io_extended_read'''( unsigned int* vaddr ) ===
    3030This function is used by the GIET-VM drivers to read a 32 bits word in a peripheral register.
    3131If the MMU is not activated, the virtual address is extended using X_IO and Y_IO (defined in the hard-config.h file) to reach the cluster_io.
    3232
    33  === void _io_extended_write( unsigned int* vaddr, unsigned int value ) ===
     33 === 7) void '''_io_extended_write'''( unsigned int* vaddr, unsigned int value ) ===
    3434This function is used by the GIET-VM drivers to write a 32 bits word in a peripheral register.
    3535If the MMU is not activated, the virtual address is extended using X_IO and Y_IO (defined in the hard-config.h file) to reach the cluster_io.
     36
     37 === 8) unsigned int '''_l2_l3_sync_read'''( unsigned int* vaddr ) ===
     38This function is used by the GIET_VM drivers to write a 32 bits word in L2 cache, with the garanty that the L3 cache will be updated.
     39
     40 === 9) void '''_l2_l3_sync_write'''( unsigned int* vaddr, unsigned int value ) ===
     41This function is used by the GIET_VM drivers to read a 32 bits word from L2 cache, with the garanty that the involved cache line has
     42been perviously invalidated.