Re: [PATCH] Drivers: hv: vmbus: include header for get_irq_regs()

From: Sebastian Andrzej Siewior
Date: Mon Sep 17 2018 - 03:54:29 EST


On 2018-09-15 23:26:53 [+0000], Michael Kelley (EOSG) wrote:
> From Sebastian Andrzej Siewior Sent: Thursday, August 30, 2018 12:55 AM
> >
> > On !RT the header file get_irq_regs() gets pulled in via other header files. On
> > RT it does not and the build fails:
> >
> > drivers/hv/vmbus_drv.c:975 implicit declaration of function âget_irq_regsâ [-
> > Werror=implicit-function-declaration]
> > drivers/hv/hv.c:115 implicit declaration of function âget_irq_regsâ [-Werror=implicit-
> > function-declaration]
> >
> > Add the header file for get_irq_regs() in a common header so it used by
> > vmbus_drv.c by hv.c for their get_irq_regs() usage.
> >
>
> get_irq_regs() is not used explicitly in either vmbus_drv.c or in hv.c. And I
> couldn't make the line numbers in the errors above line up with anything
> in the source code that might be implicitly using get_irq_regs(). Is it the
> calls to add_interrupt_randomness()? Did you figure out
> exactly what line of code is causing the compile error?

The line mentioned in the patch, is correct. I just figured out that
function is added as part preempt-RT.

> I'm wondering whether adding the #include of irq.h into hyperv_vmbus.h
> is really the right solution. More correct might be to have the file where
> get_irq_regs() is actually used to #include irq_regs.h.

nah, leave it. I'm sorry, that I haven't seen it earlier. I will submit
a complete patch once I get there. It popped during a stable update so I
assumed it was something that came via stable but it actually was there
the whole time. Again, sorry for the noise.

> Michael

Sebastian