1157299Smarcel/*-
2157299Smarcel * Copyright (c) 2004-2006 Marcel Moolenaar
3157299Smarcel * All rights reserved.
4157299Smarcel *
5157299Smarcel * Redistribution and use in source and binary forms, with or without
6157299Smarcel * modification, are permitted provided that the following conditions
7157299Smarcel * are met:
8157299Smarcel *
9157299Smarcel * 1. Redistributions of source code must retain the above copyright
10157299Smarcel *    notice, this list of conditions and the following disclaimer.
11157299Smarcel * 2. Redistributions in binary form must reproduce the above copyright
12157299Smarcel *    notice, this list of conditions and the following disclaimer in the
13157299Smarcel *    documentation and/or other materials provided with the distribution.
14157299Smarcel *
15157299Smarcel * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16157299Smarcel * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17157299Smarcel * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18157299Smarcel * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19157299Smarcel * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20157299Smarcel * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21157299Smarcel * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22157299Smarcel * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23157299Smarcel * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24157299Smarcel * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25157299Smarcel *
26157299Smarcel * $FreeBSD$
27157299Smarcel */
28157299Smarcel
29157299Smarcel#ifndef _DEV_SCC_BUS_H_
30157299Smarcel#define	_DEV_SCC_BUS_H_
31157299Smarcel
32157299Smarcel#include <sys/serial.h>
33157299Smarcel#include <serdev_if.h>
34157299Smarcel
35157299Smarcel#define	SCC_IVAR_CHANNEL	0
36157299Smarcel#define	SCC_IVAR_CLASS		1
37157299Smarcel#define	SCC_IVAR_CLOCK		2
38157299Smarcel#define	SCC_IVAR_MODE		3
39157299Smarcel#define	SCC_IVAR_REGSHFT	4
40157299Smarcel#define	SCC_IVAR_HWMTX		5
41157299Smarcel
42157299Smarcel/* Hardware class -- the SCC type. */
43157299Smarcel#define	SCC_CLASS_SAB82532	0
44157299Smarcel#define	SCC_CLASS_Z8530		1
45176772Sraj#define	SCC_CLASS_QUICC		2
46157299Smarcel
47157299Smarcel/* The possible modes supported by the SCC. */
48157299Smarcel#define	SCC_MODE_ASYNC		0x01
49157299Smarcel#define	SCC_MODE_BISYNC		0x02
50157299Smarcel#define	SCC_MODE_HDLC		0x04
51157299Smarcel
52157299Smarcel#endif /* _DEV_SCC_BUS_H_ */
53