[dpdk-dev] contigmem: include <sys/vmmeter.h> to fix FreeBSD build
Checks
Commit Message
otherwise the build fails with FreeBSD 12, like
In file included from contigmem.c:57:
/usr/srcs/head/src/sys/vm/vm_phys.h:122:10: error: use of undeclared
identifier 'vm_cnt'
return (vm_cnt.v_free_count += adj);
^
1 error generated.
*** Error code 1
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
---
lib/librte_eal/bsdapp/contigmem/contigmem.c | 1 +
1 file changed, 1 insertion(+)
--
2.15.0
Comments
On Fri, Dec 01, 2017 at 07:22:39PM +0800, kefu chai wrote:
> otherwise the build fails with FreeBSD 12, like
>
> In file included from contigmem.c:57:
> /usr/srcs/head/src/sys/vm/vm_phys.h:122:10: error: use of undeclared
> identifier 'vm_cnt'
> return (vm_cnt.v_free_count += adj);
> ^
> 1 error generated.
> *** Error code 1
>
> Signed-off-by: Kefu Chai <tchaikov@gmail.com>
> ---
As before:
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
NOTE: for minor changes to patches, feel free to include an acked-by tag
on the patch submission if the previous version had already been acked.
Also, it's good practice to have updated versions marked with a V2
number and posted in reply to the original submission. See dev page on
dpdk.org for more details. http://dpdk.org/dev/
01/12/2017 14:20, Bruce Richardson:
> On Fri, Dec 01, 2017 at 07:22:39PM +0800, kefu chai wrote:
> > otherwise the build fails with FreeBSD 12, like
> >
> > In file included from contigmem.c:57:
> > /usr/srcs/head/src/sys/vm/vm_phys.h:122:10: error: use of undeclared
> > identifier 'vm_cnt'
> > return (vm_cnt.v_free_count += adj);
> > ^
> > 1 error generated.
> > *** Error code 1
> >
> > Signed-off-by: Kefu Chai <tchaikov@gmail.com>
> > ---
> As before:
>
> Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Applied, thanks
b/lib/librte_eal/bsdapp/contigmem/contigmem.c
@@ -45,6 +45,7 @@ __FBSDID("$FreeBSD$");
#include <sys/rwlock.h>
#include <sys/systm.h>
#include <sys/sysctl.h>
+#include <sys/vmmeter.h>
#include <machine/bus.h>