[LU-14291] Improve use of HAVE_SERVER_SUPPORT and others for Linux-kernel client Created: 04/Jan/21 Updated: 29/Mar/23 |
|
| Status: | Reopened |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | Lustre 2.16.0 |
| Type: | Improvement | Priority: | Minor |
| Reporter: | Neil Brown | Assignee: | Neil Brown |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||||||
| Rank (Obsolete): | 9223372036854775807 | ||||||||||||
| Description |
|
The proposed upstreaming of Lustre to the Linux kernel will start with just the client. To assist with this the "HAVE_SERVER_SUPPORT" macro is widely used to identify code that is only needed on the server. However there is a lot of code that could be protected by this macro, but isn't. There are also some other aspects of Lustre that will not be going upstream, such as the ability to extract jobid strings from the process environment. It would help if there were marked for conditional compilation, so they can easily be removed before upstreaming. Ideally most of the server-only code would go in separate source files so that when server support is later added, we only need to add some files. We probably cannot move all server code to separate files, but we should move as much as we can, as having #ifdef in C-code files is discouraged upstream. The goal of this improvement is for all code that won't be upstream initially to with be in separate files, or to be clearly marked with a macro such s HAVE_SERVER_SUPPORT.
|
| Comments |
| Comment by Gerrit Updater [ 05/Jan/21 ] |
|
Neil Brown (neilb@suse.de) uploaded a new patch: https://review.whamcloud.com/41125 |
| Comment by Gerrit Updater [ 05/Jan/21 ] |
|
Neil Brown (neilb@suse.de) uploaded a new patch: https://review.whamcloud.com/41126 |
| Comment by Gerrit Updater [ 05/Jan/21 ] |
|
Neil Brown (neilb@suse.de) uploaded a new patch: https://review.whamcloud.com/41127 |
| Comment by Gerrit Updater [ 05/Jan/21 ] |
|
Neil Brown (neilb@suse.de) uploaded a new patch: https://review.whamcloud.com/41128 |
| Comment by Gerrit Updater [ 26/Feb/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/41127/ |
| Comment by Gerrit Updater [ 26/Feb/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/41128/ |
| Comment by Gerrit Updater [ 14/Mar/21 ] |
|
Neil Brown (neilb@suse.de) uploaded a new patch: https://review.whamcloud.com/42032 |
| Comment by Gerrit Updater [ 16/Mar/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/41126/ |
| Comment by Gerrit Updater [ 16/Mar/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/39683/ |
| Comment by Gerrit Updater [ 22/Mar/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/42032/ |
| Comment by Gerrit Updater [ 24/Mar/21 ] |
|
James Simmons (jsimmons@infradead.org) uploaded a new patch: https://review.whamcloud.com/43096 |
| Comment by Gerrit Updater [ 06/Apr/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/41125/ |
| Comment by Gerrit Updater [ 10/May/21 ] |
|
James Simmons (jsimmons@infradead.org) uploaded a new patch: https://review.whamcloud.com/43624 |
| Comment by Gerrit Updater [ 19/May/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/43096/ |
| Comment by Gerrit Updater [ 27/May/21 ] |
|
Oleg Drokin (green@whamcloud.com) merged in patch https://review.whamcloud.com/43624/ |
| Comment by Peter Jones [ 27/May/21 ] |
|
Landed for 2.15 |
| Comment by Neil Brown [ 27/May/21 ] |
|
There is still plenty of room to improve HAVE_SERVER_SUPPORT.
The ideal end-goal is to remove it from all .c files, leaving it only in Makefiles and .h. This might not be possible to fully achieve, but it would be good to keep this open until we collectively decide that we are close enough. |
| Comment by Gerrit Updater [ 10/Mar/23 ] |
|
"jsimmons <jsimmons@infradead.org>" uploaded a new patch: https://review.whamcloud.com/c/fs/lustre-release/+/50258 |
| Comment by Gerrit Updater [ 28/Mar/23 ] |
|
"Oleg Drokin <green@whamcloud.com>" merged in patch https://review.whamcloud.com/c/fs/lustre-release/+/50258/ |
| Comment by Peter Jones [ 29/Mar/23 ] |
|
Landed for 2.16 |
| Comment by Neil Brown [ 29/Mar/23 ] |
|
Some patches have landed - yes. But others haven't even been developed. I don't think we can really call "time" on this issue until we have demonstrated that everything not protected by HAVE_SERVER_SUPPORT is client-only. Getting the client code accepted into the Linux kernel would be reasonable way to demonstrate that. |