1. Please describe the problem: 5.12 kernels on ppc64le now have CONFIG_PPC_QUEUED_SPINLOCKS enabled. When building external modules that are not GPL, any use of spin locks ends up referencing "shared_processor", which is exported as GPL only. This causes builds to fail with an error like: ERROR: modpost: GPL-incompatible module XXX.ko uses GPL-only symbol 'shared_processor' Given that spin locks are one of the basic facilities for module code, this effectively makes it impossible to build/load almost any non GPL module on Fedora ppc64le. 2. What is the Version-Release number of the kernel: kernel-5.12.7-300.fc34.ppc64le, and corresponding kernel-devel. 3. Did it work previously in Fedora? If so, what kernel version did the issue *first* appear? Old kernels are available for download at https://koji.fedoraproject.org/koji/packageinfo?packageID=8 : Yes. The option was first enabled in 5.12 kernels. There was no issue using spin locks from non GPL module code in Fedora packaged 5.11 kernels. 4. Can you reproduce this issue? If so, please provide the steps to reproduce the issue below: This can be reproduced by building a non GPL module with a 5.12 kernel. One example is this issue for zfs on Linux: https://github.com/openzfs/zfs/issues/11172 5. Does this problem occur with the latest Rawhide kernel? To install the Rawhide kernel, run ``sudo dnf install fedora-repos-rawhide`` followed by ``sudo dnf update --enablerepo=rawhide kernel``: Not tested, but I don't see that this option has a different value there. 6. Are you running any modules that not shipped with directly Fedora's kernel?: Not material to this problem, as the problem occurs while building the external modules, regardless of whether one is loaded or not. 7. Please attach the kernel logs. You can get the complete kernel log for a boot with ``journalctl --no-hostname -k > dmesg.txt``. If the issue occurred on a previous boot, use the journalctl ``-b`` flag.
This is certainly going to be an issue to take up with upstream, there is nothing specific to Fedora's packaging in this regard. It cannot be simply turned off anymore, with 5.12 it is hidden behind CONFIG_EXPERT. Upstream expects it to be on. I did actually experiment with flipping expert and trying to sync up our configs with those options just last week. It exposed roughly 200 new config options that aren't able to be set without expert enabled, and left us with over 1000 places that the config had changed unexpectedly, meaning to fix all of that would be hours of work that no one in particularly interested in doing. https://lore.kernel.org/linuxppc-dev/20210118123451.1452206-1-npiggin@gmail.com/ is the change that forced it on.
------- Comment From srikar.dronamraju.com 2021-07-29 02:08 EDT------- Posted a patch which reads "Subject: [PATCH] powerpc/pseries: Fix regression while building external modules" https://lore.kernel.org/linuxppc-dev/20210729060449.292780-1-srikar@linux.vnet.ibm.com/t/#u
------- Comment From srikar.dronamraju.com 2021-08-02 00:45 EDT------- (In reply to comment #5) > Posted a patch which reads "Subject: [PATCH] powerpc/pseries: Fix regression > while building external modules" > > https://lore.kernel.org/linuxppc-dev/20210729060449.292780-1-srikar@linux. > vnet.ibm.com/t/#u Now this patch has been accepted in the mainline kernel. Upstream commit is https://git.kernel.org/powerpc/c/333cf507465fbebb3727f5b53e77538467df312a
This patch has been pulled into the 5.13 series for stable Fedora releases and will appear in updates starting with 5.13.8. Thank you.
FEDORA-2021-4d4d3866ca has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2021-4d4d3866ca
FEDORA-2021-54ee631709 has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2021-54ee631709
Thanks all, I verified that our external module builds and works fine with kernel-5.13.8-200.fc34.ppc64le Marc
FEDORA-2021-54ee631709 has been pushed to the Fedora 33 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-54ee631709` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-54ee631709 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2021-4d4d3866ca has been pushed to the Fedora 34 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-4d4d3866ca` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-4d4d3866ca See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2021-4d4d3866ca has been pushed to the Fedora 34 stable repository. If problem still persists, please make note of it in this bug report.
FEDORA-2021-54ee631709 has been pushed to the Fedora 33 stable repository. If problem still persists, please make note of it in this bug report.