File: util.h

package info (click to toggle)
djstub 0.7-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 228 kB
  • sloc: ansic: 1,957; sh: 127; makefile: 72; asm: 15
file content (17 lines) | stat: -rw-r--r-- 429 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#ifndef UTIL_H
#define UTIL_H

#ifndef PAGE_SIZE
#define PAGE_SIZE 4096
#endif
#ifndef PAGE_MASK
#define PAGE_MASK	(~(PAGE_SIZE-1))
#endif
/* to align the pointer to the (next) page boundary */
#define PAGE_ALIGN(addr)	(((addr)+PAGE_SIZE-1)&PAGE_MASK)

void farmemset(char __far *ptr, uint32_t vaddr, uint16_t val, uint32_t size);
long _long_read(int file, char __far *buf, unsigned long offset,
    unsigned long size);

#endif