Lines Matching defs:mtp
2895 mactype_t *mtp;
2914 mtp = kmem_zalloc(sizeof (*mtp), KM_SLEEP);
2915 mtp->mt_ident = mtrp->mtr_ident;
2916 mtp->mt_ops = *ops;
2917 mtp->mt_type = mtrp->mtr_mactype;
2918 mtp->mt_nativetype = mtrp->mtr_nativetype;
2919 mtp->mt_addr_length = mtrp->mtr_addrlen;
2921 mtp->mt_brdcst_addr = kmem_alloc(mtrp->mtr_addrlen, KM_SLEEP);
2922 bcopy(mtrp->mtr_brdcst_addr, mtp->mt_brdcst_addr,
2926 mtp->mt_stats = mtrp->mtr_stats;
2927 mtp->mt_statcount = mtrp->mtr_statcount;
2929 mtp->mt_mapping = mtrp->mtr_mapping;
2930 mtp->mt_mappingcount = mtrp->mtr_mappingcount;
2933 (mod_hash_key_t)mtp->mt_ident, (mod_hash_val_t)mtp) != 0) {
2934 kmem_free(mtp->mt_brdcst_addr, mtp->mt_addr_length);
2935 kmem_free(mtp, sizeof (*mtp));
2944 mactype_t *mtp;
2957 (mod_hash_val_t *)&mtp)) != 0) {
2963 if (mtp->mt_ref != 0) {
2975 ASSERT(mtp == (mactype_t *)val);
2977 if (mtp->mt_brdcst_addr != NULL)
2978 kmem_free(mtp->mt_brdcst_addr, mtp->mt_addr_length);
2979 kmem_free(mtp, sizeof (mactype_t));