Skip to content

Commit b6420eb

Browse files
committed
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/doc
Pull documentation updates from Jiri Kosina: "Updates to kernel documentation. I took this over (hopefully temporarily) from Randy who was not willing to maintain it any longer. This pile mostly is a relay of queue that Randy already had in his tree" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/doc: Documentation: fix broken v4l-utils URL Documentation: update include path for mpssd Documentation: correct parameter error for dma_mapping_error MAINTAINERS: update location of linux-doc tree Documentation: remove networking/.gitignore tools: add more endian.h macros Make Documenation depend on headers_install Docs: this_cpu_ops: remove redundant add forms Documentation: disable vdso_test to avoid breakage with old glibc Documentation: update vDSO makefile to build portable examples Documentation: update .gitignore files Documentation: support glibc versions without htole macros v4l2-pci-skeleton: Only build if PCI is available Documentation: fix misc. warnings Documentation: make functions static to avoid prototype warnings Documentation: add makefiles for more targets Documentation: use subdir-y to avoid unnecessary built-in.o files
2 parents d290106 + 0415447 commit b6420eb

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+168
-136
lines changed

Documentation/.gitignore

Lines changed: 0 additions & 7 deletions
This file was deleted.

Documentation/DMA-API-HOWTO.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ To map a single region, you do:
531531
size_t size = buffer->len;
532532

