fwmem.h revision 1.1
11.1Skiyohara/* $NetBSD: fwmem.h,v 1.1 2005/07/11 15:29:05 kiyohara Exp $ */ 21.1Skiyohara/*- 31.1Skiyohara * Copyright (C) 2002-2003 41.1Skiyohara * Hidetoshi Shimokawa. All rights reserved. 51.1Skiyohara * 61.1Skiyohara * Redistribution and use in source and binary forms, with or without 71.1Skiyohara * modification, are permitted provided that the following conditions 81.1Skiyohara * are met: 91.1Skiyohara * 1. Redistributions of source code must retain the above copyright 101.1Skiyohara * notice, this list of conditions and the following disclaimer. 111.1Skiyohara * 2. Redistributions in binary form must reproduce the above copyright 121.1Skiyohara * notice, this list of conditions and the following disclaimer in the 131.1Skiyohara * documentation and/or other materials provided with the distribution. 141.1Skiyohara * 3. All advertising materials mentioning features or use of this software 151.1Skiyohara * must display the following acknowledgement: 161.1Skiyohara * 171.1Skiyohara * This product includes software developed by Hidetoshi Shimokawa. 181.1Skiyohara * 191.1Skiyohara * 4. Neither the name of the author nor the names of its contributors 201.1Skiyohara * may be used to endorse or promote products derived from this software 211.1Skiyohara * without specific prior written permission. 221.1Skiyohara * 231.1Skiyohara * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 241.1Skiyohara * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 251.1Skiyohara * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 261.1Skiyohara * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 271.1Skiyohara * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 281.1Skiyohara * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 291.1Skiyohara * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 301.1Skiyohara * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 311.1Skiyohara * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 321.1Skiyohara * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 331.1Skiyohara * SUCH DAMAGE. 341.1Skiyohara * 351.1Skiyohara * $FreeBSD: /repoman/r/ncvs/src/sys/dev/firewire/fwmem.h,v 1.8 2005/01/06 01:42:41 imp Exp $ 361.1Skiyohara */ 371.1Skiyohara 381.1Skiyoharastruct fw_xfer *fwmem_read_quad(struct fw_device *, caddr_t, uint8_t, 391.1Skiyohara uint16_t, uint32_t, void *, void (*)(struct fw_xfer *)); 401.1Skiyoharastruct fw_xfer *fwmem_write_quad(struct fw_device *, caddr_t, uint8_t, 411.1Skiyohara uint16_t, uint32_t, void *, void (*)(struct fw_xfer *)); 421.1Skiyoharastruct fw_xfer *fwmem_read_block(struct fw_device *, caddr_t, uint8_t, 431.1Skiyohara uint16_t, uint32_t, int, void *, void (*)(struct fw_xfer *)); 441.1Skiyoharastruct fw_xfer *fwmem_write_block(struct fw_device *, caddr_t, uint8_t, 451.1Skiyohara uint16_t, uint32_t, int, void *, void (*)(struct fw_xfer *)); 461.1Skiyohara 471.1Skiyohara#if defined(__FreeBSD__) 481.1Skiyoharad_open_t fwmem_open; 491.1Skiyoharad_close_t fwmem_close; 501.1Skiyoharad_ioctl_t fwmem_ioctl; 511.1Skiyoharad_read_t fwmem_read; 521.1Skiyoharad_write_t fwmem_write; 531.1Skiyoharad_poll_t fwmem_poll; 541.1Skiyoharad_mmap_t fwmem_mmap; 551.1Skiyoharad_strategy_t fwmem_strategy; 561.1Skiyohara#elif defined(__NetBSD__) 571.1Skiyoharadev_type_open(fwmem_open); 581.1Skiyoharadev_type_close(fwmem_close); 591.1Skiyoharadev_type_ioctl(fwmem_ioctl); 601.1Skiyoharadev_type_read(fwmem_read); 611.1Skiyoharadev_type_write(fwmem_write); 621.1Skiyoharadev_type_poll(fwmem_poll); 631.1Skiyoharadev_type_mmap(fwmem_mmap); 641.1Skiyoharadev_type_strategy(fwmem_strategy); 651.1Skiyohara#endif 66