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.5 compat: blkg_tryget() #10072

Merged
merged 1 commit into from
Feb 28, 2020
Merged

Conversation

behlendorf
Copy link
Contributor

@behlendorf behlendorf commented Feb 27, 2020

Motivation and Context

Issue #9745. Compilation failure for distribution provided Linux 5.5 kernels.

Description

Commit torvalds/linux@9e8d42a0f accidentally converted the static inline
function blkg_tryget() to GPL-only for kernels built with CONFIG_PREEMPT_RCU=y
and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivilant functionality
when needed which uses rcu_read_lock_sched() internally as before.

How Has This Been Tested?

Locally compiled against a Linux 5.5 kernel configured with PREEMPT_RCU and
BLK_CGROUP enabled.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Performance enhancement (non-breaking change which improves efficiency)
  • Code cleanup (non-breaking change which makes code smaller or more readable)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (a change to man pages or other documentation)

Checklist:

  • My code follows the ZFS on Linux code style requirements.
  • I have updated the documentation accordingly.
  • I have read the contributing document.
  • I have added tests to cover my changes.
  • I have run the ZFS Test Suite with this change applied.
  • All commit messages are properly formatted and contain Signed-off-by.

@behlendorf behlendorf added the Type: Building Indicates an issue related to building binaries label Feb 27, 2020
Commit torvalds/linux@9e8d42a0f accidentally
converted the static inline function blkg_tryget() to GPL-only for
kernels built with CONFIG_PREEMPT_RCU=y and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivilant functionality
when needed which uses rcu_read_lock_sched() internally as before.

Signed-off-by: Brian Behlendorf <[email protected]>
Issue openzfs#9745
@behlendorf behlendorf changed the title Linux 5.4 compat: blkg_tryget() Linux 5.5 compat: blkg_tryget() Feb 27, 2020
@codecov-io
Copy link

Codecov Report

Merging #10072 into master will decrease coverage by 13%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #10072      +/-   ##
==========================================
- Coverage      79%      67%     -13%     
==========================================
  Files         386      304      -82     
  Lines      122316   105116   -17200     
==========================================
- Hits        97059    70194   -26865     
- Misses      25257    34922    +9665
Flag Coverage Δ
#kernel ?
#user 67% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3d5ba1c...e8ba972. Read the comment docs.

@behlendorf behlendorf added the Status: Accepted Ready to integrate (reviewed, tested) label Feb 28, 2020
@behlendorf behlendorf merged commit bd0d24e into openzfs:master Feb 28, 2020
behlendorf added a commit to behlendorf/zfs that referenced this pull request Feb 28, 2020
Commit torvalds/linux@9e8d42a0f accidentally
converted the static inline function blkg_tryget() to GPL-only for
kernels built with CONFIG_PREEMPT_RCU=y and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivalent functionality
when needed which uses rcu_read_lock_sched() internally as before.

Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#9745
Closes openzfs#10072
frebib added a commit to frebib/archzfs that referenced this pull request Feb 29, 2020
minextu added a commit to archzfs/archzfs that referenced this pull request Feb 29, 2020
* Add Linux 5.5 compat patch

Upstream fix: openzfs/zfs#10072

* Update src/zfs/PKGBUILD.sh

Co-authored-by: Jan Houben <[email protected]>
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Apr 22, 2020
Commit torvalds/linux@9e8d42a0f accidentally
converted the static inline function blkg_tryget() to GPL-only for
kernels built with CONFIG_PREEMPT_RCU=y and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivalent functionality
when needed which uses rcu_read_lock_sched() internally as before.

Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#9745
Closes openzfs#10072
tonyhutter pushed a commit to tonyhutter/zfs that referenced this pull request Apr 22, 2020
Commit torvalds/linux@9e8d42a0f accidentally
converted the static inline function blkg_tryget() to GPL-only for
kernels built with CONFIG_PREEMPT_RCU=y and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivalent functionality
when needed which uses rcu_read_lock_sched() internally as before.

Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#9745
Closes openzfs#10072
tonyhutter pushed a commit that referenced this pull request May 12, 2020
Commit torvalds/linux@9e8d42a0f accidentally
converted the static inline function blkg_tryget() to GPL-only for
kernels built with CONFIG_PREEMPT_RCU=y and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivalent functionality
when needed which uses rcu_read_lock_sched() internally as before.

Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #9745
Closes #10072
snajpa pushed a commit to vpsfreecz/zfs that referenced this pull request May 28, 2020
Commit torvalds/linux@9e8d42a0f accidentally
converted the static inline function blkg_tryget() to GPL-only for
kernels built with CONFIG_PREEMPT_RCU=y and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivalent functionality
when needed which uses rcu_read_lock_sched() internally as before.

Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#9745
Closes openzfs#10072
Signed-off-by: Pavel Snajdr <[email protected]>
jsai20 pushed a commit to jsai20/zfs that referenced this pull request Mar 30, 2021
Commit torvalds/linux@9e8d42a0f accidentally
converted the static inline function blkg_tryget() to GPL-only for
kernels built with CONFIG_PREEMPT_RCU=y and CONFIG_BLK_CGROUP=y.

Resolve the build issue by providing our own equivalent functionality
when needed which uses rcu_read_lock_sched() internally as before.

Reviewed-by: Tony Hutter <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#9745
Closes openzfs#10072
@behlendorf behlendorf deleted the issue-9745 branch April 19, 2021 19:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Accepted Ready to integrate (reviewed, tested) Type: Building Indicates an issue related to building binaries
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants