osdep.h revision d39a76e7b087a3d0927cbe6898dc0a6770fa6c68
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * CDDL HEADER START
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * The contents of this file are subject to the terms of the
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * Common Development and Distribution License (the "License").
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * You may not use this file except in compliance with the License.
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * See the License for the specific language governing permissions
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * and limitations under the License.
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * When distributing Covered Code, include this CDDL HEADER in each
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * If applicable, add the following below this CDDL HEADER, with the
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * fields enclosed by brackets "[]" replaced with your own identifying
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * information: Portions Copyright [yyyy] [name of copyright owner]
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * CDDL HEADER END
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * Use is subject to license terms.
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * This file is part of the Chelsio T1 Ethernet driver.
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * Copyright (C) 2003-2005 Chelsio Communications. All rights reserved.
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw#pragma ident "%Z%%M% %I% %E% SMI"
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xwextern "C" {
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw * Solaris includes
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw#if defined(__sparc)
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw#define t1_rx_mode_promisc(rmp) (rmp->chp->ch_flags & PEPROMISC)
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw#define t1_rx_mode_allmulti(rmp) (rmp->chp->ch_flags & PEALLMULTI)
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xwvoid t1_os_link_changed(ch_t *adapter, int port_id, int link_status,
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw#define t1_os_set_hw_addr(a, b, c) memcpy(a->port[b].enaddr, c, ETH_ALEN)
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw/* kludge for now */
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw#define SPIN_LOCK_INIT(x) mutex_init(&(x), NULL, MUTEX_DRIVER, NULL);
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xwtypedef struct ch_cyclic_s {
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw void (*func)(void *);
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xwvoid ch_init_cyclic(void *, p_ch_cyclic_t, void (*)(void *), void *);
d39a76e7b087a3d0927cbe6898dc0a6770fa6c68xw#endif /* _CHELSIO_OSDEP_H */