#ifndef PTY_FAKE_INTERNAL_H
#define PTY_FAKE_INTERNAL_H

/* For PTY/TTY MAJOR no. */
#include <linux/major.h>

/* PTMX_CHMOD is normally defined in the Makefile */
#ifndef PTMX_CHMOD
#define PTMX_CHMOD "/usr/local/lib/pty_chmod"
#endif

/* There doesn't seem to be any standard way of extacting a device
   major/minor no. from a dev_t. */
#ifndef MAJOR
#define MINORBITS       8
#define MINORMASK       ((1<<MINORBITS) - 1)
#define MAJOR(dev)      ((dev) >> MINORBITS)
#define MINOR(dev)      ((dev) & MINORMASK)
#endif

#endif

