1 /* 2 * Copyright (c) 1992 William Jolitz. All rights reserved. 3 * Written by William Jolitz 1/92 4 * 5 * Redistribution and use in source and binary forms are freely permitted 6 * provided that the above copyright notice and attribution and date of work 7 * and this paragraph are duplicated in all such forms. 8 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR 9 * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED 10 * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. 11 * 12 * Resource lists. 13 * $Id$ 14 */ 15 16 /* A resource list element. */ 17 struct rlist { 18 unsigned rl_start; /* boundaries of extent - inclusive */ 19 unsigned rl_end; /* boundaries of extent - inclusive */ 20 struct rlist *rl_next; /* next list entry, if present */ 21 }; 22 23 /* Functions to manipulate resource lists. */ 24 void rlist_free(struct rlist **, unsigned, unsigned); 25 int rlist_alloc(struct rlist **, unsigned, unsigned *); 26 void rlist_destroy(struct rlist **); 27