2010-05-05 13:35:04 +02:00
|
|
|
|
|
|
|
#ifndef _YIELDED_H
|
|
|
|
#define _YIELDED_H 1
|
|
|
|
|
|
|
|
#include <minix/type.h>
|
|
|
|
|
2010-10-15 11:10:14 +02:00
|
|
|
typedef struct block_id {
|
2010-05-05 13:35:04 +02:00
|
|
|
u64_t id;
|
|
|
|
endpoint_t owner;
|
2010-10-15 11:10:14 +02:00
|
|
|
} block_id_t;
|
|
|
|
|
|
|
|
typedef struct yielded {
|
|
|
|
/* the owner-given id and owner together
|
|
|
|
* uniquely identify a yielded block.
|
|
|
|
*/
|
|
|
|
block_id_t id;
|
2012-09-18 13:17:52 +02:00
|
|
|
phys_bytes physaddr;
|
|
|
|
int pages;
|
2010-05-05 13:35:04 +02:00
|
|
|
|
|
|
|
/* LRU fields */
|
|
|
|
struct yielded *younger, *older;
|
|
|
|
|
|
|
|
/* AVL fields */
|
|
|
|
struct yielded *less, *greater;
|
|
|
|
int factor;
|
|
|
|
} yielded_t;
|
|
|
|
|
|
|
|
#endif
|