1/* 2 * Copyright 2010, Ingo Weinhold, ingo_weinhold@gmx.de. 3 * Distributed under the terms of the MIT License. 4 */ 5#ifndef KERNEL_ARCH_M68K_PAGING_M68K_PAGING_METHOD_H 6#define KERNEL_ARCH_M68K_PAGING_M68K_PAGING_METHOD_H 7 8 9#include <SupportDefs.h> 10 11 12struct kernel_args; 13struct VMPhysicalPageMapper; 14struct VMTranslationMap; 15 16 17class M68KPagingMethod { 18public: 19 virtual ~M68KPagingMethod(); 20 21 virtual status_t Init(kernel_args* args, 22 VMPhysicalPageMapper** _physicalPageMapper) 23 = 0; 24 virtual status_t InitPostArea(kernel_args* args) = 0; 25 26 virtual status_t CreateTranslationMap(bool kernel, 27 VMTranslationMap** _map) = 0; 28 29 virtual status_t MapEarly(kernel_args* args, 30 addr_t virtualAddress, 31 phys_addr_t physicalAddress, 32 uint8 attributes, 33 phys_addr_t (*get_free_page)(kernel_args*)) 34 = 0; 35 36 virtual bool IsKernelPageAccessible(addr_t virtualAddress, 37 uint32 protection) = 0; 38 39 virtual void SetPageRoot(uint32 pageRoot) = 0; 40}; 41 42 43extern M68KPagingMethod* gM68KPagingMethod; 44 45 46#endif // KERNEL_ARCH_M68K_PAGING_M68K_PAGING_METHOD_H 47