12345678910111213141516171819202122232425262728 |
- $NetBSD: patch-ac,v 1.1.1.1 2002/07/23 12:07:45 agc Exp $
- --- include/isapnp/pnp.h Thu Apr 12 11:51:19 2001
- +++ include/isapnp/pnp.h Mon Jul 22 07:51:51 2002
- @@ -33,13 +33,23 @@
- #else /* !_OS2_ && !__DJGPP__ */
- #ifdef DEBUG
- static int x;
- +#if defined(__NetBSD__) && defined(HAVE_LIBI386)
- +#define ADDRESS(x) (outb(ADDRESS_ADDR, x), printf("\nAddress: %04x", x))
- +#define WRITE_DATA(x) (outb(WRITEDATA_ADDR, x), printf(" WR(%02x)", x & 0xff))
- +#else
- #define ADDRESS(x) (outb(x, ADDRESS_ADDR), printf("\nAddress: %04x", x))
- #define WRITE_DATA(x) (outb(x, WRITEDATA_ADDR), printf(" WR(%02x)", x & 0xff))
- +#endif
- #define READ_DATA (x = inb(read_port), printf(" RD(%02x)", x & 0xff), x)
- #define READ_IOPORT(p) (x = inb(p), printf(" [%04x](%02x)", p, x & 0xff), x)
- #else /* !DEBUG */
- +#if defined(__NetBSD__) && defined(HAVE_LIBI386)
- +#define ADDRESS(x) outb(ADDRESS_ADDR, x)
- +#define WRITE_DATA(x) outb(WRITEDATA_ADDR, x)
- +#else
- #define ADDRESS(x) outb(x, ADDRESS_ADDR)
- #define WRITE_DATA(x) outb(x, WRITEDATA_ADDR)
- +#endif
- #define READ_DATA inb(read_port)
- #define READ_IOPORT(p) inb(p)
- #endif /* !DEBUG */
|