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

ZoL 0.7.13 + Linux Kernel 5.0.4: GPL-incompatible module zfs.ko uses GPL-only symbol 'preempt_schedule_notrace' #8545

Closed
grahamc opened this issue Mar 29, 2019 · 34 comments
Labels
Type: Architecture Indicates an issue is specific to a single processor architecture Type: Building Indicates an issue related to building binaries

Comments

@grahamc
Copy link
Contributor

grahamc commented Mar 29, 2019

System information

Type Version/Name
Distribution Name NixOS
Distribution Version 19.03 (beta)
Linux Kernel 5.0.4
Architecture aarch64-linux
ZFS Version 0.7.13
SPL Version 0.7.13

Describe the problem you're observing

Kernel module build fails in MODPOST:

  LD [M]  /build/source/module/zfs/zfs.o
  Building modules, stage 2.
  MODPOST 7 modules
FATAL: modpost: GPL-incompatible module zfs.ko uses GPL-only symbol 'preempt_schedule_notrace'

I'm also seeing the following warnings:

In file included from /build/source/module/zfs/vdev_raidz_math_aarch64_neon.c:30:0:
/build/source/module/zfs/vdev_raidz_math_aarch64_neon_common.h:126:0: warning: "ASM_BUG" redefined
 #define ASM_BUG() ASSERT(0)
                 from /build/source/module/zfs/vdev_raidz_math_aarch64_neon.c:26:
/nix/store/avplvw4j265f6brz3g368sqrlzkyabas-linux-5.0.4-dev/lib/modules/5.0.4/source/arch/arm64/include/asm/asm-bug.h:52:0: note: this is the location of the previous definition
 #define ASM_BUG() ASM_BUG_FLAGS(0)
In file included from /build/source/module/zfs/vdev_raidz_math_aarch64_neonx2.c:29:0:
/build/source/module/zfs/vdev_raidz_math_aarch64_neon_common.h:126:0: warning: "ASM_BUG" redefined
 #define ASM_BUG() ASSERT(0)
                 from /build/source/module/zfs/vdev_raidz_math_aarch64_neonx2.c:29:
/nix/store/avplvw4j265f6brz3g368sqrlzkyabas-linux-5.0.4-dev/lib/modules/5.0.4/source/arch/arm64/include/asm/asm-bug.h:52:0: note: this is the location of the previous definition
 #define ASM_BUG() ASM_BUG_FLAGS(0)

Describe how to reproduce the problem

Attempt to compile the module. In this particular case, if you have a machine with Nix running aarch64:

nix-build https://github.com/nixos/nixpkgs/archive/23fd1394dc6bef03a2ff010278a24403a97f0647.tar.gz --system aarch64-linux -A linuxPackages_5_0.zfs

Include any warning/errors/backtraces from the system logs

@grahamc
Copy link
Contributor Author

grahamc commented Mar 29, 2019

