1.1 --- a/files/pipe_paging.h Sat Mar 27 00:55:05 2021 +0100
1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
1.3 @@ -1,55 +0,0 @@
1.4 -#pragma once
1.5 -
1.6 -#include <list>
1.7 -
1.8 -#include "page_mapper.h"
1.9 -#include "pages_conserving.h"
1.10 -#include "pipe_accessor.h"
1.11 -
1.12 -/* Pipe paging support, maintaining the sequence of active regions or sections
1.13 - in a pipe. */
1.14 -
1.15 -class PipePaging
1.16 -{
1.17 -protected:
1.18 - Memory *_memory;
1.19 - PagesConserving *_pages;
1.20 -
1.21 - /* Regions acting as files with their own accessors. */
1.22 -
1.23 - std::list<PageMapper *> _regions;
1.24 - std::list<PipeAccessor> _accessors;
1.25 -
1.26 - /* Pipe section/region size. */
1.27 -
1.28 - offset_t _size;
1.29 -
1.30 - /* Endpoint status. */
1.31 -
1.32 - unsigned int _endpoints = 2;
1.33 -
1.34 -public:
1.35 - explicit PipePaging(Memory *memory, offset_t size);
1.36 -
1.37 - explicit PipePaging(offset_t size);
1.38 -
1.39 - virtual void detach();
1.40 -
1.41 - virtual PagesConserving *pages()
1.42 - { return _pages; }
1.43 -
1.44 - virtual offset_t region_size()
1.45 - { return _size; }
1.46 -
1.47 - /* Region management. */
1.48 -
1.49 - virtual void add_region(PageMapper *mapper);
1.50 -
1.51 - virtual PageMapper *first_region();
1.52 -
1.53 - virtual PageMapper *next_region();
1.54 -
1.55 - virtual PipeAccessor *accessor();
1.56 -};
1.57 -
1.58 -// vim: tabstop=4 expandtab shiftwidth=4