Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • L linux-iv
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • linux-arm
  • linux-iv
  • Repository
Switch branch/tag
  • linux-iv
  • kernel
  • relay.c
Find file BlameHistoryPermalink
  • Jani Nikula's avatar
    relay: allow the use of const callback structs · 5edf0cf0
    Jani Nikula authored Nov 24, 2020
    None of the relay users require the use of mutable structs for callbacks,
    however the relay code does.  Instead of assigning the default callback
    for subbuf_start, add a wrapper to conditionally call the client callback
    if available, and fall back to default behaviour otherwise.
    
    This lets all relay users make their struct rchan_callbacks const data.
    
    Link: https://lkml.kernel.org/r/cc3ff292e4eb4fdc56bee3d690c7b8e39209cd37.1606153547.git.jani.nikula@intel.com
    
    
    Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
    Cc: Jens Axboe <axboe@kernel.dk>
    Cc: Kalle Valo <kvalo@codeaurora.org>
    Cc: Christoph Hellwig <hch@infradead.org>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
    5edf0cf0