These changes are the raw update to linux-4.4.6-rt14. Kernel sources
[kvmfornfv.git] / kernel / drivers / gpu / drm / nouveau / include / nvkm / core / option.h
1 #ifndef __NVKM_OPTION_H__
2 #define __NVKM_OPTION_H__
3 #include <core/os.h>
4
5 const char *nvkm_stropt(const char *optstr, const char *opt, int *len);
6 bool nvkm_boolopt(const char *optstr, const char *opt, bool value);
7 long nvkm_longopt(const char *optstr, const char *opt, long value);
8 int  nvkm_dbgopt(const char *optstr, const char *sub);
9
10 /* compares unterminated string 'str' with zero-terminated string 'cmp' */
11 static inline int
12 strncasecmpz(const char *str, const char *cmp, size_t len)
13 {
14         if (strlen(cmp) != len)
15                 return len;
16         return strncasecmp(str, cmp, len);
17 }
18 #endif