drm/display: Drop obsolete dependency on COMPILE_TEST
Subsystems (2)
PATCH RESEND 1/1 drm/display: Drop obsolete dependency on COMPILE_TEST
Since commit 0166dc11be91 ("of: make CONFIG_OF user selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending on COMPILE_TEST as an alternative is no longer needed.
---
Already sent on: 2022-11-21, 2023-01-27, 2023-12-02
This is one of the only 3 remaining occurrences of this deprecated construct.
Who can pick this patch and get it upstream?
drivers/gpu/drm/display/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/display/Kconfig +1 -1
@@ -3,7 +3,7 @@ config DRM_DP_AUX_BUS tristate depends on DRM - depends on OF || COMPILE_TEST + depends on OF config DRM_DISPLAY_HELPER tristate
Signature · 2 lines
Jean Delvare SUSE L3 Support
Quoted 4 lines · Jean Delvare
Since commit
0166dc11be91("of: makeCONFIG_OFuser selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending onCOMPILE_TESTas an alternative is no longer needed.
The goal of this clause is to allow build-testing the driver with OF being disabled (meaning that some of OF functions are stubbed and some might disappear). I don't see how user-selectable OF provides the same result.
Quoted 32 lines
Signed-off-by Jean Delvare <[email protected]>Reviewed-by Javier Martinez Canillas <[email protected]>Cc David Airlie <[email protected]>Cc Daniel Vetter <[email protected]>---
Already sent on: 2022-11-21, 2023-01-27, 2023-12-02This is one of the only 3 remaining occurrences of this deprecated construct.
Who can pick this patch and get it upstream?
drivers/gpu/drm/display/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/display/Kconfig +1
-1@@ -3,7 +3,7 @@ config DRM_DP_AUX_BUS tristate depends on DRM - depends on OF || COMPILE_TEST + depends on OF config DRM_DISPLAY_HELPER tristateSignature · 3 lines
-- Jean Delvare SUSE L3 Support
Signature · 2 lines
With best wishes Dmitry
Hi Dmitry,
Thanks for your feedback.
Quoted 10 lines · Dmitry Baryshkov
Quoted 4 lines · Jean Delvare
Since commit
0166dc11be91("of: makeCONFIG_OFuser selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending onCOMPILE_TESTas an alternative is no longer needed.The goal of this clause is to allow build-testing the driver with OF being disabled (meaning that some of OF functions are stubbed and some might disappear). I don't see how user-selectable OF provides the same result.
Historically, the goal of this clause *was* to allow build-testing the driver on architectures which did not support OF, and that did make sense back then. As I understand it, building the driver without OF support was never a goal per se (if it was, then the driver wouldn't be set to depend on OF in the first place).
Some of my other submissions include the following explanation which you might find useful (I ended up stripping it on resubmission after being told I was being too verbose, but maybe it was needed after all):
It is actually better to always build such drivers with OF enabled, so that the test builds are closer to how each driver will actually be built on its intended target. Building them without OF may not test much as the compiler will optimize out potentially large parts of the code. In the worst case, this could even pop false positive warnings. Dropping COMPILE_TEST here improves the quality of our testing and avoids wasting time on non-existent issues.
Signature · 2 lines
Jean Delvare SUSE L3 Support
Quoted 26 lines · Jean Delvare
Hi Dmitry,
Thanks for your feedback.
Quoted 10 lines · Dmitry Baryshkov
Quoted 4 lines · Jean Delvare
Since commit
0166dc11be91("of: makeCONFIG_OFuser selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending onCOMPILE_TESTas an alternative is no longer needed.The goal of this clause is to allow build-testing the driver with OF being disabled (meaning that some of OF functions are stubbed and some might disappear). I don't see how user-selectable OF provides the same result.
Historically, the goal of this clause *was* to allow build-testing the driver on architectures which did not support OF, and that did make sense back then. As I understand it, building the driver without OF support was never a goal per se (if it was, then the driver wouldn't be set to depend on OF in the first place).
Some of my other submissions include the following explanation which you might find useful (I ended up stripping it on resubmission after being told I was being too verbose, but maybe it was needed after all):
Quoted 7 lines
It is actually better to always build such drivers with OF enabled, so that the test builds are closer to how each driver will actually be built on its intended target. Building them without OF may not test much as the compiler will optimize out potentially large parts of the code. In the worst case, this could even pop false positive warnings. Dropping
COMPILE_TESThere improves the quality of our testing and avoids wasting time on non-existent issues.
This doesn't seem to match the COMPILE_TEST usage that I observe in other places. For example, we frequently use 'depends on ARCH_QCOM || COMPILE_TEST'. Which means that the driver itself doesn't make sense without ARCH_QCOM, but we want for it to be tested on non-ARCH_QCOM cases. I think the same logic applies to 'depends on OF || COMPILE_TEST' clauses. The driver (DP AUX bus) depends on OF to be fully functional, but it should be compilable even without OF case.
I'll let Douglas (in cc) comment if my understanding is incorrect.
Signature · 2 lines
With best wishes Dmitry
Quoted 35 lines · Dmitry Baryshkov
Quoted 26 lines · Jean Delvare
Hi Dmitry,
Thanks for your feedback.
Quoted 10 lines · Dmitry Baryshkov
Quoted 4 lines · Jean Delvare
Since commit
0166dc11be91("of: makeCONFIG_OFuser selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending onCOMPILE_TESTas an alternative is no longer needed.The goal of this clause is to allow build-testing the driver with OF being disabled (meaning that some of OF functions are stubbed and some might disappear). I don't see how user-selectable OF provides the same result.
Historically, the goal of this clause *was* to allow build-testing the driver on architectures which did not support OF, and that did make sense back then. As I understand it, building the driver without OF support was never a goal per se (if it was, then the driver wouldn't be set to depend on OF in the first place).
Some of my other submissions include the following explanation which you might find useful (I ended up stripping it on resubmission after being told I was being too verbose, but maybe it was needed after all):
Quoted 7 lines
It is actually better to always build such drivers with OF enabled, so that the test builds are closer to how each driver will actually be built on its intended target. Building them without OF may not test much as the compiler will optimize out potentially large parts of the code. In the worst case, this could even pop false positive warnings. Dropping
COMPILE_TESThere improves the quality of our testing and avoids wasting time on non-existent issues.
Quoted 7 lines
This doesn't seem to match the
COMPILE_TESTusage that I observe in other places. For example, we frequently use 'depends onARCH_QCOM||COMPILE_TEST'. Which means that the driver itself doesn't make sense withoutARCH_QCOM, but we want for it to be tested on non-ARCH_QCOM cases. I think the same logic applies to 'depends on OF ||COMPILE_TEST' clauses. The driver (DP AUX bus) depends on OF to be fully functional, but it should be compilable even without OF case.
The major difference is that one can't possibly enable ARCH_QCOM if building on X86 for example. Therefore COMPILE_TEST is the only way to let everyone (including randconfig/allmodconfig build farms) test-build your code.
On the other hand, if you want to test-build drm_dp_aux_bus, you can simply enable OF, because it is available on all architectures and doesn't depend on anything. No need for COMPILE_TEST.
For clarity, I'm not advocating against the use of COMPILE_TEST, actually if you check the history of my kernel contributions 10 years back, you'll find commits from me adding COMPILE_TEST in addition to arch-specific dependencies to many drivers. All I'm saying is that it should only be used when it is the only way to enable the build.
Signature · 2 lines
Jean Delvare SUSE L3 Support
Quoted 44 lines · Jean Delvare
Quoted 35 lines · Dmitry Baryshkov
Quoted 26 lines · Jean Delvare
Hi Dmitry,
Thanks for your feedback.
Quoted 10 lines · Dmitry Baryshkov
Quoted 4 lines · Jean Delvare
Since commit
0166dc11be91("of: makeCONFIG_OFuser selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending onCOMPILE_TESTas an alternative is no longer needed.The goal of this clause is to allow build-testing the driver with OF being disabled (meaning that some of OF functions are stubbed and some might disappear). I don't see how user-selectable OF provides the same result.
Historically, the goal of this clause *was* to allow build-testing the driver on architectures which did not support OF, and that did make sense back then. As I understand it, building the driver without OF support was never a goal per se (if it was, then the driver wouldn't be set to depend on OF in the first place).
Some of my other submissions include the following explanation which you might find useful (I ended up stripping it on resubmission after being told I was being too verbose, but maybe it was needed after all):
Quoted 7 lines
It is actually better to always build such drivers with OF enabled, so that the test builds are closer to how each driver will actually be built on its intended target. Building them without OF may not test much as the compiler will optimize out potentially large parts of the code. In the worst case, this could even pop false positive warnings. Dropping
COMPILE_TESThere improves the quality of our testing and avoids wasting time on non-existent issues.Quoted 7 lines
This doesn't seem to match the
COMPILE_TESTusage that I observe in other places. For example, we frequently use 'depends onARCH_QCOM||COMPILE_TEST'. Which means that the driver itself doesn't make sense withoutARCH_QCOM, but we want for it to be tested on non-ARCH_QCOM cases. I think the same logic applies to 'depends on OF ||COMPILE_TEST' clauses. The driver (DP AUX bus) depends on OF to be fully functional, but it should be compilable even without OF case.
Quoted 8 lines
The major difference is that one can't possibly enable
ARCH_QCOMif building on X86 for example. ThereforeCOMPILE_TESTis the only way to let everyone (including randconfig/allmodconfig build farms) test-build your code.On the other hand, if you want to test-build
drm_dp_aux_bus, you can simply enable OF, because it is available on all architectures and doesn't depend on anything. No need forCOMPILE_TEST.
I'd probably let Doug respond, what was his intention.
Quoted 6 lines
For clarity, I'm not advocating against the use of
COMPILE_TEST, actually if you check the history of my kernel contributions 10 years back, you'll find commits from me addingCOMPILE_TESTin addition to arch-specific dependencies to many drivers. All I'm saying is that it should only be used when it is the only way to enable the build.
Signature · 2 lines
With best wishes Dmitry
Hi,
Quoted 51 lines · Dmitry Baryshkov
Quoted 49 lines · Jean Delvare
Quoted 35 lines · Dmitry Baryshkov
Quoted 26 lines · Jean Delvare
Hi Dmitry,
Thanks for your feedback.
Quoted 10 lines · Dmitry Baryshkov
Quoted 4 lines · Jean Delvare
Since commit
0166dc11be91("of: makeCONFIG_OFuser selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending onCOMPILE_TESTas an alternative is no longer needed.The goal of this clause is to allow build-testing the driver with OF being disabled (meaning that some of OF functions are stubbed and some might disappear). I don't see how user-selectable OF provides the same result.
Historically, the goal of this clause *was* to allow build-testing the driver on architectures which did not support OF, and that did make sense back then. As I understand it, building the driver without OF support was never a goal per se (if it was, then the driver wouldn't be set to depend on OF in the first place).
Some of my other submissions include the following explanation which you might find useful (I ended up stripping it on resubmission after being told I was being too verbose, but maybe it was needed after all):
Quoted 7 lines
It is actually better to always build such drivers with OF enabled, so that the test builds are closer to how each driver will actually be built on its intended target. Building them without OF may not test much as the compiler will optimize out potentially large parts of the code. In the worst case, this could even pop false positive warnings. Dropping
COMPILE_TESThere improves the quality of our testing and avoids wasting time on non-existent issues.Quoted 7 lines
This doesn't seem to match the
COMPILE_TESTusage that I observe in other places. For example, we frequently use 'depends onARCH_QCOM||COMPILE_TEST'. Which means that the driver itself doesn't make sense withoutARCH_QCOM, but we want for it to be tested on non-ARCH_QCOM cases. I think the same logic applies to 'depends on OF ||COMPILE_TEST' clauses. The driver (DP AUX bus) depends on OF to be fully functional, but it should be compilable even without OF case.The major difference is that one can't possibly enable
ARCH_QCOMif building on X86 for example. ThereforeCOMPILE_TESTis the only way to let everyone (including randconfig/allmodconfig build farms) test-build your code.
Quoted 5 lines
Quoted 3 lines
On the other hand, if you want to test-build
drm_dp_aux_bus, you can simply enable OF, because it is available on all architectures and doesn't depend on anything. No need forCOMPILE_TEST.I'd probably let Doug respond, what was his intention.
Is this me? This looks like a straight revert of commit 876271118aa4 ("drm/display: Fix build error without CONFIG_OF")
I don't personally have anything against removing COMPILE_TEST for this given that I wasn't the one who added it, but make sure it's not going to cause randconfig issues.
-Doug
Hi Doug,
Quoted 13 lines · Doug Anderson
Quoted 11 lines · Dmitry Baryshkov
Quoted 8 lines · Jean Delvare
The major difference is that one can't possibly enable
ARCH_QCOMif building on X86 for example. ThereforeCOMPILE_TESTis the only way to let everyone (including randconfig/allmodconfig build farms) test-build your code.On the other hand, if you want to test-build
drm_dp_aux_bus, you can simply enable OF, because it is available on all architectures and doesn't depend on anything. No need forCOMPILE_TEST.
Quoted 8 lines
Quoted 1 line
I'd probably let Doug respond, what was his intention.
Is this me? This looks like a straight revert of commit
876271118aa4("drm/display: Fix build error withoutCONFIG_OF")I don't personally have anything against removing
COMPILE_TESTfor this given that I wasn't the one who added it, but make sure it's not going to cause randconfig issues.
Thanks for pointing this commit to my attention, I wasn't aware. This means that my proposed patch is incomplete and would indeed break randconfig. I'll send a v2.
Signature · 2 lines
Jean Delvare SUSE L3 Support
Quoted 55 lines · Doug Anderson
Hi,
Quoted 51 lines · Dmitry Baryshkov
Quoted 49 lines · Jean Delvare
Quoted 35 lines · Dmitry Baryshkov
Quoted 26 lines · Jean Delvare
Hi Dmitry,
Thanks for your feedback.
Quoted 10 lines · Dmitry Baryshkov
Quoted 4 lines · Jean Delvare
Since commit
0166dc11be91("of: makeCONFIG_OFuser selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending onCOMPILE_TESTas an alternative is no longer needed.The goal of this clause is to allow build-testing the driver with OF being disabled (meaning that some of OF functions are stubbed and some might disappear). I don't see how user-selectable OF provides the same result.
Historically, the goal of this clause *was* to allow build-testing the driver on architectures which did not support OF, and that did make sense back then. As I understand it, building the driver without OF support was never a goal per se (if it was, then the driver wouldn't be set to depend on OF in the first place).
Some of my other submissions include the following explanation which you might find useful (I ended up stripping it on resubmission after being told I was being too verbose, but maybe it was needed after all):
Quoted 7 lines
It is actually better to always build such drivers with OF enabled, so that the test builds are closer to how each driver will actually be built on its intended target. Building them without OF may not test much as the compiler will optimize out potentially large parts of the code. In the worst case, this could even pop false positive warnings. Dropping
COMPILE_TESThere improves the quality of our testing and avoids wasting time on non-existent issues.Quoted 7 lines
This doesn't seem to match the
COMPILE_TESTusage that I observe in other places. For example, we frequently use 'depends onARCH_QCOM||COMPILE_TEST'. Which means that the driver itself doesn't make sense withoutARCH_QCOM, but we want for it to be tested on non-ARCH_QCOM cases. I think the same logic applies to 'depends on OF ||COMPILE_TEST' clauses. The driver (DP AUX bus) depends on OF to be fully functional, but it should be compilable even without OF case.The major difference is that one can't possibly enable
ARCH_QCOMif building on X86 for example. ThereforeCOMPILE_TESTis the only way to let everyone (including randconfig/allmodconfig build farms) test-build your code.
Quoted 8 lines
Quoted 5 lines
Quoted 3 lines
On the other hand, if you want to test-build
drm_dp_aux_bus, you can simply enable OF, because it is available on all architectures and doesn't depend on anything. No need forCOMPILE_TEST.I'd probably let Doug respond, what was his intention.
Is this me? This looks like a straight revert of commit
876271118aa4("drm/display: Fix build error withoutCONFIG_OF")
Thanks!
Quoted 3 lines
I don't personally have anything against removing
COMPILE_TESTfor this given that I wasn't the one who added it, but make sure it's not going to cause randconfig issues.
Signature · 2 lines
With best wishes Dmitry