Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linux 5.15 compat: block device readahead #12532

Merged
merged 1 commit into from
Sep 8, 2021

Commits on Sep 2, 2021

  1. Linux 5.15 compat: block device readahead

    The 5.15 kernel moved the backing_dev_info structure out of
    the request queue structure which causes a build failure.
    
    Rather than look in the new location for the BDI we instead
    detect this upstream refactoring by the existance of either
    the blk_queue_update_readahead() or disk_update_readahead()
    functions.  In either case, there's no longer any reason to
    manually set the ra_pages value since it will be overridden
    with a reasonable default (2x the block size) when
    blk_queue_io_opt() is called.
    
    Therefore, we update the compatibility wrapper to do nothing
    for 5.9 and newer kernels.  While it's tempting to do the
    same for older kernels we want to keep the compatibility
    code to preserve the existing behavior.  Removing it would
    effectively increase the default readahead to 128k.
    
    Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
    behlendorf committed Sep 2, 2021
    Configuration menu
    Copy the full SHA
    199e14c View commit details
    Browse the repository at this point in the history