Lines Matching defs:sim
62 static void ataaction(struct cam_sim *sim, union ccb *ccb);
63 static void atapoll(struct cam_sim *sim);
187 ch->sim = cam_sim_alloc(ataaction, atapoll, "ata", ch,
189 if (ch->sim == NULL) {
190 device_printf(dev, "unable to allocate sim\n");
195 if (xpt_bus_register(ch->sim, dev, 0) != CAM_SUCCESS) {
200 if (xpt_create_path(&ch->path, /*periph*/NULL, cam_sim_path(ch->sim),
210 xpt_bus_deregister(cam_sim_path(ch->sim));
212 cam_sim_free(ch->sim, /*free_devq*/TRUE);
213 ch->sim = NULL;
243 xpt_bus_deregister(cam_sim_path(ch->sim));
244 cam_sim_free(ch->sim, /*free_devq*/TRUE);
245 ch->sim = NULL;
269 if (ch->sim == NULL) {
277 cam_sim_path(ch->sim),
292 xpt_freeze_simq(ch->sim, 1);
307 xpt_release_simq(ch->sim, TRUE);
323 xpt_freeze_simq(ch->sim, 1);
342 xpt_release_simq(ch->sim, TRUE);
898 xpt_freeze_simq(ch->sim, 1);
980 ataaction(struct cam_sim *sim, union ccb *ccb)
988 ch = (struct ata_channel *)cam_sim_softc(sim);
1166 cpi->bus_id = cam_sim_bus(sim);
1173 strlcpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN);
1174 cpi->unit_number = cam_sim_unit(sim);
1201 atapoll(struct cam_sim *sim)
1203 struct ata_channel *ch = (struct ata_channel *)cam_sim_softc(sim);