Lines Matching refs:desc

130 lookup_media_desc(const struct ifmedia_description *desc, const char *name)
133 for (; desc->ifmt_string != NULL; ++desc)
134 if (strcasecmp(desc->ifmt_string, name) == 0)
135 return (desc);
141 const struct ifmedia_description *desc;
146 const struct ifmedia_description *desc;
151 const struct ifmedia_description *desc;
221 const struct ifmedia_description *desc;
224 for (desc = ifm_type_descriptions, ttos = ifmedia_types_to_subtypes;
225 desc->ifmt_string != NULL; desc++, ttos++) {
226 if (IFM_TYPE(media) == desc->ifmt_word)
236 const struct ifmedia_description *desc;
238 for (desc = ifm_type_descriptions; desc->ifmt_string != NULL; ++desc) {
239 if (IFM_TYPE(media) == desc->ifmt_word)
240 return (desc->ifmt_string);
249 const struct ifmedia_description *desc;
251 desc = lookup_media_desc(ifm_type_descriptions, name);
252 return (desc == NULL ? INVALID_IFMEDIA : desc->ifmt_word);
258 const struct ifmedia_description *desc;
267 for (size_t i = 0; ttos->subtypes[i].desc != NULL; ++i) {
270 for (desc = ttos->subtypes[i].desc;
271 desc->ifmt_string != NULL; ++desc) {
272 if (IFM_SUBTYPE(media) == desc->ifmt_word)
273 return (desc->ifmt_string);
283 const struct ifmedia_description *desc;
292 for (size_t i = 0; ttos->subtypes[i].desc != NULL; ++i) {
293 desc = lookup_media_desc(ttos->subtypes[i].desc, name);
294 if (desc != NULL)
295 return (desc->ifmt_word);
304 const struct ifmedia_description *desc;
313 for (size_t i = 0; ttos->modes[i].desc != NULL; ++i) {
316 for (desc = ttos->modes[i].desc;
317 desc->ifmt_string != NULL; ++desc) {
318 if (IFM_MODE(media) == desc->ifmt_word)
319 return (desc->ifmt_string);
329 const struct ifmedia_description *desc;
338 for (size_t i = 0; ttos->modes[i].desc != NULL; ++i) {
339 desc = lookup_media_desc(ttos->modes[i].desc, name);
340 if (desc != NULL)
341 return (desc->ifmt_word);
351 const struct ifmedia_description *desc;
362 for (size_t i = 0; ttos->options[i].desc != NULL; ++i) {
365 for (desc = ttos->options[i].desc;
366 desc->ifmt_string != NULL; ++desc) {
367 if ((media & desc->ifmt_word) != 0)
382 for (size_t i = 0; ttos->options[i].desc != NULL; ++i) {
385 for (desc = ttos->options[i].desc;
386 desc->ifmt_string != NULL; ++desc) {
387 if ((media & desc->ifmt_word) != 0) {
388 options[n] = desc->ifmt_string;
400 const struct ifmedia_description *desc, *opt;
417 for (size_t i = 0; ttos->options[i].desc != NULL; ++i) {
418 desc = ttos->options[i].desc;
420 opt = lookup_media_desc(desc, opts[j]);