lkml.org 
[lkml]   [2016]   [Dec]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    SubjectRe: [PATCHv4 08/10] mm/kasan: Switch to using __pa_symbol and lm_alias
    From
    Date
    On 11/29/2016 09:55 PM, Laura Abbott wrote:
    > __pa_symbol is the correct API to find the physical address of symbols.
    > Switch to it to allow for debugging APIs to work correctly.

    But __pa() is correct for symbols. I see how __pa_symbol() might be a little
    faster than __pa(), but there is nothing wrong in using __pa() on symbols.

    > Other
    > functions such as p*d_populate may call __pa internally. Ensure that the
    > address passed is in the linear region by calling lm_alias.

    Why it should be linear mapping address? __pa() translates kernel image address just fine.
    This lm_alias() only obfuscates source code. Generated code is probably worse too.


    \
     
     \ /
      Last update: 2016-12-01 15:10    [W:4.177 / U:0.376 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site