Re: [PATCH V4] LoongArch: Provide kernel fpu functions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2023/3/10 10:51, Huacai Chen wrote:
Provide kernel_fpu_begin()/kernel_fpu_end() to allow the kernel itself
to use fpu. They can be used by some other kernel components, e.g., the
AMDGPU graphic driver for DCN.

Actually, as Christoph suggested earlier, you should probably send this together with the amdgpu modifications so that "actual usage" of the interface is established.


Reported-by: WANG Xuerui <kernel@xxxxxxxxxx>
Tested-by: WANG Xuerui <kernel@xxxxxxxxxx>
Signed-off-by: Huacai Chen <chenhuacai@xxxxxxxxxxx>
---
V2: Use non-GPL exports and update commit messages.
V3: Add spaces for coding style.
V4: WARN_ON unexpected requests and use GPL exports again.

We should probably provide more archaeology or legal evidence as to why the in-kernel FPU ops must be GPL-only. After all the status quo is that among all arches that provide such ops, only the x86 ones are exported GPL, so if loongarch should go GPL for this interface then probably everyone else should too. It's not only affecting loongarch IMO.


  arch/loongarch/include/asm/fpu.h |  3 +++
  arch/loongarch/kernel/Makefile   |  2 +-
  arch/loongarch/kernel/kfpu.c     | 43 ++++++++++++++++++++++++++++++++
  3 files changed, 47 insertions(+), 1 deletion(-)
  create mode 100644 arch/loongarch/kernel/kfpu.c


--
WANG "xen0n" Xuerui

Linux/LoongArch mailing list: https://lore.kernel.org/loongarch/




[Index of Archives]     [Linux Kernel]     [Kernel Newbies]     [x86 Platform Driver]     [Netdev]     [Linux Wireless]     [Netfilter]     [Bugtraq]     [Linux Filesystems]     [Yosemite Discussion]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]

  Powered by Linux