From: Axel Lin Date: Fri, 21 Oct 2016 01:09:08 +0000 (+0800) Subject: PM / devfreq: exynos-ppmu: ppmu_events array should not be NULL terminated X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f8dbe363ba01de9bebb023f499e7bf9c31f028ab;p=linux-beck.git PM / devfreq: exynos-ppmu: ppmu_events array should not be NULL terminated The rest of the code uses ARRAY_SIZE to count the number of entries in ppmu_events array. The NULL terminated entry makes ARRAY_SIZE return off-by-one value. Signed-off-by: Axel Lin Acked-by: Chanwoo Choi Signed-off-by: MyungJoo Ham --- diff --git a/drivers/devfreq/event/exynos-ppmu.c b/drivers/devfreq/event/exynos-ppmu.c index a112034997eb..958285d5d64b 100644 --- a/drivers/devfreq/event/exynos-ppmu.c +++ b/drivers/devfreq/event/exynos-ppmu.c @@ -90,8 +90,6 @@ struct __exynos_ppmu_events { PPMU_EVENT(d1-cpu), PPMU_EVENT(d1-general), PPMU_EVENT(d1-rt), - - { /* sentinel */ }, }; static int exynos_ppmu_find_ppmu_id(struct devfreq_event_dev *edev)