The following have the same problem:

  • 0.7.13 / 5.0.3 nix-build https://github.com/nixos/nixpkgs/archive/bf3c19558244f038dce7993274da241e72e03da1.tar.gz --system aarch64-linux -A linuxPackages_5_0.zfs
  • 0.7.13 / 5.0.2 (nix-build https://github.com/nixos/nixpkgs/archive/e6b124b3b57eb327f777349086a8a67325f6c949.tar.gz --system aarch64-linux -A linuxPackages_5_0.zfs)
  • 0.7.13 / 5.0.1 (nix-build https://github.com/nixos/nixpkgs/archive/2aa471997fd485a0678acb4b5d470da2f8eebbcb.tar.gz --system aarch64-linux -A linuxPackages_5_0.zfs)

@nilsmeyer
Copy link

As far as I can tell this has always been EXPORT_SYMBOL_GPL, did you set CONFIG_PREEMPT?

@grahamc
Copy link
Contributor Author

grahamc commented Mar 29, 2019

Hmm, yeah ... Not sure what is going on there. I do have CONFIG_PREEMPT set, attached is the full config.

config.txt

@grahamc
Copy link
Contributor Author

grahamc commented Mar 29, 2019

The last time NixOS was able to build ZFS on aarch64 for the latest stable was 4.19.12, I'll start bisecting.

@behlendorf behlendorf added the Type: Building Indicates an issue related to building binaries label Mar 29, 2019
@grahamc
Copy link
Contributor Author

grahamc commented Mar 29, 2019

I bisected 5.0 to 4.19 and torvalds/linux@0e9da3f is the first offending commit

Based on git merge-base b12a912 00203ba (the two parents of 0e9da3f), I've tried bisecting 40e020c129cfc991e8ab4736d2665351ffd1468d to 00203ba40d40d7f33857416adfb18adaf0e40123 but both ends built just fine.

My colleague is rebasing torvalds/linux@0e9da3f on to torvalds/linux@b12a912 and I'll be bisect that next.

@grahamc
Copy link
Contributor Author

grahamc commented Mar 30, 2019

OK I finished that rebase, and it narrowed down to this commit: torvalds/linux@7fcf2b0 -- calling it a day for now, and will look more tomorrow.

@grahamc
Copy link
Contributor Author

grahamc commented Mar 30, 2019

Attached are build logs and the results of the original attempted build (nix-build https://github.com/nixos/nixpkgs/archive/23fd1394dc6bef03a2ff010278a24403a97f0647.tar.gz --system aarch64-linux -A linuxPackages_5_0.zfs)

objdump (attached) shows https://github.com/zfsonlinux/zfs/blob/a8c2b7ebc64d23ffe15e2b168aa0bea7a4897133/module/zfs/vdev_disk.c#L702-L779 is calling preempt_schedule_notrace

@behlendorf
Copy link
Contributor

@grahamc thanks for isolating the offending commit. It looks like when they switched over to using percpu_ref's in blkg_tryget() they inadvertently converted it to the GPL-only symbol. This looks to be specific to the way preemption is handled on aarch64.

This code is pulled in though the CONFIG_BLK_CGROUP option. So if you can live without this functionality you could try disabling it until we find a good way to handle this.

@grahamc
Copy link
Contributor Author

grahamc commented Apr 4, 2019

Ah, excellent! Unfortunately, I can't turn that off so that workaround doesn't apply for me. However, I'm able to use 4.19 for the the next 4-5 months.

Thank you for doing this research and getting to the workaround!

@behlendorf behlendorf added the Type: Architecture Indicates an issue is specific to a single processor architecture label Apr 4, 2019
@vcunat
Copy link

vcunat commented Apr 4, 2019

So, in NixOS we give up on ZFS in latest-kernel stuff for aarch64? (example)

@grahamc
Copy link
Contributor Author

grahamc commented Apr 4, 2019

Something like that, but let's move that discussion to our own issue tracker NixOS/nixpkgs#58959 :)

behlendorf added a commit to behlendorf/zfs that referenced this issue May 7, 2019
The 5.0 kernel defines the macro ASM_BUG.  In order to prevent a
conflict and build failure rename ASM_BUG to ZFS_ASM_BUG.  This
is currently only an issue on aarch64 but all instances of
ASM_BUG we're renamed to avoid any future conflict on x86_64.

Signed-off-by: Brian Behlendorf <[email protected]>
Issue openzfs#8545
@behlendorf
Copy link
Contributor

@grahamc I've opened PR #8725 which resolves the ASM_BUG warnings you observed when compiling for aarch64. Regarding the original preempt_schedule_notrace issue, I discovered that neither the stock Fedora 29 or Ubuntu 19.04 aarch64 kernels encountered this issue. The reason for this is they set CONFIG_PREEMPT_VOLUNTARY=y instead of CONFIG_PREEMPT=y in their kernel config. Would this be a viable solution for NixOS?

@nilsmeyer
Copy link

I'm also wondering if this may be a general issue with CONFIG_PREEMPT or only on aarch64?

@lheckemann
Copy link

lheckemann commented May 8, 2019

I've tried disabling PREEMPT, but am still getting the same error with 5.0.9:

$ grep PREEMPT .config
# CONFIG_PREEMPT_NONE is not set
CONFIG_PREEMPT_VOLUNTARY=y
# CONFIG_PREEMPT is not set
CONFIG_PREEMPT_NOTIFIERS=y
# CONFIG_PREEMPTIRQ_EVENTS is not set
CONFIG_PREEMPTIRQ_DELAY_TEST=m

Please disregard, that works wonderfully. Thanks, @behlendorf !

behlendorf added a commit that referenced this issue May 8, 2019
The 5.0 kernel defines the macro ASM_BUG.  In order to prevent a
conflict and build failure rename ASM_BUG to ZFS_ASM_BUG.  This
is currently only an issue on aarch64 but all instances of
ASM_BUG we're renamed to avoid any future conflict on x86_64.

Reviewed-by: Tomohiro Kusumi <[email protected]>
Reviewed-by: Richard Laager <[email protected]>
Reviewed-by: Chris Dunlop <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes #8725 
Issue #8545
@behlendorf
Copy link
Contributor

may be a general issue with CONFIG_PREEMPT

This does look like it may be a general issue, but I haven't confirmed that. The ASM_BUG fix has been committed and we'll back port it to 0.7.14.

@lheckemann
Copy link

I'm currently checking if this also occurs on x86_64 with CONFIG_PREEMPT=y.

@lheckemann
Copy link

lheckemann commented May 8, 2019

This doesn't seem to affect my x86_64 build of the kernel (i.e. zfs builds fine even with CONFIG_PREEMPT=y — either it's truly an aarch64-specific issue, or there are some other config settings involved.

@nilsmeyer
Copy link

So the build should probably fail if aarch64 && CONFIG_PREEMPT? At the very least a better error message can be displayed.

@behlendorf
Copy link
Contributor

That's a good idea. This is something we could catch earlier at configure time.

@lheckemann
Copy link

Yes, but also only from 5.0 onwards.

pvdabeel pushed a commit to pvdabeel/gentoo that referenced this issue Jun 3, 2019
Upstream-issue: openzfs/zfs#8545
Package-Manager: Portage-2.3.67, Repoman-2.3.13
Signed-off-by: Georgy Yakovlev <[email protected]>
allanjude pushed a commit to allanjude/zfs that referenced this issue Jun 7, 2019
The 5.0 kernel defines the macro ASM_BUG.  In order to prevent a
conflict and build failure rename ASM_BUG to ZFS_ASM_BUG.  This
is currently only an issue on aarch64 but all instances of
ASM_BUG we're renamed to avoid any future conflict on x86_64.

Reviewed-by: Tomohiro Kusumi <[email protected]>
Reviewed-by: Richard Laager <[email protected]>
Reviewed-by: Chris Dunlop <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#8725 
Issue openzfs#8545
allanjude pushed a commit to allanjude/zfs that referenced this issue Jun 15, 2019
The 5.0 kernel defines the macro ASM_BUG.  In order to prevent a
conflict and build failure rename ASM_BUG to ZFS_ASM_BUG.  This
is currently only an issue on aarch64 but all instances of
ASM_BUG we're renamed to avoid any future conflict on x86_64.

Reviewed-by: Tomohiro Kusumi <[email protected]>
Reviewed-by: Richard Laager <[email protected]>
Reviewed-by: Chris Dunlop <[email protected]>
Signed-off-by: Brian Behlendorf <[email protected]>
Closes openzfs#8725 
Issue openzfs#8545
@crocket
Copy link

crocket commented Sep 9, 2019

It also affects PREEMPT_RT_FULL since PREEMPT_RT_FULL selects PREEMPT.

@prometheanfire
Copy link
Contributor

I seem to be hitting this on aarch64 with a kernel config set to CONFIG_PREEMPT_NONE in the kconfig (but not running config)

@prometheanfire
Copy link
Contributor

also of note, I was trying to install zfs master on 5.2.14

@satmandu
Copy link
Contributor

satmandu commented May 2, 2020

Is there any chance of the issue with preempt_schedule_notrace on aarch64 being tracked down further? I'm still seeing it with the other preempt patch in #10209 with a 5.4.x kernel. and PREEMPT set:

(This is in the default kernel config for the default 5.4 kernels put out for the Raspberry Pi by the Raspberry Pi Foundation.)

# CONFIG_PREEMPT_NONE is not set
# CONFIG_PREEMPT_VOLUNTARY is not set
CONFIG_PREEMPT=y
CONFIG_PREEMPT_COUNT=y
CONFIG_PREEMPTION=y
CONFIG_PREEMPT_RCU=y
CONFIG_PREEMPT_NOTIFIERS=y
CONFIG_DEBUG_PREEMPT=y
CONFIG_PREEMPTIRQ_TRACEPOINTS=y
# CONFIG_PREEMPTIRQ_EVENTS is not set
# CONFIG_PREEMPT_TRACER is not set
# CONFIG_PREEMPTIRQ_DELAY_TEST is not set
  CC [M]  /var/lib/dkms/zfs/0.8.4/build/module/zfs/qat_crypt.o
  CC [M]  /var/lib/dkms/zfs/0.8.4/build/module/zfs/vdev_raidz_math_aarch64_neon.o
  CC [M]  /var/lib/dkms/zfs/0.8.4/build/module/zfs/vdev_raidz_math_aarch64_neonx2.o
  LD [M]  /var/lib/dkms/zfs/0.8.4/build/module/zfs/zfs.o
  Building modules, stage 2.
  MODPOST 8 modules
FATAL: modpost: GPL-incompatible module zfs.ko uses GPL-only symbol 'preempt_schedule_notrace'
make[4]: *** [scripts/Makefile.modpost:94: __modpost] Error 1
make[3]: *** [Makefile:1607: modules] Error 2
make[3]: Leaving directory '/usr/src/linux-headers-5.4.35-v8+'
make[2]: *** [Makefile:30: modules] Error 2
make[2]: Leaving directory '/var/lib/dkms/zfs/0.8.4/build/module'
make[1]: *** [Makefile:841: all-recursive] Error 1
make[1]: Leaving directory '/var/lib/dkms/zfs/0.8.4/build'
make: *** [Makefile:710: all] Error 2

@prometheanfire
Copy link
Contributor

this seems fixed in git master, building against 5.7.8

JayBeavers pushed a commit to JayBeavers/MyPKGBUILDs that referenced this issue Jul 16, 2020
iwcfg requires various crypto changes
zfs-dkms requires CONFIG_PREEMPT_VOLUNTARY=y due to a mixed GPL license warning

See moonman#7 for a discussion of iwcfg/crypto
See openzfs/zfs#8545 for a discussion of CONFIG_PREEMPT_VOLUNTARY
JayBeavers pushed a commit to JayBeavers/MyPKGBUILDs that referenced this issue Jul 16, 2020
JayBeavers pushed a commit to JayBeavers/MyPKGBUILDs that referenced this issue Jul 16, 2020
iwcfg requires various crypto changes
zfs-dkms requires CONFIG_PREEMPT_VOLUNTARY=y due to a mixed GPL license warning

See moonman#7 for a discussion of iwcfg/crypto
See openzfs/zfs#8545 for a discussion of CONFIG_PREEMPT_VOLUNTARY
@jinnko
Copy link

jinnko commented Jul 17, 2020

Building master didn't work on Aarch64 with kernel 5.4.49 using Armbian on a NanoPi M4v2.

This is the final output:

  Building modules, stage 2.
  MODPOST 8 modules
FATAL: modpost: GPL-incompatible module zfs.ko uses GPL-only symbol 'preempt_schedule_notrace'
make[6]: *** [scripts/Makefile.modpost:94: __modpost] Error 1
make[5]: *** [Makefile:1619: modules] Error 2
make[5]: Leaving directory '/usr/src/linux-headers-5.4.49-rockchip64'
make[4]: *** [Makefile:48: modules-Linux] Error 2
make[4]: Leaving directory '/tmp/zfs-build-root-rdNNDtJ4/BUILD/zfs-kmod-0.8.0/_kmod_build_5.4.49-rockchip64/module'
make[3]: *** [Makefile:871: all-recursive] Error 1
make[3]: Leaving directory '/tmp/zfs-build-root-rdNNDtJ4/BUILD/zfs-kmod-0.8.0/_kmod_build_5.4.49-rockchip64'
make[2]: *** [Makefile:734: all] Error 2
make[2]: Leaving directory '/tmp/zfs-build-root-rdNNDtJ4/BUILD/zfs-kmod-0.8.0/_kmod_build_5.4.49-rockchip64'
error: Bad exit status from /tmp/zfs-build-root-rdNNDtJ4/TMP/rpm-tmp.M7gP99 (%build)


RPM build errors:
    Bad exit status from /tmp/zfs-build-root-rdNNDtJ4/TMP/rpm-tmp.M7gP99 (%build)
make[1]: *** [Makefile:1613: rpm-common] Error 1
make[1]: Leaving directory '/usr/src/zfs'
make: *** [Makefile:1564: rpm-kmod] Error 2

@prometheanfire
Copy link
Contributor

guess there may still be problems with 5.4 then

@satmandu
Copy link
Contributor

satmandu commented Sep 1, 2020

FYI Ubuntu has a workaround for this now: https://git.launchpad.net/ubuntu/+source/zfs-linux/commit/?h=applied/ubuntu/devel&id=e7c101ed4b81cb3c2eda8abba0b50fedac5d6bab

Also at https://git.launchpad.net/ubuntu/+source/zfs-linux/tree/debian/patches/4700-Fix-DKMS-build-on-arm64-with-PREEMPTION-and-BLK_CGRO.patch

From 46cd180400093965271820d34fa1071f9769a0fb Mon Sep 17 00:00:00 2001
From: Juerg Haefliger <[email protected]>
Date: Tue, 18 Aug 2020 10:52:25 +0200
Subject: [PATCH] Fix DKMS build on arm64 with PREEMPTION and BLK_CGROUP
 enabled

With PREEMPTION=y and BLK_CGROUP=y preempt_schedule_notrace() is being
used on arm64 which is a GPL-only function and hence the build of the
DKMS kernel module fails.

'Fix' that by redefining preempt_schedule_notrace() to preempt_schedule()
which should be safe as long as tracing is not used.

Signed-off-by: Juerg Haefliger <[email protected]>
---
 module/zfs/vdev_disk.c  |  2 ++
 module/zfs/zfs_compat.h | 14 ++++++++++++++
 2 files changed, 16 insertions(+)
 create mode 100644 module/zfs/zfs_compat.h

diff --git a/module/zfs/vdev_disk.c b/module/zfs/vdev_disk.c
index 8544bb8ffb6f..2a7096a6436d 100644
--- a/module/zfs/vdev_disk.c
+++ b/module/zfs/vdev_disk.c
@@ -26,6 +26,8 @@
  * Copyright (c) 2012, 2019 by Delphix. All rights reserved.
  */
 
+#include "zfs_compat.h"
+
 #include <sys/zfs_context.h>
 #include <sys/spa_impl.h>
 #include <sys/vdev_disk.h>
diff --git a/module/zfs/zfs_compat.h b/module/zfs/zfs_compat.h
new file mode 100644
index 000000000000..6ef26f436f3c
--- /dev/null
+++ b/module/zfs/zfs_compat.h
@@ -0,0 +1,14 @@
+#ifndef _ZFS_COMPAT_H_
+#define _ZFS_COMPAT_H_
+
+/*
+ * preempt_schedule_notrace is GPL-only which breaks the ZFS build, so
+ * replace it with preempt_schedule under the following condition:
+*/
+#if defined(CONFIG_ARM64) && \
+    defined(CONFIG_PREEMPTION) && \
+    defined(CONFIG_BLK_CGROUP)
+#define preempt_schedule_notrace(x) preempt_schedule(x)
+#endif
+
+#endif /* _ZFS_COMPAT_H_ */
-- 
2.25.1

Also should be noted for: #6146 #9745 #9948 #10416

@neszt
Copy link

neszt commented Sep 23, 2020

Aarch64 with kernel 5.8.10 using Armbian on a Rock64

MODPOST /var/lib/dkms/zfs/0.8.4/build/module/Module.symvers
FATAL: modpost: GPL-incompatible module zfs.ko uses GPL-only symbol 'preempt_schedule_notrace'
make[4]: *** [scripts/Makefile.modpost:111: /var/lib/dkms/zfs/0.8.4/build/module/Module.symvers] Error 1
make[3]: *** [Makefile:1665: modules] Error 2
make[3]: Leaving directory '/usr/src/linux-headers-5.8.10-rockchip64'
make[2]: *** [Makefile:30: modules] Error 2
make[2]: Leaving directory '/var/lib/dkms/zfs/0.8.4/build/module'
make[1]: *** [Makefile:808: all-recursive] Error 1
make[1]: Leaving directory '/var/lib/dkms/zfs/0.8.4/build'
make: *** [Makefile:677: all] Error 2
root@rock64:/# uname -a
Linux rock64 5.8.10-rockchip64 #20.08.3 SMP PREEMPT Fri Sep 18 11:05:12 CEST 2020 aarch64 GNU/Linux

behlendorf pushed a commit to behlendorf/zfs that referenced this issue Sep 23, 2020
used on arm64 which is a GPL-only function and hence the build of the
DKMS kernel module fails.

'Fix' that by redefining preempt_schedule_notrace() to preempt_schedule()
which should be safe as long as tracing is not used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Juerg Haefliger <[email protected]>
Issue openzfs#8545
@behlendorf
Copy link
Contributor

I've gone ahead and opened PR #10973 with a version of the patch applied to Ubuntu. It'd be great if someone could verify this version of the patch resolves the issue. @satmandu @neszt @grahamc

@satmandu
Copy link
Contributor

@behlendorf The patch works for me with the RPI arm64 kernel at Hexxeh/rpi-firmware@a995f0c:

modprobe configs && zcat /proc/config.gz | grep PREEMPT
# CONFIG_PREEMPT_NONE is not set
# CONFIG_PREEMPT_VOLUNTARY is not set
CONFIG_PREEMPT=y
CONFIG_PREEMPT_COUNT=y
CONFIG_PREEMPTION=y
CONFIG_PREEMPT_RCU=y
CONFIG_PREEMPT_NOTIFIERS=y
CONFIG_DEBUG_PREEMPT=y
CONFIG_PREEMPTIRQ_TRACEPOINTS=y
# CONFIG_PREEMPTIRQ_EVENTS is not set
# CONFIG_PREEMPT_TRACER is not set
# CONFIG_PREEMPTIRQ_DELAY_TEST is not set
satadru@rpi4b ~$ dmesg | grep 'PREEMPT\|ZFS\|taint'
[    0.000000] Linux version 5.4.65-v8+ (dom@buildbot) (gcc version 5.4.0 20160609 (Ubuntu/Linaro 5.4.0-6ubuntu1~16.04.9)) #1341 SMP PREEMPT Tue Sep 15 13:20:32 BST 2020
[    5.396685] spl: loading out-of-tree module taints kernel.
[    5.435122] icp: module license 'CDDL' taints kernel.
[    5.435137] Disabling lock debugging due to kernel taint
[    8.016244] ZFS: Loaded module v2.0.0-rc1, ZFS pool version 5000, ZFS filesystem version 5
satadru@rpi4b ~$ uname -a
Linux rpi4b 5.4.65-v8+ #1341 SMP PREEMPT Tue Sep 15 13:20:32 BST 2020 aarch64 GNU/Linux

tonyhutter pushed a commit to tonyhutter/zfs that referenced this issue Sep 28, 2020
With PREEMPTION=y and BLK_CGROUP=y preempt_schedule_notrace() is being
used on arm64 which is a GPL-only function and hence the build of the
DKMS kernel module fails.

Fix that by redefining preempt_schedule_notrace() to preempt_schedule()
which should be safe as long as tracing is not used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Juerg Haefliger <[email protected]>
Closes openzfs#8545 
Closes openzfs#9948 
Closes openzfs#10416 
Closes openzfs#10973
behlendorf added a commit that referenced this issue Oct 1, 2020
With PREEMPTION=y and BLK_CGROUP=y preempt_schedule_notrace() is being
used on arm64 which is a GPL-only function and hence the build of the
DKMS kernel module fails.

Fix that by redefining preempt_schedule_notrace() to preempt_schedule()
which should be safe as long as tracing is not used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Juerg Haefliger <[email protected]>
Closes #8545
Closes #9948
Closes #10416
Closes #10973
jsai20 pushed a commit to jsai20/zfs that referenced this issue Mar 30, 2021
With PREEMPTION=y and BLK_CGROUP=y preempt_schedule_notrace() is being
used on arm64 which is a GPL-only function and hence the build of the
DKMS kernel module fails.

Fix that by redefining preempt_schedule_notrace() to preempt_schedule()
which should be safe as long as tracing is not used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Juerg Haefliger <[email protected]>
Closes openzfs#8545 
Closes openzfs#9948 
Closes openzfs#10416 
Closes openzfs#10973
sempervictus pushed a commit to sempervictus/zfs that referenced this issue May 31, 2021
With PREEMPTION=y and BLK_CGROUP=y preempt_schedule_notrace() is being
used on arm64 which is a GPL-only function and hence the build of the
DKMS kernel module fails.

Fix that by redefining preempt_schedule_notrace() to preempt_schedule()
which should be safe as long as tracing is not used.

Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Juerg Haefliger <[email protected]>
Closes openzfs#8545 
Closes openzfs#9948 
Closes openzfs#10416 
Closes openzfs#10973
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Architecture Indicates an issue is specific to a single processor architecture Type: Building Indicates an issue related to building binaries
Projects
None yet
Development

No branches or pull requests