Lines Matching defs:tb

409 	sa_lot_t *tb, *findtb;
414 tb = kmem_zalloc(sizeof (sa_lot_t), KM_SLEEP);
415 tb->lot_attr_count = attr_count;
416 tb->lot_attrs = kmem_alloc(sizeof (sa_attr_type_t) * attr_count,
418 memcpy(tb->lot_attrs, attrs, sizeof (sa_attr_type_t) * attr_count);
419 tb->lot_num = lot_num;
420 tb->lot_hash = hash;
421 tb->lot_instance = 0;
438 list_create(&tb->lot_idx_tab, sizeof (sa_idx_tab_t),
442 if (sa->sa_attr_table[tb->lot_attrs[i]].sa_length == 0)
443 tb->lot_var_sizes++;
446 avl_add(&sa->sa_layout_num_tree, tb);
449 if ((findtb = avl_find(&sa->sa_layout_hash_tree, tb, &loc)) != NULL) {
452 if (findtb->lot_instance != tb->lot_instance)
454 tb->lot_instance++;
457 avl_add(&sa->sa_layout_hash_tree, tb);
458 return (tb);
465 sa_lot_t *tb, tbsearch;
473 tb = avl_find(&sa->sa_layout_hash_tree, &tbsearch, &loc);
474 if (tb) {
475 for (; tb && tb->lot_hash == hash;
476 tb = AVL_NEXT(&sa->sa_layout_hash_tree, tb)) {
477 if (sa_layout_equal(tb, attrs, count) == 0) {
484 tb = sa_add_layout_entry(os, attrs, count,
488 *lot = tb;
841 sa_attr_table_t *tb;
907 tb = sa->sa_attr_table =
925 tb[ATTR_NUM(value)].sa_attr = ATTR_NUM(value);
926 tb[ATTR_NUM(value)].sa_length = ATTR_LENGTH(value);
927 tb[ATTR_NUM(value)].sa_byteswap = ATTR_BSWAP(value);
928 tb[ATTR_NUM(value)].sa_registered = B_TRUE;
930 if (tb[ATTR_NUM(value)].sa_name) {
933 tb[ATTR_NUM(value)].sa_name =
935 (void) strlcpy(tb[ATTR_NUM(value)].sa_name, za->za_name,
953 if (tb[i].sa_name)
955 tb[i].sa_attr = sa_legacy_attrs[i].sa_attr;
956 tb[i].sa_length = sa_legacy_attrs[i].sa_length;
957 tb[i].sa_byteswap = sa_legacy_attrs[i].sa_byteswap;
958 tb[i].sa_registered = B_FALSE;
959 tb[i].sa_name =
962 (void) strlcpy(tb[i].sa_name,
972 if (tb[attr_id].sa_name)
975 tb[attr_id].sa_length = reg_attrs[i].sa_length;
976 tb[attr_id].sa_byteswap = reg_attrs[i].sa_byteswap;
977 tb[attr_id].sa_attr = attr_id;
978 tb[attr_id].sa_name =
980 (void) strlcpy(tb[attr_id].sa_name, reg_attrs[i].sa_name,
1004 sa_attr_type_t *tb;
1011 tb = os->os_sa->sa_user_table;
1013 *user_table = tb;
1181 sa_lot_t *tb = tab;
1191 tb = avl_find(&sa->sa_layout_num_tree, &search, &loc);
1192 ASSERT(tb);
1198 (sizeof (uint16_t) * tb->lot_var_sizes)), 8);
1204 for (i = 0; i != tb->lot_attr_count; i++) {
1208 reg_length = sa->sa_attr_table[tb->lot_attrs[i]].sa_length;
1218 func(hdr, data_start, tb->lot_attrs[i], attr_length,
1760 sa_lot_t *tb, search;
1774 tb = avl_find(&sa->sa_layout_num_tree, &search, &loc);
1777 ASSERT(tb);
1779 SA_HDR_SIZE_MATCH_LAYOUT(hdr, tb)) || !IS_SA_BONUSTYPE(bonustype) ||
1786 for (idx_tab = list_head(&tb->lot_idx_tab); idx_tab;
1787 idx_tab = list_next(&tb->lot_idx_tab, idx_tab)) {
1791 if (tb->lot_var_sizes != 0 &&
1793 for (i = 0; i != tb->lot_var_sizes; i++) {
1811 idx_tab->sa_layout = tb;
1813 if (tb->lot_var_sizes)
1815 tb->lot_var_sizes, KM_SLEEP);
1818 tb, idx_tab);
1821 list_insert_tail(&tb->lot_idx_tab, idx_tab);
1840 sa_attr_table_t *tb = sa->sa_attr_table;
1858 ATTR_ENCODE(attr_value, tb[i].sa_attr, tb[i].sa_length,
1859 tb[i].sa_byteswap);
1861 tb[i].sa_name, 8, 1, &attr_value, tx));
1862 tb[i].sa_registered = B_TRUE;