isp_freebsd.h (316401) | isp_freebsd.h (316403) |
---|---|
1/* $FreeBSD: stable/10/sys/dev/isp/isp_freebsd.h 316401 2017-04-02 10:53:37Z mav $ */ | 1/* $FreeBSD: stable/10/sys/dev/isp/isp_freebsd.h 316403 2017-04-02 10:54:58Z mav $ */ |
2/*- 3 * Qlogic ISP SCSI Host Adapter FreeBSD Wrapper Definitions 4 * 5 * Copyright (c) 1997-2008 by Matthew Jacob 6 * All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without 9 * modification, are permitted provided that the following conditions --- 341 unchanged lines hidden (view full) --- 351#define FCP_NEXT_CRN isp_fcp_next_crn 352#define isp_lock isp_osinfo.lock 353#define isp_regs isp_osinfo.regs 354#define isp_regs2 isp_osinfo.regs2 355 356/* 357 * Locking macros... 358 */ | 2/*- 3 * Qlogic ISP SCSI Host Adapter FreeBSD Wrapper Definitions 4 * 5 * Copyright (c) 1997-2008 by Matthew Jacob 6 * All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without 9 * modification, are permitted provided that the following conditions --- 341 unchanged lines hidden (view full) --- 351#define FCP_NEXT_CRN isp_fcp_next_crn 352#define isp_lock isp_osinfo.lock 353#define isp_regs isp_osinfo.regs 354#define isp_regs2 isp_osinfo.regs2 355 356/* 357 * Locking macros... 358 */ |
359#define ISP_LOCK(isp) mtx_lock(&(isp)->isp_osinfo.lock) 360#define ISP_UNLOCK(isp) mtx_unlock(&(isp)->isp_osinfo.lock) 361#define ISP_ASSERT_LOCKED(isp) mtx_assert(&(isp)->isp_osinfo.lock, MA_OWNED) | 359#define ISP_LOCK(isp) mtx_lock(&(isp)->isp_lock) 360#define ISP_UNLOCK(isp) mtx_unlock(&(isp)->isp_lock) 361#define ISP_ASSERT_LOCKED(isp) mtx_assert(&(isp)->isp_lock, MA_OWNED) |
362 363/* 364 * Required Macros/Defines 365 */ 366#define ISP_FC_SCRLEN 0x1000 367 368#define ISP_MEMZERO(a, b) memset(a, 0, b) 369#define ISP_MEMCPY memcpy 370#define ISP_SNPRINTF snprintf 371#define ISP_DELAY(x) DELAY(x) 372#define ISP_SLEEP(isp, x) msleep_sbt(&(isp)->isp_osinfo.is_exiting, \ | 362 363/* 364 * Required Macros/Defines 365 */ 366#define ISP_FC_SCRLEN 0x1000 367 368#define ISP_MEMZERO(a, b) memset(a, 0, b) 369#define ISP_MEMCPY memcpy 370#define ISP_SNPRINTF snprintf 371#define ISP_DELAY(x) DELAY(x) 372#define ISP_SLEEP(isp, x) msleep_sbt(&(isp)->isp_osinfo.is_exiting, \ |
373 &(isp)->isp_osinfo.lock, 0, "isp_sleep", (x) * SBT_1US, 0, 0) | 373 &(isp)->isp_lock, 0, "isp_sleep", (x) * SBT_1US, 0, 0) |
374 375#define ISP_MIN imin 376 377#ifndef DIAGNOSTIC 378#define ISP_INLINE __inline 379#else 380#define ISP_INLINE 381#endif --- 335 unchanged lines hidden (view full) --- 717void isp_platform_intr_atio(void *); 718void isp_common_dmateardown(ispsoftc_t *, struct ccb_scsiio *, uint32_t); 719void isp_fcp_reset_crn(ispsoftc_t *, int, uint32_t, int); 720int isp_fcp_next_crn(ispsoftc_t *, uint8_t *, XS_T *); 721 722/* 723 * Platform Version specific defines 724 */ | 374 375#define ISP_MIN imin 376 377#ifndef DIAGNOSTIC 378#define ISP_INLINE __inline 379#else 380#define ISP_INLINE 381#endif --- 335 unchanged lines hidden (view full) --- 717void isp_platform_intr_atio(void *); 718void isp_common_dmateardown(ispsoftc_t *, struct ccb_scsiio *, uint32_t); 719void isp_fcp_reset_crn(ispsoftc_t *, int, uint32_t, int); 720int isp_fcp_next_crn(ispsoftc_t *, uint8_t *, XS_T *); 721 722/* 723 * Platform Version specific defines 724 */ |
725#define BUS_DMA_ROOTARG(x) bus_get_dma_tag(x) 726#define isp_dma_tag_create(a, b, c, d, e, f, g, h, i, j, k, z) \ 727 bus_dma_tag_create(a, b, c, d, e, f, g, h, i, j, k, \ 728 busdma_lock_mutex, &isp->isp_osinfo.lock, z) 729 730#define isp_sim_alloc(a, b, c, d, e, f, g, h) \ 731 cam_sim_alloc(a, b, c, d, e, &(d)->isp_osinfo.lock, f, g, h) 732 | |
733#define ISP_PATH_PRT(i, l, p, ...) \ 734 if ((l) == ISP_LOGALL || ((l)& (i)->isp_dblev) != 0) { \ 735 xpt_print(p, __VA_ARGS__); \ 736 } 737 738/* 739 * Platform specific inline functions 740 */ 741 742/* 743 * ISP General Library functions 744 */ 745 746#include <dev/isp/isp_library.h> 747 748#endif /* _ISP_FREEBSD_H */ | 725#define ISP_PATH_PRT(i, l, p, ...) \ 726 if ((l) == ISP_LOGALL || ((l)& (i)->isp_dblev) != 0) { \ 727 xpt_print(p, __VA_ARGS__); \ 728 } 729 730/* 731 * Platform specific inline functions 732 */ 733 734/* 735 * ISP General Library functions 736 */ 737 738#include <dev/isp/isp_library.h> 739 740#endif /* _ISP_FREEBSD_H */ |