Lines Matching refs:ooa_hdr
400 struct ctl_ooa *ooa_hdr,
2438 struct ctl_ooa *ooa_hdr, struct ctl_ooa_entry *kern_entries)
2460 if (*cur_fill_num >= ooa_hdr->alloc_num) {
2664 struct ctl_ooa *ooa_hdr;
2668 ooa_hdr = (struct ctl_ooa *)addr;
2670 if ((ooa_hdr->alloc_len == 0)
2671 || (ooa_hdr->alloc_num == 0)) {
2674 ooa_hdr->alloc_len, ooa_hdr->alloc_num);
2679 if (ooa_hdr->alloc_len != (ooa_hdr->alloc_num *
2683 __func__, ooa_hdr->alloc_len,
2684 ooa_hdr->alloc_num,sizeof(struct ctl_ooa_entry));
2689 entries = malloc(ooa_hdr->alloc_len, M_CTL, M_WAITOK | M_ZERO);
2692 "dump\n", __func__, ooa_hdr->alloc_len);
2698 if ((ooa_hdr->flags & CTL_OOA_FLAG_ALL_LUNS) == 0 &&
2699 (ooa_hdr->lun_num >= ctl_max_luns ||
2700 softc->ctl_luns[ooa_hdr->lun_num] == NULL)) {
2704 __func__, (uintmax_t)ooa_hdr->lun_num);
2711 if (ooa_hdr->flags & CTL_OOA_FLAG_ALL_LUNS) {
2714 ooa_hdr, entries);
2717 lun = softc->ctl_luns[ooa_hdr->lun_num];
2718 ctl_ioctl_fill_ooa(lun, &cur_fill_num, ooa_hdr,
2723 ooa_hdr->fill_num = min(cur_fill_num, ooa_hdr->alloc_num);
2724 ooa_hdr->fill_len = ooa_hdr->fill_num *
2726 retval = copyout(entries, ooa_hdr->entries, ooa_hdr->fill_len);
2729 __func__, ooa_hdr->fill_len);
2732 getbinuptime(&ooa_hdr->cur_bt);
2734 if (cur_fill_num > ooa_hdr->alloc_num) {
2735 ooa_hdr->dropped_num = cur_fill_num -ooa_hdr->alloc_num;
2736 ooa_hdr->status = CTL_OOA_NEED_MORE_SPACE;
2738 ooa_hdr->dropped_num = 0;
2739 ooa_hdr->status = CTL_OOA_OK;