cam_periph.h (60168) | cam_periph.h (60833) |
---|---|
1/* 2 * Data structures and definitions for CAM peripheral ("type") drivers. 3 * 4 * Copyright (c) 1997, 1998 Justin T. Gibbs. 5 * All rights reserved. 6 * 7 * Redistribution and use in source and binary forms, with or without 8 * modification, are permitted provided that the following conditions --- 11 unchanged lines hidden (view full) --- 20 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 21 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 * | 1/* 2 * Data structures and definitions for CAM peripheral ("type") drivers. 3 * 4 * Copyright (c) 1997, 1998 Justin T. Gibbs. 5 * All rights reserved. 6 * 7 * Redistribution and use in source and binary forms, with or without 8 * modification, are permitted provided that the following conditions --- 11 unchanged lines hidden (view full) --- 20 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 21 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26 * SUCH DAMAGE. 27 * |
28 * $FreeBSD: head/sys/cam/cam_periph.h 60168 2000-05-07 18:04:50Z n_hibma $ | 28 * $FreeBSD: head/sys/cam/cam_periph.h 60833 2000-05-23 20:41:01Z jake $ |
29 */ 30 31#ifndef _CAM_CAM_PERIPH_H 32#define _CAM_CAM_PERIPH_H 1 33 34#include <sys/queue.h> 35 36#ifdef _KERNEL --- 7 unchanged lines hidden (view full) --- 44 * it can perform it's initialization since 45 * the XPT is now fully initialized. 46 */ 47typedef periph_init_t *periph_init_func_t; 48 49struct periph_driver { 50 periph_init_func_t init; 51 char *driver_name; | 29 */ 30 31#ifndef _CAM_CAM_PERIPH_H 32#define _CAM_CAM_PERIPH_H 1 33 34#include <sys/queue.h> 35 36#ifdef _KERNEL --- 7 unchanged lines hidden (view full) --- 44 * it can perform it's initialization since 45 * the XPT is now fully initialized. 46 */ 47typedef periph_init_t *periph_init_func_t; 48 49struct periph_driver { 50 periph_init_func_t init; 51 char *driver_name; |
52 TAILQ_HEAD(,cam_periph) units; | 52 TAILQ_HEAD(, struct cam_periph) units; |
53 u_int generation; 54}; 55 56typedef enum { 57 CAM_PERIPH_BIO, 58 CAM_PERIPH_NET 59} cam_periph_type; 60 --- 23 unchanged lines hidden (view full) --- 84#define CAM_PERIPH_RUNNING 0x01 85#define CAM_PERIPH_LOCKED 0x02 86#define CAM_PERIPH_LOCK_WANTED 0x04 87#define CAM_PERIPH_INVALID 0x08 88#define CAM_PERIPH_NEW_DEV_FOUND 0x10 89#define CAM_PERIPH_RECOVERY_INPROG 0x20 90 u_int32_t immediate_priority; 91 u_int32_t refcount; | 53 u_int generation; 54}; 55 56typedef enum { 57 CAM_PERIPH_BIO, 58 CAM_PERIPH_NET 59} cam_periph_type; 60 --- 23 unchanged lines hidden (view full) --- 84#define CAM_PERIPH_RUNNING 0x01 85#define CAM_PERIPH_LOCKED 0x02 86#define CAM_PERIPH_LOCK_WANTED 0x04 87#define CAM_PERIPH_INVALID 0x08 88#define CAM_PERIPH_NEW_DEV_FOUND 0x10 89#define CAM_PERIPH_RECOVERY_INPROG 0x20 90 u_int32_t immediate_priority; 91 u_int32_t refcount; |
92 SLIST_HEAD(, ccb_hdr) ccb_list; /* For "immediate" requests */ 93 SLIST_ENTRY(cam_periph) periph_links; 94 TAILQ_ENTRY(cam_periph) unit_links; | 92 SLIST_HEAD(, struct ccb_hdr) ccb_list; /* For "immediate" requests */ 93 SLIST_ENTRY(struct cam_periph) periph_links; 94 TAILQ_ENTRY(struct cam_periph) unit_links; |
95 ac_callback_t *deferred_callback; 96 ac_code deferred_ac; 97}; 98 99#define CAM_PERIPH_MAXMAPS 2 100 101struct cam_periph_map_info { 102 int num_bufs_used; --- 49 unchanged lines hidden --- | 95 ac_callback_t *deferred_callback; 96 ac_code deferred_ac; 97}; 98 99#define CAM_PERIPH_MAXMAPS 2 100 101struct cam_periph_map_info { 102 int num_bufs_used; --- 49 unchanged lines hidden --- |