Skip to contentSkip to conversation

x86/fpu: allow kernel_fpu_{begin,end} to be used by non-GPL modules

PATCH In review Aleksa Sarai 3 participants 3 messages May 22, 2019 – May 23, 2019 x86

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86/fpu: allow kernel_fpu_{begin,end} to be used by non-GPL modules

Prior to [1], all non-GPL modules were able to make use of SIMD on x86 by making use of the __kernel_fpu_* API. Given that __kernel_fpu_* were both EXPORT_SYMBOL'd and kernel_fpu_* are such trivial wrappers around the now-static __kernel_fpu_*, it seems to me that there is no reason to have different licensing rules for them.

In the case of OpenZFS, the lack of SIMD on newer Linux kernels has caused significant performance problems (since ZFS uses SIMD for calculation of blkptr checksums as well as raidz calculations).

[1]: commit 12209993e98c ("x86/fpu: Don't export __kernel_fpu_{begin,end}()")

Cc "Jason A. Donenfeld" <[email protected]>
---
 arch/x86/kernel/fpu/core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/fpu/core.c +2 -2
index 2e5003fef51a..8de5687a470d 100644
@@ -127,14 +127,14 @@ void kernel_fpu_begin(void)
 	preempt_disable();
 	__kernel_fpu_begin();
 }
-EXPORT_SYMBOL_GPL(kernel_fpu_begin);
+EXPORT_SYMBOL(kernel_fpu_begin);
 
 void kernel_fpu_end(void)
 {
 	__kernel_fpu_end();
 	preempt_enable();
 }
-EXPORT_SYMBOL_GPL(kernel_fpu_end);
+EXPORT_SYMBOL(kernel_fpu_end);
 
 /*
  * Save the FPU state (mark it for reload if necessary):
Signature · 1 line
2.21.0
#1 lore raw
Quoted 26 lines · Aleksa Sarai

Prior to [1], all non-GPL modules were able to make use of SIMD on x86 by making use of the __kernel_fpu_* API. Given that __kernel_fpu_* were both EXPORT_SYMBOL'd and kernel_fpu_* are such trivial wrappers around the now-static __kernel_fpu_*, it seems to me that there is no reason to have different licensing rules for them.

In the case of OpenZFS, the lack of SIMD on newer Linux kernels has caused significant performance problems (since ZFS uses SIMD for calculation of blkptr checksums as well as raidz calculations).

[1]: commit 12209993e98c ("x86/fpu: Don't export __kernel_fpu_{begin,end}()")

Cc "Jason A. Donenfeld" <[email protected]>
---
 arch/x86/kernel/fpu/core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/fpu/core.c +0 -0
index 2e5003fef51a..8de5687a470d 100644
@@ -127,14 +127,14 @@ void kernel_fpu_begin(void)
 	preempt_disable();
 	__kernel_fpu_begin();
 }

arch/x86/kernel/fpu/core.c void kernel_fpu_begin(void) · line 137

Quoted 10 lines
arch/x86/kernel/fpu/core.c +2 -2
-EXPORT_SYMBOL_GPL(kernel_fpu_begin);
+EXPORT_SYMBOL(kernel_fpu_begin);
 
 void kernel_fpu_end(void)
 {
 	__kernel_fpu_end();
 	preempt_enable();
 }
-EXPORT_SYMBOL_GPL(kernel_fpu_end);
+EXPORT_SYMBOL(kernel_fpu_end);

No, please, we have gone over this before, we do not care at all about external kernel modules, ESPECIALLY ones that are not GPL compatible.

greg k-h

#2 lore raw
Quoted 2 lines · Greg KH

No, please, we have gone over this before, we do not care at all about external kernel modules, ESPECIALLY ones that are not GPL compatible.

The best option here is for you to start caring. Makes the world a better place.

Free software people doing what they can to attack other free software based on relatively trivial idealogical differences isn't a good look, and it's bad for the users.

Signature · 2 lines
Mason Loring Bliss  ((   If I have not seen as far as others, it is because
 [email protected]   ))   giants were standing on my shoulders. - Hal Abelson