* [PATCH] perf tools: Fix pmu object compilation error
@ 2014-04-16 19:00 Jiri Olsa
2014-04-16 19:02 ` David Ahern
2014-04-22 18:33 ` [tip:perf/core] " tip-bot for Jiri Olsa
0 siblings, 2 replies; 3+ messages in thread
From: Jiri Olsa @ 2014-04-16 19:00 UTC (permalink / raw)
To: linux-kernel; +Cc: Jiri Olsa, David Ahern, Namhyung Kim
After applying some patches got another shadowing error:
CC util/pmu.o
util/pmu.c: In function ‘pmu_alias_terms’:
util/pmu.c:287:35: error: declaration of ‘clone’ shadows a global declaration [-Werror=shadow]
Renaming clone to cloned.
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Jiri Olsa <jolsa@redhat.com>
---
tools/perf/util/pmu.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tools/perf/util/pmu.c b/tools/perf/util/pmu.c
index 00a7dcb..7a811eb 100644
--- a/tools/perf/util/pmu.c
+++ b/tools/perf/util/pmu.c
@@ -284,17 +284,17 @@ static int pmu_aliases(const char *name, struct list_head *head)
static int pmu_alias_terms(struct perf_pmu_alias *alias,
struct list_head *terms)
{
- struct parse_events_term *term, *clone;
+ struct parse_events_term *term, *cloned;
LIST_HEAD(list);
int ret;
list_for_each_entry(term, &alias->terms, list) {
- ret = parse_events_term__clone(&clone, term);
+ ret = parse_events_term__clone(&cloned, term);
if (ret) {
parse_events__free_terms(&list);
return ret;
}
- list_add_tail(&clone->list, &list);
+ list_add_tail(&cloned->list, &list);
}
list_splice(&list, terms);
return 0;
--
1.8.3.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] perf tools: Fix pmu object compilation error
2014-04-16 19:00 [PATCH] perf tools: Fix pmu object compilation error Jiri Olsa
@ 2014-04-16 19:02 ` David Ahern
2014-04-22 18:33 ` [tip:perf/core] " tip-bot for Jiri Olsa
1 sibling, 0 replies; 3+ messages in thread
From: David Ahern @ 2014-04-16 19:02 UTC (permalink / raw)
To: Jiri Olsa, linux-kernel; +Cc: Namhyung Kim
On 4/16/14, 1:00 PM, Jiri Olsa wrote:
> After applying some patches got another shadowing error:
>
> CC util/pmu.o
> util/pmu.c: In function ‘pmu_alias_terms’:
> util/pmu.c:287:35: error: declaration of ‘clone’ shadows a global declaration [-Werror=shadow]
>
> Renaming clone to cloned.
>
> Cc: David Ahern <dsahern@gmail.com>
> Cc: Namhyung Kim <namhyung@kernel.org>
> Signed-off-by: Jiri Olsa <jolsa@redhat.com>
> ---
> tools/perf/util/pmu.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/tools/perf/util/pmu.c b/tools/perf/util/pmu.c
> index 00a7dcb..7a811eb 100644
> --- a/tools/perf/util/pmu.c
> +++ b/tools/perf/util/pmu.c
> @@ -284,17 +284,17 @@ static int pmu_aliases(const char *name, struct list_head *head)
> static int pmu_alias_terms(struct perf_pmu_alias *alias,
> struct list_head *terms)
> {
> - struct parse_events_term *term, *clone;
> + struct parse_events_term *term, *cloned;
> LIST_HEAD(list);
> int ret;
>
> list_for_each_entry(term, &alias->terms, list) {
> - ret = parse_events_term__clone(&clone, term);
> + ret = parse_events_term__clone(&cloned, term);
> if (ret) {
> parse_events__free_terms(&list);
> return ret;
> }
> - list_add_tail(&clone->list, &list);
> + list_add_tail(&cloned->list, &list);
> }
> list_splice(&list, terms);
> return 0;
>
Acked-by: David Ahern <dsahern@gmail.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [tip:perf/core] perf tools: Fix pmu object compilation error
2014-04-16 19:00 [PATCH] perf tools: Fix pmu object compilation error Jiri Olsa
2014-04-16 19:02 ` David Ahern
@ 2014-04-22 18:33 ` tip-bot for Jiri Olsa
1 sibling, 0 replies; 3+ messages in thread
From: tip-bot for Jiri Olsa @ 2014-04-22 18:33 UTC (permalink / raw)
To: linux-tip-commits
Cc: linux-kernel, hpa, mingo, dsahern, tglx, namhyung, jolsa
Commit-ID: 7c2f8164e5415ef48954f6929f4acae5764afdb4
Gitweb: http://git.kernel.org/tip/7c2f8164e5415ef48954f6929f4acae5764afdb4
Author: Jiri Olsa <jolsa@redhat.com>
AuthorDate: Wed, 16 Apr 2014 20:49:02 +0200
Committer: Jiri Olsa <jolsa@redhat.com>
CommitDate: Tue, 22 Apr 2014 17:39:09 +0200
perf tools: Fix pmu object compilation error
After applying some patches got another shadowing error:
CC util/pmu.o
util/pmu.c: In function ‘pmu_alias_terms’:
util/pmu.c:287:35: error: declaration of ‘clone’ shadows a global declaration [-Werror=shadow]
Renaming clone to cloned.
Acked-by: David Ahern <dsahern@gmail.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: http://lkml.kernel.org/r/1397674818-27054-1-git-send-email-jolsa@redhat.com
Signed-off-by: Jiri Olsa <jolsa@redhat.com>
---
tools/perf/util/pmu.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tools/perf/util/pmu.c b/tools/perf/util/pmu.c
index 00a7dcb..7a811eb 100644
--- a/tools/perf/util/pmu.c
+++ b/tools/perf/util/pmu.c
@@ -284,17 +284,17 @@ static int pmu_aliases(const char *name, struct list_head *head)
static int pmu_alias_terms(struct perf_pmu_alias *alias,
struct list_head *terms)
{
- struct parse_events_term *term, *clone;
+ struct parse_events_term *term, *cloned;
LIST_HEAD(list);
int ret;
list_for_each_entry(term, &alias->terms, list) {
- ret = parse_events_term__clone(&clone, term);
+ ret = parse_events_term__clone(&cloned, term);
if (ret) {
parse_events__free_terms(&list);
return ret;
}
- list_add_tail(&clone->list, &list);
+ list_add_tail(&cloned->list, &list);
}
list_splice(&list, terms);
return 0;
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-04-22 18:34 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-04-16 19:00 [PATCH] perf tools: Fix pmu object compilation error Jiri Olsa
2014-04-16 19:02 ` David Ahern
2014-04-22 18:33 ` [tip:perf/core] " tip-bot for Jiri Olsa
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).