Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1232648
| From | Jiri Olsa <jolsa@redhat.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 1/2] perf tools: Prompt error message for wrong terms of hw/sw events |
| Date | 2015-09-25 10:20 +0200 |
| Message-ID | <qcwox-48h-1@gated-at.bofh.it> (permalink) |
| References | <qcrRU-6eR-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, Sep 25, 2015 at 03:21:18AM +0000, He Kuang wrote:
SNIP
> static int config_attr(struct perf_event_attr *attr,
> struct list_head *head,
> - struct parse_events_error *err)
> + struct parse_events_error *err,
> + config_term_func_t config_term)
> {
> struct parse_events_term *term;
>
> @@ -735,7 +751,8 @@ int parse_events_add_numeric(struct parse_events_evlist *data,
> attr.config = config;
>
> if (head_config) {
> - if (config_attr(&attr, head_config, data->error))
> + if (config_attr(&attr, head_config, data->error,
> + config_term_common))
> return -EINVAL;
>
> if (get_config_terms(head_config, &config_terms))
> @@ -795,7 +812,7 @@ int parse_events_add_pmu(struct parse_events_evlist *data,
> * Configure hardcoded terms first, no need to check
> * return value when called with fail == 0 ;)
> */
> - if (config_attr(&attr, head_config, data->error))
> + if (config_attr(&attr, head_config, data->error, config_term_pmu))
> return -EINVAL;
>
> if (get_config_terms(head_config, &config_terms))
> @@ -1861,3 +1878,26 @@ void parse_events_evlist_error(struct parse_events_evlist *data,
> err->str = strdup(str);
> WARN_ONCE(!err->str, "WARNING: failed to allocate error string");
could you please plit this into the part that adds the
config_term callback and the error message formating change?
thanks,
jirka
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH 1/2] perf tools: Prompt error message for wrong terms of hw/sw events He Kuang <hekuang@huawei.com> - 2015-09-25 05:30 +0200
[PATCH 2/2] perf tools: Enable event_config terms to tracepoint events He Kuang <hekuang@huawei.com> - 2015-09-25 05:30 +0200
Re: [PATCH 2/2] perf tools: Enable event_config terms to tracepoint events Jiri Olsa <jolsa@redhat.com> - 2015-09-25 10:30 +0200
Re: [PATCH 2/2] perf tools: Enable event_config terms to tracepoint events Jiri Olsa <jolsa@redhat.com> - 2015-09-25 10:40 +0200
Re: [PATCH 1/2] perf tools: Prompt error message for wrong terms of hw/sw events Jiri Olsa <jolsa@redhat.com> - 2015-09-25 10:20 +0200
csiph-web