Deleted Added
sdiff udiff text old ( 235318 ) new ( 242681 )
full compact
1/*-
2 * Copyright 2007 Scott Long
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 11 unchanged lines hidden (view full) ---

20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 */
26
27#include <sys/cdefs.h>
28__FBSDID("$FreeBSD: head/sys/dev/mfi/mfi_cam.c 235318 2012-05-12 03:30:50Z sbruno $");
29
30#include "opt_mfi.h"
31
32#include <sys/param.h>
33#include <sys/systm.h>
34#include <sys/kernel.h>
35#include <sys/malloc.h>
36#include <sys/module.h>

--- 37 unchanged lines hidden (view full) ---

74static int mfip_probe(device_t);
75static int mfip_attach(device_t);
76static int mfip_detach(device_t);
77static void mfip_cam_action(struct cam_sim *, union ccb *);
78static void mfip_cam_poll(struct cam_sim *);
79static struct mfi_command * mfip_start(void *);
80static void mfip_done(struct mfi_command *cm);
81
82static devclass_t mfip_devclass;
83static device_method_t mfip_methods[] = {
84 DEVMETHOD(device_probe, mfip_probe),
85 DEVMETHOD(device_attach, mfip_attach),
86 DEVMETHOD(device_detach, mfip_detach),
87 {0, 0}
88};
89static driver_t mfip_driver = {

--- 254 unchanged lines hidden (view full) ---

344 ccbh->status = CAM_REQ_CMP;
345 csio->scsi_status = pt->header.scsi_status;
346 if (ccbh->flags & CAM_CDB_POINTER)
347 command = csio->cdb_io.cdb_ptr[0];
348 else
349 command = csio->cdb_io.cdb_bytes[0];
350 if (command == INQUIRY) {
351 device = csio->data_ptr[0] & 0x1f;
352 if ((device == T_DIRECT) || (device == T_PROCESSOR))
353 csio->data_ptr[0] =
354 (csio->data_ptr[0] & 0xe0) | T_NODEVICE;
355 }
356 break;
357 }
358 case MFI_STAT_SCSI_DONE_WITH_ERROR:
359 {
360 int sense_len;

--- 26 unchanged lines hidden (view full) ---

387
388 mfi_release_command(cm);
389 xpt_done(ccb);
390}
391
392static void
393mfip_cam_poll(struct cam_sim *sim)
394{
395 return;
396}
397