Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • L linux
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Kirill Smelkov
  • linux
  • Repository
  • linux
  • lib
  • usercopy.c
Find file BlameHistoryPermalink
  • Arnd Bergmann's avatar
    uaccess: always export _copy_[from|to]_user with CONFIG_RUST · 1f9a8286
    Arnd Bergmann authored May 28, 2024
    
    
    Rust code needs to be able to access _copy_from_user and _copy_to_user
    so that it can skip the check_copy_size check in cases where the length
    is known at compile-time, mirroring the logic for when C code will skip
    check_copy_size. To do this, we ensure that exported versions of these
    methods are available when CONFIG_RUST is enabled.
    
    Alice has verified that this patch passes the CONFIG_TEST_USER_COPY test
    on x86 using the Android cuttlefish emulator.
    
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Tested-by: default avatarAlice Ryhl <aliceryhl@google.com>
    Reviewed-by: default avatarBoqun Feng <boqun.feng@gmail.com>
    Reviewed-by: default avatarKees Cook <keescook@chromium.org>
    Signed-off-by: default avatarAlice Ryhl <aliceryhl@google.com>
    Acked-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Link: https://lore.kernel.org/r/20240528-alice-mm-v7-2-78222c31b8f4@google.com
    
    
    Signed-off-by: default avatarMiguel Ojeda <ojeda@kernel.org>
    1f9a8286
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7