15b208c27Smrg /* $OpenBSD: pyrovar.h,v 1.3 2007/04/03 19:59:01 kettenis Exp $ */ 25b208c27Smrg 35b208c27Smrg /* 45b208c27Smrg * Copyright (c) 2007 Mark Kettenis 55b208c27Smrg * All rights reserved. 65b208c27Smrg * 75b208c27Smrg * Redistribution and use in source and binary forms, with or without 85b208c27Smrg * modification, are permitted provided that the following conditions 95b208c27Smrg * are met: 105b208c27Smrg * 1. Redistributions of source code must retain the above copyright 115b208c27Smrg * notice, this list of conditions and the following disclaimer. 125b208c27Smrg * 2. Redistributions in binary form must reproduce the above copyright 135b208c27Smrg * notice, this list of conditions and the following disclaimer in the 145b208c27Smrg * documentation and/or other materials provided with the distribution. 155b208c27Smrg * 165b208c27Smrg * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 175b208c27Smrg * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 185b208c27Smrg * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 195b208c27Smrg * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, 205b208c27Smrg * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 215b208c27Smrg * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 225b208c27Smrg * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 235b208c27Smrg * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 245b208c27Smrg * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 255b208c27Smrg * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 265b208c27Smrg * POSSIBILITY OF SUCH DAMAGE. 275b208c27Smrg */ 285b208c27Smrg 295b208c27Smrg struct pyro_range { 305b208c27Smrg u_int32_t cspace; 315b208c27Smrg u_int32_t child_hi; 325b208c27Smrg u_int32_t child_lo; 335b208c27Smrg u_int32_t phys_hi; 345b208c27Smrg u_int32_t phys_lo; 355b208c27Smrg u_int32_t size_hi; 365b208c27Smrg u_int32_t size_lo; 375b208c27Smrg }; 385b208c27Smrg 395b208c27Smrg struct pyro_pbm { 405b208c27Smrg struct pyro_softc *pp_sc; 415b208c27Smrg 425b208c27Smrg struct pyro_range *pp_range; 435b208c27Smrg pci_chipset_tag_t pp_pc; 445b208c27Smrg int pp_nrange; 455b208c27Smrg 465b208c27Smrg bus_space_tag_t pp_memt; 475b208c27Smrg bus_space_tag_t pp_iot; 485b208c27Smrg bus_space_tag_t pp_cfgt; 495b208c27Smrg bus_space_handle_t pp_cfgh; 505b208c27Smrg bus_dma_tag_t pp_dmat; 51a1b3c3f0Smrg int pp_flags; 525b208c27Smrg int pp_bus_a; 535b208c27Smrg struct iommu_state pp_is; 545b208c27Smrg struct strbuf_ctl pp_sb; 555b208c27Smrg }; 565b208c27Smrg 575b208c27Smrg struct pyro_softc { 58*88655ce2Schristos device_t sc_dev; 595b208c27Smrg int sc_node; 605b208c27Smrg int sc_ign; 615b208c27Smrg bus_dma_tag_t sc_dmat; 62a1b3c3f0Smrg bus_space_tag_t sc_bustag; 635b208c27Smrg bus_addr_t sc_csr, sc_xbc; 645b208c27Smrg bus_space_handle_t sc_csrh, sc_xbch; 655b208c27Smrg 665b208c27Smrg int sc_oberon; 675b208c27Smrg }; 68