diff options
| author | Dan Williams <dan.j.williams@intel.com> | 2019-03-11 15:37:55 -0400 |
|---|---|---|
| committer | Dan Williams <dan.j.williams@intel.com> | 2019-03-11 15:37:55 -0400 |
| commit | 4083014e32699af04a8e6eaa4855b08dba36a47a (patch) | |
| tree | fa37f9f9691fe64ca8a3c0cdc0315dc12462e6e4 /tools/bpf/bpftool/common.c | |
| parent | 6fd96ff557963de8e62842a0dc360a6e3610d2bb (diff) | |
| parent | 78153dd45e7e0596ba32b15d02bda08e1513111e (diff) | |
Merge branch 'for-5.1/nfit/ars' into libnvdimm-for-next
Merge several updates to the ARS implementation. Highlights include:
* Support retrieval of short-ARS results if the ARS state is "requires
continuation", and even if the "no_init_ars" module parameter is
specified.
* Allow busy-polling of the kernel ARS state by allowing root to reset
the exponential back-off timer.
* Filter potentially stale ARS results by tracking query-ARS relative to
the previous start-ARS.
Diffstat (limited to 'tools/bpf/bpftool/common.c')
| -rw-r--r-- | tools/bpf/bpftool/common.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/tools/bpf/bpftool/common.c b/tools/bpf/bpftool/common.c index 897483457bf0..f7261fad45c1 100644 --- a/tools/bpf/bpftool/common.c +++ b/tools/bpf/bpftool/common.c | |||
| @@ -297,10 +297,8 @@ char *get_fdinfo(int fd, const char *key) | |||
| 297 | snprintf(path, sizeof(path), "/proc/self/fdinfo/%d", fd); | 297 | snprintf(path, sizeof(path), "/proc/self/fdinfo/%d", fd); |
| 298 | 298 | ||
| 299 | fdi = fopen(path, "r"); | 299 | fdi = fopen(path, "r"); |
| 300 | if (!fdi) { | 300 | if (!fdi) |
| 301 | p_err("can't open fdinfo: %s", strerror(errno)); | ||
| 302 | return NULL; | 301 | return NULL; |
| 303 | } | ||
| 304 | 302 | ||
| 305 | while ((n = getline(&line, &line_n, fdi)) > 0) { | 303 | while ((n = getline(&line, &line_n, fdi)) > 0) { |
| 306 | char *value; | 304 | char *value; |
| @@ -313,7 +311,6 @@ char *get_fdinfo(int fd, const char *key) | |||
| 313 | 311 | ||
| 314 | value = strchr(line, '\t'); | 312 | value = strchr(line, '\t'); |
| 315 | if (!value || !value[1]) { | 313 | if (!value || !value[1]) { |
| 316 | p_err("malformed fdinfo!?"); | ||
| 317 | free(line); | 314 | free(line); |
| 318 | return NULL; | 315 | return NULL; |
| 319 | } | 316 | } |
| @@ -326,7 +323,6 @@ char *get_fdinfo(int fd, const char *key) | |||
| 326 | return line; | 323 | return line; |
| 327 | } | 324 | } |
| 328 | 325 | ||
| 329 | p_err("key '%s' not found in fdinfo", key); | ||
| 330 | free(line); | 326 | free(line); |
| 331 | fclose(fdi); | 327 | fclose(fdi); |
| 332 | return NULL; | 328 | return NULL; |