533533
dma_handle = dma_map_single(dev, addr, size, direction);
534-
if (dma_mapping_error(dma_handle)) {
534+
if (dma_mapping_error(dev, dma_handle)) {
535535
/*
536536
* reduce current DMA mapping usage,
537537
* delay and try again later or
@@ -588,7 +588,7 @@ Specifically:
588588
size_t size = buffer->len;
589589

590590
dma_handle = dma_map_page(dev, page, offset, size, direction);
591-
if (dma_mapping_error(dma_handle)) {
591+
if (dma_mapping_error(dev, dma_handle)) {
592592
/*
593593
* reduce current DMA mapping usage,
594594
* delay and try again later or
@@ -689,7 +689,7 @@ to use the dma_sync_*() interfaces.
689689
dma_addr_t mapping;
690690

691691
mapping = dma_map_single(cp->dev, buffer, len, DMA_FROM_DEVICE);
692-
if (dma_mapping_error(dma_handle)) {
692+
if (dma_mapping_error(cp->dev, dma_handle)) {
693693
/*
694694
* reduce current DMA mapping usage,
695695
* delay and try again later or

Documentation/DocBook/media/v4l/common.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ makes no provisions to find these related devices. Some really
110110
complex devices use the Media Controller (see <xref linkend="media_controller" />)
111111
which can be used for this purpose. But most drivers do not use it,
112112
and while some code exists that uses sysfs to discover related devices
113-
(see libmedia_dev in the <ulink url="http://git.linuxtv.org/v4l-utils/">v4l-utils</ulink>
113+
(see libmedia_dev in the <ulink url="http://git.linuxtv.org/cgit.cgi/v4l-utils.git/">v4l-utils</ulink>
114114
git repository), there is no library yet that can provide a single API towards
115115
both Media Controller-based devices and devices that do not use the Media Controller.
116116
If you want to work on this please write to the linux-media mailing list: &v4l-ml;.</para>

Documentation/Makefile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1-
obj-m := DocBook/ accounting/ auxdisplay/ connector/ \
2-
filesystems/ filesystems/configfs/ ia64/ laptops/ networking/ \
3-
pcmcia/ spi/ timers/ watchdog/src/ misc-devices/mei/
1+
subdir-y := accounting arm auxdisplay blackfin connector \
2+
filesystems filesystems ia64 laptops mic misc-devices \
3+
networking pcmcia prctl ptp spi timers vDSO video4linux \
4+
watchdog

Documentation/accounting/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
41
# List of programs to build
52
hostprogs-y := getdelays
63

Documentation/arm/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
subdir-y := SH-Mobile
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
vrl4

Documentation/arm/SH-Mobile/Makefile

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
BIN := vrl4
1+
# List of programs to build
2+
hostprogs-y := vrl4
23

3-
.PHONY: all
4-
all: $(BIN)
4+
# Tell kbuild to always build the programs
5+
always := $(hostprogs-y)
56

6-
.PHONY: clean
7-
clean:
8-
rm -f *.o $(BIN)
7+
HOSTCFLAGS_vrl4.o += -I$(objtree)/usr/include -I$(srctree)/tools/include

Documentation/arm/SH-Mobile/vrl4.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
#include <stdint.h>
3535
#include <stdio.h>
3636
#include <errno.h>
37+
#include <tools/endian.h>
3738

3839
struct hdr {
3940
uint32_t magic1;
@@ -77,7 +78,7 @@ struct hdr {
7778

7879
#define ROUND_UP(x) ((x + ALIGN - 1) & ~(ALIGN - 1))
7980

80-
ssize_t do_read(int fd, void *buf, size_t count)
81+
static ssize_t do_read(int fd, void *buf, size_t count)
8182
{
8283
size_t offset = 0;
8384
ssize_t l;
@@ -98,7 +99,7 @@ ssize_t do_read(int fd, void *buf, size_t count)
9899
return offset;
99100
}
100101

101-
ssize_t do_write(int fd, const void *buf, size_t count)
102+
static ssize_t do_write(int fd, const void *buf, size_t count)
102103
{
103104
size_t offset = 0;
104105
ssize_t l;
@@ -117,7 +118,7 @@ ssize_t do_write(int fd, const void *buf, size_t count)
117118
return offset;
118119
}
119120

120-
ssize_t write_zero(int fd, size_t len)
121+
static ssize_t write_zero(int fd, size_t len)
121122
{
122123
size_t i = len;
123124

Documentation/auxdisplay/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
41
# List of programs to build
52
hostprogs-y := cfag12864b-example
63

Documentation/blackfin/Makefile

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1+
ifneq ($(CONFIG_BLACKFIN),)
12
obj-m := gptimers-example.o
2-
3-
all: modules
4-
5-
modules clean:
6-
$(MAKE) -C ../.. SUBDIRS=$(PWD) $@
3+
endif

Documentation/filesystems/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
dnotify_test

Documentation/filesystems/Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
1+
subdir-y := configfs
32

43
# List of programs to build
54
hostprogs-y := dnotify_test

Documentation/ia64/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
41
# List of programs to build
52
hostprogs-y := aliasing-test
63

Documentation/laptops/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
dslm
2+
freefall

Documentation/laptops/Makefile

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
41
# List of programs to build
5-
hostprogs-y := dslm
2+
hostprogs-y := dslm freefall
63

74
# Tell kbuild to always build the programs
85
always := $(hostprogs-y)

Documentation/mic/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
subdir-y := mpssd

Documentation/mic/mpssd/Makefile

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
1-
#
2-
# Makefile - Intel MIC User Space Tools.
3-
# Copyright(c) 2013, Intel Corporation.
4-
#
1+
# List of programs to build
2+
hostprogs-y := mpssd
3+
4+
mpssd-objs := mpssd.o sysfs.o
5+
6+
# Tell kbuild to always build the programs
7+
always := $(hostprogs-y)
8+
9+
HOSTCFLAGS += -I$(objtree)/usr/include -I$(srctree)/tools/include
10+
511
ifdef DEBUG
6-
CFLAGS += $(USERWARNFLAGS) -I. -g -Wall -DDEBUG=$(DEBUG)
7-
else
8-
CFLAGS += $(USERWARNFLAGS) -I. -g -Wall
12+
HOSTCFLAGS += -DDEBUG=$(DEBUG)
913
endif
1014

11-
mpssd: mpssd.o sysfs.o
12-
$(CC) $(CFLAGS) -o $@ $^ -lpthread
15+
HOSTLOADLIBES_mpssd := -lpthread
1316

1417
install:
1518
install mpssd /usr/sbin/mpssd
1619
install micctrl /usr/sbin/micctrl
17-
18-
clean:
19-
rm -f mpssd *.o

Documentation/mic/mpssd/mpssd.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@
4141
#include "mpssd.h"
4242
#include <linux/mic_ioctl.h>
4343
#include <linux/mic_common.h>
44+
#include <tools/endian.h>
4445

4546
static void init_mic(struct mic_info *mic);
4647

@@ -1476,9 +1477,9 @@ set_cmdline(struct mic_info *mic)
14761477

14771478
len = snprintf(buffer, PATH_MAX,
14781479
"clocksource=tsc highres=off nohz=off ");
1479-
len += snprintf(buffer + len, PATH_MAX,
1480+
len += snprintf(buffer + len, PATH_MAX - len,
14801481
"cpufreq_on;corec6_off;pc3_off;pc6_off ");
1481-
len += snprintf(buffer + len, PATH_MAX,
1482+
len += snprintf(buffer + len, PATH_MAX - len,
14821483
"ifcfg=static;address,172.31.%d.1;netmask,255.255.255.0",
14831484
mic->id);
14841485

Documentation/misc-devices/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
subdir-y := mei

Documentation/misc-devices/mei/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
41
# List of programs to build
52
hostprogs-y := mei-amt-version
63
HOSTCFLAGS_mei-amt-version.o += -I$(objtree)/usr/include

Documentation/networking/.gitignore

Whitespace-only changes.

Documentation/networking/Makefile

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
4-
# Tell kbuild to always build the programs
5-
always := $(hostprogs-y)
6-
7-
obj-m := timestamping/
1+
subdir-y := timestamping
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
timestamping
2+
txtimestamp
23
hwtstamp_config
Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,8 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
41
# List of programs to build
5-
hostprogs-y := timestamping hwtstamp_config
2+
hostprogs-y := hwtstamp_config timestamping
63

74
# Tell kbuild to always build the programs
85
always := $(hostprogs-y)
96

107
HOSTCFLAGS_timestamping.o += -I$(objtree)/usr/include
118
HOSTCFLAGS_hwtstamp_config.o += -I$(objtree)/usr/include
12-
13-
clean:
14-
rm -f timestamping hwtstamp_config

Documentation/pcmcia/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# kbuild trick to avoid linker error. Can be omitted if a module is built.
2-
obj- := dummy.o
3-
41
# List of programs to build
52
hostprogs-y := crc32hash
63

Documentation/prctl/.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
disable-tsc-ctxt-sw-stress-test
2+
disable-tsc-on-off-stress-test
3+
disable-tsc-test

Documentation/prctl/Makefile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# List of programs to build
2+
hostprogs-y := disable-tsc-ctxt-sw-stress-test disable-tsc-on-off-stress-test disable-tsc-test
3+
# Tell kbuild to always build the programs
4+
always := $(hostprogs-y)
5+
6+
HOSTCFLAGS_disable-tsc-ctxt-sw-stress-test.o += -I$(objtree)/usr/include
7+
HOSTCFLAGS_disable-tsc-on-off-stress-test.o += -I$(objtree)/usr/include
8+
HOSTCFLAGS_disable-tsc-test.o += -I$(objtree)/usr/include

Documentation/prctl/disable-tsc-ctxt-sw-stress-test.c

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,19 +27,20 @@
2727
# define PR_TSC_SIGSEGV 2 /* throw a SIGSEGV instead of reading the TSC */
2828
#endif
2929

30-
uint64_t rdtsc() {
30+
static uint64_t rdtsc(void)
31+
{
3132
uint32_t lo, hi;
3233
/* We cannot use "=A", since this would use %rax on x86_64 */
3334
__asm__ __volatile__ ("rdtsc" : "=a" (lo), "=d" (hi));
3435
return (uint64_t)hi << 32 | lo;
3536
}
3637

37-
void sigsegv_expect(int sig)
38+
static void sigsegv_expect(int sig)
3839
{
3940
/* */
4041
}
4142

42-
void segvtask(void)
43+
static void segvtask(void)
4344
{
4445
if (prctl(PR_SET_TSC, PR_TSC_SIGSEGV) < 0)
4546
{
@@ -54,13 +55,13 @@ void segvtask(void)
5455
}
5556

5657

57-
void sigsegv_fail(int sig)
58+
static void sigsegv_fail(int sig)
5859
{
5960
fprintf(stderr, "FATAL ERROR, rdtsc() failed while enabled\n");
6061
exit(0);
6162
}
6263

63-
void rdtsctask(void)
64+
static void rdtsctask(void)
6465
{
6566
if (prctl(PR_SET_TSC, PR_TSC_ENABLE) < 0)
6667
{

Documentation/prctl/disable-tsc-on-off-stress-test.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@
2929

3030
/* snippet from wikipedia :-) */
3131

32-
uint64_t rdtsc() {
32+
static uint64_t rdtsc(void)
33+
{
3334
uint32_t lo, hi;
3435
/* We cannot use "=A", since this would use %rax on x86_64 */
3536
__asm__ __volatile__ ("rdtsc" : "=a" (lo), "=d" (hi));
@@ -38,7 +39,7 @@ return (uint64_t)hi << 32 | lo;
3839

3940
int should_segv = 0;
4041

41-
void sigsegv_cb(int sig)
42+
static void sigsegv_cb(int sig)
4243
{
4344
if (!should_segv)
4445
{
@@ -55,7 +56,7 @@ void sigsegv_cb(int sig)
5556
rdtsc();
5657
}
5758

58-
void task(void)
59+
static void task(void)
5960
{
6061
signal(SIGSEGV, sigsegv_cb);
6162
alarm(10);

Documentation/prctl/disable-tsc-test.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,15 @@ const char *tsc_names[] =
2929
[PR_TSC_SIGSEGV] = "PR_TSC_SIGSEGV",
3030
};
3131

32-
uint64_t rdtsc() {
32+
static uint64_t rdtsc(void)
33+
{
3334
uint32_t lo, hi;
3435
/* We cannot use "=A", since this would use %rax on x86_64 */
3536
__asm__ __volatile__ ("rdtsc" : "=a" (lo), "=d" (hi));
3637
return (uint64_t)hi << 32 | lo;
3738
}
3839

39-
void sigsegv_cb(int sig)
40+
static void sigsegv_cb(int sig)
4041
{
4142
int tsc_val = 0;
4243

Documentation/ptp/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
testptp

Documentation/ptp/Makefile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# List of programs to build
2+
hostprogs-y := testptp
3+
4+
# Tell kbuild to always build the programs
5+
always := $(hostprogs-y)
6+
7+
HOSTCFLAGS_testptp.o += -I$(objtree)/usr/include
8+
HOSTLOADLIBES_testptp := -lrt

Documentation/ptp/testptp.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -500,11 +500,11 @@ int main(int argc, char *argv[])
500500
interval = t2 - t1;
501501
offset = (t2 + t1) / 2 - tp;
502502

503-
printf("system time: %" PRId64 ".%u\n",
503+
printf("system time: %lld.%u\n",
504504
(pct+2*i)->sec, (pct+2*i)->nsec);
505-
printf("phc time: %" PRId64 ".%u\n",
505+
printf("phc time: %lld.%u\n",
506506
(pct+2*i+1)->sec, (pct+2*i+1)->nsec);
507-
printf("system time: %" PRId64 ".%u\n",
507+
printf("system time: %lld.%u\n",
508508
(pct+2*i+2)->sec, (pct+2*i+2)->nsec);
509509
printf("system/phc clock time offset is %" PRId64 " ns\n"
510510
"system clock time delay is %" PRId64 " ns\n",

0 commit comments

Comments
 (0)