cia_bwx_bus_mem.c revision 1.3
11.3Smrg/* $NetBSD: cia_bwx_bus_mem.c,v 1.3 2000/06/29 08:58:46 mrg Exp $ */
21.1Sthorpej
31.1Sthorpej/*
41.1Sthorpej * Copyright (c) 1996 Carnegie-Mellon University.
51.1Sthorpej * All rights reserved.
61.1Sthorpej *
71.1Sthorpej * Author: Chris G. Demetriou
81.1Sthorpej *
91.1Sthorpej * Permission to use, copy, modify and distribute this software and
101.1Sthorpej * its documentation is hereby granted, provided that both the copyright
111.1Sthorpej * notice and this permission notice appear in all copies of the
121.1Sthorpej * software, derivative works or modified versions, and any portions
131.1Sthorpej * thereof, and that both notices appear in supporting documentation.
141.1Sthorpej *
151.1Sthorpej * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
161.1Sthorpej * CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND
171.1Sthorpej * FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
181.1Sthorpej *
191.1Sthorpej * Carnegie Mellon requests users of this software to return to
201.1Sthorpej *
211.1Sthorpej *  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
221.1Sthorpej *  School of Computer Science
231.1Sthorpej *  Carnegie Mellon University
241.1Sthorpej *  Pittsburgh PA 15213-3890
251.1Sthorpej *
261.1Sthorpej * any improvements or extensions that they make and grant Carnegie the
271.1Sthorpej * rights to redistribute these changes.
281.1Sthorpej */
291.1Sthorpej
301.1Sthorpej#include <sys/cdefs.h>			/* RCS ID & Copyright macro defns */
311.1Sthorpej
321.3Smrg__KERNEL_RCSID(1, "$NetBSD: cia_bwx_bus_mem.c,v 1.3 2000/06/29 08:58:46 mrg Exp $");
331.1Sthorpej
341.1Sthorpej#include <sys/param.h>
351.1Sthorpej#include <sys/systm.h>
361.1Sthorpej#include <sys/malloc.h>
371.1Sthorpej#include <sys/syslog.h>
381.1Sthorpej#include <sys/device.h>
391.3Smrg
401.3Smrg#include <uvm/uvm_extern.h>
411.1Sthorpej
421.1Sthorpej#include <machine/bus.h>
431.1Sthorpej
441.1Sthorpej#include <alpha/pci/ciareg.h>
451.1Sthorpej#include <alpha/pci/ciavar.h>
461.1Sthorpej
471.1Sthorpej#define	CHIP		cia_bwx
481.1Sthorpej
491.1Sthorpej#define	CHIP_EX_MALLOC_SAFE(v)	(((struct cia_config *)(v))->cc_mallocsafe)
501.1Sthorpej#define	CHIP_MEM_EXTENT(v)	(((struct cia_config *)(v))->cc_d_mem_ex)
511.1Sthorpej
521.1Sthorpej#define	CHIP_MEM_SYS_START(v)	CIA_EV56_BWMEM
531.2Sthorpej
541.2Sthorpej/*
551.2Sthorpej * CIA core logic with BWX enabled appears on EV56 and PCA56.  We
561.2Sthorpej * require at least EV56 support for the assembler to emit BWX opcodes.
571.2Sthorpej */
581.2Sthorpej__asm(".arch ev56");
591.1Sthorpej
601.1Sthorpej#include <alpha/pci/pci_bwx_bus_mem_chipdep.c>
61