Lines Matching refs:buf
38 static int get_integer(const char *buf, size_t count) in get_integer() argument
46 memcpy(tmp, buf, count); in get_integer()
52 static int get_boolean(const char *buf, size_t count) in get_boolean() argument
55 if (buf[0] == '1') in get_boolean()
57 if (buf[0] == '0') in get_boolean()
59 if (count >= 4 && memcmp(buf, "true", 4) == 0) in get_boolean()
61 if (count >= 5 && memcmp(buf, "false", 5) == 0) in get_boolean()
63 if (count >= 3 && memcmp(buf, "yes", 3) == 0) in get_boolean()
65 if (count >= 2 && memcmp(buf, "no", 2) == 0) in get_boolean()
67 if (count >= 2 && memcmp(buf, "on", 2) == 0) in get_boolean()
69 if (count >= 3 && memcmp(buf, "off", 3) == 0) in get_boolean()
77 char *buf) in b43legacy_attr_interfmode_show() argument
89 count = snprintf(buf, PAGE_SIZE, "0 (No Interference" in b43legacy_attr_interfmode_show()
93 count = snprintf(buf, PAGE_SIZE, "1 (Non-WLAN Interference" in b43legacy_attr_interfmode_show()
97 count = snprintf(buf, PAGE_SIZE, "2 (WLAN Interference" in b43legacy_attr_interfmode_show()
111 const char *buf, size_t count) in b43legacy_attr_interfmode_store() argument
121 mode = get_integer(buf, count); in b43legacy_attr_interfmode_store()
159 char *buf) in b43legacy_attr_preamble_show() argument
170 count = snprintf(buf, PAGE_SIZE, "1 (Short Preamble" in b43legacy_attr_preamble_show()
173 count = snprintf(buf, PAGE_SIZE, "0 (Short Preamble" in b43legacy_attr_preamble_show()
183 const char *buf, size_t count) in b43legacy_attr_preamble_store() argument
192 value = get_boolean(buf, count); in b43legacy_attr_preamble_store()