Those methods are not supposed to change the data structures they manipulate, so make that clearer by using the const qualifier in the function signature and in some variables. Suggested-by: Ingo Molnar <mingo@kernel.org> Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Link: http://lkml.kernel.org/n/tip-j7oyakex7zy3r82h33rdw25x@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
		
			
				
	
	
		
			18 lines
		
	
	
	
		
			496 B
			
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
	
		
			496 B
			
		
	
	
	
		
			C
		
	
	
	
	
	
#ifndef PERF_BUILD_ID_H_
 | 
						|
#define PERF_BUILD_ID_H_ 1
 | 
						|
 | 
						|
#define BUILD_ID_SIZE 20
 | 
						|
 | 
						|
#include "tool.h"
 | 
						|
#include "types.h"
 | 
						|
 | 
						|
extern struct perf_tool build_id__mark_dso_hit_ops;
 | 
						|
struct dso;
 | 
						|
 | 
						|
int build_id__sprintf(const u8 *build_id, int len, char *bf);
 | 
						|
char *dso__build_id_filename(const struct dso *dso, char *bf, size_t size);
 | 
						|
 | 
						|
int build_id__mark_dso_hit(struct perf_tool *tool, union perf_event *event,
 | 
						|
			   struct perf_sample *sample, struct perf_evsel *evsel,
 | 
						|
			   struct machine *machine);
 | 
						|
#endif
 |