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
  • kernel
  • trace
  • trace.c
Find file BlameHistoryPermalink
  • Steven Rostedt's avatar
    tracing: Fix ifdef of snapshots to not prevent last_boot_info file · 6d02eefe
    Steven Rostedt authored Jul 19, 2024
    The mapping of the ring buffer to memory allocated at boot up will also
    expose a "last_boot_info" to help tooling to read the raw data from the
    last boot. As instances that have their ring buffer mapped to fixed
    memory cannot perform snapshots, they can either have the "snapshot" file
    or the "last_boot_info" file, but not both.
    
    The code that added the "last_boot_info" file failed to notice that the
    "snapshot" creation was inside a "#ifdef CONFIG_TRACER_SNAPSHOT" and
    incorrectly placed the creation of the "last_boot_info" file within the
    ifdef block. Not only does it cause a warning when CONFIG_TRACER_SNAPSHOT
    is not enabled, it also incorrectly prevents the file from appearing.
    
    Link: https://lore.kernel.org/all/20240719102640.718554-1-arnd@kernel.org/
    
    
    
    Cc: Masami Hiramatsu <mhiramat@kernel.org>
    Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
    Reported-by: default avatarArnd Bergmann <arnd@kernel.org>
    Link: https://lore.kernel.org/20240719101312.3d4ac707@rorschach.local.home
    Fixes: 7a1d1e4b
    
     ("tracing/ring-buffer: Add last_boot_info file to boot instance")
    Signed-off-by: default avatarSteven Rostedt (Google) <rostedt@goodmis.org>
    6d02eefe
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7