lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-b86b0d3570273c6ddc16b1972e82bf7778346286@git.kernel.org>
Date:	Tue, 8 Sep 2015 07:34:06 -0700
From:	tip-bot for Jiri Olsa <tipbot@...or.com>
To:	linux-tip-commits@...r.kernel.org
Cc:	jolsa@...nel.org, raphael.beamonte@...il.com,
	linux-kernel@...r.kernel.org, hpa@...or.com, mingo@...nel.org,
	matt@...eblueprint.co.uk, dsahern@...il.com, acme@...hat.com,
	a.p.zijlstra@...llo.nl, rostedt@...dmis.org, tglx@...utronix.de,
	namhyung@...nel.org
Subject: [tip:perf/core] tools lib api fs:
  Add STR and PATH_MAX macros to fs object

Commit-ID:  b86b0d3570273c6ddc16b1972e82bf7778346286
Gitweb:     http://git.kernel.org/tip/b86b0d3570273c6ddc16b1972e82bf7778346286
Author:     Jiri Olsa <jolsa@...nel.org>
AuthorDate: Wed, 2 Sep 2015 09:56:37 +0200
Committer:  Arnaldo Carvalho de Melo <acme@...hat.com>
CommitDate: Fri, 4 Sep 2015 12:00:58 -0300

tools lib api fs: Add STR and PATH_MAX macros to fs object

We're going to get rid of findfs.h in following patches, but we'll still
need these macros.

Signed-off-by: Jiri Olsa <jolsa@...nel.org>
Cc: Raphael Beamonte <raphael.beamonte@...il.com>
Cc: David Ahern <dsahern@...il.com>
Cc: Matt Fleming <matt@...eblueprint.co.uk>
Cc: Namhyung Kim <namhyung@...nel.org>
Cc: Peter Zijlstra <a.p.zijlstra@...llo.nl>
Cc: Steven Rostedt <rostedt@...dmis.org>
Link: http://lkml.kernel.org/r/1441180605-24737-8-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@...hat.com>
---
 tools/lib/api/fs/fs.c | 3 +++
 tools/lib/api/fs/fs.h | 8 ++++++++
 2 files changed, 11 insertions(+)

diff --git a/tools/lib/api/fs/fs.c b/tools/lib/api/fs/fs.c
index 128ef63..5e838d3 100644
--- a/tools/lib/api/fs/fs.c
+++ b/tools/lib/api/fs/fs.c
@@ -15,6 +15,9 @@
 #include "debugfs.h"
 #include "fs.h"
 
+#define _STR(x) #x
+#define STR(x) _STR(x)
+
 static const char * const sysfs__fs_known_mountpoints[] = {
 	"/sys",
 	0,
diff --git a/tools/lib/api/fs/fs.h b/tools/lib/api/fs/fs.h
index 6caa2bb..fd6288d 100644
--- a/tools/lib/api/fs/fs.h
+++ b/tools/lib/api/fs/fs.h
@@ -1,6 +1,14 @@
 #ifndef __API_FS__
 #define __API_FS__
 
+/*
+ * On most systems <limits.h> would have given us this, but  not on some systems
+ * (e.g. GNU/Hurd).
+ */
+#ifndef PATH_MAX
+#define PATH_MAX 4096
+#endif
+
 #ifndef SYSFS_MAGIC
 #define SYSFS_MAGIC            0x62656572
 #endif
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