1371853e5SOlivier Houchard /* $NetBSD: sysarch.h,v 1.5 2003/09/11 09:40:12 kleink Exp $ */ 2371853e5SOlivier Houchard 3d8315c79SWarner Losh /*- 4371853e5SOlivier Houchard * Copyright (c) 1996-1997 Mark Brinicombe. 5371853e5SOlivier Houchard * All rights reserved. 6371853e5SOlivier Houchard * 7371853e5SOlivier Houchard * Redistribution and use in source and binary forms, with or without 8371853e5SOlivier Houchard * modification, are permitted provided that the following conditions 9371853e5SOlivier Houchard * are met: 10371853e5SOlivier Houchard * 1. Redistributions of source code must retain the above copyright 11371853e5SOlivier Houchard * notice, this list of conditions and the following disclaimer. 12371853e5SOlivier Houchard * 2. Redistributions in binary form must reproduce the above copyright 13371853e5SOlivier Houchard * notice, this list of conditions and the following disclaimer in the 14371853e5SOlivier Houchard * documentation and/or other materials provided with the distribution. 15371853e5SOlivier Houchard * 3. All advertising materials mentioning features or use of this software 16371853e5SOlivier Houchard * must display the following acknowledgement: 17371853e5SOlivier Houchard * This product includes software developed by Mark Brinicombe. 18371853e5SOlivier Houchard * 4. The name of the company nor the name of the author may be used to 19371853e5SOlivier Houchard * endorse or promote products derived from this software without specific 20371853e5SOlivier Houchard * prior written permission. 21371853e5SOlivier Houchard * 22371853e5SOlivier Houchard * THIS SOFTWARE IS PROVIDED BY AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED 23371853e5SOlivier Houchard * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 24371853e5SOlivier Houchard * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 25371853e5SOlivier Houchard * IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 26371853e5SOlivier Houchard * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 27371853e5SOlivier Houchard * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 28371853e5SOlivier Houchard * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29371853e5SOlivier Houchard * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30371853e5SOlivier Houchard * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31371853e5SOlivier Houchard * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32371853e5SOlivier Houchard * SUCH DAMAGE. 33371853e5SOlivier Houchard */ 34371853e5SOlivier Houchard 35371853e5SOlivier Houchard /* $FreeBSD$ */ 36371853e5SOlivier Houchard 37371853e5SOlivier Houchard #ifndef _ARM_SYSARCH_H_ 38371853e5SOlivier Houchard #define _ARM_SYSARCH_H_ 39371853e5SOlivier Houchard 40371853e5SOlivier Houchard #include <sys/cdefs.h> 41371853e5SOlivier Houchard 42371853e5SOlivier Houchard /* 43371853e5SOlivier Houchard * Pickup definition of uintptr_t 44371853e5SOlivier Houchard */ 45371853e5SOlivier Houchard #include <sys/stdint.h> 46371853e5SOlivier Houchard 47371853e5SOlivier Houchard /* 48371853e5SOlivier Houchard * Architecture specific syscalls (arm) 49371853e5SOlivier Houchard */ 50371853e5SOlivier Houchard 51371853e5SOlivier Houchard #define ARM_SYNC_ICACHE 0 52371853e5SOlivier Houchard #define ARM_DRAIN_WRITEBUF 1 53371853e5SOlivier Houchard 54371853e5SOlivier Houchard struct arm_sync_icache_args { 55371853e5SOlivier Houchard uintptr_t addr; /* Virtual start address */ 56371853e5SOlivier Houchard size_t len; /* Region size */ 57371853e5SOlivier Houchard }; 58371853e5SOlivier Houchard 59371853e5SOlivier Houchard #ifndef _KERNEL 60371853e5SOlivier Houchard __BEGIN_DECLS 61371853e5SOlivier Houchard int arm_sync_icache (u_int addr, int len); 62371853e5SOlivier Houchard int arm_drain_writebuf (void); 63371853e5SOlivier Houchard __END_DECLS 64371853e5SOlivier Houchard #endif 65371853e5SOlivier Houchard 66371853e5SOlivier Houchard #endif /* !_ARM_SYSARCH_H_ */ 67