Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bea8f354 authored by Ingo Molnar's avatar Ingo Molnar
Browse files

Merge tag 'perf-core-for-mingo' of...

Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux

 into perf/core

Pull perf/core improvements and fixes from  Arnaldo Carvalho de Melo:

 * Fix handling of unresolved samples when --symbols is used in 'report',
   from Feng Tang.

 * Add --symbols to 'script', similar to the one in 'report', from Feng Tang.

 * Add union member access support to 'probe', from Hyeoncheol Lee.

 * Make 'archive' work on Android, tweaking some of the utility parameters
   used (tar, rm), from Irina Tirdea.

 * Fixups to die() removal, from Namhyung Kim.

 * Render fixes for the TUI, from Namhyung Kim.

 * Don't enable annotation in non symbolic view, from Namhyung Kim.

 * Fix pipe mode in 'report', from Namhyung Kim.

 * Move related stats code from stat to util/, will be used by the 'stat'
   kvm tool, from Xiao Guangrong.

 * Add cpumask for uncore pmu, use it in 'stat', from Yan, Zheng.

Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: default avatarIngo Molnar <mingo@kernel.org>
parents 26f45274 7ae92e74
Loading
Loading
Loading
Loading
+25 −3
Original line number Diff line number Diff line
@@ -2341,6 +2341,27 @@ int uncore_pmu_event_init(struct perf_event *event)
	return ret;
}

static ssize_t uncore_get_attr_cpumask(struct device *dev,
				struct device_attribute *attr, char *buf)
{
	int n = cpulist_scnprintf(buf, PAGE_SIZE - 2, &uncore_cpu_mask);

	buf[n++] = '\n';
	buf[n] = '\0';
	return n;
}

static DEVICE_ATTR(cpumask, S_IRUGO, uncore_get_attr_cpumask, NULL);

static struct attribute *uncore_pmu_attrs[] = {
	&dev_attr_cpumask.attr,
	NULL,
};

static struct attribute_group uncore_pmu_attr_group = {
	.attrs = uncore_pmu_attrs,
};

static int __init uncore_pmu_register(struct intel_uncore_pmu *pmu)
{
	int ret;
@@ -2378,8 +2399,8 @@ static void __init uncore_type_exit(struct intel_uncore_type *type)
		free_percpu(type->pmus[i].box);
	kfree(type->pmus);
	type->pmus = NULL;
	kfree(type->attr_groups[1]);
	type->attr_groups[1] = NULL;
	kfree(type->events_group);
	type->events_group = NULL;
}

static void __init uncore_types_exit(struct intel_uncore_type **types)
@@ -2431,9 +2452,10 @@ static int __init uncore_type_init(struct intel_uncore_type *type)
		for (j = 0; j < i; j++)
			attrs[j] = &type->event_descs[j].attr.attr;

		type->attr_groups[1] = events_group;
		type->events_group = events_group;
	}

	type->pmu_group = &uncore_pmu_attr_group;
	type->pmus = pmus;
	return 0;
fail:
+4 −2
Original line number Diff line number Diff line
@@ -369,10 +369,12 @@ struct intel_uncore_type {
	struct intel_uncore_pmu *pmus;
	struct intel_uncore_ops *ops;
	struct uncore_event_desc *event_descs;
	const struct attribute_group *attr_groups[3];
	const struct attribute_group *attr_groups[4];
};

#define format_group attr_groups[0]
#define pmu_group attr_groups[0]
#define format_group attr_groups[1]
#define events_group attr_groups[2]

struct intel_uncore_ops {
	void (*init_box)(struct intel_uncore_box *);
+1 −1
Original line number Diff line number Diff line
@@ -129,7 +129,7 @@ CFLAGS ?= -g -Wall

# Append required CFLAGS
override CFLAGS += $(CONFIG_FLAGS) $(INCLUDES) $(PLUGIN_DIR_SQ)
override CFLAGS += $(udis86-flags)
override CFLAGS += $(udis86-flags) -D_GNU_SOURCE

ifeq ($(VERBOSE),1)
  Q =
+0 −1
Original line number Diff line number Diff line
@@ -24,7 +24,6 @@
 *  Frederic Weisbecker gave his permission to relicense the code to
 *  the Lesser General Public License.
 */
#define _GNU_SOURCE
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+1 −0
Original line number Diff line number Diff line
@@ -406,6 +406,7 @@ LIB_OBJS += $(OUTPUT)util/target.o
LIB_OBJS += $(OUTPUT)util/rblist.o
LIB_OBJS += $(OUTPUT)util/intlist.o
LIB_OBJS += $(OUTPUT)util/vdso.o
LIB_OBJS += $(OUTPUT)util/stat.o

LIB_OBJS += $(OUTPUT)ui/helpline.o
LIB_OBJS += $(OUTPUT)ui/hist.o
Loading