Lines Matching refs:mapinfo

805 cam_periph_mapmem(union ccb *ccb, struct cam_periph_map_info *mapinfo,  in cam_periph_mapmem()  argument
813 bzero(mapinfo, sizeof(*mapinfo)); in cam_periph_mapmem()
933 mapinfo->orig[i] = *data_ptrs[i]; in cam_periph_mapmem()
946 if (copyin(mapinfo->orig[i], *data_ptrs[i], in cam_periph_mapmem()
949 *data_ptrs[i] = mapinfo->orig[i]; in cam_periph_mapmem()
960 mapinfo->bp[i] = uma_zalloc(pbuf_zone, M_WAITOK); in cam_periph_mapmem()
963 mapinfo->bp[i]->b_iocmd = (dirs[i] == CAM_DIR_OUT) ? in cam_periph_mapmem()
967 if (vmapbuf(mapinfo->bp[i], *data_ptrs[i], lengths[i], 1) < 0) { in cam_periph_mapmem()
968 uma_zfree(pbuf_zone, mapinfo->bp[i]); in cam_periph_mapmem()
973 *data_ptrs[i] = mapinfo->bp[i]->b_data; in cam_periph_mapmem()
982 if (mapinfo->bp[i]) in cam_periph_mapmem()
983 BUF_KERNPROC(mapinfo->bp[i]); in cam_periph_mapmem()
986 mapinfo->num_bufs_used = numbufs; in cam_periph_mapmem()
991 if (mapinfo->bp[i]) { in cam_periph_mapmem()
992 vunmapbuf(mapinfo->bp[i]); in cam_periph_mapmem()
993 uma_zfree(pbuf_zone, mapinfo->bp[i]); in cam_periph_mapmem()
996 *data_ptrs[i] = mapinfo->orig[i]; in cam_periph_mapmem()
1006 cam_periph_unmapmem(union ccb *ccb, struct cam_periph_map_info *mapinfo) in cam_periph_unmapmem() argument
1013 if (mapinfo->num_bufs_used <= 0) { in cam_periph_unmapmem()
1086 if (mapinfo->bp[i]) { in cam_periph_unmapmem()
1088 vunmapbuf(mapinfo->bp[i]); in cam_periph_unmapmem()
1091 uma_zfree(pbuf_zone, mapinfo->bp[i]); in cam_periph_unmapmem()
1096 error1 = copyout(*data_ptrs[i], mapinfo->orig[i], in cam_periph_unmapmem()
1105 *data_ptrs[i] = mapinfo->orig[i]; in cam_periph_unmapmem()