lkml.org 
[lkml]   [2020]   [Jun]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC][PATCH v4 02/32] objtool: Make recordmcount into mcount subcmd
    On Tue, 9 Jun 2020 11:39:51 -0700
    Matt Helsley <mhelsley@vmware.com> wrote:

    > > > +ifeq ($(SRCARCH),sparc)
    > > > + SUBCMD_MCOUNT := y
    > >
    > > Is there some arch for which MCOUNT is not supported? If not you could just
    > > have MCOUNT default to 'y' and avoid adding all those tests (or maybe reduce
    > > the numbers and set to 'n' only for arches not supporting it).
    >
    > Yes, there are some which it does not support. For those architectures
    > we keep recordmcount.pl around.
    >
    > It occured to me that with your suggestion to use more CONFIG_ variables
    > we could eliminate this pattern and replace it with these pseudo-patches:
    >
    > +++ b/kernel/trace/Kconfig
    >
    > +config OBJTOOL_SUBCMD_MCOUNT
    > + bool
    > + depends on HAVE_C_RECORDMCOUNT
    > + select OBJTOOL_SUBCMDS
    > + help
    > + Record mcount call locations using objtool
    >
    > and then change the Makefiles to use the CONFIG_ variables
    > rather than have one ifeq block per arch:
    >
    > +++ b/tools/objtool/Makefile
    >
    > +SUBCMD_MCOUNT := $(CONFIG_OBJTOOL_SUBCMD_MCOUNT)

    If you can make this work, this is definitely the way to go.

    -- Steve

    >
    > Does this seem like a good use of CONFIG_ variables or is it going too
    > far?
    >
    > I haven't changed to this pattern just yet -- I'm hoping you and Josh
    > or Peter might weigh in with your preferences.

    \
     
     \ /
      Last update: 2020-06-09 20:52    [W:2.721 / U:0.032 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site