Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/ic conditionally put back the include of <uvm/uvm_pa...



details:   https://anonhg.NetBSD.org/src/rev/07b0cc5132de
branches:  trunk
changeset: 1022773:07b0cc5132de
user:      tnn <tnn%NetBSD.org@localhost>
date:      Fri Aug 06 18:15:48 2021 +0000

description:
conditionally put back the include of <uvm/uvm_page.h>

This is a kludge to fix the build on some ports. According to pmap(9),
including <uvm/uvm_extern.h> should be sufficient to use
"bool pmap_is_modified(struct vm_page *pg)". However, on several ports,
the function is implemented as a macro and depends on implementation
details of "struct vm_page *", which is normally an incomplete forward
declaration only. XXX revert when all ports are fixed.

diffstat:

 sys/dev/ic/ssdfb.c |  7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diffs (28 lines):

diff -r 8d3884cd5e74 -r 07b0cc5132de sys/dev/ic/ssdfb.c
--- a/sys/dev/ic/ssdfb.c        Fri Aug 06 16:21:00 2021 +0000
+++ b/sys/dev/ic/ssdfb.c        Fri Aug 06 18:15:48 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ssdfb.c,v 1.19 2021/08/05 22:31:20 tnn Exp $ */
+/* $NetBSD: ssdfb.c,v 1.20 2021/08/06 18:15:48 tnn Exp $ */
 
 /*
  * Copyright (c) 2019 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ssdfb.c,v 1.19 2021/08/05 22:31:20 tnn Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ssdfb.c,v 1.20 2021/08/06 18:15:48 tnn Exp $");
 
 #include "opt_ddb.h"
 
@@ -43,6 +43,9 @@
 
 #include <uvm/uvm_device.h>
 #include <uvm/uvm_extern.h>
+#ifdef pmap_is_modified
+#include <uvm/uvm_page.h>
+#endif
 
 #include <dev/wscons/wsdisplayvar.h>
 #include <dev/rasops/rasops.h>



Home | Main Index | Thread Index | Old Index