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.6 compat #9961
Linux 5.6 compat #9961
Conversation
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Codecov Report
@@ Coverage Diff @@
## master #9961 +/- ##
========================================
+ Coverage 79% 79% +<1%
========================================
Files 385 385
Lines 121938 121938
========================================
+ Hits 96748 96841 +93
+ Misses 25190 25097 -93
Continue to review full report at Codecov.
|
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes #9956 Closes #9961
|
For those who might be looking for a version of this patch for the zfs-0.8-release branch, I adapted this set of patches to be applied to the ubuntu's zfs-0.8-release based zfs-dkms_0.8.3-1ubuntu3 package using this patch: https://paste.ubuntu.com/p/wsS9GFHjyv/ Applying this patch let's me boot mainline 5.6.0-050600rc1-generic and mount my zpools. |
|
5.6.rc3 cumulative patch for zfs 0.8.x branch for ubuntu adapting #9961 & #10064 here: https://gist.github.com/satmandu/67cbae9c4d461be0e64428a1707aef1c |
|
zfs fail to build on x86_64 with latest linux 5.6 on my gentoo |
|
.3/module/lua/lauxlib.o /var/tmp/portage/sys-fs/zfs-kmod-0.8.3/work/zfs-0.8.3/module/lua/lauxlib.c |
|
This compatibility fix will be include in the next tag (0.8.4). |
|
Until then the patch #9961 (comment) remade from this pr by @satmandu worked fine for me ontop of 0.8.3 git tag. But you may also need the other patch for 5.5 compatibility with that certain kernel option too. |
|
@behlendorf May I help to prepare 0.8.4? |
|
@freswa thanks for the offer, but we'd like to apply our usual process. If you need a version of 0.8.3 which works with 5.6 kernels you can apply the following patches from master. bd0d24e Linux 5.5 compat: blkg_tryget() |
|
May I ask for a release? |
Is this patch sufficient for 5.6 support? I saw another issue which is a run time undefined symbol issue and not a build time: #10167 Do I need to include that one too for proper import of the pools with 5.6? PS: never mind, the patch from that comment is not enough to build with 5.6, still lot of errors. Any ideas on when this will be fixed for 0.8.x? |
|
@sunilvaltix the gist worked for me [edit] you may also need the 5.5.x patches. These seemed to work for other people too. However when you reboot then zfs might not import automatically your pools. That could be for a configuration reason, regarding disabled systemd services? Then there are other systemctl commands to deal with that. I run them after installing the new apt pkgs but before rebooting the system. [edit] Here are my full instructions for building from start to finish. In the middle you find the patches and how to apply them. And finally at the very bottom are the https://gist.github.com/dreamcat4/fd7d39c47ac361277283641ba6d68e66 ...this is what works for myself, YMMV. Its instructions for ubuntu only. So may need to do something else for other distro(s). |
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
I took the 5.5 and 5.6 patches from this and put it /etc/portage/patches/sys-fs/zfs-kmod for gentoo to pick them up. The patches apply correctly. But I keep getting the errors I showed above. |
|
I did another experiment:
So, how is this possible? How can official 0.8.3 tar patched with 0002-fix-5.6-build.patch not build but a tar created from git's 0.8.3 tag builds when patched with the same patch? Can someone pls explain this? |
|
Another mystery: the patch for 5.5 is not needed. |
|
@behlendorf Could we ask for a release, as it's too much confusion which patches to apply. |
|
Hey guys you should not be bothering the lead developer about these release issues, because his time is far more valuable and better spent for everyone to keep working through dev issues on master branch. And not be bogged down by this type of stuff. That can be worked out by other people and / or may be specific to your environment and / or not reproducible in his own development environment. Were he to do so that then would have the knock on effect of slowing down the main developement branch for other really important matters such as critical bug fixes and new features! Which are also very significant to the integrity of the project. I hope you can understand this.... For Release matters that is the area of other team members such as @tonyhutter. In fact we already had some discussions about the current release cycle (how slow it's gotten) and were talking about whether it made sense or not for somehow altering the release cycle, including in light of breaking kernel changes. That discussion already took place a few months ago... forgive my memory for being so cloudy but I seem to remember there were some pretty good reasons why it cannot happen ATM for zfs project. There are certain constraints going on in with the release cycle and Tony is the best person to recap on that. It's slightly unfortunate that cannot actually remember the link, to dig that out again and point you guys back to the outcomes of that previous discussion. Anyhow if you have an immediate problem (which may be important !) and either need assistance or otherwise want to just know when the next release is most likely coming up... then @tonyhutter is really the point person. He is currently the zfs release manager I believe, if I'm not mistaken? By all accounts also a very busy person too. There are certain other people involved too, unfortunately I forget their names right now. But certainly Tony is the one who has been putting together the last few official releases, bringing together patch sets. [edit] Oh and BTW sorry if you were unaware of any of that... didn't want to butt in and add any extra unnecessary noise / detract from these discussions. |
|
@tonyhutter Thank you! I'll follow it |
Did your build recipe run autoreconf so that the new m4 macros are properly converted into an updated ./configure script? If you are relying on portage's autodetection in your ebuild, then it might not recognize it is needed if the outdated configure script exists -- but it will definitely be recognized if you use the git tarball and there is a 'configure.ac' but not a 'configure', that autoreconf must be run.
It's only needed for PREEMPT_RCU kernels, which your self-compiled gentoo kernel might not be, but some generic distro kernels are. |
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes #9956 Closes #9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes #9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
The proc_ops structure was introduced to replace the use of of the file_operations structure when registering proc handlers. This change creates a new kstat_proc_op_t typedef for compatibility which can be used to pass around the correct structure. This change additionally adds the 'const' keyword to all of the existing proc operations structures. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9961
The timestamp_truncate() function was added, it replaces the existing timespec64_trunc() function. This change renames our wrapper function to be consistent with the upstream name and updates the compatibility code for older kernels accordingly. Reviewed-by: Tony Hutter <hutter2@llnl.gov> Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Closes openzfs#9956 Closes openzfs#9961
Motivation and Context
Resolve build issues with the upcoming Linux 5.6 kernel.
Description
The timestamp_truncate() function was added, it replaces the existing
timespec64_trunc() function. This change renames our wrapper function
to be consistent with the upstream name and updates the compatibility
code for older kernels accordingly.
The proc_ops structure was introduced to replace the use of of the
file_operations structure when registering proc handlers. This
change creates a new kstat_proc_op_t typedef for compatibility
which can be used to pass around the correct structure.
This change additionally adds the 'const' keyword to all of the
existing proc operations structures.
How Has This Been Tested?
Locally compiled against a v5.5-9824-g90568ecf5615 kernel.
Types of changes
Checklist:
Signed-off-by.