Skip to content
GitLab
    • GitLab: the DevOps platform
    • Explore GitLab
    • Install GitLab
    • How GitLab compares
    • Get started
    • GitLab docs
    • GitLab Learn
  • Pricing
  • Talk to an expert
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
    Projects Groups Topics Snippets
  • Register
  • Sign in
  • A android_kernel_xiaomi_violet
  • 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
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ubuntu-touch-xiaomi-violet
  • android_kernel_xiaomi_violet
  • Repository
  • android_kernel_xiaomi_violet
  • drivers
  • base
  • platform.c
Find file BlameHistoryPermalink
  • Nicolai Stange's avatar
    driver core: platform: Don't read past the end of "driver_override" buffer · bf563b01
    Nicolai Stange authored Sep 11, 2017
    When printing the driver_override parameter when it is 4095 and 4094 bytes
    long, the printing code would access invalid memory because we need count+1
    bytes for printing.
    
    Reject driver_override values of these lengths in driver_override_store().
    
    This is in close analogy to commit 4efe874a ("PCI: Don't read past the
    end of sysfs "driver_override" buffer") from Sasha Levin.
    
    Fixes: 3d713e0e
    
     ("driver core: platform: add device binding path 'driver_override'")
    Cc: stable@vger.kernel.org	# v3.17+
    Signed-off-by: default avatarNicolai Stange <nstange@suse.de>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    bf563b01