1.\" $NetBSD: xp.4,v 1.1 2022/06/12 03:51:13 tsutsui Exp $ 2.\" $OpenBSD: xp.4,v 1.2 2017/02/11 23:08:43 jmc Exp $ 3.\" 4.\" Copyright (c) 2017 Kenji Aoyama. 5.\" 6.\" Permission to use, copy, modify, and distribute this software for any 7.\" purpose with or without fee is hereby granted, provided that the above 8.\" copyright notice and this permission notice appear in all copies. 9.\" 10.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 11.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 12.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 13.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 14.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 15.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 16.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 17.Dd June 12, 2022 18.Dt XP 4 luna68k 19.Os 20.Sh NAME 21.Nm xp 22.Nd HD647180X I/O processor 23.Sh SYNOPSIS 24.Cd "xpbus0 at mainbus0" 25.Cd "xp0 at xpbus0" 26.Sh DESCRIPTION 27The file 28.Pa /dev/xp 29is an 30.Xr mmap 2 31capable interface to the memory area of the HD647180X I/O processor 32(so-called "XP") on LUNA-I and LUNA-II. 33Byte offsets in this file are interpreted as relative memory addresses 34of the I/O processor. 35The range should be between 0x0 and 0xffff. 36.Pp 37The following 38.Xr ioctl 2 39call applies to 40.Pa /dev/xp : 41.Bl -tag -width 4n 42.It Dv XPIOCDOWNLD Fa "struct xp_download" 43Load binary and reset I/O processor. 44.Bd -literal -offset indent 45struct xp_download { 46 u_int size; 47 u_int8_t *data; 48}; 49.Ed 50.Pp 51The 52.Va size 53member specifies the loading binary size, in bytes. 54The 55.Va data 56member points to the binary image. 57.El 58.Sh FILES 59.Bl -tag -width /dev/xp -compact 60.It Pa /dev/xp 61.El 62.Sh ERRORS 63.Bl -tag -width Er 64.It Bq Er EACCES 65The device is opened without write permission. 66.It Bq Er EINVAL 67The specified size is 0 or more than the I/O processor's memory size. 68.El 69.Sh SEE ALSO 70.Xr ioctl 2 71.Sh HISTORY 72The 73.Pa /dev/xp 74file first appeared in 75.Nx 7.1 . 76