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
  • stackinit_kunit.c
Find file BlameHistoryPermalink
  • Kees Cook's avatar
    lib: stackinit: Adjust target string to 8 bytes for m68k · c2efa538
    Kees Cook authored Feb 27, 2024
    
    
    For reasons I cannot understand, m68k moves the start of the stack frame
    for consecutive calls to the same function if the function's test
    variable is larger than 8 bytes. This was only happening for the char
    array test (obviously), so adjust the length of the string for m68k
    only. I want the array size to be longer than "unsigned long" for every
    given architecture, so the other remain unchanged.
    
    Additionally adjust the error message to be a bit more clear about
    what's happened, and move the KUNIT check outside of the consecutive
    calls to minimize what happens between them.
    
    Reported-by: default avatarGuenter Roeck <linux@roeck-us.net>
    Closes: https://lore.kernel.org/lkml/a0d10d50-2720-4ecd-a2c6-c2c5e5aeee65@roeck-us.net/
    
    
    Tested-by: default avatarGuenter Roeck <linux@roeck-us.net>
    Reported-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
    Closes: https://lore.kernel.org/r/CAMuHMdX_g1tbiUL9PUQdqaegrEzCNN3GtbSvSBFYAL4TzvstFg@mail.gmail.com
    Closes: https://lore.kernel.org/r/CAMuHMdW6N40+0gGQ+LSrN64Mo4A0-ELAm0pR3gWQ0mNanyBuUQ@mail.gmail.com
    
    
    Tested-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
    Link: https://lore.kernel.org/all/a4bf4063-194f-4740-9c1d-88f9ab38b778@roeck-us.net
    
    
    Signed-off-by: default avatarKees Cook <keescook@chromium.org>
    c2efa538
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7