1/* Public domain. */
2
3#ifndef _LINUX_IOPORT_H
4#define _LINUX_IOPORT_H
5
6#include <linux/types.h>
7
8#define IORESOURCE_MEM	0x0001
9
10struct resource {
11	u_long	start;
12	u_long	end;
13};
14
15static inline resource_size_t
16resource_size(const struct resource *r)
17{
18	return r->end - r->start + 1;
19}
20
21#define DEFINE_RES_MEM(_start, _size)		\
22(struct resource) {				\
23		.start = (_start),		\
24		.end = (_start) + (_size) - 1,	\
25	}
26
27#endif
28