From: Will Deacon Date: Fri, 2 Dec 2011 17:16:01 +0000 (+0100) Subject: ARM: 7185/1: perf: don't assign platform_device on unsupported CPUs X-Git-Tag: v3.2-rc6~22^2~1 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6bd054096dce061560cee0e016e292e588dc438f;p=pandora-kernel.git ARM: 7185/1: perf: don't assign platform_device on unsupported CPUs In the unlikely case that a platform registers a PMU platform_device when running on a CPU that is unsupported by perf, we will encounter a NULL dereference when trying to assign the platform_device to the cpu_pmu structure. This patch checks that the CPU is supported by perf before assigning the platform_device. Reported-by: Pawel Moll Signed-off-by: Will Deacon Signed-off-by: Russell King --- Reading git-diff-tree failed