From: Jacob Pan <jacob.jun.pan@linux.intel.com>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Mathias Krause <minipli@googlemail.com>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>,
linux-pm@vger.kernel.org,
Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Subject: Re: [PATCH] powercap / RAPL: mark rapl_ids array as __initconst
Date: Mon, 30 Mar 2015 15:46:35 -0700 [thread overview]
Message-ID: <20150330154635.3fb82c23@ultegra> (raw)
In-Reply-To: <6448986.08Uv5dyIEs@vostro.rjw.lan>
On Mon, 30 Mar 2015 21:17:02 +0200
Rafael J. Wysocki <rjw@rjwysocki.net> wrote:
> On Wednesday, March 25, 2015 10:15:52 PM Mathias Krause wrote:
> > The RAPL ids are only tested in rapl_init() which is itself an
> > __init function. For the MODULE_DEVICE_TABLE() file2alias doesn't
> > care about the section, just about the symbol name. Therefore it's
> > safe to mark the rapl_ids[] array as __initconst so its memory can
> > be released after initialization is done.
> >
> > Cc: Jacob Pan <jacob.jun.pan@linux.intel.com>
> > Cc: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
> > Signed-off-by: Mathias Krause <minipli@googlemail.com>
>
> Jacob, any comments?
>
looks good to me, though i did ack last week perhaps something wrong
with my email.
> > ---
> > drivers/powercap/intel_rapl.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/powercap/intel_rapl.c
> > b/drivers/powercap/intel_rapl.c index 63d4033eb683..62f9b322fde0
> > 100644 --- a/drivers/powercap/intel_rapl.c
> > +++ b/drivers/powercap/intel_rapl.c
> > @@ -1054,7 +1054,7 @@ static const struct rapl_defaults
> > rapl_defaults_atom = { .driver_data = (kernel_ulong_t)&_ops,
> > \ }
> >
> > -static const struct x86_cpu_id rapl_ids[] = {
> > +static const struct x86_cpu_id rapl_ids[] __initconst = {
> > RAPL_CPU(0x2a, rapl_defaults_core),/* Sandy Bridge */
> > RAPL_CPU(0x2d, rapl_defaults_core),/* Sandy Bridge EP */
> > RAPL_CPU(0x37, rapl_defaults_atom),/* Valleyview */
> >
>
> --
> I speak only for myself.
> Rafael J. Wysocki, Intel Open Source Technology Center.
--
Jacob Pan
next prev parent reply other threads:[~2015-03-30 22:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-25 21:15 [PATCH] powercap / RAPL: mark rapl_ids array as __initconst Mathias Krause
2015-03-30 19:17 ` Rafael J. Wysocki
2015-03-30 22:46 ` Jacob Pan [this message]
2015-03-31 5:17 ` Mathias Krause
2015-04-08 18:41 ` Mathias Krause
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20150330154635.3fb82c23@ultegra \
--to=jacob.jun.pan@linux.intel.com \
--cc=linux-pm@vger.kernel.org \
--cc=minipli@googlemail.com \
--cc=rafael.j.wysocki@intel.com \
--cc=rjw@rjwysocki.net \
--cc=srinivas.pandruvada@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.