All of lore.kernel.org
 help / color / mirror / Atom feed
From: Olaf Hering <olaf@aepfle.de>
To: He Chen <he.chen@linux.intel.com>
Cc: wei.liu2@citrix.com, ian.campbell@citrix.com,
	stefano.stabellini@eu.citrix.com, andrew.cooper3@citrix.com,
	ian.jackson@eu.citrix.com, jbeulich@suse.com,
	chao.p.peng@linux.intel.com, xen-devel@lists.xenproject.org,
	keir@xen.org
Subject: Re: [PATCH v7 2/3] x86: add domctl cmd to set/get CDP code/data CBM
Date: Thu, 15 Oct 2015 16:57:16 +0200	[thread overview]
Message-ID: <20151015145716.GA19658@aepfle.de> (raw)
In-Reply-To: <1444726426-10567-3-git-send-email-he.chen@linux.intel.com>

On Tue, Oct 13, He Chen wrote:

> +int psr_set_l3_cbm(struct domain *d, unsigned int socket,
> +                   uint64_t cbm, enum cbm_type type)
>  {

> +    uint64_t cbm_data, cbm_code;

> +    switch ( type )
>      {

> +    case PSR_CBM_TYPE_L3:
> +        cbm_code = cbm;
> +        break;

> +    case PSR_CBM_TYPE_L3_CODE:
> +        cbm_code = cbm;
> +        break;

> +    case PSR_CBM_TYPE_L3_DATA:
> +        cbm_code = map[old_cos].code;
> +        break;
> +
> +    default:
> +        ASSERT_UNREACHABLE();

> +    cos = find_cos(map, cos_max, cbm_code, cbm_data, cdp_enabled);

gcc5 does not like ASSERT_UNREACHABLE(), whatever is in staging fails:

[ 2144s] psr.c: In function 'psr_set_l3_cbm':
[ 2144s] psr.c:381:25: error: 'cbm_code' may be used uninitialized in this function [-Werror=maybe-uninitialized]
[ 2144s]      struct cos_cbm_info info =
[ 2144s]                          ^
[ 2144s] psr.c:442:24: note: 'cbm_code' was declared here
[ 2144s]      uint64_t cbm_data, cbm_code;
[ 2144s]                         ^
[ 2144s] psr.c:513:27: error: 'cbm_data' may be used uninitialized in this function [-Werror=maybe-uninitialized]
[ 2144s]              map[cos].data = cbm_data;
[ 2144s]                            ^
[ 2145s] cc1: all warnings being treated as errors
[ 2145s] /home/abuild/rpmbuild/BUILD/xen-4.7.31795/non-dbg/xen/Rules.mk:174: recipe for target 'psr.o' failed
[ 2145s] make[4]: *** [psr.o] Error 1

Havent checked if there is already a fix in-flight.

Olaf

  parent reply	other threads:[~2015-10-15 14:57 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-13  8:53 [PATCH v7 0/3] detect and initialize CDP (Code/Data Prioritization) feature He Chen
2015-10-13  8:53 ` [PATCH v7 1/3] x86: Support enable CDP by boot parameter and add get CDP status He Chen
2015-10-14  2:02   ` Chao Peng
2015-10-13  8:53 ` [PATCH v7 2/3] x86: add domctl cmd to set/get CDP code/data CBM He Chen
2015-10-13 15:38   ` Jan Beulich
2015-10-14  2:07     ` Chao Peng
2015-10-15 14:57   ` Olaf Hering [this message]
2015-10-15 15:10     ` Wei Liu
2015-10-15 15:22       ` Olaf Hering
2015-10-15 15:26         ` Wei Liu
2015-10-15 15:30           ` Wei Liu
2015-10-16  9:10           ` Olaf Hering
2015-10-15 15:47       ` Jan Beulich
2015-10-16  8:24         ` He Chen
2015-10-16  8:32           ` Jan Beulich
2015-10-13  8:53 ` [PATCH v7 3/3] tools & docs: add tools and docs support for Intel CDP He Chen
2015-10-13 16:23   ` Ian Campbell
2015-10-14  2:38   ` Chao Peng
2015-10-14  8:52     ` Ian Campbell
2015-10-14  9:08   ` Dario Faggioli
2015-10-14  9:20     ` Ian Campbell
2015-10-14 10:52   ` Jan Beulich

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=20151015145716.GA19658@aepfle.de \
    --to=olaf@aepfle.de \
    --cc=andrew.cooper3@citrix.com \
    --cc=chao.p.peng@linux.intel.com \
    --cc=he.chen@linux.intel.com \
    --cc=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=jbeulich@suse.com \
    --cc=keir@xen.org \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /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.