138776Snsouch/*- 238776Snsouch * Copyright (c) 1998 Nicolas Souchu 338776Snsouch * All rights reserved. 438776Snsouch * 538776Snsouch * Redistribution and use in source and binary forms, with or without 638776Snsouch * modification, are permitted provided that the following conditions 738776Snsouch * are met: 838776Snsouch * 1. Redistributions of source code must retain the above copyright 938776Snsouch * notice, this list of conditions and the following disclaimer. 1038776Snsouch * 2. Redistributions in binary form must reproduce the above copyright 1138776Snsouch * notice, this list of conditions and the following disclaimer in the 1238776Snsouch * documentation and/or other materials provided with the distribution. 1338776Snsouch * 1438776Snsouch * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 1538776Snsouch * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1638776Snsouch * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 1738776Snsouch * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 1838776Snsouch * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 1938776Snsouch * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 2038776Snsouch * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 2138776Snsouch * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 2238776Snsouch * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 2338776Snsouch * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 2438776Snsouch * SUCH DAMAGE. 2538776Snsouch * 2650477Speter * $FreeBSD$ 2738776Snsouch * 2838776Snsouch */ 2938776Snsouch#ifndef __SMBUS_H 3038776Snsouch#define __SMBUS_H 3138776Snsouch 32281985Sgrembo#define SMBUS_ADDR_MIN 0x10 33281985Sgrembo#define SMBUS_ADDR_MAX 0x70 34281985Sgrembo 3538776Snsouchstruct smbus_softc { 3638776Snsouch device_t owner; /* smbus owner device structure */ 37162234Sjhb struct mtx lock; 38281985Sgrembo unsigned char addrs[SMBUS_ADDR_MAX]; 3938776Snsouch}; 4038776Snsouch 41189580Simpvoid smbus_generic_intr(device_t dev, u_char devaddr, char low, char high, int err); 4238776Snsouch 4338776Snsouch#endif 44