From: Stephane Eranian Date: Mon, 6 Oct 2014 08:35:32 +0000 (+0200) Subject: perf tools: fix off-by-one error in maps X-Git-Tag: fixes-against-v3.18-rc2~37^2~3^2~3 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=77faf4d060e3ee1fd2ff6cd39f2b2eb887100422;p=pandora-kernel.git perf tools: fix off-by-one error in maps This patch fixes off-by-one errors in the management of maps. A map is defined by start address and length as implemented by map__new(): map__init(map, type, start, start + len, pgoff, dso); map->start = addr; map->end = end; Consequently, the actual address range is [start; end[ map->end is the first byte outside the range. This patch fixes two bugs where upper bound checking was off-by-one. In V2, we fix map_groups__fixup_overlappings() some more where map->start was off-by-one as reported by Jiri. Signed-off-by: Stephane Eranian Acked-by: Namhyung Kim Cc: David Ahern Cc: Ingo Molnar Cc: Jiri Olsa Cc: Namhyung Kim Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/20141006083532.GA4850@quad Signed-off-by: Arnaldo Carvalho de Melo --- Reading git-diff-tree failed