Commit graph

10 commits

Author SHA1 Message Date
Paul Gortmaker
6a407a81a9 Documentation/vDSO: don't build tests when cross compiling
The following was seen in linux-next build coverage, which is somewhat
unique since it uses powerpc host to cross compile x86:

Documentation/vDSO/vdso_standalone_test_x86.c:49:2: error: impossible
register constraint in 'asm'
make[4]: *** [Documentation/vDSO/vdso_standalone_test_x86.o] Error 1

It probably makes sense to just skip building these tests when
we are cross compiling.

Cc: Jonathan Corbet <corbet@lwn.net>
Cc: linux-doc@vger.kernel.org
Cc: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2015-06-22 16:04:57 -06:00
Jeff Mahoney
1679689231 vdso: don't require 64-bit math in standalone test
The use of 64-bit math on i386 causes build failures:
vdso_standalone_test_x86.c:(.text+0x101): undefined reference to `__umoddi3'
vdso_standalone_test_x86.c:(.text+0x12d): undefined reference to `__udivdi3'

Commit adb19fb66e (Documentation: add makefiles for more targets) is
now building this by default, so it's failing the kernel build entirely.

Switching the declaration from uint64_t to time_t does the right thing
and handles the x32 case automatically.

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Acked-by: Peter Foley <pefoley2@pefoley.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2014-10-25 10:53:44 -04:00
Peter Foley
60a95b772f Documentation: fix vdso_standalone_test_x86 on 32-bit
vdso_standalone_test_x86 needs -lgcc_s to build succesfully on 32bit.

Signed-off-by: Peter Foley <pefoley2@pefoley.com>
[ Fixed missing separator issue reported by Paul Bolle <pebolle@tiscali.nl> ]
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
2014-10-21 10:44:26 -04:00
Peter Foley
25b91ac204 Documentation: disable vdso_test to avoid breakage with old glibc
glibc versions older than 2.16 don't include sys/auxv.h which this
executable uses.
Since we don't have a good way to test for specific glibc versions in
kbuild, just disable it for now.

Signed-off-by: Peter Foley <pefoley2@pefoley.com>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2014-09-26 11:03:00 +02:00
Peter Foley
15565829e7 Documentation: update vDSO makefile to build portable examples
Signed-off-by: Peter Foley <pefoley2@pefoley.com>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2014-09-26 11:03:00 +02:00
Peter Foley
c5e2a7e012 Documentation: update .gitignore files
Add some missing files to .gitignore.
Push Documentation/.gitignore down into subdirectories.

Signed-off-by: Peter Foley <pefoley2@pefoley.com>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2014-09-26 11:02:59 +02:00
Peter Foley
adb19fb66e Documentation: add makefiles for more targets
Add a bunch of previously unbuilt source files to the Documentation build
machinery.

Signed-off-by: Peter Foley <pefoley2@pefoley.com>
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2014-09-26 11:02:56 +02:00
Andy Lutomirski
4ebbefd6b9 x86/vdso/doc: Make vDSO examples more portable
This adds a new vdso_test.c that's written entirely in C.  It also
makes all of the vDSO examples work on 32-bit x86.

Cc: Stefani Seibold <stefani@seibold.net>
Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Link: http://lkml.kernel.org/r/62b701fc44b79f118ac2b2d64d19965fc5c291fb.1402620737.git.luto@amacapital.net
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2014-06-12 19:01:24 -07:00
Andy Lutomirski
6e8f21584a x86/vdso/doc: Rename vdso_test.c to vdso_standalone_test_x86.c
This thing is hopelessly x86_64-specific: it's an example of how to
access the vDSO without any runtime support at all.

Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Link: http://lkml.kernel.org/r/3efc170e0e166e15f0150c9fdb37d52488b9c0a4.1402620737.git.luto@amacapital.net
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
2014-06-12 19:01:16 -07:00
Andy Lutomirski
98eedc3a9d Document the vDSO and add a reference parser
It turns out that parsing the vDSO is nontrivial if you don't already
have an ELF dynamic loader around.  So document it in Documentation/ABI
and add a reference CC0-licenced parser.

This code is dedicated to Go issue 1933:
http://code.google.com/p/go/issues/detail?id=1933

Signed-off-by: Andy Lutomirski <luto@mit.edu>
Link: http://lkml.kernel.org/r/a315a9514cd71bcf29436cc31e35aada21a5ff21.1310563276.git.luto@mit.edu
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2011-07-14 17:57:09 -07:00