struct dqsbuf {
	int bufl,bufc;
	char *bufb;
	struct dqsbuf *bufn;
	struct buf *bufa;
};
struct dqsdat	{
	int  state;
	char qcase,open;
	char *addr;
	int  dly;
	int  ttd,ack0,wack,ackx;
	char eot,enq,nak,etb,etx;
	char slp,time,try;
	int  cc,resp,uoff;
	struct dqsbuf *x,*q,*u;
	struct dqsbuf bf[2];
}dqs;
struct {
	char name[8];
	int type;
	int value;
} nl[2];

main()
{
	int fd;
	cps(&nl[0], "_dqsx");
	nlist("/unix", nl);
	fd = open("/dev/mem", 0);
	lseek(fd, (long)(nl[0].value), 0);
	read(fd, &dqs, 100);
	printf("State=%d  case=%d  open=%d  addr=%o\n",
		dqs.state,dqs.qcase,dqs.open,
			dqs.addr);
	printf("dly=%d ttd=%d ack0=%d wack=%d ackx=%d\n",
		dqs.dly,dqs.ttd,dqs.ack0,dqs.wack,dqs.ackx);
	printf("eot=%d enq=%d nak=%d etb=%d etx=%d\n",
		dqs.eot,dqs.enq,dqs.nak,dqs.etb,dqs.etx);
	printf("slp=%d time=%d try=%d cc=%d resp=%d uoff=%d\n",
		dqs.slp,dqs.time,dqs.try,dqs.cc,dqs.resp,dqs.uoff);
	printf("structs x=%o  q=%o  u=%o\n", dqs.x,dqs.q,dqs.u);
}

cps(s,t)
char *s,*t;
{
while(*s++ = *t++);
}
