Hi there, some general debugging features like kmemleak, KASAN, lockdep,
UBSAN etc help fix many viruses like a microscope. On the other hand, those
features are scatter around and mixed up with more situational debugging
options making them difficult to consume properly.
Since I have been deal with those options on a daily basis for the last
a few years and accumulated the knowledge of their pros and cons, I am
thinking about to create an initial "make debugconfig" target, so that
it could amplify the general debugging/testing efforts and help
establish sensitive default values for those options across the broad.
The idea is to have a debugconfig inside kernel/configs/ and update
scripts/kconfig/Makefile and Documentation/admin-guide/README.rst
accordingly. I am still trying to figure out a few implementation
details like how to convert an existing .config to debugconfig, but want
to gather some feedback before I dive in too deep.
On Thu, Oct 28, 2021 at 10:32 PM Qian Cai <[email protected]> wrote:
>
> Hi there, some general debugging features like kmemleak, KASAN, lockdep,
>
> UBSAN etc help fix many viruses like a microscope. On the other hand, those
> features are scatter around and mixed up with more situational debugging
> options making them difficult to consume properly.
>
>
>
> Since I have been deal with those options on a daily basis for the last
>
> a few years and accumulated the knowledge of their pros and cons, I am
>
> thinking about to create an initial "make debugconfig" target, so that
> it could amplify the general debugging/testing efforts and help
> establish sensitive default values for those options across the broad.
>
>
> The idea is to have a debugconfig inside kernel/configs/ and update
> scripts/kconfig/Makefile
Please do not wire it up to Makefile.
> and Documentation/admin-guide/README.rst
> accordingly. I am still trying to figure out a few implementation
> details like how to convert an existing .config to debugconfig, but want
> to gather some feedback before I dive in too deep.
--
Best Regards
Masahiro Yamada
On 10/28/21 10:03 AM, Masahiro Yamada wrote:
>> The idea is to have a debugconfig inside kernel/configs/ and update
>> scripts/kconfig/Makefile
>
> Please do not wire it up to Makefile.
Masahiro, I am afraid I don't follow here. I meant that in order for
"make help" to show things like:
debug.config - Enable Kconfig items for running kernel for general debugging
It needs to modify scripts/kconfig/Makefile or use a arch-specific
Makefile like kvm_guest.config. Do you mean you would prefer the latter?
On 10/28/21 10:03 AM, Masahiro Yamada wrote:
>> The idea is to have a debugconfig inside kernel/configs/ and update
>> scripts/kconfig/Makefile
>
> Please do not wire it up to Makefile.
Okay, I guess you mean that like android-base.config, and don't need to
show up in "make help". I am fine with that and that would make things
simplier, and I'll bake a debug.config to kernel/configs for review.
Please let me know if I am missing anything.