Lines Matching defs:desc
59 struct ifmedia_description *desc;
61 for (desc = ifm_type_descriptions; desc->ifmt_string != NULL; desc++) {
62 if (IFM_TYPE(mword) == desc->ifmt_word)
63 return (desc->ifmt_string);
71 struct ifmedia_description *desc;
73 for (desc = ifm_subtype_descriptions; desc->ifmt_string != NULL;
74 desc++) {
75 if (IFM_TYPE_MATCH(desc->ifmt_word, mword) &&
76 IFM_SUBTYPE(desc->ifmt_word) == IFM_SUBTYPE(mword))
77 return desc->ifmt_string;
85 struct ifmedia_description *desc;
87 for (desc = ifm_mode_descriptions; desc->ifmt_string != NULL; desc++) {
88 if (IFM_TYPE_MATCH(desc->ifmt_word, mword) &&
89 IFM_MODE(mword) == IFM_MODE(desc->ifmt_word))
90 return desc->ifmt_string;
98 struct ifmedia_description *desc;
101 for (desc = ifm_option_descriptions; desc->ifmt_string != NULL;
102 desc++) {
103 if (!IFM_TYPE_MATCH(desc->ifmt_word, mword))
105 if (mword & IFM_OPTIONS(desc->ifmt_word)) {
106 *mwordp = mword & ~IFM_OPTIONS(desc->ifmt_word);
107 return desc->ifmt_string;
117 lookup_media_word(struct ifmedia_description *desc, int type, const char *val)
120 for (; desc->ifmt_string != NULL; desc++) {
121 if (IFM_TYPE_MATCH(desc->ifmt_word, type) &&
122 strcasecmp(desc->ifmt_string, val) == 0)
123 return (desc->ifmt_word);