Sat Jun 27 02:40:24 2020 UTC ()
Fix MODULAR support for ibm4xx by providing __nothing as VM_MDPAGE_INIT().


(rin)
diff -r1.38 -r1.39 src/sys/arch/powerpc/include/pmap.h

cvs diff -r1.38 -r1.39 src/sys/arch/powerpc/include/pmap.h (expand / switch to unified diff)

--- src/sys/arch/powerpc/include/pmap.h 2011/06/20 21:45:16 1.38
+++ src/sys/arch/powerpc/include/pmap.h 2020/06/27 02:40:24 1.39
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: pmap.h,v 1.38 2011/06/20 21:45:16 matt Exp $ */ 1/* $NetBSD: pmap.h,v 1.39 2020/06/27 02:40:24 rin Exp $ */
2 2
3#ifndef _POWERPC_PMAP_H_ 3#ifndef _POWERPC_PMAP_H_
4#define _POWERPC_PMAP_H_ 4#define _POWERPC_PMAP_H_
5 5
6#ifdef _KERNEL_OPT 6#ifdef _KERNEL_OPT
7#include "opt_ppcarch.h" 7#include "opt_ppcarch.h"
8#include "opt_modular.h" 8#include "opt_modular.h"
9#endif 9#endif
10 10
11#if !defined(_MODULE) 11#if !defined(_MODULE)
12 12
13#if defined(PPC_BOOKE) 13#if defined(PPC_BOOKE)
14#include <powerpc/booke/pmap.h> 14#include <powerpc/booke/pmap.h>
@@ -20,24 +20,25 @@ @@ -20,24 +20,25 @@
20#error unknown PPC variant 20#error unknown PPC variant
21#endif 21#endif
22 22
23#endif /* !_MODULE */ 23#endif /* !_MODULE */
24 24
25#if !defined(_LOCORE) && (defined(MODULAR) || defined(_MODULE)) 25#if !defined(_LOCORE) && (defined(MODULAR) || defined(_MODULE))
26/* 26/*
27 * Both BOOKE and OEA use __HAVE_VM_PAGE_MD but IBM4XX doesn't so define 27 * Both BOOKE and OEA use __HAVE_VM_PAGE_MD but IBM4XX doesn't so define
28 * a compatible vm_page_md so that struct vm_page is the same size for all 28 * a compatible vm_page_md so that struct vm_page is the same size for all
29 * PPC variants. 29 * PPC variants.
30 */ 30 */
31#ifndef __HAVE_VM_PAGE_MD 31#ifndef __HAVE_VM_PAGE_MD
32#define __HAVE_VM_PAGE_MD 32#define __HAVE_VM_PAGE_MD
 33#define VM_MDPAGE_INIT(pg) __nothing
33 34
34struct vm_page_md { 35struct vm_page_md {
35 uintptr_t mdpg_dummy[5]; 36 uintptr_t mdpg_dummy[5];
36}; 37};
37#endif /* !__HVE_VM_PAGE_MD */ 38#endif /* !__HVE_VM_PAGE_MD */
38 39
39__CTASSERT(sizeof(struct vm_page_md) == sizeof(uintptr_t)*5); 40__CTASSERT(sizeof(struct vm_page_md) == sizeof(uintptr_t)*5);
40 41
41#endif /* !LOCORE && (MODULAR || _MODULE) */ 42#endif /* !LOCORE && (MODULAR || _MODULE) */
42 43
43#endif /* !_POWERPC_PMAP_H_ */ 44#endif /* !_POWERPC_PMAP_H_ */