Re: [PATCH v4] drm/panfrost: fix -Wmissing-prototypes warnings

From: Rob Herring
Date: Tue Oct 29 2019 - 14:26:11 EST


On Mon, Oct 28, 2019 at 8:55 PM Yi Wang <wang.yi59@xxxxxxxxxx> wrote:
>
> We get these warnings when build kernel W=1:
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c:35:6: warning: no previous prototype for âpanfrost_perfcnt_clean_cache_doneâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c:40:6: warning: no previous prototype for âpanfrost_perfcnt_sample_doneâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c:190:5: warning: no previous prototype for âpanfrost_ioctl_perfcnt_enableâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c:218:5: warning: no previous prototype for âpanfrost_ioctl_perfcnt_dumpâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c:250:6: warning: no previous prototype for âpanfrost_perfcnt_closeâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c:264:5: warning: no previous prototype for âpanfrost_perfcnt_initâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c:320:6: warning: no previous prototype for âpanfrost_perfcnt_finiâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_mmu.c:227:6: warning: no previous prototype for âpanfrost_mmu_flush_rangeâ [-Wmissing-prototypes]
> drivers/gpu/drm/panfrost/panfrost_mmu.c:435:5: warning: no previous prototype for âpanfrost_mmu_map_fault_addrâ [-Wmissing-prototypes]
>
> For file panfrost_mmu.c, make functions static to fix this.
> For file panfrost_perfcnt.c, include header file can fix this.
>
> Signed-off-by: Yi Wang <wang.yi59@xxxxxxxxxx>
> Reviewed-by: Steven Price <steven.price@xxxxxxx>
> ---
>
> v4: make the parameters aligned.
>
> v3: using tab size of 8 other than 4.
>
> v2: align parameter line and modify comment. Thanks to Steve.
> ---
> drivers/gpu/drm/panfrost/panfrost_mmu.c | 9 +++++----
> drivers/gpu/drm/panfrost/panfrost_perfcnt.c | 1 +
> 2 files changed, 6 insertions(+), 4 deletions(-)

v4 didn't seem to make it to the list yet (non-subscribers get
moderated) and I missed this. I applied v3 and fixed up the alignment.

Rob