Changeset View
Changeset View
Standalone View
Standalone View
sys/cam/scsi/scsi_target.c
Show First 20 Lines • Show All 398 Lines • ▼ Show 20 Lines | targenable(struct targ_softc *softc, struct cam_path *path, int grp6_len, | ||||
} | } | ||||
if ((cpi.target_sprt & PIT_PROCESSOR) == 0) { | if ((cpi.target_sprt & PIT_PROCESSOR) == 0) { | ||||
printf("controller does not support target mode\n"); | printf("controller does not support target mode\n"); | ||||
status = CAM_FUNC_NOTAVAIL; | status = CAM_FUNC_NOTAVAIL; | ||||
goto enable_fail; | goto enable_fail; | ||||
} | } | ||||
if (cpi.maxio == 0) | if (cpi.maxio == 0) | ||||
softc->maxio = DFLTPHYS; /* traditional default */ | softc->maxio = DFLTPHYS; /* traditional default */ | ||||
else if (cpi.maxio > MAXPHYS) | else if (cpi.maxio > maxphys) | ||||
softc->maxio = MAXPHYS; /* for safety */ | softc->maxio = maxphys; /* for safety */ | ||||
else | else | ||||
softc->maxio = cpi.maxio; /* real value */ | softc->maxio = cpi.maxio; /* real value */ | ||||
/* Destroy any periph on our path if it is disabled */ | /* Destroy any periph on our path if it is disabled */ | ||||
periph = cam_periph_find(path, "targ"); | periph = cam_periph_find(path, "targ"); | ||||
if (periph != NULL) { | if (periph != NULL) { | ||||
struct targ_softc *del_softc; | struct targ_softc *del_softc; | ||||
▲ Show 20 Lines • Show All 742 Lines • Show Last 20 Lines |