2020-10-26 19:46:37

by Diana Madalina Craciun

[permalink] [raw]
Subject: [PATCH] vfio/fsl-mc: Make vfio_fsl_mc_irqs_allocate static

Fixed compiler warning:
drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c:16:5: warning: no previous
prototype for function 'vfio_fsl_mc_irqs_allocate' [-Wmissing-prototypes]
^
drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c:16:1: note: declare 'static'
if the function is not intended to be used outside of this translation unit
int vfio_fsl_mc_irqs_allocate(struct vfio_fsl_mc_device *vdev)

Reported-by: kernel test robot <[email protected]>
Signed-off-by: Diana Craciun <[email protected]>
---
drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c b/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c
index c80dceb46f79..0d9f3002df7f 100644
--- a/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c
+++ b/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c
@@ -13,7 +13,7 @@
#include "linux/fsl/mc.h"
#include "vfio_fsl_mc_private.h"

-int vfio_fsl_mc_irqs_allocate(struct vfio_fsl_mc_device *vdev)
+static int vfio_fsl_mc_irqs_allocate(struct vfio_fsl_mc_device *vdev)
{
struct fsl_mc_device *mc_dev = vdev->mc_dev;
struct vfio_fsl_mc_irq *mc_irq;
--
2.17.1


2020-11-03 18:22:36

by Alex Williamson

[permalink] [raw]
Subject: Re: [PATCH] vfio/fsl-mc: Make vfio_fsl_mc_irqs_allocate static

On Mon, 26 Oct 2020 18:53:36 +0200
Diana Craciun <[email protected]> wrote:

> Fixed compiler warning:
> drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c:16:5: warning: no previous
> prototype for function 'vfio_fsl_mc_irqs_allocate' [-Wmissing-prototypes]
> ^
> drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c:16:1: note: declare 'static'
> if the function is not intended to be used outside of this translation unit
> int vfio_fsl_mc_irqs_allocate(struct vfio_fsl_mc_device *vdev)
>
> Reported-by: kernel test robot <[email protected]>
> Signed-off-by: Diana Craciun <[email protected]>
> ---
> drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)

Applied to vfio for-linus branch for v5.10. Thanks,

Alex


>
> diff --git a/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c b/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c
> index c80dceb46f79..0d9f3002df7f 100644
> --- a/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c
> +++ b/drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c
> @@ -13,7 +13,7 @@
> #include "linux/fsl/mc.h"
> #include "vfio_fsl_mc_private.h"
>
> -int vfio_fsl_mc_irqs_allocate(struct vfio_fsl_mc_device *vdev)
> +static int vfio_fsl_mc_irqs_allocate(struct vfio_fsl_mc_device *vdev)
> {
> struct fsl_mc_device *mc_dev = vdev->mc_dev;
> struct vfio_fsl_mc_irq *mc_irq;