• G
    clk: Fix debugfs_create_*() usage · 4c8326d5
    Geert Uytterhoeven 提交于
    When exposing data access through debugfs, the correct
    debugfs_create_*() functions must be used, matching the data
    types.
    
    Remove all casts from data pointers passed to debugfs_create_*()
    functions, as such casts prevent the compiler from flagging bugs.
    
    clk_core.rate and .accuracy are "unsigned long", hence casting
    their addresses to "u32 *" exposed the wrong halves on big-endian
    64-bit systems. Fix this by using debugfs_create_ulong() instead.
    
    Octal permissions are preferred, as they are easier to read than
    symbolic permissions. Hence replace "S_IRUGO" by "0444"
    throughout.
    Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be>
    [sboyd@codeaurora.org: Squash the octal change in too]
    Signed-off-by: NStephen Boyd <sboyd@codeaurora.org>
    4c8326d5
clk.c 97.1 KB