diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-03-09 10:21:57 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-03-09 10:21:57 -0400 |
commit | efdcd41b4e41560375bb34ad8b095bcaa1c3a93f (patch) | |
tree | 57200ef68bae530776c0c2621c51e9464e1e72f9 /Documentation | |
parent | 33dbe6114047496a5b6fee0941c52dad41250043 (diff) | |
parent | 79c7cdd5441f5d3900c1632adcc8cd2bee35c8da (diff) |
Merge branch 'topic/vmaster-update' into topic/docbook-fix
Diffstat (limited to 'Documentation')
54 files changed, 1774 insertions, 1560 deletions
diff --git a/Documentation/ABI/testing/sysfs-bus-pci b/Documentation/ABI/testing/sysfs-bus-pci index ceddcff4082a..e638e15a8895 100644 --- a/Documentation/ABI/testing/sysfs-bus-pci +++ b/Documentation/ABI/testing/sysfs-bus-pci | |||
@@ -1,3 +1,46 @@ | |||
1 | What: /sys/bus/pci/drivers/.../bind | ||
2 | Date: December 2003 | ||
3 | Contact: linux-pci@vger.kernel.org | ||
4 | Description: | ||
5 | Writing a device location to this file will cause | ||
6 | the driver to attempt to bind to the device found at | ||
7 | this location. This is useful for overriding default | ||
8 | bindings. The format for the location is: DDDD:BB:DD.F. | ||
9 | That is Domain:Bus:Device.Function and is the same as | ||
10 | found in /sys/bus/pci/devices/. For example: | ||
11 | # echo 0000:00:19.0 > /sys/bus/pci/drivers/foo/bind | ||
12 | (Note: kernels before 2.6.28 may require echo -n). | ||
13 | |||
14 | What: /sys/bus/pci/drivers/.../unbind | ||
15 | Date: December 2003 | ||
16 | Contact: linux-pci@vger.kernel.org | ||
17 | Description: | ||
18 | Writing a device location to this file will cause the | ||
19 | driver to attempt to unbind from the device found at | ||
20 | this location. This may be useful when overriding default | ||
21 | bindings. The format for the location is: DDDD:BB:DD.F. | ||
22 | That is Domain:Bus:Device.Function and is the same as | ||
23 | found in /sys/bus/pci/devices/. For example: | ||
24 | # echo 0000:00:19.0 > /sys/bus/pci/drivers/foo/unbind | ||
25 | (Note: kernels before 2.6.28 may require echo -n). | ||
26 | |||
27 | What: /sys/bus/pci/drivers/.../new_id | ||
28 | Date: December 2003 | ||
29 | Contact: linux-pci@vger.kernel.org | ||
30 | Description: | ||
31 | Writing a device ID to this file will attempt to | ||
32 | dynamically add a new device ID to a PCI device driver. | ||
33 | This may allow the driver to support more hardware than | ||
34 | was included in the driver's static device ID support | ||
35 | table at compile time. The format for the device ID is: | ||
36 | VVVV DDDD SVVV SDDD CCCC MMMM PPPP. That is Vendor ID, | ||
37 | Device ID, Subsystem Vendor ID, Subsystem Device ID, | ||
38 | Class, Class Mask, and Private Driver Data. The Vendor ID | ||
39 | and Device ID fields are required, the rest are optional. | ||
40 | Upon successfully adding an ID, the driver will probe | ||
41 | for the device and attempt to bind to it. For example: | ||
42 | # echo "8086 10f5" > /sys/bus/pci/drivers/foo/new_id | ||
43 | |||
1 | What: /sys/bus/pci/devices/.../vpd | 44 | What: /sys/bus/pci/devices/.../vpd |
2 | Date: February 2008 | 45 | Date: February 2008 |
3 | Contact: Ben Hutchings <bhutchings@solarflare.com> | 46 | Contact: Ben Hutchings <bhutchings@solarflare.com> |
diff --git a/Documentation/ABI/testing/sysfs-firmware-memmap b/Documentation/ABI/testing/sysfs-firmware-memmap index 0d99ee6ae02e..eca0d65087dc 100644 --- a/Documentation/ABI/testing/sysfs-firmware-memmap +++ b/Documentation/ABI/testing/sysfs-firmware-memmap | |||
@@ -1,6 +1,6 @@ | |||
1 | What: /sys/firmware/memmap/ | 1 | What: /sys/firmware/memmap/ |
2 | Date: June 2008 | 2 | Date: June 2008 |
3 | Contact: Bernhard Walle <bwalle@suse.de> | 3 | Contact: Bernhard Walle <bernhard.walle@gmx.de> |
4 | Description: | 4 | Description: |
5 | On all platforms, the firmware provides a memory map which the | 5 | On all platforms, the firmware provides a memory map which the |
6 | kernel reads. The resources from that memory map are registered | 6 | kernel reads. The resources from that memory map are registered |
diff --git a/Documentation/Changes b/Documentation/Changes index cb2b141b1c3e..b95082be4d5e 100644 --- a/Documentation/Changes +++ b/Documentation/Changes | |||
@@ -33,10 +33,12 @@ o Gnu make 3.79.1 # make --version | |||
33 | o binutils 2.12 # ld -v | 33 | o binutils 2.12 # ld -v |
34 | o util-linux 2.10o # fdformat --version | 34 | o util-linux 2.10o # fdformat --version |
35 | o module-init-tools 0.9.10 # depmod -V | 35 | o module-init-tools 0.9.10 # depmod -V |
36 | o e2fsprogs 1.29 # tune2fs | 36 | o e2fsprogs 1.41.4 # e2fsck -V |
37 | o jfsutils 1.1.3 # fsck.jfs -V | 37 | o jfsutils 1.1.3 # fsck.jfs -V |
38 | o reiserfsprogs 3.6.3 # reiserfsck -V 2>&1|grep reiserfsprogs | 38 | o reiserfsprogs 3.6.3 # reiserfsck -V 2>&1|grep reiserfsprogs |
39 | o xfsprogs 2.6.0 # xfs_db -V | 39 | o xfsprogs 2.6.0 # xfs_db -V |
40 | o squashfs-tools 4.0 # mksquashfs -version | ||
41 | o btrfs-progs 0.18 # btrfsck | ||
40 | o pcmciautils 004 # pccardctl -V | 42 | o pcmciautils 004 # pccardctl -V |
41 | o quota-tools 3.09 # quota -V | 43 | o quota-tools 3.09 # quota -V |
42 | o PPP 2.4.0 # pppd --version | 44 | o PPP 2.4.0 # pppd --version |
diff --git a/Documentation/CodingStyle b/Documentation/CodingStyle index 1875e502f872..72968cd5eaf3 100644 --- a/Documentation/CodingStyle +++ b/Documentation/CodingStyle | |||
@@ -483,17 +483,25 @@ values. To do the latter, you can stick the following in your .emacs file: | |||
483 | (* (max steps 1) | 483 | (* (max steps 1) |
484 | c-basic-offset))) | 484 | c-basic-offset))) |
485 | 485 | ||
486 | (add-hook 'c-mode-common-hook | ||
487 | (lambda () | ||
488 | ;; Add kernel style | ||
489 | (c-add-style | ||
490 | "linux-tabs-only" | ||
491 | '("linux" (c-offsets-alist | ||
492 | (arglist-cont-nonempty | ||
493 | c-lineup-gcc-asm-reg | ||
494 | c-lineup-arglist-tabs-only)))))) | ||
495 | |||
486 | (add-hook 'c-mode-hook | 496 | (add-hook 'c-mode-hook |
487 | (lambda () | 497 | (lambda () |
488 | (let ((filename (buffer-file-name))) | 498 | (let ((filename (buffer-file-name))) |
489 | ;; Enable kernel mode for the appropriate files | 499 | ;; Enable kernel mode for the appropriate files |
490 | (when (and filename | 500 | (when (and filename |
491 | (string-match "~/src/linux-trees" filename)) | 501 | (string-match (expand-file-name "~/src/linux-trees") |
502 | filename)) | ||
492 | (setq indent-tabs-mode t) | 503 | (setq indent-tabs-mode t) |
493 | (c-set-style "linux") | 504 | (c-set-style "linux-tabs-only"))))) |
494 | (c-set-offset 'arglist-cont-nonempty | ||
495 | '(c-lineup-gcc-asm-reg | ||
496 | c-lineup-arglist-tabs-only)))))) | ||
497 | 505 | ||
498 | This will make emacs go better with the kernel coding style for C | 506 | This will make emacs go better with the kernel coding style for C |
499 | files below ~/src/linux-trees. | 507 | files below ~/src/linux-trees. |
diff --git a/Documentation/DMA-API.txt b/Documentation/DMA-API.txt index b462bb149543..2a3fcc55e981 100644 --- a/Documentation/DMA-API.txt +++ b/Documentation/DMA-API.txt | |||
@@ -5,7 +5,7 @@ | |||
5 | 5 | ||
6 | This document describes the DMA API. For a more gentle introduction | 6 | This document describes the DMA API. For a more gentle introduction |
7 | phrased in terms of the pci_ equivalents (and actual examples) see | 7 | phrased in terms of the pci_ equivalents (and actual examples) see |
8 | DMA-mapping.txt | 8 | Documentation/PCI/PCI-DMA-mapping.txt. |
9 | 9 | ||
10 | This API is split into two pieces. Part I describes the API and the | 10 | This API is split into two pieces. Part I describes the API and the |
11 | corresponding pci_ API. Part II describes the extensions to the API | 11 | corresponding pci_ API. Part II describes the extensions to the API |
@@ -170,16 +170,15 @@ Returns: 0 if successful and a negative error if not. | |||
170 | u64 | 170 | u64 |
171 | dma_get_required_mask(struct device *dev) | 171 | dma_get_required_mask(struct device *dev) |
172 | 172 | ||
173 | After setting the mask with dma_set_mask(), this API returns the | 173 | This API returns the mask that the platform requires to |
174 | actual mask (within that already set) that the platform actually | 174 | operate efficiently. Usually this means the returned mask |
175 | requires to operate efficiently. Usually this means the returned mask | ||
176 | is the minimum required to cover all of memory. Examining the | 175 | is the minimum required to cover all of memory. Examining the |
177 | required mask gives drivers with variable descriptor sizes the | 176 | required mask gives drivers with variable descriptor sizes the |
178 | opportunity to use smaller descriptors as necessary. | 177 | opportunity to use smaller descriptors as necessary. |
179 | 178 | ||
180 | Requesting the required mask does not alter the current mask. If you | 179 | Requesting the required mask does not alter the current mask. If you |
181 | wish to take advantage of it, you should issue another dma_set_mask() | 180 | wish to take advantage of it, you should issue a dma_set_mask() |
182 | call to lower the mask again. | 181 | call to set the mask to the value returned. |
183 | 182 | ||
184 | 183 | ||
185 | Part Id - Streaming DMA mappings | 184 | Part Id - Streaming DMA mappings |
diff --git a/Documentation/DocBook/Makefile b/Documentation/DocBook/Makefile index dc3154e49279..1462ed86d40a 100644 --- a/Documentation/DocBook/Makefile +++ b/Documentation/DocBook/Makefile | |||
@@ -6,7 +6,7 @@ | |||
6 | # To add a new book the only step required is to add the book to the | 6 | # To add a new book the only step required is to add the book to the |
7 | # list of DOCBOOKS. | 7 | # list of DOCBOOKS. |
8 | 8 | ||
9 | DOCBOOKS := z8530book.xml mcabook.xml \ | 9 | DOCBOOKS := z8530book.xml mcabook.xml device-drivers.xml \ |
10 | kernel-hacking.xml kernel-locking.xml deviceiobook.xml \ | 10 | kernel-hacking.xml kernel-locking.xml deviceiobook.xml \ |
11 | procfs-guide.xml writing_usb_driver.xml networking.xml \ | 11 | procfs-guide.xml writing_usb_driver.xml networking.xml \ |
12 | kernel-api.xml filesystems.xml lsm.xml usb.xml kgdb.xml \ | 12 | kernel-api.xml filesystems.xml lsm.xml usb.xml kgdb.xml \ |
diff --git a/Documentation/DocBook/device-drivers.tmpl b/Documentation/DocBook/device-drivers.tmpl new file mode 100644 index 000000000000..94a20fe8fedf --- /dev/null +++ b/Documentation/DocBook/device-drivers.tmpl | |||
@@ -0,0 +1,418 @@ | |||
1 | <?xml version="1.0" encoding="UTF-8"?> | ||
2 | <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" | ||
3 | "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" []> | ||
4 | |||
5 | <book id="LinuxDriversAPI"> | ||
6 | <bookinfo> | ||
7 | <title>Linux Device Drivers</title> | ||
8 | |||
9 | <legalnotice> | ||
10 | <para> | ||
11 | This documentation is free software; you can redistribute | ||
12 | it and/or modify it under the terms of the GNU General Public | ||
13 | License as published by the Free Software Foundation; either | ||
14 | version 2 of the License, or (at your option) any later | ||
15 | version. | ||
16 | </para> | ||
17 | |||
18 | <para> | ||
19 | This program is distributed in the hope that it will be | ||
20 | useful, but WITHOUT ANY WARRANTY; without even the implied | ||
21 | warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | ||
22 | See the GNU General Public License for more details. | ||
23 | </para> | ||
24 | |||
25 | <para> | ||
26 | You should have received a copy of the GNU General Public | ||
27 | License along with this program; if not, write to the Free | ||
28 | Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, | ||
29 | MA 02111-1307 USA | ||
30 | </para> | ||
31 | |||
32 | <para> | ||
33 | For more details see the file COPYING in the source | ||
34 | distribution of Linux. | ||
35 | </para> | ||
36 | </legalnotice> | ||
37 | </bookinfo> | ||
38 | |||
39 | <toc></toc> | ||
40 | |||
41 | <chapter id="Basics"> | ||
42 | <title>Driver Basics</title> | ||
43 | <sect1><title>Driver Entry and Exit points</title> | ||
44 | !Iinclude/linux/init.h | ||
45 | </sect1> | ||
46 | |||
47 | <sect1><title>Atomic and pointer manipulation</title> | ||
48 | !Iarch/x86/include/asm/atomic_32.h | ||
49 | !Iarch/x86/include/asm/unaligned.h | ||
50 | </sect1> | ||
51 | |||
52 | <sect1><title>Delaying, scheduling, and timer routines</title> | ||
53 | !Iinclude/linux/sched.h | ||
54 | !Ekernel/sched.c | ||
55 | !Ekernel/timer.c | ||
56 | </sect1> | ||
57 | <sect1><title>High-resolution timers</title> | ||
58 | !Iinclude/linux/ktime.h | ||
59 | !Iinclude/linux/hrtimer.h | ||
60 | !Ekernel/hrtimer.c | ||
61 | </sect1> | ||
62 | <sect1><title>Workqueues and Kevents</title> | ||
63 | !Ekernel/workqueue.c | ||
64 | </sect1> | ||
65 | <sect1><title>Internal Functions</title> | ||
66 | !Ikernel/exit.c | ||
67 | !Ikernel/signal.c | ||
68 | !Iinclude/linux/kthread.h | ||
69 | !Ekernel/kthread.c | ||
70 | </sect1> | ||
71 | |||
72 | <sect1><title>Kernel objects manipulation</title> | ||
73 | <!-- | ||
74 | X!Iinclude/linux/kobject.h | ||
75 | --> | ||
76 | !Elib/kobject.c | ||
77 | </sect1> | ||
78 | |||
79 | <sect1><title>Kernel utility functions</title> | ||
80 | !Iinclude/linux/kernel.h | ||
81 | !Ekernel/printk.c | ||
82 | !Ekernel/panic.c | ||
83 | !Ekernel/sys.c | ||
84 | !Ekernel/rcupdate.c | ||
85 | </sect1> | ||
86 | |||
87 | <sect1><title>Device Resource Management</title> | ||
88 | !Edrivers/base/devres.c | ||
89 | </sect1> | ||
90 | |||
91 | </chapter> | ||
92 | |||
93 | <chapter id="devdrivers"> | ||
94 | <title>Device drivers infrastructure</title> | ||
95 | <sect1><title>Device Drivers Base</title> | ||
96 | <!-- | ||
97 | X!Iinclude/linux/device.h | ||
98 | --> | ||
99 | !Edrivers/base/driver.c | ||
100 | !Edrivers/base/core.c | ||
101 | !Edrivers/base/class.c | ||
102 | !Edrivers/base/firmware_class.c | ||
103 | !Edrivers/base/transport_class.c | ||
104 | <!-- Cannot be included, because | ||
105 | attribute_container_add_class_device_adapter | ||
106 | and attribute_container_classdev_to_container | ||
107 | exceed allowed 44 characters maximum | ||
108 | X!Edrivers/base/attribute_container.c | ||
109 | --> | ||
110 | !Edrivers/base/sys.c | ||
111 | <!-- | ||
112 | X!Edrivers/base/interface.c | ||
113 | --> | ||
114 | !Edrivers/base/platform.c | ||
115 | !Edrivers/base/bus.c | ||
116 | </sect1> | ||
117 | <sect1><title>Device Drivers Power Management</title> | ||
118 | !Edrivers/base/power/main.c | ||
119 | </sect1> | ||
120 | <sect1><title>Device Drivers ACPI Support</title> | ||
121 | <!-- Internal functions only | ||
122 | X!Edrivers/acpi/sleep/main.c | ||
123 | X!Edrivers/acpi/sleep/wakeup.c | ||
124 | X!Edrivers/acpi/motherboard.c | ||
125 | X!Edrivers/acpi/bus.c | ||
126 | --> | ||
127 | !Edrivers/acpi/scan.c | ||
128 | !Idrivers/acpi/scan.c | ||
129 | <!-- No correct structured comments | ||
130 | X!Edrivers/acpi/pci_bind.c | ||
131 | --> | ||
132 | </sect1> | ||
133 | <sect1><title>Device drivers PnP support</title> | ||
134 | !Idrivers/pnp/core.c | ||
135 | <!-- No correct structured comments | ||
136 | X!Edrivers/pnp/system.c | ||
137 | --> | ||
138 | !Edrivers/pnp/card.c | ||
139 | !Idrivers/pnp/driver.c | ||
140 | !Edrivers/pnp/manager.c | ||
141 | !Edrivers/pnp/support.c | ||
142 | </sect1> | ||
143 | <sect1><title>Userspace IO devices</title> | ||
144 | !Edrivers/uio/uio.c | ||
145 | !Iinclude/linux/uio_driver.h | ||
146 | </sect1> | ||
147 | </chapter> | ||
148 | |||
149 | <chapter id="parportdev"> | ||
150 | <title>Parallel Port Devices</title> | ||
151 | !Iinclude/linux/parport.h | ||
152 | !Edrivers/parport/ieee1284.c | ||
153 | !Edrivers/parport/share.c | ||
154 | !Idrivers/parport/daisy.c | ||
155 | </chapter> | ||
156 | |||
157 | <chapter id="message_devices"> | ||
158 | <title>Message-based devices</title> | ||
159 | <sect1><title>Fusion message devices</title> | ||
160 | !Edrivers/message/fusion/mptbase.c | ||
161 | !Idrivers/message/fusion/mptbase.c | ||
162 | !Edrivers/message/fusion/mptscsih.c | ||
163 | !Idrivers/message/fusion/mptscsih.c | ||
164 | !Idrivers/message/fusion/mptctl.c | ||
165 | !Idrivers/message/fusion/mptspi.c | ||
166 | !Idrivers/message/fusion/mptfc.c | ||
167 | !Idrivers/message/fusion/mptlan.c | ||
168 | </sect1> | ||
169 | <sect1><title>I2O message devices</title> | ||
170 | !Iinclude/linux/i2o.h | ||
171 | !Idrivers/message/i2o/core.h | ||
172 | !Edrivers/message/i2o/iop.c | ||
173 | !Idrivers/message/i2o/iop.c | ||
174 | !Idrivers/message/i2o/config-osm.c | ||
175 | !Edrivers/message/i2o/exec-osm.c | ||
176 | !Idrivers/message/i2o/exec-osm.c | ||
177 | !Idrivers/message/i2o/bus-osm.c | ||
178 | !Edrivers/message/i2o/device.c | ||
179 | !Idrivers/message/i2o/device.c | ||
180 | !Idrivers/message/i2o/driver.c | ||
181 | !Idrivers/message/i2o/pci.c | ||
182 | !Idrivers/message/i2o/i2o_block.c | ||
183 | !Idrivers/message/i2o/i2o_scsi.c | ||
184 | !Idrivers/message/i2o/i2o_proc.c | ||
185 | </sect1> | ||
186 | </chapter> | ||
187 | |||
188 | <chapter id="snddev"> | ||
189 | <title>Sound Devices</title> | ||
190 | !Iinclude/sound/core.h | ||
191 | !Esound/sound_core.c | ||
192 | !Iinclude/sound/pcm.h | ||
193 | !Esound/core/pcm.c | ||
194 | !Esound/core/device.c | ||
195 | !Esound/core/info.c | ||
196 | !Esound/core/rawmidi.c | ||
197 | !Esound/core/sound.c | ||
198 | !Esound/core/memory.c | ||
199 | !Esound/core/pcm_memory.c | ||
200 | !Esound/core/init.c | ||
201 | !Esound/core/isadma.c | ||
202 | !Esound/core/control.c | ||
203 | !Esound/core/pcm_lib.c | ||
204 | !Esound/core/hwdep.c | ||
205 | !Esound/core/pcm_native.c | ||
206 | !Esound/core/memalloc.c | ||
207 | <!-- FIXME: Removed for now since no structured comments in source | ||
208 | X!Isound/sound_firmware.c | ||
209 | --> | ||
210 | </chapter> | ||
211 | |||
212 | <chapter id="uart16x50"> | ||
213 | <title>16x50 UART Driver</title> | ||
214 | !Iinclude/linux/serial_core.h | ||
215 | !Edrivers/serial/serial_core.c | ||
216 | !Edrivers/serial/8250.c | ||
217 | </chapter> | ||
218 | |||
219 | <chapter id="fbdev"> | ||
220 | <title>Frame Buffer Library</title> | ||
221 | |||
222 | <para> | ||
223 | The frame buffer drivers depend heavily on four data structures. | ||
224 | These structures are declared in include/linux/fb.h. They are | ||
225 | fb_info, fb_var_screeninfo, fb_fix_screeninfo and fb_monospecs. | ||
226 | The last three can be made available to and from userland. | ||
227 | </para> | ||
228 | |||
229 | <para> | ||
230 | fb_info defines the current state of a particular video card. | ||
231 | Inside fb_info, there exists a fb_ops structure which is a | ||
232 | collection of needed functions to make fbdev and fbcon work. | ||
233 | fb_info is only visible to the kernel. | ||
234 | </para> | ||
235 | |||
236 | <para> | ||
237 | fb_var_screeninfo is used to describe the features of a video card | ||
238 | that are user defined. With fb_var_screeninfo, things such as | ||
239 | depth and the resolution may be defined. | ||
240 | </para> | ||
241 | |||
242 | <para> | ||
243 | The next structure is fb_fix_screeninfo. This defines the | ||
244 | properties of a card that are created when a mode is set and can't | ||
245 | be changed otherwise. A good example of this is the start of the | ||
246 | frame buffer memory. This "locks" the address of the frame buffer | ||
247 | memory, so that it cannot be changed or moved. | ||
248 | </para> | ||
249 | |||
250 | <para> | ||
251 | The last structure is fb_monospecs. In the old API, there was | ||
252 | little importance for fb_monospecs. This allowed for forbidden things | ||
253 | such as setting a mode of 800x600 on a fix frequency monitor. With | ||
254 | the new API, fb_monospecs prevents such things, and if used | ||
255 | correctly, can prevent a monitor from being cooked. fb_monospecs | ||
256 | will not be useful until kernels 2.5.x. | ||
257 | </para> | ||
258 | |||
259 | <sect1><title>Frame Buffer Memory</title> | ||
260 | !Edrivers/video/fbmem.c | ||
261 | </sect1> | ||
262 | <!-- | ||
263 | <sect1><title>Frame Buffer Console</title> | ||
264 | X!Edrivers/video/console/fbcon.c | ||
265 | </sect1> | ||
266 | --> | ||
267 | <sect1><title>Frame Buffer Colormap</title> | ||
268 | !Edrivers/video/fbcmap.c | ||
269 | </sect1> | ||
270 | <!-- FIXME: | ||
271 | drivers/video/fbgen.c has no docs, which stuffs up the sgml. Comment | ||
272 | out until somebody adds docs. KAO | ||
273 | <sect1><title>Frame Buffer Generic Functions</title> | ||
274 | X!Idrivers/video/fbgen.c | ||
275 | </sect1> | ||
276 | KAO --> | ||
277 | <sect1><title>Frame Buffer Video Mode Database</title> | ||
278 | !Idrivers/video/modedb.c | ||
279 | !Edrivers/video/modedb.c | ||
280 | </sect1> | ||
281 | <sect1><title>Frame Buffer Macintosh Video Mode Database</title> | ||
282 | !Edrivers/video/macmodes.c | ||
283 | </sect1> | ||
284 | <sect1><title>Frame Buffer Fonts</title> | ||
285 | <para> | ||
286 | Refer to the file drivers/video/console/fonts.c for more information. | ||
287 | </para> | ||
288 | <!-- FIXME: Removed for now since no structured comments in source | ||
289 | X!Idrivers/video/console/fonts.c | ||
290 | --> | ||
291 | </sect1> | ||
292 | </chapter> | ||
293 | |||
294 | <chapter id="input_subsystem"> | ||
295 | <title>Input Subsystem</title> | ||
296 | !Iinclude/linux/input.h | ||
297 | !Edrivers/input/input.c | ||
298 | !Edrivers/input/ff-core.c | ||
299 | !Edrivers/input/ff-memless.c | ||
300 | </chapter> | ||
301 | |||
302 | <chapter id="spi"> | ||
303 | <title>Serial Peripheral Interface (SPI)</title> | ||
304 | <para> | ||
305 | SPI is the "Serial Peripheral Interface", widely used with | ||
306 | embedded systems because it is a simple and efficient | ||
307 | interface: basically a multiplexed shift register. | ||
308 | Its three signal wires hold a clock (SCK, often in the range | ||
309 | of 1-20 MHz), a "Master Out, Slave In" (MOSI) data line, and | ||
310 | a "Master In, Slave Out" (MISO) data line. | ||
311 | SPI is a full duplex protocol; for each bit shifted out the | ||
312 | MOSI line (one per clock) another is shifted in on the MISO line. | ||
313 | Those bits are assembled into words of various sizes on the | ||
314 | way to and from system memory. | ||
315 | An additional chipselect line is usually active-low (nCS); | ||
316 | four signals are normally used for each peripheral, plus | ||
317 | sometimes an interrupt. | ||
318 | </para> | ||
319 | <para> | ||
320 | The SPI bus facilities listed here provide a generalized | ||
321 | interface to declare SPI busses and devices, manage them | ||
322 | according to the standard Linux driver model, and perform | ||
323 | input/output operations. | ||
324 | At this time, only "master" side interfaces are supported, | ||
325 | where Linux talks to SPI peripherals and does not implement | ||
326 | such a peripheral itself. | ||
327 | (Interfaces to support implementing SPI slaves would | ||
328 | necessarily look different.) | ||
329 | </para> | ||
330 | <para> | ||
331 | The programming interface is structured around two kinds of driver, | ||
332 | and two kinds of device. | ||
333 | A "Controller Driver" abstracts the controller hardware, which may | ||
334 | be as simple as a set of GPIO pins or as complex as a pair of FIFOs | ||
335 | connected to dual DMA engines on the other side of the SPI shift | ||
336 | register (maximizing throughput). Such drivers bridge between | ||
337 | whatever bus they sit on (often the platform bus) and SPI, and | ||
338 | expose the SPI side of their device as a | ||
339 | <structname>struct spi_master</structname>. | ||
340 | SPI devices are children of that master, represented as a | ||
341 | <structname>struct spi_device</structname> and manufactured from | ||
342 | <structname>struct spi_board_info</structname> descriptors which | ||
343 | are usually provided by board-specific initialization code. | ||
344 | A <structname>struct spi_driver</structname> is called a | ||
345 | "Protocol Driver", and is bound to a spi_device using normal | ||
346 | driver model calls. | ||
347 | </para> | ||
348 | <para> | ||
349 | The I/O model is a set of queued messages. Protocol drivers | ||
350 | submit one or more <structname>struct spi_message</structname> | ||
351 | objects, which are processed and completed asynchronously. | ||
352 | (There are synchronous wrappers, however.) Messages are | ||
353 | built from one or more <structname>struct spi_transfer</structname> | ||
354 | objects, each of which wraps a full duplex SPI transfer. | ||
355 | A variety of protocol tweaking options are needed, because | ||
356 | different chips adopt very different policies for how they | ||
357 | use the bits transferred with SPI. | ||
358 | </para> | ||
359 | !Iinclude/linux/spi/spi.h | ||
360 | !Fdrivers/spi/spi.c spi_register_board_info | ||
361 | !Edrivers/spi/spi.c | ||
362 | </chapter> | ||
363 | |||
364 | <chapter id="i2c"> | ||
365 | <title>I<superscript>2</superscript>C and SMBus Subsystem</title> | ||
366 | |||
367 | <para> | ||
368 | I<superscript>2</superscript>C (or without fancy typography, "I2C") | ||
369 | is an acronym for the "Inter-IC" bus, a simple bus protocol which is | ||
370 | widely used where low data rate communications suffice. | ||
371 | Since it's also a licensed trademark, some vendors use another | ||
372 | name (such as "Two-Wire Interface", TWI) for the same bus. | ||
373 | I2C only needs two signals (SCL for clock, SDA for data), conserving | ||
374 | board real estate and minimizing signal quality issues. | ||
375 | Most I2C devices use seven bit addresses, and bus speeds of up | ||
376 | to 400 kHz; there's a high speed extension (3.4 MHz) that's not yet | ||
377 | found wide use. | ||
378 | I2C is a multi-master bus; open drain signaling is used to | ||
379 | arbitrate between masters, as well as to handshake and to | ||
380 | synchronize clocks from slower clients. | ||
381 | </para> | ||
382 | |||
383 | <para> | ||
384 | The Linux I2C programming interfaces support only the master | ||
385 | side of bus interactions, not the slave side. | ||
386 | The programming interface is structured around two kinds of driver, | ||
387 | and two kinds of device. | ||
388 | An I2C "Adapter Driver" abstracts the controller hardware; it binds | ||
389 | to a physical device (perhaps a PCI device or platform_device) and | ||
390 | exposes a <structname>struct i2c_adapter</structname> representing | ||
391 | each I2C bus segment it manages. | ||
392 | On each I2C bus segment will be I2C devices represented by a | ||
393 | <structname>struct i2c_client</structname>. Those devices will | ||
394 | be bound to a <structname>struct i2c_driver</structname>, | ||
395 | which should follow the standard Linux driver model. | ||
396 | (At this writing, a legacy model is more widely used.) | ||
397 | There are functions to perform various I2C protocol operations; at | ||
398 | this writing all such functions are usable only from task context. | ||
399 | </para> | ||
400 | |||
401 | <para> | ||
402 | The System Management Bus (SMBus) is a sibling protocol. Most SMBus | ||
403 | systems are also I2C conformant. The electrical constraints are | ||
404 | tighter for SMBus, and it standardizes particular protocol messages | ||
405 | and idioms. Controllers that support I2C can also support most | ||
406 | SMBus operations, but SMBus controllers don't support all the protocol | ||
407 | options that an I2C controller will. | ||
408 | There are functions to perform various SMBus protocol operations, | ||
409 | either using I2C primitives or by issuing SMBus commands to | ||
410 | i2c_adapter devices which don't support those I2C operations. | ||
411 | </para> | ||
412 | |||
413 | !Iinclude/linux/i2c.h | ||
414 | !Fdrivers/i2c/i2c-boardinfo.c i2c_register_board_info | ||
415 | !Edrivers/i2c/i2c-core.c | ||
416 | </chapter> | ||
417 | |||
418 | </book> | ||
diff --git a/Documentation/DocBook/kernel-api.tmpl b/Documentation/DocBook/kernel-api.tmpl index 5818ff75786a..bc962cda6504 100644 --- a/Documentation/DocBook/kernel-api.tmpl +++ b/Documentation/DocBook/kernel-api.tmpl | |||
@@ -38,58 +38,6 @@ | |||
38 | 38 | ||
39 | <toc></toc> | 39 | <toc></toc> |
40 | 40 | ||
41 | <chapter id="Basics"> | ||
42 | <title>Driver Basics</title> | ||
43 | <sect1><title>Driver Entry and Exit points</title> | ||
44 | !Iinclude/linux/init.h | ||
45 | </sect1> | ||
46 | |||
47 | <sect1><title>Atomic and pointer manipulation</title> | ||
48 | !Iarch/x86/include/asm/atomic_32.h | ||
49 | !Iarch/x86/include/asm/unaligned.h | ||
50 | </sect1> | ||
51 | |||
52 | <sect1><title>Delaying, scheduling, and timer routines</title> | ||
53 | !Iinclude/linux/sched.h | ||
54 | !Ekernel/sched.c | ||
55 | !Ekernel/timer.c | ||
56 | </sect1> | ||
57 | <sect1><title>High-resolution timers</title> | ||
58 | !Iinclude/linux/ktime.h | ||
59 | !Iinclude/linux/hrtimer.h | ||
60 | !Ekernel/hrtimer.c | ||
61 | </sect1> | ||
62 | <sect1><title>Workqueues and Kevents</title> | ||
63 | !Ekernel/workqueue.c | ||
64 | </sect1> | ||
65 | <sect1><title>Internal Functions</title> | ||
66 | !Ikernel/exit.c | ||
67 | !Ikernel/signal.c | ||
68 | !Iinclude/linux/kthread.h | ||
69 | !Ekernel/kthread.c | ||
70 | </sect1> | ||
71 | |||
72 | <sect1><title>Kernel objects manipulation</title> | ||
73 | <!-- | ||
74 | X!Iinclude/linux/kobject.h | ||
75 | --> | ||
76 | !Elib/kobject.c | ||
77 | </sect1> | ||
78 | |||
79 | <sect1><title>Kernel utility functions</title> | ||
80 | !Iinclude/linux/kernel.h | ||
81 | !Ekernel/printk.c | ||
82 | !Ekernel/panic.c | ||
83 | !Ekernel/sys.c | ||
84 | !Ekernel/rcupdate.c | ||
85 | </sect1> | ||
86 | |||
87 | <sect1><title>Device Resource Management</title> | ||
88 | !Edrivers/base/devres.c | ||
89 | </sect1> | ||
90 | |||
91 | </chapter> | ||
92 | |||
93 | <chapter id="adt"> | 41 | <chapter id="adt"> |
94 | <title>Data Types</title> | 42 | <title>Data Types</title> |
95 | <sect1><title>Doubly Linked Lists</title> | 43 | <sect1><title>Doubly Linked Lists</title> |
@@ -298,62 +246,6 @@ X!Earch/x86/kernel/mca_32.c | |||
298 | !Ikernel/acct.c | 246 | !Ikernel/acct.c |
299 | </chapter> | 247 | </chapter> |
300 | 248 | ||
301 | <chapter id="devdrivers"> | ||
302 | <title>Device drivers infrastructure</title> | ||
303 | <sect1><title>Device Drivers Base</title> | ||
304 | <!-- | ||
305 | X!Iinclude/linux/device.h | ||
306 | --> | ||
307 | !Edrivers/base/driver.c | ||
308 | !Edrivers/base/core.c | ||
309 | !Edrivers/base/class.c | ||
310 | !Edrivers/base/firmware_class.c | ||
311 | !Edrivers/base/transport_class.c | ||
312 | <!-- Cannot be included, because | ||
313 | attribute_container_add_class_device_adapter | ||
314 | and attribute_container_classdev_to_container | ||
315 | exceed allowed 44 characters maximum | ||
316 | X!Edrivers/base/attribute_container.c | ||
317 | --> | ||
318 | !Edrivers/base/sys.c | ||
319 | <!-- | ||
320 | X!Edrivers/base/interface.c | ||
321 | --> | ||
322 | !Edrivers/base/platform.c | ||
323 | !Edrivers/base/bus.c | ||
324 | </sect1> | ||
325 | <sect1><title>Device Drivers Power Management</title> | ||
326 | !Edrivers/base/power/main.c | ||
327 | </sect1> | ||
328 | <sect1><title>Device Drivers ACPI Support</title> | ||
329 | <!-- Internal functions only | ||
330 | X!Edrivers/acpi/sleep/main.c | ||
331 | X!Edrivers/acpi/sleep/wakeup.c | ||
332 | X!Edrivers/acpi/motherboard.c | ||
333 | X!Edrivers/acpi/bus.c | ||
334 | --> | ||
335 | !Edrivers/acpi/scan.c | ||
336 | !Idrivers/acpi/scan.c | ||
337 | <!-- No correct structured comments | ||
338 | X!Edrivers/acpi/pci_bind.c | ||
339 | --> | ||
340 | </sect1> | ||
341 | <sect1><title>Device drivers PnP support</title> | ||
342 | !Idrivers/pnp/core.c | ||
343 | <!-- No correct structured comments | ||
344 | X!Edrivers/pnp/system.c | ||
345 | --> | ||
346 | !Edrivers/pnp/card.c | ||
347 | !Idrivers/pnp/driver.c | ||
348 | !Edrivers/pnp/manager.c | ||
349 | !Edrivers/pnp/support.c | ||
350 | </sect1> | ||
351 | <sect1><title>Userspace IO devices</title> | ||
352 | !Edrivers/uio/uio.c | ||
353 | !Iinclude/linux/uio_driver.h | ||
354 | </sect1> | ||
355 | </chapter> | ||
356 | |||
357 | <chapter id="blkdev"> | 249 | <chapter id="blkdev"> |
358 | <title>Block Devices</title> | 250 | <title>Block Devices</title> |
359 | !Eblock/blk-core.c | 251 | !Eblock/blk-core.c |
@@ -381,275 +273,6 @@ X!Edrivers/pnp/system.c | |||
381 | !Edrivers/char/misc.c | 273 | !Edrivers/char/misc.c |
382 | </chapter> | 274 | </chapter> |
383 | 275 | ||
384 | <chapter id="parportdev"> | ||
385 | <title>Parallel Port Devices</title> | ||
386 | !Iinclude/linux/parport.h | ||
387 | !Edrivers/parport/ieee1284.c | ||
388 | !Edrivers/parport/share.c | ||
389 | !Idrivers/parport/daisy.c | ||
390 | </chapter> | ||
391 | |||
392 | <chapter id="message_devices"> | ||
393 | <title>Message-based devices</title> | ||
394 | <sect1><title>Fusion message devices</title> | ||
395 | !Edrivers/message/fusion/mptbase.c | ||
396 | !Idrivers/message/fusion/mptbase.c | ||
397 | !Edrivers/message/fusion/mptscsih.c | ||
398 | !Idrivers/message/fusion/mptscsih.c | ||
399 | !Idrivers/message/fusion/mptctl.c | ||
400 | !Idrivers/message/fusion/mptspi.c | ||
401 | !Idrivers/message/fusion/mptfc.c | ||
402 | !Idrivers/message/fusion/mptlan.c | ||
403 | </sect1> | ||
404 | <sect1><title>I2O message devices</title> | ||
405 | !Iinclude/linux/i2o.h | ||
406 | !Idrivers/message/i2o/core.h | ||
407 | !Edrivers/message/i2o/iop.c | ||
408 | !Idrivers/message/i2o/iop.c | ||
409 | !Idrivers/message/i2o/config-osm.c | ||
410 | !Edrivers/message/i2o/exec-osm.c | ||
411 | !Idrivers/message/i2o/exec-osm.c | ||
412 | !Idrivers/message/i2o/bus-osm.c | ||
413 | !Edrivers/message/i2o/device.c | ||
414 | !Idrivers/message/i2o/device.c | ||
415 | !Idrivers/message/i2o/driver.c | ||
416 | !Idrivers/message/i2o/pci.c | ||
417 | !Idrivers/message/i2o/i2o_block.c | ||
418 | !Idrivers/message/i2o/i2o_scsi.c | ||
419 | !Idrivers/message/i2o/i2o_proc.c | ||
420 | </sect1> | ||
421 | </chapter> | ||
422 | |||
423 | <chapter id="snddev"> | ||
424 | <title>Sound Devices</title> | ||
425 | !Iinclude/sound/core.h | ||
426 | !Esound/sound_core.c | ||
427 | !Iinclude/sound/pcm.h | ||
428 | !Esound/core/pcm.c | ||
429 | !Esound/core/device.c | ||
430 | !Esound/core/info.c | ||
431 | !Esound/core/rawmidi.c | ||
432 | !Esound/core/sound.c | ||
433 | !Esound/core/memory.c | ||
434 | !Esound/core/pcm_memory.c | ||
435 | !Esound/core/init.c | ||
436 | !Esound/core/isadma.c | ||
437 | !Esound/core/control.c | ||
438 | !Esound/core/pcm_lib.c | ||
439 | !Esound/core/hwdep.c | ||
440 | !Esound/core/pcm_native.c | ||
441 | !Esound/core/memalloc.c | ||
442 | <!-- FIXME: Removed for now since no structured comments in source | ||
443 | X!Isound/sound_firmware.c | ||
444 | --> | ||
445 | </chapter> | ||
446 | |||
447 | <chapter id="uart16x50"> | ||
448 | <title>16x50 UART Driver</title> | ||
449 | !Iinclude/linux/serial_core.h | ||
450 | !Edrivers/serial/serial_core.c | ||
451 | !Edrivers/serial/8250.c | ||
452 | </chapter> | ||
453 | |||
454 | <chapter id="fbdev"> | ||
455 | <title>Frame Buffer Library</title> | ||
456 | |||
457 | <para> | ||
458 | The frame buffer drivers depend heavily on four data structures. | ||
459 | These structures are declared in include/linux/fb.h. They are | ||
460 | fb_info, fb_var_screeninfo, fb_fix_screeninfo and fb_monospecs. | ||
461 | The last three can be made available to and from userland. | ||
462 | </para> | ||
463 | |||
464 | <para> | ||
465 | fb_info defines the current state of a particular video card. | ||
466 | Inside fb_info, there exists a fb_ops structure which is a | ||
467 | collection of needed functions to make fbdev and fbcon work. | ||
468 | fb_info is only visible to the kernel. | ||
469 | </para> | ||
470 | |||
471 | <para> | ||
472 | fb_var_screeninfo is used to describe the features of a video card | ||
473 | that are user defined. With fb_var_screeninfo, things such as | ||
474 | depth and the resolution may be defined. | ||
475 | </para> | ||
476 | |||
477 | <para> | ||
478 | The next structure is fb_fix_screeninfo. This defines the | ||
479 | properties of a card that are created when a mode is set and can't | ||
480 | be changed otherwise. A good example of this is the start of the | ||
481 | frame buffer memory. This "locks" the address of the frame buffer | ||
482 | memory, so that it cannot be changed or moved. | ||
483 | </para> | ||
484 | |||
485 | <para> | ||
486 | The last structure is fb_monospecs. In the old API, there was | ||
487 | little importance for fb_monospecs. This allowed for forbidden things | ||
488 | such as setting a mode of 800x600 on a fix frequency monitor. With | ||
489 | the new API, fb_monospecs prevents such things, and if used | ||
490 | correctly, can prevent a monitor from being cooked. fb_monospecs | ||
491 | will not be useful until kernels 2.5.x. | ||
492 | </para> | ||
493 | |||
494 | <sect1><title>Frame Buffer Memory</title> | ||
495 | !Edrivers/video/fbmem.c | ||
496 | </sect1> | ||
497 | <!-- | ||
498 | <sect1><title>Frame Buffer Console</title> | ||
499 | X!Edrivers/video/console/fbcon.c | ||
500 | </sect1> | ||
501 | --> | ||
502 | <sect1><title>Frame Buffer Colormap</title> | ||
503 | !Edrivers/video/fbcmap.c | ||
504 | </sect1> | ||
505 | <!-- FIXME: | ||
506 | drivers/video/fbgen.c has no docs, which stuffs up the sgml. Comment | ||
507 | out until somebody adds docs. KAO | ||
508 | <sect1><title>Frame Buffer Generic Functions</title> | ||
509 | X!Idrivers/video/fbgen.c | ||
510 | </sect1> | ||
511 | KAO --> | ||
512 | <sect1><title>Frame Buffer Video Mode Database</title> | ||
513 | !Idrivers/video/modedb.c | ||
514 | !Edrivers/video/modedb.c | ||
515 | </sect1> | ||
516 | <sect1><title>Frame Buffer Macintosh Video Mode Database</title> | ||
517 | !Edrivers/video/macmodes.c | ||
518 | </sect1> | ||
519 | <sect1><title>Frame Buffer Fonts</title> | ||
520 | <para> | ||
521 | Refer to the file drivers/video/console/fonts.c for more information. | ||
522 | </para> | ||
523 | <!-- FIXME: Removed for now since no structured comments in source | ||
524 | X!Idrivers/video/console/fonts.c | ||
525 | --> | ||
526 | </sect1> | ||
527 | </chapter> | ||
528 | |||
529 | <chapter id="input_subsystem"> | ||
530 | <title>Input Subsystem</title> | ||
531 | !Iinclude/linux/input.h | ||
532 | !Edrivers/input/input.c | ||
533 | !Edrivers/input/ff-core.c | ||
534 | !Edrivers/input/ff-memless.c | ||
535 | </chapter> | ||
536 | |||
537 | <chapter id="spi"> | ||
538 | <title>Serial Peripheral Interface (SPI)</title> | ||
539 | <para> | ||
540 | SPI is the "Serial Peripheral Interface", widely used with | ||
541 | embedded systems because it is a simple and efficient | ||
542 | interface: basically a multiplexed shift register. | ||
543 | Its three signal wires hold a clock (SCK, often in the range | ||
544 | of 1-20 MHz), a "Master Out, Slave In" (MOSI) data line, and | ||
545 | a "Master In, Slave Out" (MISO) data line. | ||
546 | SPI is a full duplex protocol; for each bit shifted out the | ||
547 | MOSI line (one per clock) another is shifted in on the MISO line. | ||
548 | Those bits are assembled into words of various sizes on the | ||
549 | way to and from system memory. | ||
550 | An additional chipselect line is usually active-low (nCS); | ||
551 | four signals are normally used for each peripheral, plus | ||
552 | sometimes an interrupt. | ||
553 | </para> | ||
554 | <para> | ||
555 | The SPI bus facilities listed here provide a generalized | ||
556 | interface to declare SPI busses and devices, manage them | ||
557 | according to the standard Linux driver model, and perform | ||
558 | input/output operations. | ||
559 | At this time, only "master" side interfaces are supported, | ||
560 | where Linux talks to SPI peripherals and does not implement | ||
561 | such a peripheral itself. | ||
562 | (Interfaces to support implementing SPI slaves would | ||
563 | necessarily look different.) | ||
564 | </para> | ||
565 | <para> | ||
566 | The programming interface is structured around two kinds of driver, | ||
567 | and two kinds of device. | ||
568 | A "Controller Driver" abstracts the controller hardware, which may | ||
569 | be as simple as a set of GPIO pins or as complex as a pair of FIFOs | ||
570 | connected to dual DMA engines on the other side of the SPI shift | ||
571 | register (maximizing throughput). Such drivers bridge between | ||
572 | whatever bus they sit on (often the platform bus) and SPI, and | ||
573 | expose the SPI side of their device as a | ||
574 | <structname>struct spi_master</structname>. | ||
575 | SPI devices are children of that master, represented as a | ||
576 | <structname>struct spi_device</structname> and manufactured from | ||
577 | <structname>struct spi_board_info</structname> descriptors which | ||
578 | are usually provided by board-specific initialization code. | ||
579 | A <structname>struct spi_driver</structname> is called a | ||
580 | "Protocol Driver", and is bound to a spi_device using normal | ||
581 | driver model calls. | ||
582 | </para> | ||
583 | <para> | ||
584 | The I/O model is a set of queued messages. Protocol drivers | ||
585 | submit one or more <structname>struct spi_message</structname> | ||
586 | objects, which are processed and completed asynchronously. | ||
587 | (There are synchronous wrappers, however.) Messages are | ||
588 | built from one or more <structname>struct spi_transfer</structname> | ||
589 | objects, each of which wraps a full duplex SPI transfer. | ||
590 | A variety of protocol tweaking options are needed, because | ||
591 | different chips adopt very different policies for how they | ||
592 | use the bits transferred with SPI. | ||
593 | </para> | ||
594 | !Iinclude/linux/spi/spi.h | ||
595 | !Fdrivers/spi/spi.c spi_register_board_info | ||
596 | !Edrivers/spi/spi.c | ||
597 | </chapter> | ||
598 | |||
599 | <chapter id="i2c"> | ||
600 | <title>I<superscript>2</superscript>C and SMBus Subsystem</title> | ||
601 | |||
602 | <para> | ||
603 | I<superscript>2</superscript>C (or without fancy typography, "I2C") | ||
604 | is an acronym for the "Inter-IC" bus, a simple bus protocol which is | ||
605 | widely used where low data rate communications suffice. | ||
606 | Since it's also a licensed trademark, some vendors use another | ||
607 | name (such as "Two-Wire Interface", TWI) for the same bus. | ||
608 | I2C only needs two signals (SCL for clock, SDA for data), conserving | ||
609 | board real estate and minimizing signal quality issues. | ||
610 | Most I2C devices use seven bit addresses, and bus speeds of up | ||
611 | to 400 kHz; there's a high speed extension (3.4 MHz) that's not yet | ||
612 | found wide use. | ||
613 | I2C is a multi-master bus; open drain signaling is used to | ||
614 | arbitrate between masters, as well as to handshake and to | ||
615 | synchronize clocks from slower clients. | ||
616 | </para> | ||
617 | |||
618 | <para> | ||
619 | The Linux I2C programming interfaces support only the master | ||
620 | side of bus interactions, not the slave side. | ||
621 | The programming interface is structured around two kinds of driver, | ||
622 | and two kinds of device. | ||
623 | An I2C "Adapter Driver" abstracts the controller hardware; it binds | ||
624 | to a physical device (perhaps a PCI device or platform_device) and | ||
625 | exposes a <structname>struct i2c_adapter</structname> representing | ||
626 | each I2C bus segment it manages. | ||
627 | On each I2C bus segment will be I2C devices represented by a | ||
628 | <structname>struct i2c_client</structname>. Those devices will | ||
629 | be bound to a <structname>struct i2c_driver</structname>, | ||
630 | which should follow the standard Linux driver model. | ||
631 | (At this writing, a legacy model is more widely used.) | ||
632 | There are functions to perform various I2C protocol operations; at | ||
633 | this writing all such functions are usable only from task context. | ||
634 | </para> | ||
635 | |||
636 | <para> | ||
637 | The System Management Bus (SMBus) is a sibling protocol. Most SMBus | ||
638 | systems are also I2C conformant. The electrical constraints are | ||
639 | tighter for SMBus, and it standardizes particular protocol messages | ||
640 | and idioms. Controllers that support I2C can also support most | ||
641 | SMBus operations, but SMBus controllers don't support all the protocol | ||
642 | options that an I2C controller will. | ||
643 | There are functions to perform various SMBus protocol operations, | ||
644 | either using I2C primitives or by issuing SMBus commands to | ||
645 | i2c_adapter devices which don't support those I2C operations. | ||
646 | </para> | ||
647 | |||
648 | !Iinclude/linux/i2c.h | ||
649 | !Fdrivers/i2c/i2c-boardinfo.c i2c_register_board_info | ||
650 | !Edrivers/i2c/i2c-core.c | ||
651 | </chapter> | ||
652 | |||
653 | <chapter id="clk"> | 276 | <chapter id="clk"> |
654 | <title>Clock Framework</title> | 277 | <title>Clock Framework</title> |
655 | 278 | ||
diff --git a/Documentation/DocBook/uio-howto.tmpl b/Documentation/DocBook/uio-howto.tmpl index b787e4721c90..52e1b79ce0e6 100644 --- a/Documentation/DocBook/uio-howto.tmpl +++ b/Documentation/DocBook/uio-howto.tmpl | |||
@@ -42,6 +42,12 @@ GPL version 2. | |||
42 | 42 | ||
43 | <revhistory> | 43 | <revhistory> |
44 | <revision> | 44 | <revision> |
45 | <revnumber>0.7</revnumber> | ||
46 | <date>2008-12-23</date> | ||
47 | <authorinitials>hjk</authorinitials> | ||
48 | <revremark>Added generic platform drivers and offset attribute.</revremark> | ||
49 | </revision> | ||
50 | <revision> | ||
45 | <revnumber>0.6</revnumber> | 51 | <revnumber>0.6</revnumber> |
46 | <date>2008-12-05</date> | 52 | <date>2008-12-05</date> |
47 | <authorinitials>hjk</authorinitials> | 53 | <authorinitials>hjk</authorinitials> |
@@ -312,6 +318,16 @@ interested in translating it, please email me | |||
312 | pointed to by addr. | 318 | pointed to by addr. |
313 | </para> | 319 | </para> |
314 | </listitem> | 320 | </listitem> |
321 | <listitem> | ||
322 | <para> | ||
323 | <filename>offset</filename>: The offset, in bytes, that has to be | ||
324 | added to the pointer returned by <function>mmap()</function> to get | ||
325 | to the actual device memory. This is important if the device's memory | ||
326 | is not page aligned. Remember that pointers returned by | ||
327 | <function>mmap()</function> are always page aligned, so it is good | ||
328 | style to always add this offset. | ||
329 | </para> | ||
330 | </listitem> | ||
315 | </itemizedlist> | 331 | </itemizedlist> |
316 | 332 | ||
317 | <para> | 333 | <para> |
@@ -594,6 +610,78 @@ framework to set up sysfs files for this region. Simply leave it alone. | |||
594 | </para> | 610 | </para> |
595 | </sect1> | 611 | </sect1> |
596 | 612 | ||
613 | <sect1 id="using_uio_pdrv"> | ||
614 | <title>Using uio_pdrv for platform devices</title> | ||
615 | <para> | ||
616 | In many cases, UIO drivers for platform devices can be handled in a | ||
617 | generic way. In the same place where you define your | ||
618 | <varname>struct platform_device</varname>, you simply also implement | ||
619 | your interrupt handler and fill your | ||
620 | <varname>struct uio_info</varname>. A pointer to this | ||
621 | <varname>struct uio_info</varname> is then used as | ||
622 | <varname>platform_data</varname> for your platform device. | ||
623 | </para> | ||
624 | <para> | ||
625 | You also need to set up an array of <varname>struct resource</varname> | ||
626 | containing addresses and sizes of your memory mappings. This | ||
627 | information is passed to the driver using the | ||
628 | <varname>.resource</varname> and <varname>.num_resources</varname> | ||
629 | elements of <varname>struct platform_device</varname>. | ||
630 | </para> | ||
631 | <para> | ||
632 | You now have to set the <varname>.name</varname> element of | ||
633 | <varname>struct platform_device</varname> to | ||
634 | <varname>"uio_pdrv"</varname> to use the generic UIO platform device | ||
635 | driver. This driver will fill the <varname>mem[]</varname> array | ||
636 | according to the resources given, and register the device. | ||
637 | </para> | ||
638 | <para> | ||
639 | The advantage of this approach is that you only have to edit a file | ||
640 | you need to edit anyway. You do not have to create an extra driver. | ||
641 | </para> | ||
642 | </sect1> | ||
643 | |||
644 | <sect1 id="using_uio_pdrv_genirq"> | ||
645 | <title>Using uio_pdrv_genirq for platform devices</title> | ||
646 | <para> | ||
647 | Especially in embedded devices, you frequently find chips where the | ||
648 | irq pin is tied to its own dedicated interrupt line. In such cases, | ||
649 | where you can be really sure the interrupt is not shared, we can take | ||
650 | the concept of <varname>uio_pdrv</varname> one step further and use a | ||
651 | generic interrupt handler. That's what | ||
652 | <varname>uio_pdrv_genirq</varname> does. | ||
653 | </para> | ||
654 | <para> | ||
655 | The setup for this driver is the same as described above for | ||
656 | <varname>uio_pdrv</varname>, except that you do not implement an | ||
657 | interrupt handler. The <varname>.handler</varname> element of | ||
658 | <varname>struct uio_info</varname> must remain | ||
659 | <varname>NULL</varname>. The <varname>.irq_flags</varname> element | ||
660 | must not contain <varname>IRQF_SHARED</varname>. | ||
661 | </para> | ||
662 | <para> | ||
663 | You will set the <varname>.name</varname> element of | ||
664 | <varname>struct platform_device</varname> to | ||
665 | <varname>"uio_pdrv_genirq"</varname> to use this driver. | ||
666 | </para> | ||
667 | <para> | ||
668 | The generic interrupt handler of <varname>uio_pdrv_genirq</varname> | ||
669 | will simply disable the interrupt line using | ||
670 | <function>disable_irq_nosync()</function>. After doing its work, | ||
671 | userspace can reenable the interrupt by writing 0x00000001 to the UIO | ||
672 | device file. The driver already implements an | ||
673 | <function>irq_control()</function> to make this possible, you must not | ||
674 | implement your own. | ||
675 | </para> | ||
676 | <para> | ||
677 | Using <varname>uio_pdrv_genirq</varname> not only saves a few lines of | ||
678 | interrupt handler code. You also do not need to know anything about | ||
679 | the chip's internal registers to create the kernel part of the driver. | ||
680 | All you need to know is the irq number of the pin the chip is | ||
681 | connected to. | ||
682 | </para> | ||
683 | </sect1> | ||
684 | |||
597 | </chapter> | 685 | </chapter> |
598 | 686 | ||
599 | <chapter id="userspace_driver" xreflabel="Writing a driver in user space"> | 687 | <chapter id="userspace_driver" xreflabel="Writing a driver in user space"> |
diff --git a/Documentation/IO-mapping.txt b/Documentation/IO-mapping.txt index 86edb61bdee6..78a440695e11 100644 --- a/Documentation/IO-mapping.txt +++ b/Documentation/IO-mapping.txt | |||
@@ -1,6 +1,6 @@ | |||
1 | [ NOTE: The virt_to_bus() and bus_to_virt() functions have been | 1 | [ NOTE: The virt_to_bus() and bus_to_virt() functions have been |
2 | superseded by the functionality provided by the PCI DMA | 2 | superseded by the functionality provided by the PCI DMA interface |
3 | interface (see Documentation/DMA-mapping.txt). They continue | 3 | (see Documentation/PCI/PCI-DMA-mapping.txt). They continue |
4 | to be documented below for historical purposes, but new code | 4 | to be documented below for historical purposes, but new code |
5 | must not use them. --davidm 00/12/12 ] | 5 | must not use them. --davidm 00/12/12 ] |
6 | 6 | ||
diff --git a/Documentation/PCI/PCIEBUS-HOWTO.txt b/Documentation/PCI/PCIEBUS-HOWTO.txt index 9a07e38631b0..6bd5f372adec 100644 --- a/Documentation/PCI/PCIEBUS-HOWTO.txt +++ b/Documentation/PCI/PCIEBUS-HOWTO.txt | |||
@@ -93,7 +93,7 @@ the PCI Express Port Bus driver from loading a service driver. | |||
93 | 93 | ||
94 | int pcie_port_service_register(struct pcie_port_service_driver *new) | 94 | int pcie_port_service_register(struct pcie_port_service_driver *new) |
95 | 95 | ||
96 | This API replaces the Linux Driver Model's pci_module_init API. A | 96 | This API replaces the Linux Driver Model's pci_register_driver API. A |
97 | service driver should always calls pcie_port_service_register at | 97 | service driver should always calls pcie_port_service_register at |
98 | module init. Note that after service driver being loaded, calls | 98 | module init. Note that after service driver being loaded, calls |
99 | such as pci_enable_device(dev) and pci_set_master(dev) are no longer | 99 | such as pci_enable_device(dev) and pci_set_master(dev) are no longer |
diff --git a/Documentation/accounting/getdelays.c b/Documentation/accounting/getdelays.c index cc49400b4af8..7ea231172c85 100644 --- a/Documentation/accounting/getdelays.c +++ b/Documentation/accounting/getdelays.c | |||
@@ -392,6 +392,10 @@ int main(int argc, char *argv[]) | |||
392 | goto err; | 392 | goto err; |
393 | } | 393 | } |
394 | } | 394 | } |
395 | if (!maskset && !tid && !containerset) { | ||
396 | usage(); | ||
397 | goto err; | ||
398 | } | ||
395 | 399 | ||
396 | do { | 400 | do { |
397 | int i; | 401 | int i; |
diff --git a/Documentation/block/biodoc.txt b/Documentation/block/biodoc.txt index 3c5434c83daf..ecad6ee75705 100644 --- a/Documentation/block/biodoc.txt +++ b/Documentation/block/biodoc.txt | |||
@@ -186,8 +186,9 @@ a virtual address mapping (unlike the earlier scheme of virtual address | |||
186 | do not have a corresponding kernel virtual address space mapping) and | 186 | do not have a corresponding kernel virtual address space mapping) and |
187 | low-memory pages. | 187 | low-memory pages. |
188 | 188 | ||
189 | Note: Please refer to DMA-mapping.txt for a discussion on PCI high mem DMA | 189 | Note: Please refer to Documentation/PCI/PCI-DMA-mapping.txt for a discussion |
190 | aspects and mapping of scatter gather lists, and support for 64 bit PCI. | 190 | on PCI high mem DMA aspects and mapping of scatter gather lists, and support |
191 | for 64 bit PCI. | ||
191 | 192 | ||
192 | Special handling is required only for cases where i/o needs to happen on | 193 | Special handling is required only for cases where i/o needs to happen on |
193 | pages at physical memory addresses beyond what the device can support. In these | 194 | pages at physical memory addresses beyond what the device can support. In these |
@@ -953,14 +954,14 @@ elevator_allow_merge_fn called whenever the block layer determines | |||
953 | results in some sort of conflict internally, | 954 | results in some sort of conflict internally, |
954 | this hook allows it to do that. | 955 | this hook allows it to do that. |
955 | 956 | ||
956 | elevator_dispatch_fn fills the dispatch queue with ready requests. | 957 | elevator_dispatch_fn* fills the dispatch queue with ready requests. |
957 | I/O schedulers are free to postpone requests by | 958 | I/O schedulers are free to postpone requests by |
958 | not filling the dispatch queue unless @force | 959 | not filling the dispatch queue unless @force |
959 | is non-zero. Once dispatched, I/O schedulers | 960 | is non-zero. Once dispatched, I/O schedulers |
960 | are not allowed to manipulate the requests - | 961 | are not allowed to manipulate the requests - |
961 | they belong to generic dispatch queue. | 962 | they belong to generic dispatch queue. |
962 | 963 | ||
963 | elevator_add_req_fn called to add a new request into the scheduler | 964 | elevator_add_req_fn* called to add a new request into the scheduler |
964 | 965 | ||
965 | elevator_queue_empty_fn returns true if the merge queue is empty. | 966 | elevator_queue_empty_fn returns true if the merge queue is empty. |
966 | Drivers shouldn't use this, but rather check | 967 | Drivers shouldn't use this, but rather check |
@@ -990,7 +991,7 @@ elevator_activate_req_fn Called when device driver first sees a request. | |||
990 | elevator_deactivate_req_fn Called when device driver decides to delay | 991 | elevator_deactivate_req_fn Called when device driver decides to delay |
991 | a request by requeueing it. | 992 | a request by requeueing it. |
992 | 993 | ||
993 | elevator_init_fn | 994 | elevator_init_fn* |
994 | elevator_exit_fn Allocate and free any elevator specific storage | 995 | elevator_exit_fn Allocate and free any elevator specific storage |
995 | for a queue. | 996 | for a queue. |
996 | 997 | ||
diff --git a/Documentation/block/queue-sysfs.txt b/Documentation/block/queue-sysfs.txt new file mode 100644 index 000000000000..e164403f60e1 --- /dev/null +++ b/Documentation/block/queue-sysfs.txt | |||
@@ -0,0 +1,63 @@ | |||
1 | Queue sysfs files | ||
2 | ================= | ||
3 | |||
4 | This text file will detail the queue files that are located in the sysfs tree | ||
5 | for each block device. Note that stacked devices typically do not export | ||
6 | any settings, since their queue merely functions are a remapping target. | ||
7 | These files are the ones found in the /sys/block/xxx/queue/ directory. | ||
8 | |||
9 | Files denoted with a RO postfix are readonly and the RW postfix means | ||
10 | read-write. | ||
11 | |||
12 | hw_sector_size (RO) | ||
13 | ------------------- | ||
14 | This is the hardware sector size of the device, in bytes. | ||
15 | |||
16 | max_hw_sectors_kb (RO) | ||
17 | ---------------------- | ||
18 | This is the maximum number of kilobytes supported in a single data transfer. | ||
19 | |||
20 | max_sectors_kb (RW) | ||
21 | ------------------- | ||
22 | This is the maximum number of kilobytes that the block layer will allow | ||
23 | for a filesystem request. Must be smaller than or equal to the maximum | ||
24 | size allowed by the hardware. | ||
25 | |||
26 | nomerges (RW) | ||
27 | ------------- | ||
28 | This enables the user to disable the lookup logic involved with IO merging | ||
29 | requests in the block layer. Merging may still occur through a direct | ||
30 | 1-hit cache, since that comes for (almost) free. The IO scheduler will not | ||
31 | waste cycles doing tree/hash lookups for merges if nomerges is 1. Defaults | ||
32 | to 0, enabling all merges. | ||
33 | |||
34 | nr_requests (RW) | ||
35 | ---------------- | ||
36 | This controls how many requests may be allocated in the block layer for | ||
37 | read or write requests. Note that the total allocated number may be twice | ||
38 | this amount, since it applies only to reads or writes (not the accumulated | ||
39 | sum). | ||
40 | |||
41 | read_ahead_kb (RW) | ||
42 | ------------------ | ||
43 | Maximum number of kilobytes to read-ahead for filesystems on this block | ||
44 | device. | ||
45 | |||
46 | rq_affinity (RW) | ||
47 | ---------------- | ||
48 | If this option is enabled, the block layer will migrate request completions | ||
49 | to the CPU that originally submitted the request. For some workloads | ||
50 | this provides a significant reduction in CPU cycles due to caching effects. | ||
51 | |||
52 | scheduler (RW) | ||
53 | -------------- | ||
54 | When read, this file will display the current and available IO schedulers | ||
55 | for this block device. The currently active IO scheduler will be enclosed | ||
56 | in [] brackets. Writing an IO scheduler name to this file will switch | ||
57 | control of this block device to that new IO scheduler. Note that writing | ||
58 | an IO scheduler name to this file will attempt to load that IO scheduler | ||
59 | module, if it isn't already present in the system. | ||
60 | |||
61 | |||
62 | |||
63 | Jens Axboe <jens.axboe@oracle.com>, February 2009 | ||
diff --git a/Documentation/cgroups/cgroups.txt b/Documentation/cgroups/cgroups.txt index e33ee74eee77..93feb8444489 100644 --- a/Documentation/cgroups/cgroups.txt +++ b/Documentation/cgroups/cgroups.txt | |||
@@ -1,7 +1,8 @@ | |||
1 | CGROUPS | 1 | CGROUPS |
2 | ------- | 2 | ------- |
3 | 3 | ||
4 | Written by Paul Menage <menage@google.com> based on Documentation/cpusets.txt | 4 | Written by Paul Menage <menage@google.com> based on |
5 | Documentation/cgroups/cpusets.txt | ||
5 | 6 | ||
6 | Original copyright statements from cpusets.txt: | 7 | Original copyright statements from cpusets.txt: |
7 | Portions Copyright (C) 2004 BULL SA. | 8 | Portions Copyright (C) 2004 BULL SA. |
@@ -68,7 +69,7 @@ On their own, the only use for cgroups is for simple job | |||
68 | tracking. The intention is that other subsystems hook into the generic | 69 | tracking. The intention is that other subsystems hook into the generic |
69 | cgroup support to provide new attributes for cgroups, such as | 70 | cgroup support to provide new attributes for cgroups, such as |
70 | accounting/limiting the resources which processes in a cgroup can | 71 | accounting/limiting the resources which processes in a cgroup can |
71 | access. For example, cpusets (see Documentation/cpusets.txt) allows | 72 | access. For example, cpusets (see Documentation/cgroups/cpusets.txt) allows |
72 | you to associate a set of CPUs and a set of memory nodes with the | 73 | you to associate a set of CPUs and a set of memory nodes with the |
73 | tasks in each cgroup. | 74 | tasks in each cgroup. |
74 | 75 | ||
@@ -251,10 +252,8 @@ cgroup file system directories. | |||
251 | When a task is moved from one cgroup to another, it gets a new | 252 | When a task is moved from one cgroup to another, it gets a new |
252 | css_set pointer - if there's an already existing css_set with the | 253 | css_set pointer - if there's an already existing css_set with the |
253 | desired collection of cgroups then that group is reused, else a new | 254 | desired collection of cgroups then that group is reused, else a new |
254 | css_set is allocated. Note that the current implementation uses a | 255 | css_set is allocated. The appropriate existing css_set is located by |
255 | linear search to locate an appropriate existing css_set, so isn't | 256 | looking into a hash table. |
256 | very efficient. A future version will use a hash table for better | ||
257 | performance. | ||
258 | 257 | ||
259 | To allow access from a cgroup to the css_sets (and hence tasks) | 258 | To allow access from a cgroup to the css_sets (and hence tasks) |
260 | that comprise it, a set of cg_cgroup_link objects form a lattice; | 259 | that comprise it, a set of cg_cgroup_link objects form a lattice; |
diff --git a/Documentation/controllers/cpuacct.txt b/Documentation/cgroups/cpuacct.txt index bb775fbe43d7..bb775fbe43d7 100644 --- a/Documentation/controllers/cpuacct.txt +++ b/Documentation/cgroups/cpuacct.txt | |||
diff --git a/Documentation/cpusets.txt b/Documentation/cgroups/cpusets.txt index 5c86c258c791..0611e9528c7c 100644 --- a/Documentation/cpusets.txt +++ b/Documentation/cgroups/cpusets.txt | |||
@@ -142,7 +142,7 @@ into the rest of the kernel, none in performance critical paths: | |||
142 | - in fork and exit, to attach and detach a task from its cpuset. | 142 | - in fork and exit, to attach and detach a task from its cpuset. |
143 | - in sched_setaffinity, to mask the requested CPUs by what's | 143 | - in sched_setaffinity, to mask the requested CPUs by what's |
144 | allowed in that tasks cpuset. | 144 | allowed in that tasks cpuset. |
145 | - in sched.c migrate_all_tasks(), to keep migrating tasks within | 145 | - in sched.c migrate_live_tasks(), to keep migrating tasks within |
146 | the CPUs allowed by their cpuset, if possible. | 146 | the CPUs allowed by their cpuset, if possible. |
147 | - in the mbind and set_mempolicy system calls, to mask the requested | 147 | - in the mbind and set_mempolicy system calls, to mask the requested |
148 | Memory Nodes by what's allowed in that tasks cpuset. | 148 | Memory Nodes by what's allowed in that tasks cpuset. |
@@ -175,6 +175,10 @@ files describing that cpuset: | |||
175 | - mem_exclusive flag: is memory placement exclusive? | 175 | - mem_exclusive flag: is memory placement exclusive? |
176 | - mem_hardwall flag: is memory allocation hardwalled | 176 | - mem_hardwall flag: is memory allocation hardwalled |
177 | - memory_pressure: measure of how much paging pressure in cpuset | 177 | - memory_pressure: measure of how much paging pressure in cpuset |
178 | - memory_spread_page flag: if set, spread page cache evenly on allowed nodes | ||
179 | - memory_spread_slab flag: if set, spread slab cache evenly on allowed nodes | ||
180 | - sched_load_balance flag: if set, load balance within CPUs on that cpuset | ||
181 | - sched_relax_domain_level: the searching range when migrating tasks | ||
178 | 182 | ||
179 | In addition, the root cpuset only has the following file: | 183 | In addition, the root cpuset only has the following file: |
180 | - memory_pressure_enabled flag: compute memory_pressure? | 184 | - memory_pressure_enabled flag: compute memory_pressure? |
@@ -252,7 +256,7 @@ is causing. | |||
252 | 256 | ||
253 | This is useful both on tightly managed systems running a wide mix of | 257 | This is useful both on tightly managed systems running a wide mix of |
254 | submitted jobs, which may choose to terminate or re-prioritize jobs that | 258 | submitted jobs, which may choose to terminate or re-prioritize jobs that |
255 | are trying to use more memory than allowed on the nodes assigned them, | 259 | are trying to use more memory than allowed on the nodes assigned to them, |
256 | and with tightly coupled, long running, massively parallel scientific | 260 | and with tightly coupled, long running, massively parallel scientific |
257 | computing jobs that will dramatically fail to meet required performance | 261 | computing jobs that will dramatically fail to meet required performance |
258 | goals if they start to use more memory than allowed to them. | 262 | goals if they start to use more memory than allowed to them. |
@@ -378,7 +382,7 @@ as cpusets and sched_setaffinity. | |||
378 | The algorithmic cost of load balancing and its impact on key shared | 382 | The algorithmic cost of load balancing and its impact on key shared |
379 | kernel data structures such as the task list increases more than | 383 | kernel data structures such as the task list increases more than |
380 | linearly with the number of CPUs being balanced. So the scheduler | 384 | linearly with the number of CPUs being balanced. So the scheduler |
381 | has support to partition the systems CPUs into a number of sched | 385 | has support to partition the systems CPUs into a number of sched |
382 | domains such that it only load balances within each sched domain. | 386 | domains such that it only load balances within each sched domain. |
383 | Each sched domain covers some subset of the CPUs in the system; | 387 | Each sched domain covers some subset of the CPUs in the system; |
384 | no two sched domains overlap; some CPUs might not be in any sched | 388 | no two sched domains overlap; some CPUs might not be in any sched |
@@ -485,17 +489,22 @@ of CPUs allowed to a cpuset having 'sched_load_balance' enabled. | |||
485 | The internal kernel cpuset to scheduler interface passes from the | 489 | The internal kernel cpuset to scheduler interface passes from the |
486 | cpuset code to the scheduler code a partition of the load balanced | 490 | cpuset code to the scheduler code a partition of the load balanced |
487 | CPUs in the system. This partition is a set of subsets (represented | 491 | CPUs in the system. This partition is a set of subsets (represented |
488 | as an array of cpumask_t) of CPUs, pairwise disjoint, that cover all | 492 | as an array of struct cpumask) of CPUs, pairwise disjoint, that cover |
489 | the CPUs that must be load balanced. | 493 | all the CPUs that must be load balanced. |
490 | 494 | ||
491 | Whenever the 'sched_load_balance' flag changes, or CPUs come or go | 495 | The cpuset code builds a new such partition and passes it to the |
492 | from a cpuset with this flag enabled, or a cpuset with this flag | 496 | scheduler sched domain setup code, to have the sched domains rebuilt |
493 | enabled is removed, the cpuset code builds a new such partition and | 497 | as necessary, whenever: |
494 | passes it to the scheduler sched domain setup code, to have the sched | 498 | - the 'sched_load_balance' flag of a cpuset with non-empty CPUs changes, |
495 | domains rebuilt as necessary. | 499 | - or CPUs come or go from a cpuset with this flag enabled, |
500 | - or 'sched_relax_domain_level' value of a cpuset with non-empty CPUs | ||
501 | and with this flag enabled changes, | ||
502 | - or a cpuset with non-empty CPUs and with this flag enabled is removed, | ||
503 | - or a cpu is offlined/onlined. | ||
496 | 504 | ||
497 | This partition exactly defines what sched domains the scheduler should | 505 | This partition exactly defines what sched domains the scheduler should |
498 | setup - one sched domain for each element (cpumask_t) in the partition. | 506 | setup - one sched domain for each element (struct cpumask) in the |
507 | partition. | ||
499 | 508 | ||
500 | The scheduler remembers the currently active sched domain partitions. | 509 | The scheduler remembers the currently active sched domain partitions. |
501 | When the scheduler routine partition_sched_domains() is invoked from | 510 | When the scheduler routine partition_sched_domains() is invoked from |
@@ -559,7 +568,7 @@ domain, the largest value among those is used. Be careful, if one | |||
559 | requests 0 and others are -1 then 0 is used. | 568 | requests 0 and others are -1 then 0 is used. |
560 | 569 | ||
561 | Note that modifying this file will have both good and bad effects, | 570 | Note that modifying this file will have both good and bad effects, |
562 | and whether it is acceptable or not will be depend on your situation. | 571 | and whether it is acceptable or not depends on your situation. |
563 | Don't modify this file if you are not sure. | 572 | Don't modify this file if you are not sure. |
564 | 573 | ||
565 | If your situation is: | 574 | If your situation is: |
@@ -600,19 +609,15 @@ to allocate a page of memory for that task. | |||
600 | 609 | ||
601 | If a cpuset has its 'cpus' modified, then each task in that cpuset | 610 | If a cpuset has its 'cpus' modified, then each task in that cpuset |
602 | will have its allowed CPU placement changed immediately. Similarly, | 611 | will have its allowed CPU placement changed immediately. Similarly, |
603 | if a tasks pid is written to a cpusets 'tasks' file, in either its | 612 | if a tasks pid is written to another cpusets 'tasks' file, then its |
604 | current cpuset or another cpuset, then its allowed CPU placement is | 613 | allowed CPU placement is changed immediately. If such a task had been |
605 | changed immediately. If such a task had been bound to some subset | 614 | bound to some subset of its cpuset using the sched_setaffinity() call, |
606 | of its cpuset using the sched_setaffinity() call, the task will be | 615 | the task will be allowed to run on any CPU allowed in its new cpuset, |
607 | allowed to run on any CPU allowed in its new cpuset, negating the | 616 | negating the effect of the prior sched_setaffinity() call. |
608 | affect of the prior sched_setaffinity() call. | ||
609 | 617 | ||
610 | In summary, the memory placement of a task whose cpuset is changed is | 618 | In summary, the memory placement of a task whose cpuset is changed is |
611 | updated by the kernel, on the next allocation of a page for that task, | 619 | updated by the kernel, on the next allocation of a page for that task, |
612 | but the processor placement is not updated, until that tasks pid is | 620 | and the processor placement is updated immediately. |
613 | rewritten to the 'tasks' file of its cpuset. This is done to avoid | ||
614 | impacting the scheduler code in the kernel with a check for changes | ||
615 | in a tasks processor placement. | ||
616 | 621 | ||
617 | Normally, once a page is allocated (given a physical page | 622 | Normally, once a page is allocated (given a physical page |
618 | of main memory) then that page stays on whatever node it | 623 | of main memory) then that page stays on whatever node it |
@@ -681,10 +686,14 @@ and then start a subshell 'sh' in that cpuset: | |||
681 | # The next line should display '/Charlie' | 686 | # The next line should display '/Charlie' |
682 | cat /proc/self/cpuset | 687 | cat /proc/self/cpuset |
683 | 688 | ||
684 | In the future, a C library interface to cpusets will likely be | 689 | There are ways to query or modify cpusets: |
685 | available. For now, the only way to query or modify cpusets is | 690 | - via the cpuset file system directly, using the various cd, mkdir, echo, |
686 | via the cpuset file system, using the various cd, mkdir, echo, cat, | 691 | cat, rmdir commands from the shell, or their equivalent from C. |
687 | rmdir commands from the shell, or their equivalent from C. | 692 | - via the C library libcpuset. |
693 | - via the C library libcgroup. | ||
694 | (http://sourceforge.net/proects/libcg/) | ||
695 | - via the python application cset. | ||
696 | (http://developer.novell.com/wiki/index.php/Cpuset) | ||
688 | 697 | ||
689 | The sched_setaffinity calls can also be done at the shell prompt using | 698 | The sched_setaffinity calls can also be done at the shell prompt using |
690 | SGI's runon or Robert Love's taskset. The mbind and set_mempolicy | 699 | SGI's runon or Robert Love's taskset. The mbind and set_mempolicy |
@@ -756,7 +765,7 @@ mount -t cpuset X /dev/cpuset | |||
756 | 765 | ||
757 | is equivalent to | 766 | is equivalent to |
758 | 767 | ||
759 | mount -t cgroup -ocpuset X /dev/cpuset | 768 | mount -t cgroup -ocpuset,noprefix X /dev/cpuset |
760 | echo "/sbin/cpuset_release_agent" > /dev/cpuset/release_agent | 769 | echo "/sbin/cpuset_release_agent" > /dev/cpuset/release_agent |
761 | 770 | ||
762 | 2.2 Adding/removing cpus | 771 | 2.2 Adding/removing cpus |
diff --git a/Documentation/controllers/devices.txt b/Documentation/cgroups/devices.txt index 7cc6e6a60672..7cc6e6a60672 100644 --- a/Documentation/controllers/devices.txt +++ b/Documentation/cgroups/devices.txt | |||
diff --git a/Documentation/controllers/memcg_test.txt b/Documentation/cgroups/memcg_test.txt index 08d4d3ea0d79..523a9c16c400 100644 --- a/Documentation/controllers/memcg_test.txt +++ b/Documentation/cgroups/memcg_test.txt | |||
@@ -1,12 +1,12 @@ | |||
1 | Memory Resource Controller(Memcg) Implementation Memo. | 1 | Memory Resource Controller(Memcg) Implementation Memo. |
2 | Last Updated: 2008/12/15 | 2 | Last Updated: 2009/1/19 |
3 | Base Kernel Version: based on 2.6.28-rc8-mm. | 3 | Base Kernel Version: based on 2.6.29-rc2. |
4 | 4 | ||
5 | Because VM is getting complex (one of reasons is memcg...), memcg's behavior | 5 | Because VM is getting complex (one of reasons is memcg...), memcg's behavior |
6 | is complex. This is a document for memcg's internal behavior. | 6 | is complex. This is a document for memcg's internal behavior. |
7 | Please note that implementation details can be changed. | 7 | Please note that implementation details can be changed. |
8 | 8 | ||
9 | (*) Topics on API should be in Documentation/controllers/memory.txt) | 9 | (*) Topics on API should be in Documentation/cgroups/memory.txt) |
10 | 10 | ||
11 | 0. How to record usage ? | 11 | 0. How to record usage ? |
12 | 2 objects are used. | 12 | 2 objects are used. |
@@ -340,3 +340,23 @@ Under below explanation, we assume CONFIG_MEM_RES_CTRL_SWAP=y. | |||
340 | # mount -t cgroup none /cgroup -t cpuset,memory,cpu,devices | 340 | # mount -t cgroup none /cgroup -t cpuset,memory,cpu,devices |
341 | 341 | ||
342 | and do task move, mkdir, rmdir etc...under this. | 342 | and do task move, mkdir, rmdir etc...under this. |
343 | |||
344 | 9.7 swapoff. | ||
345 | Besides management of swap is one of complicated parts of memcg, | ||
346 | call path of swap-in at swapoff is not same as usual swap-in path.. | ||
347 | It's worth to be tested explicitly. | ||
348 | |||
349 | For example, test like following is good. | ||
350 | (Shell-A) | ||
351 | # mount -t cgroup none /cgroup -t memory | ||
352 | # mkdir /cgroup/test | ||
353 | # echo 40M > /cgroup/test/memory.limit_in_bytes | ||
354 | # echo 0 > /cgroup/test/tasks | ||
355 | Run malloc(100M) program under this. You'll see 60M of swaps. | ||
356 | (Shell-B) | ||
357 | # move all tasks in /cgroup/test to /cgroup | ||
358 | # /sbin/swapoff -a | ||
359 | # rmdir /test/cgroup | ||
360 | # kill malloc task. | ||
361 | |||
362 | Of course, tmpfs v.s. swapoff test should be tested, too. | ||
diff --git a/Documentation/controllers/memory.txt b/Documentation/cgroups/memory.txt index e1501964df1e..e1501964df1e 100644 --- a/Documentation/controllers/memory.txt +++ b/Documentation/cgroups/memory.txt | |||
diff --git a/Documentation/controllers/resource_counter.txt b/Documentation/cgroups/resource_counter.txt index f196ac1d7d25..f196ac1d7d25 100644 --- a/Documentation/controllers/resource_counter.txt +++ b/Documentation/cgroups/resource_counter.txt | |||
diff --git a/Documentation/connector/cn_test.c b/Documentation/connector/cn_test.c index be7af146dd30..6977c178729a 100644 --- a/Documentation/connector/cn_test.c +++ b/Documentation/connector/cn_test.c | |||
@@ -137,7 +137,7 @@ static void cn_test_timer_func(unsigned long __data) | |||
137 | 137 | ||
138 | memcpy(m + 1, data, m->len); | 138 | memcpy(m + 1, data, m->len); |
139 | 139 | ||
140 | cn_netlink_send(m, 0, gfp_any()); | 140 | cn_netlink_send(m, 0, GFP_ATOMIC); |
141 | kfree(m); | 141 | kfree(m); |
142 | } | 142 | } |
143 | 143 | ||
@@ -160,10 +160,8 @@ static int cn_test_init(void) | |||
160 | goto err_out; | 160 | goto err_out; |
161 | } | 161 | } |
162 | 162 | ||
163 | init_timer(&cn_test_timer); | 163 | setup_timer(&cn_test_timer, cn_test_timer_func, 0); |
164 | cn_test_timer.function = cn_test_timer_func; | ||
165 | cn_test_timer.expires = jiffies + HZ; | 164 | cn_test_timer.expires = jiffies + HZ; |
166 | cn_test_timer.data = 0; | ||
167 | add_timer(&cn_test_timer); | 165 | add_timer(&cn_test_timer); |
168 | 166 | ||
169 | return 0; | 167 | return 0; |
diff --git a/Documentation/cpu-freq/user-guide.txt b/Documentation/cpu-freq/user-guide.txt index e3443ddcfb89..917918f84fc7 100644 --- a/Documentation/cpu-freq/user-guide.txt +++ b/Documentation/cpu-freq/user-guide.txt | |||
@@ -195,19 +195,3 @@ scaling_setspeed. By "echoing" a new frequency into this | |||
195 | you can change the speed of the CPU, | 195 | you can change the speed of the CPU, |
196 | but only within the limits of | 196 | but only within the limits of |
197 | scaling_min_freq and scaling_max_freq. | 197 | scaling_min_freq and scaling_max_freq. |
198 | |||
199 | |||
200 | 3.2 Deprecated Interfaces | ||
201 | ------------------------- | ||
202 | |||
203 | Depending on your kernel configuration, you might find the following | ||
204 | cpufreq-related files: | ||
205 | /proc/cpufreq | ||
206 | /proc/sys/cpu/*/speed | ||
207 | /proc/sys/cpu/*/speed-min | ||
208 | /proc/sys/cpu/*/speed-max | ||
209 | |||
210 | These are files for deprecated interfaces to cpufreq, which offer far | ||
211 | less functionality. Because of this, these interfaces aren't described | ||
212 | here. | ||
213 | |||
diff --git a/Documentation/driver-model/device.txt b/Documentation/driver-model/device.txt index a05ec50f8004..a7cbfff40d07 100644 --- a/Documentation/driver-model/device.txt +++ b/Documentation/driver-model/device.txt | |||
@@ -127,9 +127,11 @@ void unlock_device(struct device * dev); | |||
127 | Attributes | 127 | Attributes |
128 | ~~~~~~~~~~ | 128 | ~~~~~~~~~~ |
129 | struct device_attribute { | 129 | struct device_attribute { |
130 | struct attribute attr; | 130 | struct attribute attr; |
131 | ssize_t (*show)(struct device * dev, char * buf, size_t count, loff_t off); | 131 | ssize_t (*show)(struct device *dev, struct device_attribute *attr, |
132 | ssize_t (*store)(struct device * dev, const char * buf, size_t count, loff_t off); | 132 | char *buf); |
133 | ssize_t (*store)(struct device *dev, struct device_attribute *attr, | ||
134 | const char *buf, size_t count); | ||
133 | }; | 135 | }; |
134 | 136 | ||
135 | Attributes of devices can be exported via drivers using a simple | 137 | Attributes of devices can be exported via drivers using a simple |
diff --git a/Documentation/dvb/README.flexcop b/Documentation/dvb/README.flexcop deleted file mode 100644 index 5515469de7cf..000000000000 --- a/Documentation/dvb/README.flexcop +++ /dev/null | |||
@@ -1,205 +0,0 @@ | |||
1 | This README escorted the skystar2-driver rewriting procedure. It describes the | ||
2 | state of the new flexcop-driver set and some internals are written down here | ||
3 | too. | ||
4 | |||
5 | This document hopefully describes things about the flexcop and its | ||
6 | device-offsprings. Goal was to write an easy-to-write and easy-to-read set of | ||
7 | drivers based on the skystar2.c and other information. | ||
8 | |||
9 | Remark: flexcop-pci.c was a copy of skystar2.c, but every line has been | ||
10 | touched and rewritten. | ||
11 | |||
12 | History & News | ||
13 | ============== | ||
14 | 2005-04-01 - correct USB ISOC transfers (thanks to Vadim Catana) | ||
15 | |||
16 | |||
17 | |||
18 | |||
19 | General coding processing | ||
20 | ========================= | ||
21 | |||
22 | We should proceed as follows (as long as no one complains): | ||
23 | |||
24 | 0) Think before start writing code! | ||
25 | |||
26 | 1) rewriting the skystar2.c with the help of the flexcop register descriptions | ||
27 | and splitting up the files to a pci-bus-part and a flexcop-part. | ||
28 | The new driver will be called b2c2-flexcop-pci.ko/b2c2-flexcop-usb.ko for the | ||
29 | device-specific part and b2c2-flexcop.ko for the common flexcop-functions. | ||
30 | |||
31 | 2) Search for errors in the leftover of flexcop-pci.c (compare with pluto2.c | ||
32 | and other pci drivers) | ||
33 | |||
34 | 3) make some beautification (see 'Improvements when rewriting (refactoring) is | ||
35 | done') | ||
36 | |||
37 | 4) Testing the new driver and maybe substitute the skystar2.c with it, to reach | ||
38 | a wider tester audience. | ||
39 | |||
40 | 5) creating an usb-bus-part using the already written flexcop code for the pci | ||
41 | card. | ||
42 | |||
43 | Idea: create a kernel-object for the flexcop and export all important | ||
44 | functions. This option saves kernel-memory, but maybe a lot of functions have | ||
45 | to be exported to kernel namespace. | ||
46 | |||
47 | |||
48 | Current situation | ||
49 | ================= | ||
50 | |||
51 | 0) Done :) | ||
52 | 1) Done (some minor issues left) | ||
53 | 2) Done | ||
54 | 3) Not ready yet, more information is necessary | ||
55 | 4) next to be done (see the table below) | ||
56 | 5) USB driver is working (yes, there are some minor issues) | ||
57 | |||
58 | What seems to be ready? | ||
59 | ----------------------- | ||
60 | |||
61 | 1) Rewriting | ||
62 | 1a) i2c is cut off from the flexcop-pci.c and seems to work | ||
63 | 1b) moved tuner and demod stuff from flexcop-pci.c to flexcop-tuner-fe.c | ||
64 | 1c) moved lnb and diseqc stuff from flexcop-pci.c to flexcop-tuner-fe.c | ||
65 | 1e) eeprom (reading MAC address) | ||
66 | 1d) sram (no dynamic sll size detection (commented out) (using default as JJ told me)) | ||
67 | 1f) misc. register accesses for reading parameters (e.g. resetting, revision) | ||
68 | 1g) pid/mac filter (flexcop-hw-filter.c) | ||
69 | 1i) dvb-stuff initialization in flexcop.c (done) | ||
70 | 1h) dma stuff (now just using the size-irq, instead of all-together, to be done) | ||
71 | 1j) remove flexcop initialization from flexcop-pci.c completely (done) | ||
72 | 1l) use a well working dma IRQ method (done, see 'Known bugs and problems and TODO') | ||
73 | 1k) cleanup flexcop-files (remove unused EXPORT_SYMBOLs, make static from | ||
74 | non-static where possible, moved code to proper places) | ||
75 | |||
76 | 2) Search for errors in the leftover of flexcop-pci.c (partially done) | ||
77 | 5a) add MAC address reading | ||
78 | 5c) feeding of ISOC data to the software demux (format of the isochronous data | ||
79 | and speed optimization, no real error) (thanks to Vadim Catana) | ||
80 | |||
81 | What to do in the near future? | ||
82 | -------------------------------------- | ||
83 | (no special order here) | ||
84 | |||
85 | 5) USB driver | ||
86 | 5b) optimize isoc-transfer (submitting/killing isoc URBs when transfer is starting) | ||
87 | |||
88 | Testing changes | ||
89 | --------------- | ||
90 | |||
91 | O = item is working | ||
92 | P = item is partially working | ||
93 | X = item is not working | ||
94 | N = item does not apply here | ||
95 | <empty field> = item need to be examined | ||
96 | |||
97 | | PCI | USB | ||
98 | item | mt352 | nxt2002 | stv0299 | mt312 | mt352 | nxt2002 | stv0299 | mt312 | ||
99 | -------+-------+---------+---------+-------+-------+---------+---------+------- | ||
100 | 1a) | O | | | | N | N | N | N | ||
101 | 1b) | O | | | | | | O | | ||
102 | 1c) | N | N | | | N | N | O | | ||
103 | 1d) | O | O | ||
104 | 1e) | O | O | ||
105 | 1f) | P | ||
106 | 1g) | O | ||
107 | 1h) | P | | ||
108 | 1i) | O | N | ||
109 | 1j) | O | N | ||
110 | 1l) | O | N | ||
111 | 2) | O | N | ||
112 | 5a) | N | O | ||
113 | 5b)* | N | | ||
114 | 5c) | N | O | ||
115 | |||
116 | * - not done yet | ||
117 | |||
118 | Known bugs and problems and TODO | ||
119 | -------------------------------- | ||
120 | |||
121 | 1g/h/l) when pid filtering is enabled on the pci card | ||
122 | |||
123 | DMA usage currently: | ||
124 | The DMA is splitted in 2 equal-sized subbuffers. The Flexcop writes to first | ||
125 | address and triggers an IRQ when it's full and starts writing to the second | ||
126 | address. When the second address is full, the IRQ is triggered again, and | ||
127 | the flexcop writes to first address again, and so on. | ||
128 | The buffersize of each address is currently 640*188 bytes. | ||
129 | |||
130 | Problem is, when using hw-pid-filtering and doing some low-bandwidth | ||
131 | operation (like scanning) the buffers won't be filled enough to trigger | ||
132 | the IRQ. That's why: | ||
133 | |||
134 | When PID filtering is activated, the timer IRQ is used. Every 1.97 ms the IRQ | ||
135 | is triggered. Is the current write address of DMA1 different to the one | ||
136 | during the last IRQ, then the data is passed to the demuxer. | ||
137 | |||
138 | There is an additional DMA-IRQ-method: packet count IRQ. This isn't | ||
139 | implemented correctly yet. | ||
140 | |||
141 | The solution is to disable HW PID filtering, but I don't know how the DVB | ||
142 | API software demux behaves on slow systems with 45MBit/s TS. | ||
143 | |||
144 | Solved bugs :) | ||
145 | -------------- | ||
146 | 1g) pid-filtering (somehow pid index 4 and 5 (EMM_PID and ECM_PID) aren't | ||
147 | working) | ||
148 | SOLUTION: also index 0 was affected, because net_translation is done for | ||
149 | these indexes by default | ||
150 | |||
151 | 5b) isochronous transfer does only work in the first attempt (for the Sky2PC | ||
152 | USB, Air2PC is working) SOLUTION: the flexcop was going asleep and never really | ||
153 | woke up again (don't know if this need fixes, see | ||
154 | flexcop-fe-tuner.c:flexcop_sleep) | ||
155 | |||
156 | NEWS: when the driver is loaded and unloaded and loaded again (w/o doing | ||
157 | anything in the while the driver is loaded the first time), no transfers take | ||
158 | place anymore. | ||
159 | |||
160 | Improvements when rewriting (refactoring) is done | ||
161 | ================================================= | ||
162 | |||
163 | - split sleeping of the flexcop (misc_204.ACPI3_sig = 1;) from lnb_control | ||
164 | (enable sleeping for other demods than dvb-s) | ||
165 | - add support for CableStar (stv0297 Microtune 203x/ALPS) (almost done, incompatibilities with the Nexus-CA) | ||
166 | |||
167 | Debugging | ||
168 | --------- | ||
169 | - add verbose debugging to skystar2.c (dump the reg_dw_data) and compare it | ||
170 | with this flexcop, this is important, because i2c is now using the | ||
171 | flexcop_ibi_value union from flexcop-reg.h (do you have a better idea for | ||
172 | that, please tell us so). | ||
173 | |||
174 | Everything which is identical in the following table, can be put into a common | ||
175 | flexcop-module. | ||
176 | |||
177 | PCI USB | ||
178 | ------------------------------------------------------------------------------- | ||
179 | Different: | ||
180 | Register access: accessing IO memory USB control message | ||
181 | I2C bus: I2C bus of the FC USB control message | ||
182 | Data transfer: DMA isochronous transfer | ||
183 | EEPROM transfer: through i2c bus not clear yet | ||
184 | |||
185 | Identical: | ||
186 | Streaming: accessing registers | ||
187 | PID Filtering: accessing registers | ||
188 | Sram destinations: accessing registers | ||
189 | Tuner/Demod: I2C bus | ||
190 | DVB-stuff: can be written for common use | ||
191 | |||
192 | Acknowledgements (just for the rewriting part) | ||
193 | ================ | ||
194 | |||
195 | Bjarne Steinsbo thought a lot in the first place of the pci part for this code | ||
196 | sharing idea. | ||
197 | |||
198 | Andreas Oberritter for providing a recent PCI initialization template | ||
199 | (pluto2.c). | ||
200 | |||
201 | Boleslaw Ciesielski for pointing out a problem with firmware loader. | ||
202 | |||
203 | Vadim Catana for correcting the USB transfer. | ||
204 | |||
205 | comments, critics and ideas to linux-dvb@linuxtv.org. | ||
diff --git a/Documentation/dvb/technisat.txt b/Documentation/dvb/technisat.txt index cdf6ee4b2da1..3f435ffb289c 100644 --- a/Documentation/dvb/technisat.txt +++ b/Documentation/dvb/technisat.txt | |||
@@ -1,5 +1,5 @@ | |||
1 | How to set up the Technisat devices | 1 | How to set up the Technisat/B2C2 Flexcop devices |
2 | =================================== | 2 | ================================================ |
3 | 3 | ||
4 | 1) Find out what device you have | 4 | 1) Find out what device you have |
5 | ================================ | 5 | ================================ |
@@ -16,54 +16,60 @@ DVB: registering frontend 0 (Conexant CX24123/CX24109)... | |||
16 | 16 | ||
17 | If the Technisat is the only TV device in your box get rid of unnecessary modules and check this one: | 17 | If the Technisat is the only TV device in your box get rid of unnecessary modules and check this one: |
18 | "Multimedia devices" => "Customise analog and hybrid tuner modules to build" | 18 | "Multimedia devices" => "Customise analog and hybrid tuner modules to build" |
19 | In this directory uncheck every driver which is activated there. | 19 | In this directory uncheck every driver which is activated there (except "Simple tuner support" for case 9 only). |
20 | 20 | ||
21 | Then please activate: | 21 | Then please activate: |
22 | 2a) Main module part: | 22 | 2a) Main module part: |
23 | 23 | ||
24 | a.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" | 24 | a.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" |
25 | b.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" => "Technisat/B2C2 Air/Sky/Cable2PC PCI" in case of a PCI card OR | 25 | b.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" => "Technisat/B2C2 Air/Sky/Cable2PC PCI" in case of a PCI card |
26 | OR | ||
26 | c.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" => "Technisat/B2C2 Air/Sky/Cable2PC USB" in case of an USB 1.1 adapter | 27 | c.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" => "Technisat/B2C2 Air/Sky/Cable2PC USB" in case of an USB 1.1 adapter |
27 | d.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" => "Enable debug for the B2C2 FlexCop drivers" | 28 | d.)"Multimedia devices" => "DVB/ATSC adapters" => "Technisat/B2C2 FlexcopII(b) and FlexCopIII adapters" => "Enable debug for the B2C2 FlexCop drivers" |
28 | Notice: d.) is helpful for troubleshooting | 29 | Notice: d.) is helpful for troubleshooting |
29 | 30 | ||
30 | 2b) Frontend module part: | 31 | 2b) Frontend module part: |
31 | 32 | ||
32 | 1.) Revision 2.3: | 33 | 1.) SkyStar DVB-S Revision 2.3: |
33 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 34 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
34 | b.)"Multimedia devices" => "Customise DVB frontends" => "Zarlink VP310/MT312/ZL10313 based" | 35 | b.)"Multimedia devices" => "Customise DVB frontends" => "Zarlink VP310/MT312/ZL10313 based" |
35 | 36 | ||
36 | 2.) Revision 2.6: | 37 | 2.) SkyStar DVB-S Revision 2.6: |
37 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 38 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
38 | b.)"Multimedia devices" => "Customise DVB frontends" => "ST STV0299 based" | 39 | b.)"Multimedia devices" => "Customise DVB frontends" => "ST STV0299 based" |
39 | 40 | ||
40 | 3.) Revision 2.7: | 41 | 3.) SkyStar DVB-S Revision 2.7: |
41 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 42 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
42 | b.)"Multimedia devices" => "Customise DVB frontends" => "Samsung S5H1420 based" | 43 | b.)"Multimedia devices" => "Customise DVB frontends" => "Samsung S5H1420 based" |
43 | c.)"Multimedia devices" => "Customise DVB frontends" => "Integrant ITD1000 Zero IF tuner for DVB-S/DSS" | 44 | c.)"Multimedia devices" => "Customise DVB frontends" => "Integrant ITD1000 Zero IF tuner for DVB-S/DSS" |
44 | d.)"Multimedia devices" => "Customise DVB frontends" => "ISL6421 SEC controller" | 45 | d.)"Multimedia devices" => "Customise DVB frontends" => "ISL6421 SEC controller" |
45 | 46 | ||
46 | 4.) Revision 2.8: | 47 | 4.) SkyStar DVB-S Revision 2.8: |
47 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 48 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
48 | b.)"Multimedia devices" => "Customise DVB frontends" => "Conexant CX24113/CX24128 tuner for DVB-S/DSS" | 49 | b.)"Multimedia devices" => "Customise DVB frontends" => "Conexant CX24113/CX24128 tuner for DVB-S/DSS" |
49 | c.)"Multimedia devices" => "Customise DVB frontends" => "Conexant CX24123 based" | 50 | c.)"Multimedia devices" => "Customise DVB frontends" => "Conexant CX24123 based" |
50 | d.)"Multimedia devices" => "Customise DVB frontends" => "ISL6421 SEC controller" | 51 | d.)"Multimedia devices" => "Customise DVB frontends" => "ISL6421 SEC controller" |
51 | 52 | ||
52 | 5.) DVB-T card: | 53 | 5.) AirStar DVB-T card: |
53 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 54 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
54 | b.)"Multimedia devices" => "Customise DVB frontends" => "Zarlink MT352 based" | 55 | b.)"Multimedia devices" => "Customise DVB frontends" => "Zarlink MT352 based" |
55 | 56 | ||
56 | 6.) DVB-C card: | 57 | 6.) CableStar DVB-C card: |
57 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 58 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
58 | b.)"Multimedia devices" => "Customise DVB frontends" => "ST STV0297 based" | 59 | b.)"Multimedia devices" => "Customise DVB frontends" => "ST STV0297 based" |
59 | 60 | ||
60 | 7.) ATSC card 1st generation: | 61 | 7.) AirStar ATSC card 1st generation: |
61 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 62 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
62 | b.)"Multimedia devices" => "Customise DVB frontends" => "Broadcom BCM3510" | 63 | b.)"Multimedia devices" => "Customise DVB frontends" => "Broadcom BCM3510" |
63 | 64 | ||
64 | 8.) ATSC card 2nd generation: | 65 | 8.) AirStar ATSC card 2nd generation: |
65 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | 66 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" |
66 | b.)"Multimedia devices" => "Customise DVB frontends" => "NxtWave Communications NXT2002/NXT2004 based" | 67 | b.)"Multimedia devices" => "Customise DVB frontends" => "NxtWave Communications NXT2002/NXT2004 based" |
67 | c.)"Multimedia devices" => "Customise DVB frontends" => "LG Electronics LGDT3302/LGDT3303 based" | 68 | c.)"Multimedia devices" => "Customise DVB frontends" => "Generic I2C PLL based tuners" |
68 | 69 | ||
69 | Author: Uwe Bugla <uwe.bugla@gmx.de> December 2008 | 70 | 9.) AirStar ATSC card 3rd generation: |
71 | a.)"Multimedia devices" => "Customise DVB frontends" => "Customise the frontend modules to build" | ||
72 | b.)"Multimedia devices" => "Customise DVB frontends" => "LG Electronics LGDT3302/LGDT3303 based" | ||
73 | c.)"Multimedia devices" => "Customise analog and hybrid tuner modules to build" => "Simple tuner support" | ||
74 | |||
75 | Author: Uwe Bugla <uwe.bugla@gmx.de> February 2009 | ||
diff --git a/Documentation/filesystems/nfs-rdma.txt b/Documentation/filesystems/nfs-rdma.txt index 44bd766f2e5d..85eaeaddd27c 100644 --- a/Documentation/filesystems/nfs-rdma.txt +++ b/Documentation/filesystems/nfs-rdma.txt | |||
@@ -251,7 +251,7 @@ NFS/RDMA Setup | |||
251 | 251 | ||
252 | Instruct the server to listen on the RDMA transport: | 252 | Instruct the server to listen on the RDMA transport: |
253 | 253 | ||
254 | $ echo rdma 2050 > /proc/fs/nfsd/portlist | 254 | $ echo rdma 20049 > /proc/fs/nfsd/portlist |
255 | 255 | ||
256 | - On the client system | 256 | - On the client system |
257 | 257 | ||
@@ -263,7 +263,7 @@ NFS/RDMA Setup | |||
263 | Regardless of how the client was built (module or built-in), use this | 263 | Regardless of how the client was built (module or built-in), use this |
264 | command to mount the NFS/RDMA server: | 264 | command to mount the NFS/RDMA server: |
265 | 265 | ||
266 | $ mount -o rdma,port=2050 <IPoIB-server-name-or-address>:/<export> /mnt | 266 | $ mount -o rdma,port=20049 <IPoIB-server-name-or-address>:/<export> /mnt |
267 | 267 | ||
268 | To verify that the mount is using RDMA, run "cat /proc/mounts" and check | 268 | To verify that the mount is using RDMA, run "cat /proc/mounts" and check |
269 | the "proto" field for the given mount. | 269 | the "proto" field for the given mount. |
diff --git a/Documentation/filesystems/proc.txt b/Documentation/filesystems/proc.txt index d105eb45282a..a87be42f8211 100644 --- a/Documentation/filesystems/proc.txt +++ b/Documentation/filesystems/proc.txt | |||
@@ -1371,292 +1371,8 @@ auto_msgmni default value is 1. | |||
1371 | 2.4 /proc/sys/vm - The virtual memory subsystem | 1371 | 2.4 /proc/sys/vm - The virtual memory subsystem |
1372 | ----------------------------------------------- | 1372 | ----------------------------------------------- |
1373 | 1373 | ||
1374 | The files in this directory can be used to tune the operation of the virtual | 1374 | Please see: Documentation/sysctls/vm.txt for a description of these |
1375 | memory (VM) subsystem of the Linux kernel. | 1375 | entries. |
1376 | |||
1377 | vfs_cache_pressure | ||
1378 | ------------------ | ||
1379 | |||
1380 | Controls the tendency of the kernel to reclaim the memory which is used for | ||
1381 | caching of directory and inode objects. | ||
1382 | |||
1383 | At the default value of vfs_cache_pressure=100 the kernel will attempt to | ||
1384 | reclaim dentries and inodes at a "fair" rate with respect to pagecache and | ||
1385 | swapcache reclaim. Decreasing vfs_cache_pressure causes the kernel to prefer | ||
1386 | to retain dentry and inode caches. Increasing vfs_cache_pressure beyond 100 | ||
1387 | causes the kernel to prefer to reclaim dentries and inodes. | ||
1388 | |||
1389 | dirty_background_bytes | ||
1390 | ---------------------- | ||
1391 | |||
1392 | Contains the amount of dirty memory at which the pdflush background writeback | ||
1393 | daemon will start writeback. | ||
1394 | |||
1395 | If dirty_background_bytes is written, dirty_background_ratio becomes a function | ||
1396 | of its value (dirty_background_bytes / the amount of dirtyable system memory). | ||
1397 | |||
1398 | dirty_background_ratio | ||
1399 | ---------------------- | ||
1400 | |||
1401 | Contains, as a percentage of the dirtyable system memory (free pages + mapped | ||
1402 | pages + file cache, not including locked pages and HugePages), the number of | ||
1403 | pages at which the pdflush background writeback daemon will start writing out | ||
1404 | dirty data. | ||
1405 | |||
1406 | If dirty_background_ratio is written, dirty_background_bytes becomes a function | ||
1407 | of its value (dirty_background_ratio * the amount of dirtyable system memory). | ||
1408 | |||
1409 | dirty_bytes | ||
1410 | ----------- | ||
1411 | |||
1412 | Contains the amount of dirty memory at which a process generating disk writes | ||
1413 | will itself start writeback. | ||
1414 | |||
1415 | If dirty_bytes is written, dirty_ratio becomes a function of its value | ||
1416 | (dirty_bytes / the amount of dirtyable system memory). | ||
1417 | |||
1418 | dirty_ratio | ||
1419 | ----------- | ||
1420 | |||
1421 | Contains, as a percentage of the dirtyable system memory (free pages + mapped | ||
1422 | pages + file cache, not including locked pages and HugePages), the number of | ||
1423 | pages at which a process which is generating disk writes will itself start | ||
1424 | writing out dirty data. | ||
1425 | |||
1426 | If dirty_ratio is written, dirty_bytes becomes a function of its value | ||
1427 | (dirty_ratio * the amount of dirtyable system memory). | ||
1428 | |||
1429 | dirty_writeback_centisecs | ||
1430 | ------------------------- | ||
1431 | |||
1432 | The pdflush writeback daemons will periodically wake up and write `old' data | ||
1433 | out to disk. This tunable expresses the interval between those wakeups, in | ||
1434 | 100'ths of a second. | ||
1435 | |||
1436 | Setting this to zero disables periodic writeback altogether. | ||
1437 | |||
1438 | dirty_expire_centisecs | ||
1439 | ---------------------- | ||
1440 | |||
1441 | This tunable is used to define when dirty data is old enough to be eligible | ||
1442 | for writeout by the pdflush daemons. It is expressed in 100'ths of a second. | ||
1443 | Data which has been dirty in-memory for longer than this interval will be | ||
1444 | written out next time a pdflush daemon wakes up. | ||
1445 | |||
1446 | highmem_is_dirtyable | ||
1447 | -------------------- | ||
1448 | |||
1449 | Only present if CONFIG_HIGHMEM is set. | ||
1450 | |||
1451 | This defaults to 0 (false), meaning that the ratios set above are calculated | ||
1452 | as a percentage of lowmem only. This protects against excessive scanning | ||
1453 | in page reclaim, swapping and general VM distress. | ||
1454 | |||
1455 | Setting this to 1 can be useful on 32 bit machines where you want to make | ||
1456 | random changes within an MMAPed file that is larger than your available | ||
1457 | lowmem without causing large quantities of random IO. Is is safe if the | ||
1458 | behavior of all programs running on the machine is known and memory will | ||
1459 | not be otherwise stressed. | ||
1460 | |||
1461 | legacy_va_layout | ||
1462 | ---------------- | ||
1463 | |||
1464 | If non-zero, this sysctl disables the new 32-bit mmap mmap layout - the kernel | ||
1465 | will use the legacy (2.4) layout for all processes. | ||
1466 | |||
1467 | lowmem_reserve_ratio | ||
1468 | --------------------- | ||
1469 | |||
1470 | For some specialised workloads on highmem machines it is dangerous for | ||
1471 | the kernel to allow process memory to be allocated from the "lowmem" | ||
1472 | zone. This is because that memory could then be pinned via the mlock() | ||
1473 | system call, or by unavailability of swapspace. | ||
1474 | |||
1475 | And on large highmem machines this lack of reclaimable lowmem memory | ||
1476 | can be fatal. | ||
1477 | |||
1478 | So the Linux page allocator has a mechanism which prevents allocations | ||
1479 | which _could_ use highmem from using too much lowmem. This means that | ||
1480 | a certain amount of lowmem is defended from the possibility of being | ||
1481 | captured into pinned user memory. | ||
1482 | |||
1483 | (The same argument applies to the old 16 megabyte ISA DMA region. This | ||
1484 | mechanism will also defend that region from allocations which could use | ||
1485 | highmem or lowmem). | ||
1486 | |||
1487 | The `lowmem_reserve_ratio' tunable determines how aggressive the kernel is | ||
1488 | in defending these lower zones. | ||
1489 | |||
1490 | If you have a machine which uses highmem or ISA DMA and your | ||
1491 | applications are using mlock(), or if you are running with no swap then | ||
1492 | you probably should change the lowmem_reserve_ratio setting. | ||
1493 | |||
1494 | The lowmem_reserve_ratio is an array. You can see them by reading this file. | ||
1495 | - | ||
1496 | % cat /proc/sys/vm/lowmem_reserve_ratio | ||
1497 | 256 256 32 | ||
1498 | - | ||
1499 | Note: # of this elements is one fewer than number of zones. Because the highest | ||
1500 | zone's value is not necessary for following calculation. | ||
1501 | |||
1502 | But, these values are not used directly. The kernel calculates # of protection | ||
1503 | pages for each zones from them. These are shown as array of protection pages | ||
1504 | in /proc/zoneinfo like followings. (This is an example of x86-64 box). | ||
1505 | Each zone has an array of protection pages like this. | ||
1506 | |||
1507 | - | ||
1508 | Node 0, zone DMA | ||
1509 | pages free 1355 | ||
1510 | min 3 | ||
1511 | low 3 | ||
1512 | high 4 | ||
1513 | : | ||
1514 | : | ||
1515 | numa_other 0 | ||
1516 | protection: (0, 2004, 2004, 2004) | ||
1517 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
1518 | pagesets | ||
1519 | cpu: 0 pcp: 0 | ||
1520 | : | ||
1521 | - | ||
1522 | These protections are added to score to judge whether this zone should be used | ||
1523 | for page allocation or should be reclaimed. | ||
1524 | |||
1525 | In this example, if normal pages (index=2) are required to this DMA zone and | ||
1526 | pages_high is used for watermark, the kernel judges this zone should not be | ||
1527 | used because pages_free(1355) is smaller than watermark + protection[2] | ||
1528 | (4 + 2004 = 2008). If this protection value is 0, this zone would be used for | ||
1529 | normal page requirement. If requirement is DMA zone(index=0), protection[0] | ||
1530 | (=0) is used. | ||
1531 | |||
1532 | zone[i]'s protection[j] is calculated by following expression. | ||
1533 | |||
1534 | (i < j): | ||
1535 | zone[i]->protection[j] | ||
1536 | = (total sums of present_pages from zone[i+1] to zone[j] on the node) | ||
1537 | / lowmem_reserve_ratio[i]; | ||
1538 | (i = j): | ||
1539 | (should not be protected. = 0; | ||
1540 | (i > j): | ||
1541 | (not necessary, but looks 0) | ||
1542 | |||
1543 | The default values of lowmem_reserve_ratio[i] are | ||
1544 | 256 (if zone[i] means DMA or DMA32 zone) | ||
1545 | 32 (others). | ||
1546 | As above expression, they are reciprocal number of ratio. | ||
1547 | 256 means 1/256. # of protection pages becomes about "0.39%" of total present | ||
1548 | pages of higher zones on the node. | ||
1549 | |||
1550 | If you would like to protect more pages, smaller values are effective. | ||
1551 | The minimum value is 1 (1/1 -> 100%). | ||
1552 | |||
1553 | page-cluster | ||
1554 | ------------ | ||
1555 | |||
1556 | page-cluster controls the number of pages which are written to swap in | ||
1557 | a single attempt. The swap I/O size. | ||
1558 | |||
1559 | It is a logarithmic value - setting it to zero means "1 page", setting | ||
1560 | it to 1 means "2 pages", setting it to 2 means "4 pages", etc. | ||
1561 | |||
1562 | The default value is three (eight pages at a time). There may be some | ||
1563 | small benefits in tuning this to a different value if your workload is | ||
1564 | swap-intensive. | ||
1565 | |||
1566 | overcommit_memory | ||
1567 | ----------------- | ||
1568 | |||
1569 | Controls overcommit of system memory, possibly allowing processes | ||
1570 | to allocate (but not use) more memory than is actually available. | ||
1571 | |||
1572 | |||
1573 | 0 - Heuristic overcommit handling. Obvious overcommits of | ||
1574 | address space are refused. Used for a typical system. It | ||
1575 | ensures a seriously wild allocation fails while allowing | ||
1576 | overcommit to reduce swap usage. root is allowed to | ||
1577 | allocate slightly more memory in this mode. This is the | ||
1578 | default. | ||
1579 | |||
1580 | 1 - Always overcommit. Appropriate for some scientific | ||
1581 | applications. | ||
1582 | |||
1583 | 2 - Don't overcommit. The total address space commit | ||
1584 | for the system is not permitted to exceed swap plus a | ||
1585 | configurable percentage (default is 50) of physical RAM. | ||
1586 | Depending on the percentage you use, in most situations | ||
1587 | this means a process will not be killed while attempting | ||
1588 | to use already-allocated memory but will receive errors | ||
1589 | on memory allocation as appropriate. | ||
1590 | |||
1591 | overcommit_ratio | ||
1592 | ---------------- | ||
1593 | |||
1594 | Percentage of physical memory size to include in overcommit calculations | ||
1595 | (see above.) | ||
1596 | |||
1597 | Memory allocation limit = swapspace + physmem * (overcommit_ratio / 100) | ||
1598 | |||
1599 | swapspace = total size of all swap areas | ||
1600 | physmem = size of physical memory in system | ||
1601 | |||
1602 | nr_hugepages and hugetlb_shm_group | ||
1603 | ---------------------------------- | ||
1604 | |||
1605 | nr_hugepages configures number of hugetlb page reserved for the system. | ||
1606 | |||
1607 | hugetlb_shm_group contains group id that is allowed to create SysV shared | ||
1608 | memory segment using hugetlb page. | ||
1609 | |||
1610 | hugepages_treat_as_movable | ||
1611 | -------------------------- | ||
1612 | |||
1613 | This parameter is only useful when kernelcore= is specified at boot time to | ||
1614 | create ZONE_MOVABLE for pages that may be reclaimed or migrated. Huge pages | ||
1615 | are not movable so are not normally allocated from ZONE_MOVABLE. A non-zero | ||
1616 | value written to hugepages_treat_as_movable allows huge pages to be allocated | ||
1617 | from ZONE_MOVABLE. | ||
1618 | |||
1619 | Once enabled, the ZONE_MOVABLE is treated as an area of memory the huge | ||
1620 | pages pool can easily grow or shrink within. Assuming that applications are | ||
1621 | not running that mlock() a lot of memory, it is likely the huge pages pool | ||
1622 | can grow to the size of ZONE_MOVABLE by repeatedly entering the desired value | ||
1623 | into nr_hugepages and triggering page reclaim. | ||
1624 | |||
1625 | laptop_mode | ||
1626 | ----------- | ||
1627 | |||
1628 | laptop_mode is a knob that controls "laptop mode". All the things that are | ||
1629 | controlled by this knob are discussed in Documentation/laptops/laptop-mode.txt. | ||
1630 | |||
1631 | block_dump | ||
1632 | ---------- | ||
1633 | |||
1634 | block_dump enables block I/O debugging when set to a nonzero value. More | ||
1635 | information on block I/O debugging is in Documentation/laptops/laptop-mode.txt. | ||
1636 | |||
1637 | swap_token_timeout | ||
1638 | ------------------ | ||
1639 | |||
1640 | This file contains valid hold time of swap out protection token. The Linux | ||
1641 | VM has token based thrashing control mechanism and uses the token to prevent | ||
1642 | unnecessary page faults in thrashing situation. The unit of the value is | ||
1643 | second. The value would be useful to tune thrashing behavior. | ||
1644 | |||
1645 | drop_caches | ||
1646 | ----------- | ||
1647 | |||
1648 | Writing to this will cause the kernel to drop clean caches, dentries and | ||
1649 | inodes from memory, causing that memory to become free. | ||
1650 | |||
1651 | To free pagecache: | ||
1652 | echo 1 > /proc/sys/vm/drop_caches | ||
1653 | To free dentries and inodes: | ||
1654 | echo 2 > /proc/sys/vm/drop_caches | ||
1655 | To free pagecache, dentries and inodes: | ||
1656 | echo 3 > /proc/sys/vm/drop_caches | ||
1657 | |||
1658 | As this is a non-destructive operation and dirty objects are not freeable, the | ||
1659 | user should run `sync' first. | ||
1660 | 1376 | ||
1661 | 1377 | ||
1662 | 2.5 /proc/sys/dev - Device specific parameters | 1378 | 2.5 /proc/sys/dev - Device specific parameters |
@@ -2311,6 +2027,34 @@ increase the likelihood of this process being killed by the oom-killer. Valid | |||
2311 | values are in the range -16 to +15, plus the special value -17, which disables | 2027 | values are in the range -16 to +15, plus the special value -17, which disables |
2312 | oom-killing altogether for this process. | 2028 | oom-killing altogether for this process. |
2313 | 2029 | ||
2030 | The process to be killed in an out-of-memory situation is selected among all others | ||
2031 | based on its badness score. This value equals the original memory size of the process | ||
2032 | and is then updated according to its CPU time (utime + stime) and the | ||
2033 | run time (uptime - start time). The longer it runs the smaller is the score. | ||
2034 | Badness score is divided by the square root of the CPU time and then by | ||
2035 | the double square root of the run time. | ||
2036 | |||
2037 | Swapped out tasks are killed first. Half of each child's memory size is added to | ||
2038 | the parent's score if they do not share the same memory. Thus forking servers | ||
2039 | are the prime candidates to be killed. Having only one 'hungry' child will make | ||
2040 | parent less preferable than the child. | ||
2041 | |||
2042 | /proc/<pid>/oom_score shows process' current badness score. | ||
2043 | |||
2044 | The following heuristics are then applied: | ||
2045 | * if the task was reniced, its score doubles | ||
2046 | * superuser or direct hardware access tasks (CAP_SYS_ADMIN, CAP_SYS_RESOURCE | ||
2047 | or CAP_SYS_RAWIO) have their score divided by 4 | ||
2048 | * if oom condition happened in one cpuset and checked task does not belong | ||
2049 | to it, its score is divided by 8 | ||
2050 | * the resulting score is multiplied by two to the power of oom_adj, i.e. | ||
2051 | points <<= oom_adj when it is positive and | ||
2052 | points >>= -(oom_adj) otherwise | ||
2053 | |||
2054 | The task with the highest badness score is then selected and its children | ||
2055 | are killed, process itself will be killed in an OOM situation when it does | ||
2056 | not have children or some of them disabled oom like described above. | ||
2057 | |||
2314 | 2.13 /proc/<pid>/oom_score - Display current oom-killer score | 2058 | 2.13 /proc/<pid>/oom_score - Display current oom-killer score |
2315 | ------------------------------------------------------------- | 2059 | ------------------------------------------------------------- |
2316 | 2060 | ||
diff --git a/Documentation/filesystems/sysfs-pci.txt b/Documentation/filesystems/sysfs-pci.txt index 68ef48839c04..9f8740ca3f3b 100644 --- a/Documentation/filesystems/sysfs-pci.txt +++ b/Documentation/filesystems/sysfs-pci.txt | |||
@@ -9,6 +9,7 @@ that support it. For example, a given bus might look like this: | |||
9 | | |-- class | 9 | | |-- class |
10 | | |-- config | 10 | | |-- config |
11 | | |-- device | 11 | | |-- device |
12 | | |-- enable | ||
12 | | |-- irq | 13 | | |-- irq |
13 | | |-- local_cpus | 14 | | |-- local_cpus |
14 | | |-- resource | 15 | | |-- resource |
@@ -32,6 +33,7 @@ files, each with their own function. | |||
32 | class PCI class (ascii, ro) | 33 | class PCI class (ascii, ro) |
33 | config PCI config space (binary, rw) | 34 | config PCI config space (binary, rw) |
34 | device PCI device (ascii, ro) | 35 | device PCI device (ascii, ro) |
36 | enable Whether the device is enabled (ascii, rw) | ||
35 | irq IRQ number (ascii, ro) | 37 | irq IRQ number (ascii, ro) |
36 | local_cpus nearby CPU mask (cpumask, ro) | 38 | local_cpus nearby CPU mask (cpumask, ro) |
37 | resource PCI resource host addresses (ascii, ro) | 39 | resource PCI resource host addresses (ascii, ro) |
@@ -57,10 +59,19 @@ used to do actual device programming from userspace. Note that some platforms | |||
57 | don't support mmapping of certain resources, so be sure to check the return | 59 | don't support mmapping of certain resources, so be sure to check the return |
58 | value from any attempted mmap. | 60 | value from any attempted mmap. |
59 | 61 | ||
62 | The 'enable' file provides a counter that indicates how many times the device | ||
63 | has been enabled. If the 'enable' file currently returns '4', and a '1' is | ||
64 | echoed into it, it will then return '5'. Echoing a '0' into it will decrease | ||
65 | the count. Even when it returns to 0, though, some of the initialisation | ||
66 | may not be reversed. | ||
67 | |||
60 | The 'rom' file is special in that it provides read-only access to the device's | 68 | The 'rom' file is special in that it provides read-only access to the device's |
61 | ROM file, if available. It's disabled by default, however, so applications | 69 | ROM file, if available. It's disabled by default, however, so applications |
62 | should write the string "1" to the file to enable it before attempting a read | 70 | should write the string "1" to the file to enable it before attempting a read |
63 | call, and disable it following the access by writing "0" to the file. | 71 | call, and disable it following the access by writing "0" to the file. Note |
72 | that the device must be enabled for a rom read to return data succesfully. | ||
73 | In the event a driver is not bound to the device, it can be enabled using the | ||
74 | 'enable' file, documented above. | ||
64 | 75 | ||
65 | Accessing legacy resources through sysfs | 76 | Accessing legacy resources through sysfs |
66 | ---------------------------------------- | 77 | ---------------------------------------- |
diff --git a/Documentation/filesystems/sysfs.txt b/Documentation/filesystems/sysfs.txt index 9e9c348275a9..7e81e37c0b1e 100644 --- a/Documentation/filesystems/sysfs.txt +++ b/Documentation/filesystems/sysfs.txt | |||
@@ -2,8 +2,10 @@ | |||
2 | sysfs - _The_ filesystem for exporting kernel objects. | 2 | sysfs - _The_ filesystem for exporting kernel objects. |
3 | 3 | ||
4 | Patrick Mochel <mochel@osdl.org> | 4 | Patrick Mochel <mochel@osdl.org> |
5 | Mike Murphy <mamurph@cs.clemson.edu> | ||
5 | 6 | ||
6 | 10 January 2003 | 7 | Revised: 22 February 2009 |
8 | Original: 10 January 2003 | ||
7 | 9 | ||
8 | 10 | ||
9 | What it is: | 11 | What it is: |
@@ -64,12 +66,13 @@ An attribute definition is simply: | |||
64 | 66 | ||
65 | struct attribute { | 67 | struct attribute { |
66 | char * name; | 68 | char * name; |
69 | struct module *owner; | ||
67 | mode_t mode; | 70 | mode_t mode; |
68 | }; | 71 | }; |
69 | 72 | ||
70 | 73 | ||
71 | int sysfs_create_file(struct kobject * kobj, struct attribute * attr); | 74 | int sysfs_create_file(struct kobject * kobj, const struct attribute * attr); |
72 | void sysfs_remove_file(struct kobject * kobj, struct attribute * attr); | 75 | void sysfs_remove_file(struct kobject * kobj, const struct attribute * attr); |
73 | 76 | ||
74 | 77 | ||
75 | A bare attribute contains no means to read or write the value of the | 78 | A bare attribute contains no means to read or write the value of the |
@@ -80,9 +83,11 @@ a specific object type. | |||
80 | For example, the driver model defines struct device_attribute like: | 83 | For example, the driver model defines struct device_attribute like: |
81 | 84 | ||
82 | struct device_attribute { | 85 | struct device_attribute { |
83 | struct attribute attr; | 86 | struct attribute attr; |
84 | ssize_t (*show)(struct device * dev, char * buf); | 87 | ssize_t (*show)(struct device *dev, struct device_attribute *attr, |
85 | ssize_t (*store)(struct device * dev, const char * buf); | 88 | char *buf); |
89 | ssize_t (*store)(struct device *dev, struct device_attribute *attr, | ||
90 | const char *buf, size_t count); | ||
86 | }; | 91 | }; |
87 | 92 | ||
88 | int device_create_file(struct device *, struct device_attribute *); | 93 | int device_create_file(struct device *, struct device_attribute *); |
@@ -90,12 +95,8 @@ void device_remove_file(struct device *, struct device_attribute *); | |||
90 | 95 | ||
91 | It also defines this helper for defining device attributes: | 96 | It also defines this helper for defining device attributes: |
92 | 97 | ||
93 | #define DEVICE_ATTR(_name, _mode, _show, _store) \ | 98 | #define DEVICE_ATTR(_name, _mode, _show, _store) \ |
94 | struct device_attribute dev_attr_##_name = { \ | 99 | struct device_attribute dev_attr_##_name = __ATTR(_name, _mode, _show, _store) |
95 | .attr = {.name = __stringify(_name) , .mode = _mode }, \ | ||
96 | .show = _show, \ | ||
97 | .store = _store, \ | ||
98 | }; | ||
99 | 100 | ||
100 | For example, declaring | 101 | For example, declaring |
101 | 102 | ||
@@ -107,9 +108,9 @@ static struct device_attribute dev_attr_foo = { | |||
107 | .attr = { | 108 | .attr = { |
108 | .name = "foo", | 109 | .name = "foo", |
109 | .mode = S_IWUSR | S_IRUGO, | 110 | .mode = S_IWUSR | S_IRUGO, |
111 | .show = show_foo, | ||
112 | .store = store_foo, | ||
110 | }, | 113 | }, |
111 | .show = show_foo, | ||
112 | .store = store_foo, | ||
113 | }; | 114 | }; |
114 | 115 | ||
115 | 116 | ||
@@ -161,10 +162,12 @@ To read or write attributes, show() or store() methods must be | |||
161 | specified when declaring the attribute. The method types should be as | 162 | specified when declaring the attribute. The method types should be as |
162 | simple as those defined for device attributes: | 163 | simple as those defined for device attributes: |
163 | 164 | ||
164 | ssize_t (*show)(struct device * dev, char * buf); | 165 | ssize_t (*show)(struct device * dev, struct device_attribute * attr, |
165 | ssize_t (*store)(struct device * dev, const char * buf); | 166 | char * buf); |
167 | ssize_t (*store)(struct device * dev, struct device_attribute * attr, | ||
168 | const char * buf); | ||
166 | 169 | ||
167 | IOW, they should take only an object and a buffer as parameters. | 170 | IOW, they should take only an object, an attribute, and a buffer as parameters. |
168 | 171 | ||
169 | 172 | ||
170 | sysfs allocates a buffer of size (PAGE_SIZE) and passes it to the | 173 | sysfs allocates a buffer of size (PAGE_SIZE) and passes it to the |
@@ -299,14 +302,16 @@ The following interface layers currently exist in sysfs: | |||
299 | Structure: | 302 | Structure: |
300 | 303 | ||
301 | struct device_attribute { | 304 | struct device_attribute { |
302 | struct attribute attr; | 305 | struct attribute attr; |
303 | ssize_t (*show)(struct device * dev, char * buf); | 306 | ssize_t (*show)(struct device *dev, struct device_attribute *attr, |
304 | ssize_t (*store)(struct device * dev, const char * buf); | 307 | char *buf); |
308 | ssize_t (*store)(struct device *dev, struct device_attribute *attr, | ||
309 | const char *buf, size_t count); | ||
305 | }; | 310 | }; |
306 | 311 | ||
307 | Declaring: | 312 | Declaring: |
308 | 313 | ||
309 | DEVICE_ATTR(_name, _str, _mode, _show, _store); | 314 | DEVICE_ATTR(_name, _mode, _show, _store); |
310 | 315 | ||
311 | Creation/Removal: | 316 | Creation/Removal: |
312 | 317 | ||
@@ -342,7 +347,8 @@ Structure: | |||
342 | struct driver_attribute { | 347 | struct driver_attribute { |
343 | struct attribute attr; | 348 | struct attribute attr; |
344 | ssize_t (*show)(struct device_driver *, char * buf); | 349 | ssize_t (*show)(struct device_driver *, char * buf); |
345 | ssize_t (*store)(struct device_driver *, const char * buf); | 350 | ssize_t (*store)(struct device_driver *, const char * buf, |
351 | size_t count); | ||
346 | }; | 352 | }; |
347 | 353 | ||
348 | Declaring: | 354 | Declaring: |
diff --git a/Documentation/filesystems/ubifs.txt b/Documentation/filesystems/ubifs.txt index 84da2a4ba25a..12fedb7834c6 100644 --- a/Documentation/filesystems/ubifs.txt +++ b/Documentation/filesystems/ubifs.txt | |||
@@ -79,13 +79,6 @@ Mount options | |||
79 | 79 | ||
80 | (*) == default. | 80 | (*) == default. |
81 | 81 | ||
82 | norm_unmount (*) commit on unmount; the journal is committed | ||
83 | when the file-system is unmounted so that the | ||
84 | next mount does not have to replay the journal | ||
85 | and it becomes very fast; | ||
86 | fast_unmount do not commit on unmount; this option makes | ||
87 | unmount faster, but the next mount slower | ||
88 | because of the need to replay the journal. | ||
89 | bulk_read read more in one go to take advantage of flash | 82 | bulk_read read more in one go to take advantage of flash |
90 | media that read faster sequentially | 83 | media that read faster sequentially |
91 | no_bulk_read (*) do not bulk-read | 84 | no_bulk_read (*) do not bulk-read |
diff --git a/Documentation/hwmon/adt7475 b/Documentation/hwmon/adt7475 new file mode 100644 index 000000000000..a2b1abec850e --- /dev/null +++ b/Documentation/hwmon/adt7475 | |||
@@ -0,0 +1,87 @@ | |||
1 | This describes the interface for the ADT7475 driver: | ||
2 | |||
3 | (there are 4 fans, numbered fan1 to fan4): | ||
4 | |||
5 | fanX_input Read the current speed of the fan (in RPMs) | ||
6 | fanX_min Read/write the minimum speed of the fan. Dropping | ||
7 | below this sets an alarm. | ||
8 | |||
9 | (there are three PWMs, numbered pwm1 to pwm3): | ||
10 | |||
11 | pwmX Read/write the current duty cycle of the PWM. Writes | ||
12 | only have effect when auto mode is turned off (see | ||
13 | below). Range is 0 - 255. | ||
14 | |||
15 | pwmX_enable Fan speed control method: | ||
16 | |||
17 | 0 - No control (fan at full speed) | ||
18 | 1 - Manual fan speed control (using pwm[1-*]) | ||
19 | 2 - Automatic fan speed control | ||
20 | |||
21 | pwmX_auto_channels_temp Select which channels affect this PWM | ||
22 | |||
23 | 1 - TEMP1 controls PWM | ||
24 | 2 - TEMP2 controls PWM | ||
25 | 4 - TEMP3 controls PWM | ||
26 | 6 - TEMP2 and TEMP3 control PWM | ||
27 | 7 - All three inputs control PWM | ||
28 | |||
29 | pwmX_freq Read/write the PWM frequency in Hz. The number | ||
30 | should be one of the following: | ||
31 | |||
32 | 11 Hz | ||
33 | 14 Hz | ||
34 | 22 Hz | ||
35 | 29 Hz | ||
36 | 35 Hz | ||
37 | 44 Hz | ||
38 | 58 Hz | ||
39 | 88 Hz | ||
40 | |||
41 | pwmX_auto_point1_pwm Read/write the minimum PWM duty cycle in automatic mode | ||
42 | |||
43 | pwmX_auto_point2_pwm Read/write the maximum PWM duty cycle in automatic mode | ||
44 | |||
45 | (there are three temperature settings numbered temp1 to temp3): | ||
46 | |||
47 | tempX_input Read the current temperature. The value is in milli | ||
48 | degrees of Celsius. | ||
49 | |||
50 | tempX_max Read/write the upper temperature limit - exceeding this | ||
51 | will cause an alarm. | ||
52 | |||
53 | tempX_min Read/write the lower temperature limit - exceeding this | ||
54 | will cause an alarm. | ||
55 | |||
56 | tempX_offset Read/write the temperature adjustment offset | ||
57 | |||
58 | tempX_crit Read/write the THERM limit for remote1. | ||
59 | |||
60 | tempX_crit_hyst Set the temperature value below crit where the | ||
61 | fans will stay on - this helps drive the temperature | ||
62 | low enough so it doesn't stay near the edge and | ||
63 | cause THERM to keep tripping. | ||
64 | |||
65 | tempX_auto_point1_temp Read/write the minimum temperature where the fans will | ||
66 | turn on in automatic mode. | ||
67 | |||
68 | tempX_auto_point2_temp Read/write the maximum temperature over which the fans | ||
69 | will run in automatic mode. tempX_auto_point1_temp | ||
70 | and tempX_auto_point2_temp together define the | ||
71 | range of automatic control. | ||
72 | |||
73 | tempX_alarm Read a 1 if the max/min alarm is set | ||
74 | tempX_fault Read a 1 if either temp1 or temp3 diode has a fault | ||
75 | |||
76 | (There are two voltage settings, in1 and in2): | ||
77 | |||
78 | inX_input Read the current voltage on VCC. Value is in | ||
79 | millivolts. | ||
80 | |||
81 | inX_min read/write the minimum voltage limit. | ||
82 | Dropping below this causes an alarm. | ||
83 | |||
84 | inX_max read/write the maximum voltage limit. | ||
85 | Exceeding this causes an alarm. | ||
86 | |||
87 | inX_alarm Read a 1 if the max/min alarm is set. | ||
diff --git a/Documentation/hwmon/hpfall.c b/Documentation/hwmon/hpfall.c new file mode 100644 index 000000000000..bbea1ccfd46a --- /dev/null +++ b/Documentation/hwmon/hpfall.c | |||
@@ -0,0 +1,101 @@ | |||
1 | /* Disk protection for HP machines. | ||
2 | * | ||
3 | * Copyright 2008 Eric Piel | ||
4 | * Copyright 2009 Pavel Machek <pavel@suse.cz> | ||
5 | * | ||
6 | * GPLv2. | ||
7 | */ | ||
8 | |||
9 | #include <stdio.h> | ||
10 | #include <stdlib.h> | ||
11 | #include <unistd.h> | ||
12 | #include <fcntl.h> | ||
13 | #include <sys/stat.h> | ||
14 | #include <sys/types.h> | ||
15 | #include <string.h> | ||
16 | #include <stdint.h> | ||
17 | #include <errno.h> | ||
18 | #include <signal.h> | ||
19 | |||
20 | void write_int(char *path, int i) | ||
21 | { | ||
22 | char buf[1024]; | ||
23 | int fd = open(path, O_RDWR); | ||
24 | if (fd < 0) { | ||
25 | perror("open"); | ||
26 | exit(1); | ||
27 | } | ||
28 | sprintf(buf, "%d", i); | ||
29 | if (write(fd, buf, strlen(buf)) != strlen(buf)) { | ||
30 | perror("write"); | ||
31 | exit(1); | ||
32 | } | ||
33 | close(fd); | ||
34 | } | ||
35 | |||
36 | void set_led(int on) | ||
37 | { | ||
38 | write_int("/sys/class/leds/hp::hddprotect/brightness", on); | ||
39 | } | ||
40 | |||
41 | void protect(int seconds) | ||
42 | { | ||
43 | write_int("/sys/block/sda/device/unload_heads", seconds*1000); | ||
44 | } | ||
45 | |||
46 | int on_ac(void) | ||
47 | { | ||
48 | // /sys/class/power_supply/AC0/online | ||
49 | } | ||
50 | |||
51 | int lid_open(void) | ||
52 | { | ||
53 | // /proc/acpi/button/lid/LID/state | ||
54 | } | ||
55 | |||
56 | void ignore_me(void) | ||
57 | { | ||
58 | protect(0); | ||
59 | set_led(0); | ||
60 | |||
61 | } | ||
62 | |||
63 | int main(int argc, char* argv[]) | ||
64 | { | ||
65 | int fd, ret; | ||
66 | |||
67 | fd = open("/dev/freefall", O_RDONLY); | ||
68 | if (fd < 0) { | ||
69 | perror("open"); | ||
70 | return EXIT_FAILURE; | ||
71 | } | ||
72 | |||
73 | signal(SIGALRM, ignore_me); | ||
74 | |||
75 | for (;;) { | ||
76 | unsigned char count; | ||
77 | |||
78 | ret = read(fd, &count, sizeof(count)); | ||
79 | alarm(0); | ||
80 | if ((ret == -1) && (errno == EINTR)) { | ||
81 | /* Alarm expired, time to unpark the heads */ | ||
82 | continue; | ||
83 | } | ||
84 | |||
85 | if (ret != sizeof(count)) { | ||
86 | perror("read"); | ||
87 | break; | ||
88 | } | ||
89 | |||
90 | protect(21); | ||
91 | set_led(1); | ||
92 | if (1 || on_ac() || lid_open()) { | ||
93 | alarm(2); | ||
94 | } else { | ||
95 | alarm(20); | ||
96 | } | ||
97 | } | ||
98 | |||
99 | close(fd); | ||
100 | return EXIT_SUCCESS; | ||
101 | } | ||
diff --git a/Documentation/hwmon/lis3lv02d b/Documentation/hwmon/lis3lv02d index 65dfb0c0fd67..287f8c902656 100644 --- a/Documentation/hwmon/lis3lv02d +++ b/Documentation/hwmon/lis3lv02d | |||
@@ -13,23 +13,34 @@ Author: | |||
13 | Description | 13 | Description |
14 | ----------- | 14 | ----------- |
15 | 15 | ||
16 | This driver provides support for the accelerometer found in various HP laptops | 16 | This driver provides support for the accelerometer found in various HP |
17 | sporting the feature officially called "HP Mobile Data Protection System 3D" or | 17 | laptops sporting the feature officially called "HP Mobile Data |
18 | "HP 3D DriveGuard". It detect automatically laptops with this sensor. Known models | 18 | Protection System 3D" or "HP 3D DriveGuard". It detect automatically |
19 | (for now the HP 2133, nc6420, nc2510, nc8510, nc84x0, nw9440 and nx9420) will | 19 | laptops with this sensor. Known models (for now the HP 2133, nc6420, |
20 | have their axis automatically oriented on standard way (eg: you can directly | 20 | nc2510, nc8510, nc84x0, nw9440 and nx9420) will have their axis |
21 | play neverball). The accelerometer data is readable via | 21 | automatically oriented on standard way (eg: you can directly play |
22 | neverball). The accelerometer data is readable via | ||
22 | /sys/devices/platform/lis3lv02d. | 23 | /sys/devices/platform/lis3lv02d. |
23 | 24 | ||
24 | Sysfs attributes under /sys/devices/platform/lis3lv02d/: | 25 | Sysfs attributes under /sys/devices/platform/lis3lv02d/: |
25 | position - 3D position that the accelerometer reports. Format: "(x,y,z)" | 26 | position - 3D position that the accelerometer reports. Format: "(x,y,z)" |
26 | calibrate - read: values (x, y, z) that are used as the base for input class device operation. | 27 | calibrate - read: values (x, y, z) that are used as the base for input |
27 | write: forces the base to be recalibrated with the current position. | 28 | class device operation. |
29 | write: forces the base to be recalibrated with the current | ||
30 | position. | ||
28 | rate - reports the sampling rate of the accelerometer device in HZ | 31 | rate - reports the sampling rate of the accelerometer device in HZ |
29 | 32 | ||
30 | This driver also provides an absolute input class device, allowing | 33 | This driver also provides an absolute input class device, allowing |
31 | the laptop to act as a pinball machine-esque joystick. | 34 | the laptop to act as a pinball machine-esque joystick. |
32 | 35 | ||
36 | Another feature of the driver is misc device called "freefall" that | ||
37 | acts similar to /dev/rtc and reacts on free-fall interrupts received | ||
38 | from the device. It supports blocking operations, poll/select and | ||
39 | fasync operation modes. You must read 1 bytes from the device. The | ||
40 | result is number of free-fall interrupts since the last successful | ||
41 | read (or 255 if number of interrupts would not fit). | ||
42 | |||
43 | |||
33 | Axes orientation | 44 | Axes orientation |
34 | ---------------- | 45 | ---------------- |
35 | 46 | ||
@@ -39,11 +50,12 @@ the accelerometer are converted into a "standard" organisation of the axes | |||
39 | * When the laptop is horizontal the position reported is about 0 for X and Y | 50 | * When the laptop is horizontal the position reported is about 0 for X and Y |
40 | and a positive value for Z | 51 | and a positive value for Z |
41 | * If the left side is elevated, X increases (becomes positive) | 52 | * If the left side is elevated, X increases (becomes positive) |
42 | * If the front side (where the touchpad is) is elevated, Y decreases (becomes negative) | 53 | * If the front side (where the touchpad is) is elevated, Y decreases |
54 | (becomes negative) | ||
43 | * If the laptop is put upside-down, Z becomes negative | 55 | * If the laptop is put upside-down, Z becomes negative |
44 | 56 | ||
45 | If your laptop model is not recognized (cf "dmesg"), you can send an email to the | 57 | If your laptop model is not recognized (cf "dmesg"), you can send an |
46 | authors to add it to the database. When reporting a new laptop, please include | 58 | email to the authors to add it to the database. When reporting a new |
47 | the output of "dmidecode" plus the value of /sys/devices/platform/lis3lv02d/position | 59 | laptop, please include the output of "dmidecode" plus the value of |
48 | in these four cases. | 60 | /sys/devices/platform/lis3lv02d/position in these four cases. |
49 | 61 | ||
diff --git a/Documentation/ja_JP/stable_kernel_rules.txt b/Documentation/ja_JP/stable_kernel_rules.txt index b3ffe870de33..14265837c4ce 100644 --- a/Documentation/ja_JP/stable_kernel_rules.txt +++ b/Documentation/ja_JP/stable_kernel_rules.txt | |||
@@ -12,11 +12,11 @@ file at first. | |||
12 | 12 | ||
13 | ================================== | 13 | ================================== |
14 | これは、 | 14 | これは、 |
15 | linux-2.6.24/Documentation/stable_kernel_rules.txt | 15 | linux-2.6.29/Documentation/stable_kernel_rules.txt |
16 | の和訳です。 | 16 | の和訳です。 |
17 | 17 | ||
18 | 翻訳団体: JF プロジェクト < http://www.linux.or.jp/JF/ > | 18 | 翻訳団体: JF プロジェクト < http://www.linux.or.jp/JF/ > |
19 | 翻訳日: 2007/12/30 | 19 | 翻訳日: 2009/1/14 |
20 | 翻訳者: Tsugikazu Shibata <tshibata at ab dot jp dot nec dot com> | 20 | 翻訳者: Tsugikazu Shibata <tshibata at ab dot jp dot nec dot com> |
21 | 校正者: 武井伸光さん、<takei at webmasters dot gr dot jp> | 21 | 校正者: 武井伸光さん、<takei at webmasters dot gr dot jp> |
22 | かねこさん (Seiji Kaneko) <skaneko at a2 dot mbn dot or dot jp> | 22 | かねこさん (Seiji Kaneko) <skaneko at a2 dot mbn dot or dot jp> |
@@ -38,12 +38,15 @@ linux-2.6.24/Documentation/stable_kernel_rules.txt | |||
38 | - ビルドエラー(CONFIG_BROKENになっているものを除く), oops, ハング、デー | 38 | - ビルドエラー(CONFIG_BROKENになっているものを除く), oops, ハング、デー |
39 | タ破壊、現実のセキュリティ問題、その他 "ああ、これはダメだね"という | 39 | タ破壊、現実のセキュリティ問題、その他 "ああ、これはダメだね"という |
40 | ようなものを修正しなければならない。短く言えば、重大な問題。 | 40 | ようなものを修正しなければならない。短く言えば、重大な問題。 |
41 | - 新しい device ID とクオークも受け入れられる。 | ||
41 | - どのように競合状態が発生するかの説明も一緒に書かれていない限り、 | 42 | - どのように競合状態が発生するかの説明も一緒に書かれていない限り、 |
42 | "理論的には競合状態になる"ようなものは不可。 | 43 | "理論的には競合状態になる"ようなものは不可。 |
43 | - いかなる些細な修正も含めることはできない。(スペルの修正、空白のクリー | 44 | - いかなる些細な修正も含めることはできない。(スペルの修正、空白のクリー |
44 | ンアップなど) | 45 | ンアップなど) |
45 | - 対応するサブシステムメンテナが受け入れたものでなければならない。 | ||
46 | - Documentation/SubmittingPatches の規則に従ったものでなければならない。 | 46 | - Documentation/SubmittingPatches の規則に従ったものでなければならない。 |
47 | - パッチ自体か同等の修正が Linus のツリーに既に存在しなければならない。 | ||
48 | Linus のツリーでのコミットID を -stable へのパッチ投稿の際に引用す | ||
49 | ること。 | ||
47 | 50 | ||
48 | -stable ツリーにパッチを送付する手続き- | 51 | -stable ツリーにパッチを送付する手続き- |
49 | 52 | ||
@@ -52,8 +55,10 @@ linux-2.6.24/Documentation/stable_kernel_rules.txt | |||
52 | - 送信者はパッチがキューに受け付けられた際には ACK を、却下された場合 | 55 | - 送信者はパッチがキューに受け付けられた際には ACK を、却下された場合 |
53 | には NAK を受け取る。この反応は開発者たちのスケジュールによって、数 | 56 | には NAK を受け取る。この反応は開発者たちのスケジュールによって、数 |
54 | 日かかる場合がある。 | 57 | 日かかる場合がある。 |
55 | - もし受け取られたら、パッチは他の開発者たちのレビューのために | 58 | - もし受け取られたら、パッチは他の開発者たちと関連するサブシステムの |
56 | -stable キューに追加される。 | 59 | メンテナーによるレビューのために -stable キューに追加される。 |
60 | - パッチに stable@kernel.org のアドレスが付加されているときには、それ | ||
61 | が Linus のツリーに入る時に自動的に stable チームに email される。 | ||
57 | - セキュリティパッチはこのエイリアス (stable@kernel.org) に送られるべ | 62 | - セキュリティパッチはこのエイリアス (stable@kernel.org) に送られるべ |
58 | きではなく、代わりに security@kernel.org のアドレスに送られる。 | 63 | きではなく、代わりに security@kernel.org のアドレスに送られる。 |
59 | 64 | ||
diff --git a/Documentation/kbuild/kbuild.txt b/Documentation/kbuild/kbuild.txt index 923f9ddee8f6..f3355b6812df 100644 --- a/Documentation/kbuild/kbuild.txt +++ b/Documentation/kbuild/kbuild.txt | |||
@@ -3,7 +3,7 @@ Environment variables | |||
3 | KCPPFLAGS | 3 | KCPPFLAGS |
4 | -------------------------------------------------- | 4 | -------------------------------------------------- |
5 | Additional options to pass when preprocessing. The preprocessing options | 5 | Additional options to pass when preprocessing. The preprocessing options |
6 | will be used in all cases where kbuild do preprocessing including | 6 | will be used in all cases where kbuild does preprocessing including |
7 | building C files and assembler files. | 7 | building C files and assembler files. |
8 | 8 | ||
9 | KAFLAGS | 9 | KAFLAGS |
@@ -16,7 +16,7 @@ Additional options to the C compiler. | |||
16 | 16 | ||
17 | KBUILD_VERBOSE | 17 | KBUILD_VERBOSE |
18 | -------------------------------------------------- | 18 | -------------------------------------------------- |
19 | Set the kbuild verbosity. Can be assinged same values as "V=...". | 19 | Set the kbuild verbosity. Can be assigned same values as "V=...". |
20 | See make help for the full list. | 20 | See make help for the full list. |
21 | Setting "V=..." takes precedence over KBUILD_VERBOSE. | 21 | Setting "V=..." takes precedence over KBUILD_VERBOSE. |
22 | 22 | ||
@@ -35,14 +35,14 @@ KBUILD_OUTPUT | |||
35 | -------------------------------------------------- | 35 | -------------------------------------------------- |
36 | Specify the output directory when building the kernel. | 36 | Specify the output directory when building the kernel. |
37 | The output directory can also be specificed using "O=...". | 37 | The output directory can also be specificed using "O=...". |
38 | Setting "O=..." takes precedence over KBUILD_OUTPUT | 38 | Setting "O=..." takes precedence over KBUILD_OUTPUT. |
39 | 39 | ||
40 | ARCH | 40 | ARCH |
41 | -------------------------------------------------- | 41 | -------------------------------------------------- |
42 | Set ARCH to the architecture to be built. | 42 | Set ARCH to the architecture to be built. |
43 | In most cases the name of the architecture is the same as the | 43 | In most cases the name of the architecture is the same as the |
44 | directory name found in the arch/ directory. | 44 | directory name found in the arch/ directory. |
45 | But some architectures suach as x86 and sparc has aliases. | 45 | But some architectures such as x86 and sparc have aliases. |
46 | x86: i386 for 32 bit, x86_64 for 64 bit | 46 | x86: i386 for 32 bit, x86_64 for 64 bit |
47 | sparc: sparc for 32 bit, sparc64 for 64 bit | 47 | sparc: sparc for 32 bit, sparc64 for 64 bit |
48 | 48 | ||
@@ -63,7 +63,7 @@ CF is often used on the command-line like this: | |||
63 | INSTALL_PATH | 63 | INSTALL_PATH |
64 | -------------------------------------------------- | 64 | -------------------------------------------------- |
65 | INSTALL_PATH specifies where to place the updated kernel and system map | 65 | INSTALL_PATH specifies where to place the updated kernel and system map |
66 | images. Default is /boot, but you can set it to other values | 66 | images. Default is /boot, but you can set it to other values. |
67 | 67 | ||
68 | 68 | ||
69 | MODLIB | 69 | MODLIB |
@@ -90,7 +90,7 @@ INSTALL_MOD_STRIP will used as the options to the strip command. | |||
90 | 90 | ||
91 | INSTALL_FW_PATH | 91 | INSTALL_FW_PATH |
92 | -------------------------------------------------- | 92 | -------------------------------------------------- |
93 | INSTALL_FW_PATH specify where to install the firmware blobs. | 93 | INSTALL_FW_PATH specifies where to install the firmware blobs. |
94 | The default value is: | 94 | The default value is: |
95 | 95 | ||
96 | $(INSTALL_MOD_PATH)/lib/firmware | 96 | $(INSTALL_MOD_PATH)/lib/firmware |
@@ -99,7 +99,7 @@ The value can be overridden in which case the default value is ignored. | |||
99 | 99 | ||
100 | INSTALL_HDR_PATH | 100 | INSTALL_HDR_PATH |
101 | -------------------------------------------------- | 101 | -------------------------------------------------- |
102 | INSTALL_HDR_PATH specify where to install user space headers when | 102 | INSTALL_HDR_PATH specifies where to install user space headers when |
103 | executing "make headers_*". | 103 | executing "make headers_*". |
104 | The default value is: | 104 | The default value is: |
105 | 105 | ||
@@ -112,22 +112,23 @@ The value can be overridden in which case the default value is ignored. | |||
112 | 112 | ||
113 | KBUILD_MODPOST_WARN | 113 | KBUILD_MODPOST_WARN |
114 | -------------------------------------------------- | 114 | -------------------------------------------------- |
115 | KBUILD_MODPOST_WARN can be set to avoid error out in case of undefined | 115 | KBUILD_MODPOST_WARN can be set to avoid errors in case of undefined |
116 | symbols in the final module linking stage. | 116 | symbols in the final module linking stage. It changes such errors |
117 | into warnings. | ||
117 | 118 | ||
118 | KBUILD_MODPOST_FINAL | 119 | KBUILD_MODPOST_NOFINAL |
119 | -------------------------------------------------- | 120 | -------------------------------------------------- |
120 | KBUILD_MODPOST_NOFINAL can be set to skip the final link of modules. | 121 | KBUILD_MODPOST_NOFINAL can be set to skip the final link of modules. |
121 | This is solely usefull to speed up test compiles. | 122 | This is solely useful to speed up test compiles. |
122 | 123 | ||
123 | KBUILD_EXTRA_SYMBOLS | 124 | KBUILD_EXTRA_SYMBOLS |
124 | -------------------------------------------------- | 125 | -------------------------------------------------- |
125 | For modules use symbols from another modules. | 126 | For modules that use symbols from other modules. |
126 | See more details in modules.txt. | 127 | See more details in modules.txt. |
127 | 128 | ||
128 | ALLSOURCE_ARCHS | 129 | ALLSOURCE_ARCHS |
129 | -------------------------------------------------- | 130 | -------------------------------------------------- |
130 | For tags/TAGS/cscope targets, you can specify more than one archs | 131 | For tags/TAGS/cscope targets, you can specify more than one arch |
131 | to be included in the databases, separated by blankspace. e.g. | 132 | to be included in the databases, separated by blank space. E.g.: |
132 | 133 | ||
133 | $ make ALLSOURCE_ARCHS="x86 mips arm" tags | 134 | $ make ALLSOURCE_ARCHS="x86 mips arm" tags |
diff --git a/Documentation/kernel-doc-nano-HOWTO.txt b/Documentation/kernel-doc-nano-HOWTO.txt index d73fbd2b2b45..026ec7d57384 100644 --- a/Documentation/kernel-doc-nano-HOWTO.txt +++ b/Documentation/kernel-doc-nano-HOWTO.txt | |||
@@ -43,7 +43,8 @@ Only comments so marked will be considered by the kernel-doc scripts, | |||
43 | and any comment so marked must be in kernel-doc format. Do not use | 43 | and any comment so marked must be in kernel-doc format. Do not use |
44 | "/**" to be begin a comment block unless the comment block contains | 44 | "/**" to be begin a comment block unless the comment block contains |
45 | kernel-doc formatted comments. The closing comment marker for | 45 | kernel-doc formatted comments. The closing comment marker for |
46 | kernel-doc comments can be either "*/" or "**/". | 46 | kernel-doc comments can be either "*/" or "**/", but "*/" is |
47 | preferred in the Linux kernel tree. | ||
47 | 48 | ||
48 | Kernel-doc comments should be placed just before the function | 49 | Kernel-doc comments should be placed just before the function |
49 | or data structure being described. | 50 | or data structure being described. |
@@ -63,7 +64,7 @@ Example kernel-doc function comment: | |||
63 | * comment lines. | 64 | * comment lines. |
64 | * | 65 | * |
65 | * The longer description can have multiple paragraphs. | 66 | * The longer description can have multiple paragraphs. |
66 | **/ | 67 | */ |
67 | 68 | ||
68 | The first line, with the short description, must be on a single line. | 69 | The first line, with the short description, must be on a single line. |
69 | 70 | ||
@@ -85,7 +86,7 @@ Example kernel-doc data structure comment. | |||
85 | * perhaps with more lines and words. | 86 | * perhaps with more lines and words. |
86 | * | 87 | * |
87 | * Longer description of this structure. | 88 | * Longer description of this structure. |
88 | **/ | 89 | */ |
89 | 90 | ||
90 | The kernel-doc function comments describe each parameter to the | 91 | The kernel-doc function comments describe each parameter to the |
91 | function, in order, with the @name lines. | 92 | function, in order, with the @name lines. |
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index 8511d3532c27..54f21a5c262b 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt | |||
@@ -114,7 +114,7 @@ In addition, the following text indicates that the option: | |||
114 | Parameters denoted with BOOT are actually interpreted by the boot | 114 | Parameters denoted with BOOT are actually interpreted by the boot |
115 | loader, and have no meaning to the kernel directly. | 115 | loader, and have no meaning to the kernel directly. |
116 | Do not modify the syntax of boot loader parameters without extreme | 116 | Do not modify the syntax of boot loader parameters without extreme |
117 | need or coordination with <Documentation/x86/i386/boot.txt>. | 117 | need or coordination with <Documentation/x86/boot.txt>. |
118 | 118 | ||
119 | There are also arch-specific kernel-parameters not documented here. | 119 | There are also arch-specific kernel-parameters not documented here. |
120 | See for example <Documentation/x86/x86_64/boot-options.txt>. | 120 | See for example <Documentation/x86/x86_64/boot-options.txt>. |
@@ -134,7 +134,7 @@ and is between 256 and 4096 characters. It is defined in the file | |||
134 | 134 | ||
135 | acpi= [HW,ACPI,X86-64,i386] | 135 | acpi= [HW,ACPI,X86-64,i386] |
136 | Advanced Configuration and Power Interface | 136 | Advanced Configuration and Power Interface |
137 | Format: { force | off | ht | strict | noirq } | 137 | Format: { force | off | ht | strict | noirq | rsdt } |
138 | force -- enable ACPI if default was off | 138 | force -- enable ACPI if default was off |
139 | off -- disable ACPI if default was on | 139 | off -- disable ACPI if default was on |
140 | noirq -- do not use ACPI for IRQ routing | 140 | noirq -- do not use ACPI for IRQ routing |
@@ -577,9 +577,6 @@ and is between 256 and 4096 characters. It is defined in the file | |||
577 | a memory unit (amount[KMG]). See also | 577 | a memory unit (amount[KMG]). See also |
578 | Documentation/kdump/kdump.txt for a example. | 578 | Documentation/kdump/kdump.txt for a example. |
579 | 579 | ||
580 | cs4232= [HW,OSS] | ||
581 | Format: <io>,<irq>,<dma>,<dma2>,<mpuio>,<mpuirq> | ||
582 | |||
583 | cs89x0_dma= [HW,NET] | 580 | cs89x0_dma= [HW,NET] |
584 | Format: <dma> | 581 | Format: <dma> |
585 | 582 | ||
@@ -732,10 +729,6 @@ and is between 256 and 4096 characters. It is defined in the file | |||
732 | Default value is 0. | 729 | Default value is 0. |
733 | Value can be changed at runtime via /selinux/enforce. | 730 | Value can be changed at runtime via /selinux/enforce. |
734 | 731 | ||
735 | es1371= [HW,OSS] | ||
736 | Format: <spdif>,[<nomix>,[<amplifier>]] | ||
737 | See also header of sound/oss/es1371.c. | ||
738 | |||
739 | ether= [HW,NET] Ethernet cards parameters | 732 | ether= [HW,NET] Ethernet cards parameters |
740 | This option is obsoleted by the "netdev=" option, which | 733 | This option is obsoleted by the "netdev=" option, which |
741 | has equivalent usage. See its documentation for details. | 734 | has equivalent usage. See its documentation for details. |
@@ -875,8 +868,10 @@ and is between 256 and 4096 characters. It is defined in the file | |||
875 | icn= [HW,ISDN] | 868 | icn= [HW,ISDN] |
876 | Format: <io>[,<membase>[,<icn_id>[,<icn_id2>]]] | 869 | Format: <io>[,<membase>[,<icn_id>[,<icn_id2>]]] |
877 | 870 | ||
878 | ide= [HW] (E)IDE subsystem | 871 | ide-core.nodma= [HW] (E)IDE subsystem |
879 | Format: ide=nodma or ide=doubler | 872 | Format: =0.0 to prevent dma on hda, =0.1 hdb =1.0 hdc |
873 | .vlb_clock .pci_clock .noflush .noprobe .nowerr .cdrom | ||
874 | .chs .ignore_cable are additional options | ||
880 | See Documentation/ide/ide.txt. | 875 | See Documentation/ide/ide.txt. |
881 | 876 | ||
882 | idebus= [HW] (E)IDE subsystem - VLB/PCI bus speed | 877 | idebus= [HW] (E)IDE subsystem - VLB/PCI bus speed |
@@ -944,6 +939,8 @@ and is between 256 and 4096 characters. It is defined in the file | |||
944 | 939 | ||
945 | 940 | ||
946 | intel_iommu= [DMAR] Intel IOMMU driver (DMAR) option | 941 | intel_iommu= [DMAR] Intel IOMMU driver (DMAR) option |
942 | on | ||
943 | Enable intel iommu driver. | ||
947 | off | 944 | off |
948 | Disable intel iommu driver. | 945 | Disable intel iommu driver. |
949 | igfx_off [Default Off] | 946 | igfx_off [Default Off] |
@@ -2454,7 +2451,7 @@ and is between 256 and 4096 characters. It is defined in the file | |||
2454 | See Documentation/fb/modedb.txt. | 2451 | See Documentation/fb/modedb.txt. |
2455 | 2452 | ||
2456 | vga= [BOOT,X86-32] Select a particular video mode | 2453 | vga= [BOOT,X86-32] Select a particular video mode |
2457 | See Documentation/x86/i386/boot.txt and | 2454 | See Documentation/x86/boot.txt and |
2458 | Documentation/svga.txt. | 2455 | Documentation/svga.txt. |
2459 | Use vga=ask for menu. | 2456 | Use vga=ask for menu. |
2460 | This is actually a boot loader parameter; the value is | 2457 | This is actually a boot loader parameter; the value is |
diff --git a/Documentation/laptops/thinkpad-acpi.txt b/Documentation/laptops/thinkpad-acpi.txt index 898b4987bb80..41bc99fa1884 100644 --- a/Documentation/laptops/thinkpad-acpi.txt +++ b/Documentation/laptops/thinkpad-acpi.txt | |||
@@ -1,7 +1,7 @@ | |||
1 | ThinkPad ACPI Extras Driver | 1 | ThinkPad ACPI Extras Driver |
2 | 2 | ||
3 | Version 0.21 | 3 | Version 0.22 |
4 | May 29th, 2008 | 4 | November 23rd, 2008 |
5 | 5 | ||
6 | Borislav Deianov <borislav@users.sf.net> | 6 | Borislav Deianov <borislav@users.sf.net> |
7 | Henrique de Moraes Holschuh <hmh@hmh.eng.br> | 7 | Henrique de Moraes Holschuh <hmh@hmh.eng.br> |
@@ -16,7 +16,8 @@ supported by the generic Linux ACPI drivers. | |||
16 | This driver used to be named ibm-acpi until kernel 2.6.21 and release | 16 | This driver used to be named ibm-acpi until kernel 2.6.21 and release |
17 | 0.13-20070314. It used to be in the drivers/acpi tree, but it was | 17 | 0.13-20070314. It used to be in the drivers/acpi tree, but it was |
18 | moved to the drivers/misc tree and renamed to thinkpad-acpi for kernel | 18 | moved to the drivers/misc tree and renamed to thinkpad-acpi for kernel |
19 | 2.6.22, and release 0.14. | 19 | 2.6.22, and release 0.14. It was moved to drivers/platform/x86 for |
20 | kernel 2.6.29 and release 0.22. | ||
20 | 21 | ||
21 | The driver is named "thinkpad-acpi". In some places, like module | 22 | The driver is named "thinkpad-acpi". In some places, like module |
22 | names, "thinkpad_acpi" is used because of userspace issues. | 23 | names, "thinkpad_acpi" is used because of userspace issues. |
@@ -1412,6 +1413,24 @@ Sysfs notes: | |||
1412 | rfkill controller switch "tpacpi_wwan_sw": refer to | 1413 | rfkill controller switch "tpacpi_wwan_sw": refer to |
1413 | Documentation/rfkill.txt for details. | 1414 | Documentation/rfkill.txt for details. |
1414 | 1415 | ||
1416 | EXPERIMENTAL: UWB | ||
1417 | ----------------- | ||
1418 | |||
1419 | This feature is marked EXPERIMENTAL because it has not been extensively | ||
1420 | tested and validated in various ThinkPad models yet. The feature may not | ||
1421 | work as expected. USE WITH CAUTION! To use this feature, you need to supply | ||
1422 | the experimental=1 parameter when loading the module. | ||
1423 | |||
1424 | sysfs rfkill class: switch "tpacpi_uwb_sw" | ||
1425 | |||
1426 | This feature exports an rfkill controller for the UWB device, if one is | ||
1427 | present and enabled in the BIOS. | ||
1428 | |||
1429 | Sysfs notes: | ||
1430 | |||
1431 | rfkill controller switch "tpacpi_uwb_sw": refer to | ||
1432 | Documentation/rfkill.txt for details. | ||
1433 | |||
1415 | Multiple Commands, Module Parameters | 1434 | Multiple Commands, Module Parameters |
1416 | ------------------------------------ | 1435 | ------------------------------------ |
1417 | 1436 | ||
diff --git a/Documentation/lguest/Makefile b/Documentation/lguest/Makefile index 725eef81cd48..1f4f9e888bd1 100644 --- a/Documentation/lguest/Makefile +++ b/Documentation/lguest/Makefile | |||
@@ -1,5 +1,5 @@ | |||
1 | # This creates the demonstration utility "lguest" which runs a Linux guest. | 1 | # This creates the demonstration utility "lguest" which runs a Linux guest. |
2 | CFLAGS:=-Wall -Wmissing-declarations -Wmissing-prototypes -O3 -I../../include -I../../arch/x86/include | 2 | CFLAGS:=-Wall -Wmissing-declarations -Wmissing-prototypes -O3 -I../../include -I../../arch/x86/include -U_FORTIFY_SOURCE |
3 | LDLIBS:=-lz | 3 | LDLIBS:=-lz |
4 | 4 | ||
5 | all: lguest | 5 | all: lguest |
diff --git a/Documentation/mips/AU1xxx_IDE.README b/Documentation/mips/AU1xxx_IDE.README index f54962aea84d..8ace35ebdcd5 100644 --- a/Documentation/mips/AU1xxx_IDE.README +++ b/Documentation/mips/AU1xxx_IDE.README | |||
@@ -52,14 +52,12 @@ Two files are introduced: | |||
52 | b) 'drivers/ide/mips/au1xxx-ide.c' | 52 | b) 'drivers/ide/mips/au1xxx-ide.c' |
53 | contains the functionality of the AU1XXX IDE driver | 53 | contains the functionality of the AU1XXX IDE driver |
54 | 54 | ||
55 | Four configs variables are introduced: | 55 | Following extra configs variables are introduced: |
56 | 56 | ||
57 | CONFIG_BLK_DEV_IDE_AU1XXX_PIO_DBDMA - enable the PIO+DBDMA mode | 57 | CONFIG_BLK_DEV_IDE_AU1XXX_PIO_DBDMA - enable the PIO+DBDMA mode |
58 | CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA - enable the MWDMA mode | 58 | CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA - enable the MWDMA mode |
59 | CONFIG_BLK_DEV_IDE_AU1XXX_BURSTABLE_ON - set Burstable FIFO in DBDMA | 59 | CONFIG_BLK_DEV_IDE_AU1XXX_BURSTABLE_ON - set Burstable FIFO in DBDMA |
60 | controller | 60 | controller |
61 | CONFIG_BLK_DEV_IDE_AU1XXX_SEQTS_PER_RQ - maximum transfer size | ||
62 | per descriptor | ||
63 | 61 | ||
64 | 62 | ||
65 | SUPPORTED IDE MODES | 63 | SUPPORTED IDE MODES |
@@ -87,7 +85,6 @@ CONFIG_BLK_DEV_IDEDMA_PCI=y | |||
87 | CONFIG_IDEDMA_PCI_AUTO=y | 85 | CONFIG_IDEDMA_PCI_AUTO=y |
88 | CONFIG_BLK_DEV_IDE_AU1XXX=y | 86 | CONFIG_BLK_DEV_IDE_AU1XXX=y |
89 | CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA=y | 87 | CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA=y |
90 | CONFIG_BLK_DEV_IDE_AU1XXX_SEQTS_PER_RQ=128 | ||
91 | CONFIG_BLK_DEV_IDEDMA=y | 88 | CONFIG_BLK_DEV_IDEDMA=y |
92 | CONFIG_IDEDMA_AUTO=y | 89 | CONFIG_IDEDMA_AUTO=y |
93 | 90 | ||
@@ -105,7 +102,6 @@ CONFIG_BLK_DEV_IDEDMA_PCI=y | |||
105 | CONFIG_IDEDMA_PCI_AUTO=y | 102 | CONFIG_IDEDMA_PCI_AUTO=y |
106 | CONFIG_BLK_DEV_IDE_AU1XXX=y | 103 | CONFIG_BLK_DEV_IDE_AU1XXX=y |
107 | CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA=y | 104 | CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA=y |
108 | CONFIG_BLK_DEV_IDE_AU1XXX_SEQTS_PER_RQ=128 | ||
109 | CONFIG_BLK_DEV_IDEDMA=y | 105 | CONFIG_BLK_DEV_IDEDMA=y |
110 | CONFIG_IDEDMA_AUTO=y | 106 | CONFIG_IDEDMA_AUTO=y |
111 | 107 | ||
diff --git a/Documentation/networking/alias.txt b/Documentation/networking/alias.txt index cd12c2ff518a..85046f53fcfc 100644 --- a/Documentation/networking/alias.txt +++ b/Documentation/networking/alias.txt | |||
@@ -2,13 +2,13 @@ | |||
2 | IP-Aliasing: | 2 | IP-Aliasing: |
3 | ============ | 3 | ============ |
4 | 4 | ||
5 | IP-aliases are additional IP-addresses/masks hooked up to a base | 5 | IP-aliases are an obsolete way to manage multiple IP-addresses/masks |
6 | interface by adding a colon and a string when running ifconfig. | 6 | per interface. Newer tools such as iproute2 support multiple |
7 | This string is usually numeric, but this is not a must. | 7 | address/prefixes per interface, but aliases are still supported |
8 | 8 | for backwards compatibility. | |
9 | IP-Aliases are avail if CONFIG_INET (`standard' IPv4 networking) | ||
10 | is configured in the kernel. | ||
11 | 9 | ||
10 | An alias is formed by adding a colon and a string when running ifconfig. | ||
11 | This string is usually numeric, but this is not a must. | ||
12 | 12 | ||
13 | o Alias creation. | 13 | o Alias creation. |
14 | Alias creation is done by 'magic' interface naming: eg. to create a | 14 | Alias creation is done by 'magic' interface naming: eg. to create a |
@@ -38,16 +38,3 @@ o Relationship with main device | |||
38 | 38 | ||
39 | If the base device is shut down the added aliases will be deleted | 39 | If the base device is shut down the added aliases will be deleted |
40 | too. | 40 | too. |
41 | |||
42 | |||
43 | Contact | ||
44 | ------- | ||
45 | Please finger or e-mail me: | ||
46 | Juan Jose Ciarlante <jjciarla@raiz.uncu.edu.ar> | ||
47 | |||
48 | Updated by Erik Schoenfelder <schoenfr@gaertner.DE> | ||
49 | |||
50 | ; local variables: | ||
51 | ; mode: indented-text | ||
52 | ; mode: auto-fill | ||
53 | ; end: | ||
diff --git a/Documentation/networking/netconsole.txt b/Documentation/networking/netconsole.txt index 3c2f2b328638..8d022073e3ef 100644 --- a/Documentation/networking/netconsole.txt +++ b/Documentation/networking/netconsole.txt | |||
@@ -51,7 +51,8 @@ Built-in netconsole starts immediately after the TCP stack is | |||
51 | initialized and attempts to bring up the supplied dev at the supplied | 51 | initialized and attempts to bring up the supplied dev at the supplied |
52 | address. | 52 | address. |
53 | 53 | ||
54 | The remote host can run either 'netcat -u -l -p <port>' or syslogd. | 54 | The remote host can run either 'netcat -u -l -p <port>', |
55 | 'nc -l -u <port>' or syslogd. | ||
55 | 56 | ||
56 | Dynamic reconfiguration: | 57 | Dynamic reconfiguration: |
57 | ======================== | 58 | ======================== |
diff --git a/Documentation/powerpc/dts-bindings/fsl/mpc5200.txt b/Documentation/powerpc/dts-bindings/fsl/mpc5200.txt new file mode 100644 index 000000000000..8447fd7090d0 --- /dev/null +++ b/Documentation/powerpc/dts-bindings/fsl/mpc5200.txt | |||
@@ -0,0 +1,180 @@ | |||
1 | MPC5200 Device Tree Bindings | ||
2 | ---------------------------- | ||
3 | |||
4 | (c) 2006-2009 Secret Lab Technologies Ltd | ||
5 | Grant Likely <grant.likely@secretlab.ca> | ||
6 | |||
7 | Naming conventions | ||
8 | ------------------ | ||
9 | For mpc5200 on-chip devices, the format for each compatible value is | ||
10 | <chip>-<device>[-<mode>]. The OS should be able to match a device driver | ||
11 | to the device based solely on the compatible value. If two drivers | ||
12 | match on the compatible list; the 'most compatible' driver should be | ||
13 | selected. | ||
14 | |||
15 | The split between the MPC5200 and the MPC5200B leaves a bit of a | ||
16 | conundrum. How should the compatible property be set up to provide | ||
17 | maximum compatibility information; but still accurately describe the | ||
18 | chip? For the MPC5200; the answer is easy. Most of the SoC devices | ||
19 | originally appeared on the MPC5200. Since they didn't exist anywhere | ||
20 | else; the 5200 compatible properties will contain only one item; | ||
21 | "fsl,mpc5200-<device>". | ||
22 | |||
23 | The 5200B is almost the same as the 5200, but not quite. It fixes | ||
24 | silicon bugs and it adds a small number of enhancements. Most of the | ||
25 | devices either provide exactly the same interface as on the 5200. A few | ||
26 | devices have extra functions but still have a backwards compatible mode. | ||
27 | To express this information as completely as possible, 5200B device trees | ||
28 | should have two items in the compatible list: | ||
29 | compatible = "fsl,mpc5200b-<device>","fsl,mpc5200-<device>"; | ||
30 | |||
31 | It is *strongly* recommended that 5200B device trees follow this convention | ||
32 | (instead of only listing the base mpc5200 item). | ||
33 | |||
34 | ie. ethernet on mpc5200: compatible = "fsl,mpc5200-fec"; | ||
35 | ethernet on mpc5200b: compatible = "fsl,mpc5200b-fec", "fsl,mpc5200-fec"; | ||
36 | |||
37 | Modal devices, like PSCs, also append the configured function to the | ||
38 | end of the compatible field. ie. A PSC in i2s mode would specify | ||
39 | "fsl,mpc5200-psc-i2s", not "fsl,mpc5200-i2s". This convention is chosen to | ||
40 | avoid naming conflicts with non-psc devices providing the same | ||
41 | function. For example, "fsl,mpc5200-spi" and "fsl,mpc5200-psc-spi" describe | ||
42 | the mpc5200 simple spi device and a PSC spi mode respectively. | ||
43 | |||
44 | At the time of writing, exact chip may be either 'fsl,mpc5200' or | ||
45 | 'fsl,mpc5200b'. | ||
46 | |||
47 | The soc node | ||
48 | ------------ | ||
49 | This node describes the on chip SOC peripherals. Every mpc5200 based | ||
50 | board will have this node, and as such there is a common naming | ||
51 | convention for SOC devices. | ||
52 | |||
53 | Required properties: | ||
54 | name description | ||
55 | ---- ----------- | ||
56 | ranges Memory range of the internal memory mapped registers. | ||
57 | Should be <0 [baseaddr] 0xc000> | ||
58 | reg Should be <[baseaddr] 0x100> | ||
59 | compatible mpc5200: "fsl,mpc5200-immr" | ||
60 | mpc5200b: "fsl,mpc5200b-immr" | ||
61 | system-frequency 'fsystem' frequency in Hz; XLB, IPB, USB and PCI | ||
62 | clocks are derived from the fsystem clock. | ||
63 | bus-frequency IPB bus frequency in Hz. Clock rate | ||
64 | used by most of the soc devices. | ||
65 | |||
66 | soc child nodes | ||
67 | --------------- | ||
68 | Any on chip SOC devices available to Linux must appear as soc5200 child nodes. | ||
69 | |||
70 | Note: The tables below show the value for the mpc5200. A mpc5200b device | ||
71 | tree should use the "fsl,mpc5200b-<device>","fsl,mpc5200-<device>" form. | ||
72 | |||
73 | Required soc5200 child nodes: | ||
74 | name compatible Description | ||
75 | ---- ---------- ----------- | ||
76 | cdm@<addr> fsl,mpc5200-cdm Clock Distribution | ||
77 | interrupt-controller@<addr> fsl,mpc5200-pic need an interrupt | ||
78 | controller to boot | ||
79 | bestcomm@<addr> fsl,mpc5200-bestcomm Bestcomm DMA controller | ||
80 | |||
81 | Recommended soc5200 child nodes; populate as needed for your board | ||
82 | name compatible Description | ||
83 | ---- ---------- ----------- | ||
84 | timer@<addr> fsl,mpc5200-gpt General purpose timers | ||
85 | gpio@<addr> fsl,mpc5200-gpio MPC5200 simple gpio controller | ||
86 | gpio@<addr> fsl,mpc5200-gpio-wkup MPC5200 wakeup gpio controller | ||
87 | rtc@<addr> fsl,mpc5200-rtc Real time clock | ||
88 | mscan@<addr> fsl,mpc5200-mscan CAN bus controller | ||
89 | pci@<addr> fsl,mpc5200-pci PCI bridge | ||
90 | serial@<addr> fsl,mpc5200-psc-uart PSC in serial mode | ||
91 | i2s@<addr> fsl,mpc5200-psc-i2s PSC in i2s mode | ||
92 | ac97@<addr> fsl,mpc5200-psc-ac97 PSC in ac97 mode | ||
93 | spi@<addr> fsl,mpc5200-psc-spi PSC in spi mode | ||
94 | irda@<addr> fsl,mpc5200-psc-irda PSC in IrDA mode | ||
95 | spi@<addr> fsl,mpc5200-spi MPC5200 spi device | ||
96 | ethernet@<addr> fsl,mpc5200-fec MPC5200 ethernet device | ||
97 | ata@<addr> fsl,mpc5200-ata IDE ATA interface | ||
98 | i2c@<addr> fsl,mpc5200-i2c I2C controller | ||
99 | usb@<addr> fsl,mpc5200-ohci,ohci-be USB controller | ||
100 | xlb@<addr> fsl,mpc5200-xlb XLB arbitrator | ||
101 | |||
102 | fsl,mpc5200-gpt nodes | ||
103 | --------------------- | ||
104 | On the mpc5200 and 5200b, GPT0 has a watchdog timer function. If the board | ||
105 | design supports the internal wdt, then the device node for GPT0 should | ||
106 | include the empty property 'fsl,has-wdt'. | ||
107 | |||
108 | An mpc5200-gpt can be used as a single line GPIO controller. To do so, | ||
109 | add the following properties to the gpt node: | ||
110 | gpio-controller; | ||
111 | #gpio-cells = <2>; | ||
112 | When referencing the GPIO line from another node, the first cell must always | ||
113 | be zero and the second cell represents the gpio flags and described in the | ||
114 | gpio device tree binding. | ||
115 | |||
116 | An mpc5200-gpt can be used as a single line edge sensitive interrupt | ||
117 | controller. To do so, add the following properties to the gpt node: | ||
118 | interrupt-controller; | ||
119 | #interrupt-cells = <1>; | ||
120 | When referencing the IRQ line from another node, the cell represents the | ||
121 | sense mode; 1 for edge rising, 2 for edge falling. | ||
122 | |||
123 | fsl,mpc5200-psc nodes | ||
124 | --------------------- | ||
125 | The PSCs should include a cell-index which is the index of the PSC in | ||
126 | hardware. cell-index is used to determine which shared SoC registers to | ||
127 | use when setting up PSC clocking. cell-index number starts at '0'. ie: | ||
128 | PSC1 has 'cell-index = <0>' | ||
129 | PSC4 has 'cell-index = <3>' | ||
130 | |||
131 | PSC in i2s mode: The mpc5200 and mpc5200b PSCs are not compatible when in | ||
132 | i2s mode. An 'mpc5200b-psc-i2s' node cannot include 'mpc5200-psc-i2s' in the | ||
133 | compatible field. | ||
134 | |||
135 | |||
136 | fsl,mpc5200-gpio and fsl,mpc5200-gpio-wkup nodes | ||
137 | ------------------------------------------------ | ||
138 | Each GPIO controller node should have the empty property gpio-controller and | ||
139 | #gpio-cells set to 2. First cell is the GPIO number which is interpreted | ||
140 | according to the bit numbers in the GPIO control registers. The second cell | ||
141 | is for flags which is currently unused. | ||
142 | |||
143 | fsl,mpc5200-fec nodes | ||
144 | --------------------- | ||
145 | The FEC node can specify one of the following properties to configure | ||
146 | the MII link: | ||
147 | - fsl,7-wire-mode - An empty property that specifies the link uses 7-wire | ||
148 | mode instead of MII | ||
149 | - current-speed - Specifies that the MII should be configured for a fixed | ||
150 | speed. This property should contain two cells. The | ||
151 | first cell specifies the speed in Mbps and the second | ||
152 | should be '0' for half duplex and '1' for full duplex | ||
153 | - phy-handle - Contains a phandle to an Ethernet PHY. | ||
154 | |||
155 | Interrupt controller (fsl,mpc5200-pic) node | ||
156 | ------------------------------------------- | ||
157 | The mpc5200 pic binding splits hardware IRQ numbers into two levels. The | ||
158 | split reflects the layout of the PIC hardware itself, which groups | ||
159 | interrupts into one of three groups; CRIT, MAIN or PERP. Also, the | ||
160 | Bestcomm dma engine has it's own set of interrupt sources which are | ||
161 | cascaded off of peripheral interrupt 0, which the driver interprets as a | ||
162 | fourth group, SDMA. | ||
163 | |||
164 | The interrupts property for device nodes using the mpc5200 pic consists | ||
165 | of three cells; <L1 L2 level> | ||
166 | |||
167 | L1 := [CRIT=0, MAIN=1, PERP=2, SDMA=3] | ||
168 | L2 := interrupt number; directly mapped from the value in the | ||
169 | "ICTL PerStat, MainStat, CritStat Encoded Register" | ||
170 | level := [LEVEL_HIGH=0, EDGE_RISING=1, EDGE_FALLING=2, LEVEL_LOW=3] | ||
171 | |||
172 | For external IRQs, use the following interrupt property values (how to | ||
173 | specify external interrupts is a frequently asked question): | ||
174 | External interrupts: | ||
175 | external irq0: interrupts = <0 0 n>; | ||
176 | external irq1: interrupts = <1 1 n>; | ||
177 | external irq2: interrupts = <1 2 n>; | ||
178 | external irq3: interrupts = <1 3 n>; | ||
179 | 'n' is sense (0: level high, 1: edge rising, 2: edge falling 3: level low) | ||
180 | |||
diff --git a/Documentation/powerpc/mpc52xx-device-tree-bindings.txt b/Documentation/powerpc/mpc52xx-device-tree-bindings.txt deleted file mode 100644 index 6f12f1c79c0c..000000000000 --- a/Documentation/powerpc/mpc52xx-device-tree-bindings.txt +++ /dev/null | |||
@@ -1,277 +0,0 @@ | |||
1 | MPC5200 Device Tree Bindings | ||
2 | ---------------------------- | ||
3 | |||
4 | (c) 2006-2007 Secret Lab Technologies Ltd | ||
5 | Grant Likely <grant.likely at secretlab.ca> | ||
6 | |||
7 | ********** DRAFT *********** | ||
8 | * WARNING: Do not depend on the stability of these bindings just yet. | ||
9 | * The MPC5200 device tree conventions are still in flux | ||
10 | * Keep an eye on the linuxppc-dev mailing list for more details | ||
11 | ********** DRAFT *********** | ||
12 | |||
13 | I - Introduction | ||
14 | ================ | ||
15 | Boards supported by the arch/powerpc architecture require device tree be | ||
16 | passed by the boot loader to the kernel at boot time. The device tree | ||
17 | describes what devices are present on the board and how they are | ||
18 | connected. The device tree can either be passed as a binary blob (as | ||
19 | described in Documentation/powerpc/booting-without-of.txt), or passed | ||
20 | by Open Firmware (IEEE 1275) compatible firmware using an OF compatible | ||
21 | client interface API. | ||
22 | |||
23 | This document specifies the requirements on the device-tree for mpc5200 | ||
24 | based boards. These requirements are above and beyond the details | ||
25 | specified in either the Open Firmware spec or booting-without-of.txt | ||
26 | |||
27 | All new mpc5200-based boards are expected to match this document. In | ||
28 | cases where this document is not sufficient to support a new board port, | ||
29 | this document should be updated as part of adding the new board support. | ||
30 | |||
31 | II - Philosophy | ||
32 | =============== | ||
33 | The core of this document is naming convention. The whole point of | ||
34 | defining this convention is to reduce or eliminate the number of | ||
35 | special cases required to support a 5200 board. If all 5200 boards | ||
36 | follow the same convention, then generic 5200 support code will work | ||
37 | rather than coding special cases for each new board. | ||
38 | |||
39 | This section tries to capture the thought process behind why the naming | ||
40 | convention is what it is. | ||
41 | |||
42 | 1. names | ||
43 | --------- | ||
44 | There is strong convention/requirements already established for children | ||
45 | of the root node. 'cpus' describes the processor cores, 'memory' | ||
46 | describes memory, and 'chosen' provides boot configuration. Other nodes | ||
47 | are added to describe devices attached to the processor local bus. | ||
48 | |||
49 | Following convention already established with other system-on-chip | ||
50 | processors, 5200 device trees should use the name 'soc5200' for the | ||
51 | parent node of on chip devices, and the root node should be its parent. | ||
52 | |||
53 | Child nodes are typically named after the configured function. ie. | ||
54 | the FEC node is named 'ethernet', and a PSC in uart mode is named 'serial'. | ||
55 | |||
56 | 2. device_type property | ||
57 | ----------------------- | ||
58 | similar to the node name convention above; the device_type reflects the | ||
59 | configured function of a device. ie. 'serial' for a uart and 'spi' for | ||
60 | an spi controller. However, while node names *should* reflect the | ||
61 | configured function, device_type *must* match the configured function | ||
62 | exactly. | ||
63 | |||
64 | 3. compatible property | ||
65 | ---------------------- | ||
66 | Since device_type isn't enough to match devices to drivers, there also | ||
67 | needs to be a naming convention for the compatible property. Compatible | ||
68 | is an list of device descriptions sorted from specific to generic. For | ||
69 | the mpc5200, the required format for each compatible value is | ||
70 | <chip>-<device>[-<mode>]. The OS should be able to match a device driver | ||
71 | to the device based solely on the compatible value. If two drivers | ||
72 | match on the compatible list; the 'most compatible' driver should be | ||
73 | selected. | ||
74 | |||
75 | The split between the MPC5200 and the MPC5200B leaves a bit of a | ||
76 | conundrum. How should the compatible property be set up to provide | ||
77 | maximum compatibility information; but still accurately describe the | ||
78 | chip? For the MPC5200; the answer is easy. Most of the SoC devices | ||
79 | originally appeared on the MPC5200. Since they didn't exist anywhere | ||
80 | else; the 5200 compatible properties will contain only one item; | ||
81 | "mpc5200-<device>". | ||
82 | |||
83 | The 5200B is almost the same as the 5200, but not quite. It fixes | ||
84 | silicon bugs and it adds a small number of enhancements. Most of the | ||
85 | devices either provide exactly the same interface as on the 5200. A few | ||
86 | devices have extra functions but still have a backwards compatible mode. | ||
87 | To express this information as completely as possible, 5200B device trees | ||
88 | should have two items in the compatible list; | ||
89 | "mpc5200b-<device>\0mpc5200-<device>". It is *strongly* recommended | ||
90 | that 5200B device trees follow this convention (instead of only listing | ||
91 | the base mpc5200 item). | ||
92 | |||
93 | If another chip appear on the market with one of the mpc5200 SoC | ||
94 | devices, then the compatible list should include mpc5200-<device>. | ||
95 | |||
96 | ie. ethernet on mpc5200: compatible = "mpc5200-ethernet" | ||
97 | ethernet on mpc5200b: compatible = "mpc5200b-ethernet\0mpc5200-ethernet" | ||
98 | |||
99 | Modal devices, like PSCs, also append the configured function to the | ||
100 | end of the compatible field. ie. A PSC in i2s mode would specify | ||
101 | "mpc5200-psc-i2s", not "mpc5200-i2s". This convention is chosen to | ||
102 | avoid naming conflicts with non-psc devices providing the same | ||
103 | function. For example, "mpc5200-spi" and "mpc5200-psc-spi" describe | ||
104 | the mpc5200 simple spi device and a PSC spi mode respectively. | ||
105 | |||
106 | If the soc device is more generic and present on other SOCs, the | ||
107 | compatible property can specify the more generic device type also. | ||
108 | |||
109 | ie. mscan: compatible = "mpc5200-mscan\0fsl,mscan"; | ||
110 | |||
111 | At the time of writing, exact chip may be either 'mpc5200' or | ||
112 | 'mpc5200b'. | ||
113 | |||
114 | Device drivers should always try to match as generically as possible. | ||
115 | |||
116 | III - Structure | ||
117 | =============== | ||
118 | The device tree for an mpc5200 board follows the structure defined in | ||
119 | booting-without-of.txt with the following additional notes: | ||
120 | |||
121 | 0) the root node | ||
122 | ---------------- | ||
123 | Typical root description node; see booting-without-of | ||
124 | |||
125 | 1) The cpus node | ||
126 | ---------------- | ||
127 | The cpus node follows the basic layout described in booting-without-of. | ||
128 | The bus-frequency property holds the XLB bus frequency | ||
129 | The clock-frequency property holds the core frequency | ||
130 | |||
131 | 2) The memory node | ||
132 | ------------------ | ||
133 | Typical memory description node; see booting-without-of. | ||
134 | |||
135 | 3) The soc5200 node | ||
136 | ------------------- | ||
137 | This node describes the on chip SOC peripherals. Every mpc5200 based | ||
138 | board will have this node, and as such there is a common naming | ||
139 | convention for SOC devices. | ||
140 | |||
141 | Required properties: | ||
142 | name type description | ||
143 | ---- ---- ----------- | ||
144 | device_type string must be "soc" | ||
145 | ranges int should be <0 baseaddr baseaddr+10000> | ||
146 | reg int must be <baseaddr 10000> | ||
147 | compatible string mpc5200: "mpc5200-soc" | ||
148 | mpc5200b: "mpc5200b-soc\0mpc5200-soc" | ||
149 | system-frequency int Fsystem frequency; source of all | ||
150 | other clocks. | ||
151 | bus-frequency int IPB bus frequency in HZ. Clock rate | ||
152 | used by most of the soc devices. | ||
153 | #interrupt-cells int must be <3>. | ||
154 | |||
155 | Recommended properties: | ||
156 | name type description | ||
157 | ---- ---- ----------- | ||
158 | model string Exact model of the chip; | ||
159 | ie: model="fsl,mpc5200" | ||
160 | revision string Silicon revision of chip | ||
161 | ie: revision="M08A" | ||
162 | |||
163 | The 'model' and 'revision' properties are *strongly* recommended. Having | ||
164 | them presence acts as a bit of a safety net for working around as yet | ||
165 | undiscovered bugs on one version of silicon. For example, device drivers | ||
166 | can use the model and revision properties to decide if a bug fix should | ||
167 | be turned on. | ||
168 | |||
169 | 4) soc5200 child nodes | ||
170 | ---------------------- | ||
171 | Any on chip SOC devices available to Linux must appear as soc5200 child nodes. | ||
172 | |||
173 | Note: The tables below show the value for the mpc5200. A mpc5200b device | ||
174 | tree should use the "mpc5200b-<device>\0mpc5200-<device> form. | ||
175 | |||
176 | Required soc5200 child nodes: | ||
177 | name device_type compatible Description | ||
178 | ---- ----------- ---------- ----------- | ||
179 | cdm@<addr> cdm mpc5200-cmd Clock Distribution | ||
180 | pic@<addr> interrupt-controller mpc5200-pic need an interrupt | ||
181 | controller to boot | ||
182 | bestcomm@<addr> dma-controller mpc5200-bestcomm 5200 pic also requires | ||
183 | the bestcomm device | ||
184 | |||
185 | Recommended soc5200 child nodes; populate as needed for your board | ||
186 | name device_type compatible Description | ||
187 | ---- ----------- ---------- ----------- | ||
188 | gpt@<addr> gpt fsl,mpc5200-gpt General purpose timers | ||
189 | gpt@<addr> gpt fsl,mpc5200-gpt-gpio General purpose | ||
190 | timers in GPIO mode | ||
191 | gpio@<addr> fsl,mpc5200-gpio MPC5200 simple gpio | ||
192 | controller | ||
193 | gpio@<addr> fsl,mpc5200-gpio-wkup MPC5200 wakeup gpio | ||
194 | controller | ||
195 | rtc@<addr> rtc mpc5200-rtc Real time clock | ||
196 | mscan@<addr> mscan mpc5200-mscan CAN bus controller | ||
197 | pci@<addr> pci mpc5200-pci PCI bridge | ||
198 | serial@<addr> serial mpc5200-psc-uart PSC in serial mode | ||
199 | i2s@<addr> sound mpc5200-psc-i2s PSC in i2s mode | ||
200 | ac97@<addr> sound mpc5200-psc-ac97 PSC in ac97 mode | ||
201 | spi@<addr> spi mpc5200-psc-spi PSC in spi mode | ||
202 | irda@<addr> irda mpc5200-psc-irda PSC in IrDA mode | ||
203 | spi@<addr> spi mpc5200-spi MPC5200 spi device | ||
204 | ethernet@<addr> network mpc5200-fec MPC5200 ethernet device | ||
205 | ata@<addr> ata mpc5200-ata IDE ATA interface | ||
206 | i2c@<addr> i2c mpc5200-i2c I2C controller | ||
207 | usb@<addr> usb-ohci-be mpc5200-ohci,ohci-be USB controller | ||
208 | xlb@<addr> xlb mpc5200-xlb XLB arbitrator | ||
209 | |||
210 | Important child node properties | ||
211 | name type description | ||
212 | ---- ---- ----------- | ||
213 | cell-index int When multiple devices are present, is the | ||
214 | index of the device in the hardware (ie. There | ||
215 | are 6 PSC on the 5200 numbered PSC1 to PSC6) | ||
216 | PSC1 has 'cell-index = <0>' | ||
217 | PSC4 has 'cell-index = <3>' | ||
218 | |||
219 | 5) General Purpose Timer nodes (child of soc5200 node) | ||
220 | On the mpc5200 and 5200b, GPT0 has a watchdog timer function. If the board | ||
221 | design supports the internal wdt, then the device node for GPT0 should | ||
222 | include the empty property 'fsl,has-wdt'. | ||
223 | |||
224 | 6) PSC nodes (child of soc5200 node) | ||
225 | PSC nodes can define the optional 'port-number' property to force assignment | ||
226 | order of serial ports. For example, PSC5 might be physically connected to | ||
227 | the port labeled 'COM1' and PSC1 wired to 'COM1'. In this case, PSC5 would | ||
228 | have a "port-number = <0>" property, and PSC1 would have "port-number = <1>". | ||
229 | |||
230 | PSC in i2s mode: The mpc5200 and mpc5200b PSCs are not compatible when in | ||
231 | i2s mode. An 'mpc5200b-psc-i2s' node cannot include 'mpc5200-psc-i2s' in the | ||
232 | compatible field. | ||
233 | |||
234 | 7) GPIO controller nodes | ||
235 | Each GPIO controller node should have the empty property gpio-controller and | ||
236 | #gpio-cells set to 2. First cell is the GPIO number which is interpreted | ||
237 | according to the bit numbers in the GPIO control registers. The second cell | ||
238 | is for flags which is currently unsused. | ||
239 | |||
240 | 8) FEC nodes | ||
241 | The FEC node can specify one of the following properties to configure | ||
242 | the MII link: | ||
243 | "fsl,7-wire-mode" - An empty property that specifies the link uses 7-wire | ||
244 | mode instead of MII | ||
245 | "current-speed" - Specifies that the MII should be configured for a fixed | ||
246 | speed. This property should contain two cells. The | ||
247 | first cell specifies the speed in Mbps and the second | ||
248 | should be '0' for half duplex and '1' for full duplex | ||
249 | "phy-handle" - Contains a phandle to an Ethernet PHY. | ||
250 | |||
251 | IV - Extra Notes | ||
252 | ================ | ||
253 | |||
254 | 1. Interrupt mapping | ||
255 | -------------------- | ||
256 | The mpc5200 pic driver splits hardware IRQ numbers into two levels. The | ||
257 | split reflects the layout of the PIC hardware itself, which groups | ||
258 | interrupts into one of three groups; CRIT, MAIN or PERP. Also, the | ||
259 | Bestcomm dma engine has it's own set of interrupt sources which are | ||
260 | cascaded off of peripheral interrupt 0, which the driver interprets as a | ||
261 | fourth group, SDMA. | ||
262 | |||
263 | The interrupts property for device nodes using the mpc5200 pic consists | ||
264 | of three cells; <L1 L2 level> | ||
265 | |||
266 | L1 := [CRIT=0, MAIN=1, PERP=2, SDMA=3] | ||
267 | L2 := interrupt number; directly mapped from the value in the | ||
268 | "ICTL PerStat, MainStat, CritStat Encoded Register" | ||
269 | level := [LEVEL_HIGH=0, EDGE_RISING=1, EDGE_FALLING=2, LEVEL_LOW=3] | ||
270 | |||
271 | 2. Shared registers | ||
272 | ------------------- | ||
273 | Some SoC devices share registers between them. ie. the i2c devices use | ||
274 | a single clock control register, and almost all device are affected by | ||
275 | the port_config register. Devices which need to manipulate shared regs | ||
276 | should look to the parent SoC node. The soc node is responsible | ||
277 | for arbitrating all shared register access. | ||
diff --git a/Documentation/scheduler/sched-design-CFS.txt b/Documentation/scheduler/sched-design-CFS.txt index 8398ca4ff4ed..6f33593e59e2 100644 --- a/Documentation/scheduler/sched-design-CFS.txt +++ b/Documentation/scheduler/sched-design-CFS.txt | |||
@@ -231,7 +231,7 @@ CPU bandwidth control purposes: | |||
231 | 231 | ||
232 | This options needs CONFIG_CGROUPS to be defined, and lets the administrator | 232 | This options needs CONFIG_CGROUPS to be defined, and lets the administrator |
233 | create arbitrary groups of tasks, using the "cgroup" pseudo filesystem. See | 233 | create arbitrary groups of tasks, using the "cgroup" pseudo filesystem. See |
234 | Documentation/cgroups.txt for more information about this filesystem. | 234 | Documentation/cgroups/cgroups.txt for more information about this filesystem. |
235 | 235 | ||
236 | Only one of these options to group tasks can be chosen and not both. | 236 | Only one of these options to group tasks can be chosen and not both. |
237 | 237 | ||
diff --git a/Documentation/scsi/cxgb3i.txt b/Documentation/scsi/cxgb3i.txt index 8141fa01978e..7ac8032ee9b2 100644 --- a/Documentation/scsi/cxgb3i.txt +++ b/Documentation/scsi/cxgb3i.txt | |||
@@ -4,7 +4,7 @@ Introduction | |||
4 | ============ | 4 | ============ |
5 | 5 | ||
6 | The Chelsio T3 ASIC based Adapters (S310, S320, S302, S304, Mezz cards, etc. | 6 | The Chelsio T3 ASIC based Adapters (S310, S320, S302, S304, Mezz cards, etc. |
7 | series of products) supports iSCSI acceleration and iSCSI Direct Data Placement | 7 | series of products) support iSCSI acceleration and iSCSI Direct Data Placement |
8 | (DDP) where the hardware handles the expensive byte touching operations, such | 8 | (DDP) where the hardware handles the expensive byte touching operations, such |
9 | as CRC computation and verification, and direct DMA to the final host memory | 9 | as CRC computation and verification, and direct DMA to the final host memory |
10 | destination: | 10 | destination: |
@@ -31,9 +31,9 @@ destination: | |||
31 | the TCP segments onto the wire. It handles TCP retransmission if | 31 | the TCP segments onto the wire. It handles TCP retransmission if |
32 | needed. | 32 | needed. |
33 | 33 | ||
34 | On receving, S3 h/w recovers the iSCSI PDU by reassembling TCP | 34 | On receiving, S3 h/w recovers the iSCSI PDU by reassembling TCP |
35 | segments, separating the header and data, calculating and verifying | 35 | segments, separating the header and data, calculating and verifying |
36 | the digests, then forwards the header to the host. The payload data, | 36 | the digests, then forwarding the header to the host. The payload data, |
37 | if possible, will be directly placed into the pre-posted host DDP | 37 | if possible, will be directly placed into the pre-posted host DDP |
38 | buffer. Otherwise, the payload data will be sent to the host too. | 38 | buffer. Otherwise, the payload data will be sent to the host too. |
39 | 39 | ||
@@ -68,9 +68,8 @@ The following steps need to be taken to accelerates the open-iscsi initiator: | |||
68 | sure the ip address is unique in the network. | 68 | sure the ip address is unique in the network. |
69 | 69 | ||
70 | 3. edit /etc/iscsi/iscsid.conf | 70 | 3. edit /etc/iscsi/iscsid.conf |
71 | The default setting for MaxRecvDataSegmentLength (131072) is too big, | 71 | The default setting for MaxRecvDataSegmentLength (131072) is too big; |
72 | replace "node.conn[0].iscsi.MaxRecvDataSegmentLength" to be a value no | 72 | replace with a value no bigger than 15360 (for example 8192): |
73 | bigger than 15360 (for example 8192): | ||
74 | 73 | ||
75 | node.conn[0].iscsi.MaxRecvDataSegmentLength = 8192 | 74 | node.conn[0].iscsi.MaxRecvDataSegmentLength = 8192 |
76 | 75 | ||
diff --git a/Documentation/sound/alsa/DocBook/alsa-driver-api.tmpl b/Documentation/sound/alsa/DocBook/alsa-driver-api.tmpl index 37b006cdf2f9..90f163c4bde9 100644 --- a/Documentation/sound/alsa/DocBook/alsa-driver-api.tmpl +++ b/Documentation/sound/alsa/DocBook/alsa-driver-api.tmpl | |||
@@ -71,6 +71,10 @@ | |||
71 | !Esound/pci/ac97/ac97_codec.c | 71 | !Esound/pci/ac97/ac97_codec.c |
72 | !Esound/pci/ac97/ac97_pcm.c | 72 | !Esound/pci/ac97/ac97_pcm.c |
73 | </sect1> | 73 | </sect1> |
74 | <sect1><title>Virtual Master Control API</title> | ||
75 | !Esound/core/vmaster.c | ||
76 | !Iinclude/sound/control.h | ||
77 | </sect1> | ||
74 | </chapter> | 78 | </chapter> |
75 | <chapter><title>MIDI API</title> | 79 | <chapter><title>MIDI API</title> |
76 | <sect1><title>Raw MIDI API</title> | 80 | <sect1><title>Raw MIDI API</title> |
diff --git a/Documentation/sound/alsa/HD-Audio-Models.txt b/Documentation/sound/alsa/HD-Audio-Models.txt index 4b7ac21ea9eb..0f5d26bea80f 100644 --- a/Documentation/sound/alsa/HD-Audio-Models.txt +++ b/Documentation/sound/alsa/HD-Audio-Models.txt | |||
@@ -275,7 +275,8 @@ STAC9200 | |||
275 | dell-m25 Dell Inspiron E1505n | 275 | dell-m25 Dell Inspiron E1505n |
276 | dell-m26 Dell Inspiron 1501 | 276 | dell-m26 Dell Inspiron 1501 |
277 | dell-m27 Dell Inspiron E1705/9400 | 277 | dell-m27 Dell Inspiron E1705/9400 |
278 | gateway Gateway laptops with EAPD control | 278 | gateway-m4 Gateway laptops with EAPD control |
279 | gateway-m4-2 Gateway laptops with EAPD control | ||
279 | panasonic Panasonic CF-74 | 280 | panasonic Panasonic CF-74 |
280 | 281 | ||
281 | STAC9205/9254 | 282 | STAC9205/9254 |
@@ -302,6 +303,7 @@ STAC9220/9221 | |||
302 | macbook-pro Intel Mac Book Pro 2nd generation (eq. type 3) | 303 | macbook-pro Intel Mac Book Pro 2nd generation (eq. type 3) |
303 | imac-intel Intel iMac (eq. type 2) | 304 | imac-intel Intel iMac (eq. type 2) |
304 | imac-intel-20 Intel iMac (newer version) (eq. type 3) | 305 | imac-intel-20 Intel iMac (newer version) (eq. type 3) |
306 | ecs202 ECS/PC chips | ||
305 | dell-d81 Dell (unknown) | 307 | dell-d81 Dell (unknown) |
306 | dell-d82 Dell (unknown) | 308 | dell-d82 Dell (unknown) |
307 | dell-m81 Dell (unknown) | 309 | dell-m81 Dell (unknown) |
@@ -310,9 +312,13 @@ STAC9220/9221 | |||
310 | STAC9202/9250/9251 | 312 | STAC9202/9250/9251 |
311 | ================== | 313 | ================== |
312 | ref Reference board, base config | 314 | ref Reference board, base config |
315 | m1 Some Gateway MX series laptops (NX560XL) | ||
316 | m1-2 Some Gateway MX series laptops (MX6453) | ||
317 | m2 Some Gateway MX series laptops (M255) | ||
313 | m2-2 Some Gateway MX series laptops | 318 | m2-2 Some Gateway MX series laptops |
319 | m3 Some Gateway MX series laptops | ||
320 | m5 Some Gateway MX series laptops (MP6954) | ||
314 | m6 Some Gateway NX series laptops | 321 | m6 Some Gateway NX series laptops |
315 | pa6 Gateway NX860 series | ||
316 | 322 | ||
317 | STAC9227/9228/9229/927x | 323 | STAC9227/9228/9229/927x |
318 | ======================= | 324 | ======================= |
@@ -329,6 +335,7 @@ STAC92HD71B* | |||
329 | dell-m4-1 Dell desktops | 335 | dell-m4-1 Dell desktops |
330 | dell-m4-2 Dell desktops | 336 | dell-m4-2 Dell desktops |
331 | dell-m4-3 Dell desktops | 337 | dell-m4-3 Dell desktops |
338 | hp-m4 HP dv laptops | ||
332 | 339 | ||
333 | STAC92HD73* | 340 | STAC92HD73* |
334 | =========== | 341 | =========== |
@@ -337,10 +344,12 @@ STAC92HD73* | |||
337 | dell-m6-amic Dell desktops/laptops with analog mics | 344 | dell-m6-amic Dell desktops/laptops with analog mics |
338 | dell-m6-dmic Dell desktops/laptops with digital mics | 345 | dell-m6-dmic Dell desktops/laptops with digital mics |
339 | dell-m6 Dell desktops/laptops with both type of mics | 346 | dell-m6 Dell desktops/laptops with both type of mics |
347 | dell-eq Dell desktops/laptops | ||
340 | 348 | ||
341 | STAC92HD83* | 349 | STAC92HD83* |
342 | =========== | 350 | =========== |
343 | ref Reference board | 351 | ref Reference board |
352 | mic-ref Reference board with power managment for ports | ||
344 | 353 | ||
345 | STAC9872 | 354 | STAC9872 |
346 | ======== | 355 | ======== |
diff --git a/Documentation/sysctl/vm.txt b/Documentation/sysctl/vm.txt index a3415070bcac..3197fc83bc51 100644 --- a/Documentation/sysctl/vm.txt +++ b/Documentation/sysctl/vm.txt | |||
@@ -1,12 +1,13 @@ | |||
1 | Documentation for /proc/sys/vm/* kernel version 2.2.10 | 1 | Documentation for /proc/sys/vm/* kernel version 2.6.29 |
2 | (c) 1998, 1999, Rik van Riel <riel@nl.linux.org> | 2 | (c) 1998, 1999, Rik van Riel <riel@nl.linux.org> |
3 | (c) 2008 Peter W. Morreale <pmorreale@novell.com> | ||
3 | 4 | ||
4 | For general info and legal blurb, please look in README. | 5 | For general info and legal blurb, please look in README. |
5 | 6 | ||
6 | ============================================================== | 7 | ============================================================== |
7 | 8 | ||
8 | This file contains the documentation for the sysctl files in | 9 | This file contains the documentation for the sysctl files in |
9 | /proc/sys/vm and is valid for Linux kernel version 2.2. | 10 | /proc/sys/vm and is valid for Linux kernel version 2.6.29. |
10 | 11 | ||
11 | The files in this directory can be used to tune the operation | 12 | The files in this directory can be used to tune the operation |
12 | of the virtual memory (VM) subsystem of the Linux kernel and | 13 | of the virtual memory (VM) subsystem of the Linux kernel and |
@@ -16,180 +17,274 @@ Default values and initialization routines for most of these | |||
16 | files can be found in mm/swap.c. | 17 | files can be found in mm/swap.c. |
17 | 18 | ||
18 | Currently, these files are in /proc/sys/vm: | 19 | Currently, these files are in /proc/sys/vm: |
19 | - overcommit_memory | 20 | |
20 | - page-cluster | 21 | - block_dump |
21 | - dirty_ratio | 22 | - dirty_background_bytes |
22 | - dirty_background_ratio | 23 | - dirty_background_ratio |
24 | - dirty_bytes | ||
23 | - dirty_expire_centisecs | 25 | - dirty_expire_centisecs |
26 | - dirty_ratio | ||
24 | - dirty_writeback_centisecs | 27 | - dirty_writeback_centisecs |
25 | - highmem_is_dirtyable (only if CONFIG_HIGHMEM set) | 28 | - drop_caches |
29 | - hugepages_treat_as_movable | ||
30 | - hugetlb_shm_group | ||
31 | - laptop_mode | ||
32 | - legacy_va_layout | ||
33 | - lowmem_reserve_ratio | ||
26 | - max_map_count | 34 | - max_map_count |
27 | - min_free_kbytes | 35 | - min_free_kbytes |
28 | - laptop_mode | ||
29 | - block_dump | ||
30 | - drop-caches | ||
31 | - zone_reclaim_mode | ||
32 | - min_unmapped_ratio | ||
33 | - min_slab_ratio | 36 | - min_slab_ratio |
34 | - panic_on_oom | 37 | - min_unmapped_ratio |
35 | - oom_dump_tasks | 38 | - mmap_min_addr |
36 | - oom_kill_allocating_task | ||
37 | - mmap_min_address | ||
38 | - numa_zonelist_order | ||
39 | - nr_hugepages | 39 | - nr_hugepages |
40 | - nr_overcommit_hugepages | 40 | - nr_overcommit_hugepages |
41 | - nr_trim_pages (only if CONFIG_MMU=n) | 41 | - nr_pdflush_threads |
42 | - nr_trim_pages (only if CONFIG_MMU=n) | ||
43 | - numa_zonelist_order | ||
44 | - oom_dump_tasks | ||
45 | - oom_kill_allocating_task | ||
46 | - overcommit_memory | ||
47 | - overcommit_ratio | ||
48 | - page-cluster | ||
49 | - panic_on_oom | ||
50 | - percpu_pagelist_fraction | ||
51 | - stat_interval | ||
52 | - swappiness | ||
53 | - vfs_cache_pressure | ||
54 | - zone_reclaim_mode | ||
55 | |||
42 | 56 | ||
43 | ============================================================== | 57 | ============================================================== |
44 | 58 | ||
45 | dirty_bytes, dirty_ratio, dirty_background_bytes, | 59 | block_dump |
46 | dirty_background_ratio, dirty_expire_centisecs, | ||
47 | dirty_writeback_centisecs, highmem_is_dirtyable, | ||
48 | vfs_cache_pressure, laptop_mode, block_dump, swap_token_timeout, | ||
49 | drop-caches, hugepages_treat_as_movable: | ||
50 | 60 | ||
51 | See Documentation/filesystems/proc.txt | 61 | block_dump enables block I/O debugging when set to a nonzero value. More |
62 | information on block I/O debugging is in Documentation/laptops/laptop-mode.txt. | ||
52 | 63 | ||
53 | ============================================================== | 64 | ============================================================== |
54 | 65 | ||
55 | overcommit_memory: | 66 | dirty_background_bytes |
56 | 67 | ||
57 | This value contains a flag that enables memory overcommitment. | 68 | Contains the amount of dirty memory at which the pdflush background writeback |
69 | daemon will start writeback. | ||
58 | 70 | ||
59 | When this flag is 0, the kernel attempts to estimate the amount | 71 | If dirty_background_bytes is written, dirty_background_ratio becomes a function |
60 | of free memory left when userspace requests more memory. | 72 | of its value (dirty_background_bytes / the amount of dirtyable system memory). |
61 | 73 | ||
62 | When this flag is 1, the kernel pretends there is always enough | 74 | ============================================================== |
63 | memory until it actually runs out. | ||
64 | 75 | ||
65 | When this flag is 2, the kernel uses a "never overcommit" | 76 | dirty_background_ratio |
66 | policy that attempts to prevent any overcommit of memory. | ||
67 | 77 | ||
68 | This feature can be very useful because there are a lot of | 78 | Contains, as a percentage of total system memory, the number of pages at which |
69 | programs that malloc() huge amounts of memory "just-in-case" | 79 | the pdflush background writeback daemon will start writing out dirty data. |
70 | and don't use much of it. | ||
71 | 80 | ||
72 | The default value is 0. | 81 | ============================================================== |
73 | 82 | ||
74 | See Documentation/vm/overcommit-accounting and | 83 | dirty_bytes |
75 | security/commoncap.c::cap_vm_enough_memory() for more information. | 84 | |
85 | Contains the amount of dirty memory at which a process generating disk writes | ||
86 | will itself start writeback. | ||
87 | |||
88 | If dirty_bytes is written, dirty_ratio becomes a function of its value | ||
89 | (dirty_bytes / the amount of dirtyable system memory). | ||
76 | 90 | ||
77 | ============================================================== | 91 | ============================================================== |
78 | 92 | ||
79 | overcommit_ratio: | 93 | dirty_expire_centisecs |
80 | 94 | ||
81 | When overcommit_memory is set to 2, the committed address | 95 | This tunable is used to define when dirty data is old enough to be eligible |
82 | space is not permitted to exceed swap plus this percentage | 96 | for writeout by the pdflush daemons. It is expressed in 100'ths of a second. |
83 | of physical RAM. See above. | 97 | Data which has been dirty in-memory for longer than this interval will be |
98 | written out next time a pdflush daemon wakes up. | ||
99 | |||
100 | ============================================================== | ||
101 | |||
102 | dirty_ratio | ||
103 | |||
104 | Contains, as a percentage of total system memory, the number of pages at which | ||
105 | a process which is generating disk writes will itself start writing out dirty | ||
106 | data. | ||
84 | 107 | ||
85 | ============================================================== | 108 | ============================================================== |
86 | 109 | ||
87 | page-cluster: | 110 | dirty_writeback_centisecs |
88 | 111 | ||
89 | The Linux VM subsystem avoids excessive disk seeks by reading | 112 | The pdflush writeback daemons will periodically wake up and write `old' data |
90 | multiple pages on a page fault. The number of pages it reads | 113 | out to disk. This tunable expresses the interval between those wakeups, in |
91 | is dependent on the amount of memory in your machine. | 114 | 100'ths of a second. |
92 | 115 | ||
93 | The number of pages the kernel reads in at once is equal to | 116 | Setting this to zero disables periodic writeback altogether. |
94 | 2 ^ page-cluster. Values above 2 ^ 5 don't make much sense | ||
95 | for swap because we only cluster swap data in 32-page groups. | ||
96 | 117 | ||
97 | ============================================================== | 118 | ============================================================== |
98 | 119 | ||
99 | max_map_count: | 120 | drop_caches |
100 | 121 | ||
101 | This file contains the maximum number of memory map areas a process | 122 | Writing to this will cause the kernel to drop clean caches, dentries and |
102 | may have. Memory map areas are used as a side-effect of calling | 123 | inodes from memory, causing that memory to become free. |
103 | malloc, directly by mmap and mprotect, and also when loading shared | ||
104 | libraries. | ||
105 | 124 | ||
106 | While most applications need less than a thousand maps, certain | 125 | To free pagecache: |
107 | programs, particularly malloc debuggers, may consume lots of them, | 126 | echo 1 > /proc/sys/vm/drop_caches |
108 | e.g., up to one or two maps per allocation. | 127 | To free dentries and inodes: |
128 | echo 2 > /proc/sys/vm/drop_caches | ||
129 | To free pagecache, dentries and inodes: | ||
130 | echo 3 > /proc/sys/vm/drop_caches | ||
109 | 131 | ||
110 | The default value is 65536. | 132 | As this is a non-destructive operation and dirty objects are not freeable, the |
133 | user should run `sync' first. | ||
111 | 134 | ||
112 | ============================================================== | 135 | ============================================================== |
113 | 136 | ||
114 | min_free_kbytes: | 137 | hugepages_treat_as_movable |
115 | 138 | ||
116 | This is used to force the Linux VM to keep a minimum number | 139 | This parameter is only useful when kernelcore= is specified at boot time to |
117 | of kilobytes free. The VM uses this number to compute a pages_min | 140 | create ZONE_MOVABLE for pages that may be reclaimed or migrated. Huge pages |
118 | value for each lowmem zone in the system. Each lowmem zone gets | 141 | are not movable so are not normally allocated from ZONE_MOVABLE. A non-zero |
119 | a number of reserved free pages based proportionally on its size. | 142 | value written to hugepages_treat_as_movable allows huge pages to be allocated |
143 | from ZONE_MOVABLE. | ||
120 | 144 | ||
121 | Some minimal amount of memory is needed to satisfy PF_MEMALLOC | 145 | Once enabled, the ZONE_MOVABLE is treated as an area of memory the huge |
122 | allocations; if you set this to lower than 1024KB, your system will | 146 | pages pool can easily grow or shrink within. Assuming that applications are |
123 | become subtly broken, and prone to deadlock under high loads. | 147 | not running that mlock() a lot of memory, it is likely the huge pages pool |
124 | 148 | can grow to the size of ZONE_MOVABLE by repeatedly entering the desired value | |
125 | Setting this too high will OOM your machine instantly. | 149 | into nr_hugepages and triggering page reclaim. |
126 | 150 | ||
127 | ============================================================== | 151 | ============================================================== |
128 | 152 | ||
129 | percpu_pagelist_fraction | 153 | hugetlb_shm_group |
130 | 154 | ||
131 | This is the fraction of pages at most (high mark pcp->high) in each zone that | 155 | hugetlb_shm_group contains group id that is allowed to create SysV |
132 | are allocated for each per cpu page list. The min value for this is 8. It | 156 | shared memory segment using hugetlb page. |
133 | means that we don't allow more than 1/8th of pages in each zone to be | ||
134 | allocated in any single per_cpu_pagelist. This entry only changes the value | ||
135 | of hot per cpu pagelists. User can specify a number like 100 to allocate | ||
136 | 1/100th of each zone to each per cpu page list. | ||
137 | 157 | ||
138 | The batch value of each per cpu pagelist is also updated as a result. It is | 158 | ============================================================== |
139 | set to pcp->high/4. The upper limit of batch is (PAGE_SHIFT * 8) | ||
140 | 159 | ||
141 | The initial value is zero. Kernel does not use this value at boot time to set | 160 | laptop_mode |
142 | the high water marks for each per cpu page list. | ||
143 | 161 | ||
144 | =============================================================== | 162 | laptop_mode is a knob that controls "laptop mode". All the things that are |
163 | controlled by this knob are discussed in Documentation/laptops/laptop-mode.txt. | ||
145 | 164 | ||
146 | zone_reclaim_mode: | 165 | ============================================================== |
147 | 166 | ||
148 | Zone_reclaim_mode allows someone to set more or less aggressive approaches to | 167 | legacy_va_layout |
149 | reclaim memory when a zone runs out of memory. If it is set to zero then no | ||
150 | zone reclaim occurs. Allocations will be satisfied from other zones / nodes | ||
151 | in the system. | ||
152 | 168 | ||
153 | This is value ORed together of | 169 | If non-zero, this sysctl disables the new 32-bit mmap mmap layout - the kernel |
170 | will use the legacy (2.4) layout for all processes. | ||
154 | 171 | ||
155 | 1 = Zone reclaim on | 172 | ============================================================== |
156 | 2 = Zone reclaim writes dirty pages out | ||
157 | 4 = Zone reclaim swaps pages | ||
158 | 173 | ||
159 | zone_reclaim_mode is set during bootup to 1 if it is determined that pages | 174 | lowmem_reserve_ratio |
160 | from remote zones will cause a measurable performance reduction. The | 175 | |
161 | page allocator will then reclaim easily reusable pages (those page | 176 | For some specialised workloads on highmem machines it is dangerous for |
162 | cache pages that are currently not used) before allocating off node pages. | 177 | the kernel to allow process memory to be allocated from the "lowmem" |
178 | zone. This is because that memory could then be pinned via the mlock() | ||
179 | system call, or by unavailability of swapspace. | ||
180 | |||
181 | And on large highmem machines this lack of reclaimable lowmem memory | ||
182 | can be fatal. | ||
183 | |||
184 | So the Linux page allocator has a mechanism which prevents allocations | ||
185 | which _could_ use highmem from using too much lowmem. This means that | ||
186 | a certain amount of lowmem is defended from the possibility of being | ||
187 | captured into pinned user memory. | ||
188 | |||
189 | (The same argument applies to the old 16 megabyte ISA DMA region. This | ||
190 | mechanism will also defend that region from allocations which could use | ||
191 | highmem or lowmem). | ||
192 | |||
193 | The `lowmem_reserve_ratio' tunable determines how aggressive the kernel is | ||
194 | in defending these lower zones. | ||
195 | |||
196 | If you have a machine which uses highmem or ISA DMA and your | ||
197 | applications are using mlock(), or if you are running with no swap then | ||
198 | you probably should change the lowmem_reserve_ratio setting. | ||
199 | |||
200 | The lowmem_reserve_ratio is an array. You can see them by reading this file. | ||
201 | - | ||
202 | % cat /proc/sys/vm/lowmem_reserve_ratio | ||
203 | 256 256 32 | ||
204 | - | ||
205 | Note: # of this elements is one fewer than number of zones. Because the highest | ||
206 | zone's value is not necessary for following calculation. | ||
207 | |||
208 | But, these values are not used directly. The kernel calculates # of protection | ||
209 | pages for each zones from them. These are shown as array of protection pages | ||
210 | in /proc/zoneinfo like followings. (This is an example of x86-64 box). | ||
211 | Each zone has an array of protection pages like this. | ||
212 | |||
213 | - | ||
214 | Node 0, zone DMA | ||
215 | pages free 1355 | ||
216 | min 3 | ||
217 | low 3 | ||
218 | high 4 | ||
219 | : | ||
220 | : | ||
221 | numa_other 0 | ||
222 | protection: (0, 2004, 2004, 2004) | ||
223 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
224 | pagesets | ||
225 | cpu: 0 pcp: 0 | ||
226 | : | ||
227 | - | ||
228 | These protections are added to score to judge whether this zone should be used | ||
229 | for page allocation or should be reclaimed. | ||
230 | |||
231 | In this example, if normal pages (index=2) are required to this DMA zone and | ||
232 | pages_high is used for watermark, the kernel judges this zone should not be | ||
233 | used because pages_free(1355) is smaller than watermark + protection[2] | ||
234 | (4 + 2004 = 2008). If this protection value is 0, this zone would be used for | ||
235 | normal page requirement. If requirement is DMA zone(index=0), protection[0] | ||
236 | (=0) is used. | ||
237 | |||
238 | zone[i]'s protection[j] is calculated by following expression. | ||
239 | |||
240 | (i < j): | ||
241 | zone[i]->protection[j] | ||
242 | = (total sums of present_pages from zone[i+1] to zone[j] on the node) | ||
243 | / lowmem_reserve_ratio[i]; | ||
244 | (i = j): | ||
245 | (should not be protected. = 0; | ||
246 | (i > j): | ||
247 | (not necessary, but looks 0) | ||
248 | |||
249 | The default values of lowmem_reserve_ratio[i] are | ||
250 | 256 (if zone[i] means DMA or DMA32 zone) | ||
251 | 32 (others). | ||
252 | As above expression, they are reciprocal number of ratio. | ||
253 | 256 means 1/256. # of protection pages becomes about "0.39%" of total present | ||
254 | pages of higher zones on the node. | ||
255 | |||
256 | If you would like to protect more pages, smaller values are effective. | ||
257 | The minimum value is 1 (1/1 -> 100%). | ||
163 | 258 | ||
164 | It may be beneficial to switch off zone reclaim if the system is | 259 | ============================================================== |
165 | used for a file server and all of memory should be used for caching files | ||
166 | from disk. In that case the caching effect is more important than | ||
167 | data locality. | ||
168 | 260 | ||
169 | Allowing zone reclaim to write out pages stops processes that are | 261 | max_map_count: |
170 | writing large amounts of data from dirtying pages on other nodes. Zone | ||
171 | reclaim will write out dirty pages if a zone fills up and so effectively | ||
172 | throttle the process. This may decrease the performance of a single process | ||
173 | since it cannot use all of system memory to buffer the outgoing writes | ||
174 | anymore but it preserve the memory on other nodes so that the performance | ||
175 | of other processes running on other nodes will not be affected. | ||
176 | 262 | ||
177 | Allowing regular swap effectively restricts allocations to the local | 263 | This file contains the maximum number of memory map areas a process |
178 | node unless explicitly overridden by memory policies or cpuset | 264 | may have. Memory map areas are used as a side-effect of calling |
179 | configurations. | 265 | malloc, directly by mmap and mprotect, and also when loading shared |
266 | libraries. | ||
180 | 267 | ||
181 | ============================================================= | 268 | While most applications need less than a thousand maps, certain |
269 | programs, particularly malloc debuggers, may consume lots of them, | ||
270 | e.g., up to one or two maps per allocation. | ||
182 | 271 | ||
183 | min_unmapped_ratio: | 272 | The default value is 65536. |
184 | 273 | ||
185 | This is available only on NUMA kernels. | 274 | ============================================================== |
186 | 275 | ||
187 | A percentage of the total pages in each zone. Zone reclaim will only | 276 | min_free_kbytes: |
188 | occur if more than this percentage of pages are file backed and unmapped. | ||
189 | This is to insure that a minimal amount of local pages is still available for | ||
190 | file I/O even if the node is overallocated. | ||
191 | 277 | ||
192 | The default is 1 percent. | 278 | This is used to force the Linux VM to keep a minimum number |
279 | of kilobytes free. The VM uses this number to compute a pages_min | ||
280 | value for each lowmem zone in the system. Each lowmem zone gets | ||
281 | a number of reserved free pages based proportionally on its size. | ||
282 | |||
283 | Some minimal amount of memory is needed to satisfy PF_MEMALLOC | ||
284 | allocations; if you set this to lower than 1024KB, your system will | ||
285 | become subtly broken, and prone to deadlock under high loads. | ||
286 | |||
287 | Setting this too high will OOM your machine instantly. | ||
193 | 288 | ||
194 | ============================================================= | 289 | ============================================================= |
195 | 290 | ||
@@ -211,82 +306,73 @@ and may not be fast. | |||
211 | 306 | ||
212 | ============================================================= | 307 | ============================================================= |
213 | 308 | ||
214 | panic_on_oom | 309 | min_unmapped_ratio: |
215 | 310 | ||
216 | This enables or disables panic on out-of-memory feature. | 311 | This is available only on NUMA kernels. |
217 | 312 | ||
218 | If this is set to 0, the kernel will kill some rogue process, | 313 | A percentage of the total pages in each zone. Zone reclaim will only |
219 | called oom_killer. Usually, oom_killer can kill rogue processes and | 314 | occur if more than this percentage of pages are file backed and unmapped. |
220 | system will survive. | 315 | This is to insure that a minimal amount of local pages is still available for |
316 | file I/O even if the node is overallocated. | ||
221 | 317 | ||
222 | If this is set to 1, the kernel panics when out-of-memory happens. | 318 | The default is 1 percent. |
223 | However, if a process limits using nodes by mempolicy/cpusets, | ||
224 | and those nodes become memory exhaustion status, one process | ||
225 | may be killed by oom-killer. No panic occurs in this case. | ||
226 | Because other nodes' memory may be free. This means system total status | ||
227 | may be not fatal yet. | ||
228 | 319 | ||
229 | If this is set to 2, the kernel panics compulsorily even on the | 320 | ============================================================== |
230 | above-mentioned. | ||
231 | 321 | ||
232 | The default value is 0. | 322 | mmap_min_addr |
233 | 1 and 2 are for failover of clustering. Please select either | ||
234 | according to your policy of failover. | ||
235 | 323 | ||
236 | ============================================================= | 324 | This file indicates the amount of address space which a user process will |
325 | be restricted from mmaping. Since kernel null dereference bugs could | ||
326 | accidentally operate based on the information in the first couple of pages | ||
327 | of memory userspace processes should not be allowed to write to them. By | ||
328 | default this value is set to 0 and no protections will be enforced by the | ||
329 | security module. Setting this value to something like 64k will allow the | ||
330 | vast majority of applications to work correctly and provide defense in depth | ||
331 | against future potential kernel bugs. | ||
237 | 332 | ||
238 | oom_dump_tasks | 333 | ============================================================== |
239 | 334 | ||
240 | Enables a system-wide task dump (excluding kernel threads) to be | 335 | nr_hugepages |
241 | produced when the kernel performs an OOM-killing and includes such | ||
242 | information as pid, uid, tgid, vm size, rss, cpu, oom_adj score, and | ||
243 | name. This is helpful to determine why the OOM killer was invoked | ||
244 | and to identify the rogue task that caused it. | ||
245 | 336 | ||
246 | If this is set to zero, this information is suppressed. On very | 337 | Change the minimum size of the hugepage pool. |
247 | large systems with thousands of tasks it may not be feasible to dump | ||
248 | the memory state information for each one. Such systems should not | ||
249 | be forced to incur a performance penalty in OOM conditions when the | ||
250 | information may not be desired. | ||
251 | 338 | ||
252 | If this is set to non-zero, this information is shown whenever the | 339 | See Documentation/vm/hugetlbpage.txt |
253 | OOM killer actually kills a memory-hogging task. | ||
254 | 340 | ||
255 | The default value is 0. | 341 | ============================================================== |
256 | 342 | ||
257 | ============================================================= | 343 | nr_overcommit_hugepages |
258 | 344 | ||
259 | oom_kill_allocating_task | 345 | Change the maximum size of the hugepage pool. The maximum is |
346 | nr_hugepages + nr_overcommit_hugepages. | ||
260 | 347 | ||
261 | This enables or disables killing the OOM-triggering task in | 348 | See Documentation/vm/hugetlbpage.txt |
262 | out-of-memory situations. | ||
263 | 349 | ||
264 | If this is set to zero, the OOM killer will scan through the entire | 350 | ============================================================== |
265 | tasklist and select a task based on heuristics to kill. This normally | ||
266 | selects a rogue memory-hogging task that frees up a large amount of | ||
267 | memory when killed. | ||
268 | 351 | ||
269 | If this is set to non-zero, the OOM killer simply kills the task that | 352 | nr_pdflush_threads |
270 | triggered the out-of-memory condition. This avoids the expensive | ||
271 | tasklist scan. | ||
272 | 353 | ||
273 | If panic_on_oom is selected, it takes precedence over whatever value | 354 | The current number of pdflush threads. This value is read-only. |
274 | is used in oom_kill_allocating_task. | 355 | The value changes according to the number of dirty pages in the system. |
275 | 356 | ||
276 | The default value is 0. | 357 | When neccessary, additional pdflush threads are created, one per second, up to |
358 | nr_pdflush_threads_max. | ||
277 | 359 | ||
278 | ============================================================== | 360 | ============================================================== |
279 | 361 | ||
280 | mmap_min_addr | 362 | nr_trim_pages |
281 | 363 | ||
282 | This file indicates the amount of address space which a user process will | 364 | This is available only on NOMMU kernels. |
283 | be restricted from mmaping. Since kernel null dereference bugs could | 365 | |
284 | accidentally operate based on the information in the first couple of pages | 366 | This value adjusts the excess page trimming behaviour of power-of-2 aligned |
285 | of memory userspace processes should not be allowed to write to them. By | 367 | NOMMU mmap allocations. |
286 | default this value is set to 0 and no protections will be enforced by the | 368 | |
287 | security module. Setting this value to something like 64k will allow the | 369 | A value of 0 disables trimming of allocations entirely, while a value of 1 |
288 | vast majority of applications to work correctly and provide defense in depth | 370 | trims excess pages aggressively. Any value >= 1 acts as the watermark where |
289 | against future potential kernel bugs. | 371 | trimming of allocations is initiated. |
372 | |||
373 | The default value is 1. | ||
374 | |||
375 | See Documentation/nommu-mmap.txt for more information. | ||
290 | 376 | ||
291 | ============================================================== | 377 | ============================================================== |
292 | 378 | ||
@@ -335,34 +421,199 @@ this is causing problems for your system/application. | |||
335 | 421 | ||
336 | ============================================================== | 422 | ============================================================== |
337 | 423 | ||
338 | nr_hugepages | 424 | oom_dump_tasks |
339 | 425 | ||
340 | Change the minimum size of the hugepage pool. | 426 | Enables a system-wide task dump (excluding kernel threads) to be |
427 | produced when the kernel performs an OOM-killing and includes such | ||
428 | information as pid, uid, tgid, vm size, rss, cpu, oom_adj score, and | ||
429 | name. This is helpful to determine why the OOM killer was invoked | ||
430 | and to identify the rogue task that caused it. | ||
341 | 431 | ||
342 | See Documentation/vm/hugetlbpage.txt | 432 | If this is set to zero, this information is suppressed. On very |
433 | large systems with thousands of tasks it may not be feasible to dump | ||
434 | the memory state information for each one. Such systems should not | ||
435 | be forced to incur a performance penalty in OOM conditions when the | ||
436 | information may not be desired. | ||
437 | |||
438 | If this is set to non-zero, this information is shown whenever the | ||
439 | OOM killer actually kills a memory-hogging task. | ||
440 | |||
441 | The default value is 0. | ||
343 | 442 | ||
344 | ============================================================== | 443 | ============================================================== |
345 | 444 | ||
346 | nr_overcommit_hugepages | 445 | oom_kill_allocating_task |
347 | 446 | ||
348 | Change the maximum size of the hugepage pool. The maximum is | 447 | This enables or disables killing the OOM-triggering task in |
349 | nr_hugepages + nr_overcommit_hugepages. | 448 | out-of-memory situations. |
350 | 449 | ||
351 | See Documentation/vm/hugetlbpage.txt | 450 | If this is set to zero, the OOM killer will scan through the entire |
451 | tasklist and select a task based on heuristics to kill. This normally | ||
452 | selects a rogue memory-hogging task that frees up a large amount of | ||
453 | memory when killed. | ||
454 | |||
455 | If this is set to non-zero, the OOM killer simply kills the task that | ||
456 | triggered the out-of-memory condition. This avoids the expensive | ||
457 | tasklist scan. | ||
458 | |||
459 | If panic_on_oom is selected, it takes precedence over whatever value | ||
460 | is used in oom_kill_allocating_task. | ||
461 | |||
462 | The default value is 0. | ||
352 | 463 | ||
353 | ============================================================== | 464 | ============================================================== |
354 | 465 | ||
355 | nr_trim_pages | 466 | overcommit_memory: |
356 | 467 | ||
357 | This is available only on NOMMU kernels. | 468 | This value contains a flag that enables memory overcommitment. |
358 | 469 | ||
359 | This value adjusts the excess page trimming behaviour of power-of-2 aligned | 470 | When this flag is 0, the kernel attempts to estimate the amount |
360 | NOMMU mmap allocations. | 471 | of free memory left when userspace requests more memory. |
361 | 472 | ||
362 | A value of 0 disables trimming of allocations entirely, while a value of 1 | 473 | When this flag is 1, the kernel pretends there is always enough |
363 | trims excess pages aggressively. Any value >= 1 acts as the watermark where | 474 | memory until it actually runs out. |
364 | trimming of allocations is initiated. | ||
365 | 475 | ||
366 | The default value is 1. | 476 | When this flag is 2, the kernel uses a "never overcommit" |
477 | policy that attempts to prevent any overcommit of memory. | ||
367 | 478 | ||
368 | See Documentation/nommu-mmap.txt for more information. | 479 | This feature can be very useful because there are a lot of |
480 | programs that malloc() huge amounts of memory "just-in-case" | ||
481 | and don't use much of it. | ||
482 | |||
483 | The default value is 0. | ||
484 | |||
485 | See Documentation/vm/overcommit-accounting and | ||
486 | security/commoncap.c::cap_vm_enough_memory() for more information. | ||
487 | |||
488 | ============================================================== | ||
489 | |||
490 | overcommit_ratio: | ||
491 | |||
492 | When overcommit_memory is set to 2, the committed address | ||
493 | space is not permitted to exceed swap plus this percentage | ||
494 | of physical RAM. See above. | ||
495 | |||
496 | ============================================================== | ||
497 | |||
498 | page-cluster | ||
499 | |||
500 | page-cluster controls the number of pages which are written to swap in | ||
501 | a single attempt. The swap I/O size. | ||
502 | |||
503 | It is a logarithmic value - setting it to zero means "1 page", setting | ||
504 | it to 1 means "2 pages", setting it to 2 means "4 pages", etc. | ||
505 | |||
506 | The default value is three (eight pages at a time). There may be some | ||
507 | small benefits in tuning this to a different value if your workload is | ||
508 | swap-intensive. | ||
509 | |||
510 | ============================================================= | ||
511 | |||
512 | panic_on_oom | ||
513 | |||
514 | This enables or disables panic on out-of-memory feature. | ||
515 | |||
516 | If this is set to 0, the kernel will kill some rogue process, | ||
517 | called oom_killer. Usually, oom_killer can kill rogue processes and | ||
518 | system will survive. | ||
519 | |||
520 | If this is set to 1, the kernel panics when out-of-memory happens. | ||
521 | However, if a process limits using nodes by mempolicy/cpusets, | ||
522 | and those nodes become memory exhaustion status, one process | ||
523 | may be killed by oom-killer. No panic occurs in this case. | ||
524 | Because other nodes' memory may be free. This means system total status | ||
525 | may be not fatal yet. | ||
526 | |||
527 | If this is set to 2, the kernel panics compulsorily even on the | ||
528 | above-mentioned. | ||
529 | |||
530 | The default value is 0. | ||
531 | 1 and 2 are for failover of clustering. Please select either | ||
532 | according to your policy of failover. | ||
533 | |||
534 | ============================================================= | ||
535 | |||
536 | percpu_pagelist_fraction | ||
537 | |||
538 | This is the fraction of pages at most (high mark pcp->high) in each zone that | ||
539 | are allocated for each per cpu page list. The min value for this is 8. It | ||
540 | means that we don't allow more than 1/8th of pages in each zone to be | ||
541 | allocated in any single per_cpu_pagelist. This entry only changes the value | ||
542 | of hot per cpu pagelists. User can specify a number like 100 to allocate | ||
543 | 1/100th of each zone to each per cpu page list. | ||
544 | |||
545 | The batch value of each per cpu pagelist is also updated as a result. It is | ||
546 | set to pcp->high/4. The upper limit of batch is (PAGE_SHIFT * 8) | ||
547 | |||
548 | The initial value is zero. Kernel does not use this value at boot time to set | ||
549 | the high water marks for each per cpu page list. | ||
550 | |||
551 | ============================================================== | ||
552 | |||
553 | stat_interval | ||
554 | |||
555 | The time interval between which vm statistics are updated. The default | ||
556 | is 1 second. | ||
557 | |||
558 | ============================================================== | ||
559 | |||
560 | swappiness | ||
561 | |||
562 | This control is used to define how aggressive the kernel will swap | ||
563 | memory pages. Higher values will increase agressiveness, lower values | ||
564 | descrease the amount of swap. | ||
565 | |||
566 | The default value is 60. | ||
567 | |||
568 | ============================================================== | ||
569 | |||
570 | vfs_cache_pressure | ||
571 | ------------------ | ||
572 | |||
573 | Controls the tendency of the kernel to reclaim the memory which is used for | ||
574 | caching of directory and inode objects. | ||
575 | |||
576 | At the default value of vfs_cache_pressure=100 the kernel will attempt to | ||
577 | reclaim dentries and inodes at a "fair" rate with respect to pagecache and | ||
578 | swapcache reclaim. Decreasing vfs_cache_pressure causes the kernel to prefer | ||
579 | to retain dentry and inode caches. Increasing vfs_cache_pressure beyond 100 | ||
580 | causes the kernel to prefer to reclaim dentries and inodes. | ||
581 | |||
582 | ============================================================== | ||
583 | |||
584 | zone_reclaim_mode: | ||
585 | |||
586 | Zone_reclaim_mode allows someone to set more or less aggressive approaches to | ||
587 | reclaim memory when a zone runs out of memory. If it is set to zero then no | ||
588 | zone reclaim occurs. Allocations will be satisfied from other zones / nodes | ||
589 | in the system. | ||
590 | |||
591 | This is value ORed together of | ||
592 | |||
593 | 1 = Zone reclaim on | ||
594 | 2 = Zone reclaim writes dirty pages out | ||
595 | 4 = Zone reclaim swaps pages | ||
596 | |||
597 | zone_reclaim_mode is set during bootup to 1 if it is determined that pages | ||
598 | from remote zones will cause a measurable performance reduction. The | ||
599 | page allocator will then reclaim easily reusable pages (those page | ||
600 | cache pages that are currently not used) before allocating off node pages. | ||
601 | |||
602 | It may be beneficial to switch off zone reclaim if the system is | ||
603 | used for a file server and all of memory should be used for caching files | ||
604 | from disk. In that case the caching effect is more important than | ||
605 | data locality. | ||
606 | |||
607 | Allowing zone reclaim to write out pages stops processes that are | ||
608 | writing large amounts of data from dirtying pages on other nodes. Zone | ||
609 | reclaim will write out dirty pages if a zone fills up and so effectively | ||
610 | throttle the process. This may decrease the performance of a single process | ||
611 | since it cannot use all of system memory to buffer the outgoing writes | ||
612 | anymore but it preserve the memory on other nodes so that the performance | ||
613 | of other processes running on other nodes will not be affected. | ||
614 | |||
615 | Allowing regular swap effectively restricts allocations to the local | ||
616 | node unless explicitly overridden by memory policies or cpuset | ||
617 | configurations. | ||
618 | |||
619 | ============ End of Document ================================= | ||
diff --git a/Documentation/sysrq.txt b/Documentation/sysrq.txt index 10a0263ebb3f..9e592c718afb 100644 --- a/Documentation/sysrq.txt +++ b/Documentation/sysrq.txt | |||
@@ -1,6 +1,5 @@ | |||
1 | Linux Magic System Request Key Hacks | 1 | Linux Magic System Request Key Hacks |
2 | Documentation for sysrq.c | 2 | Documentation for sysrq.c |
3 | Last update: 2007-AUG-04 | ||
4 | 3 | ||
5 | * What is the magic SysRq key? | 4 | * What is the magic SysRq key? |
6 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 5 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
@@ -211,6 +210,24 @@ within a function called by handle_sysrq, you must be aware that you are in | |||
211 | a lock (you are also in an interrupt handler, which means don't sleep!), so | 210 | a lock (you are also in an interrupt handler, which means don't sleep!), so |
212 | you must call __handle_sysrq_nolock instead. | 211 | you must call __handle_sysrq_nolock instead. |
213 | 212 | ||
213 | * When I hit a SysRq key combination only the header appears on the console? | ||
214 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
215 | Sysrq output is subject to the same console loglevel control as all | ||
216 | other console output. This means that if the kernel was booted 'quiet' | ||
217 | as is common on distro kernels the output may not appear on the actual | ||
218 | console, even though it will appear in the dmesg buffer, and be accessible | ||
219 | via the dmesg command and to the consumers of /proc/kmsg. As a specific | ||
220 | exception the header line from the sysrq command is passed to all console | ||
221 | consumers as if the current loglevel was maximum. If only the header | ||
222 | is emitted it is almost certain that the kernel loglevel is too low. | ||
223 | Should you require the output on the console channel then you will need | ||
224 | to temporarily up the console loglevel using alt-sysrq-8 or: | ||
225 | |||
226 | echo 8 > /proc/sysrq-trigger | ||
227 | |||
228 | Remember to return the loglevel to normal after triggering the sysrq | ||
229 | command you are interested in. | ||
230 | |||
214 | * I have more questions, who can I ask? | 231 | * I have more questions, who can I ask? |
215 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | 232 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
216 | And I'll answer any questions about the registration system you got, also | 233 | And I'll answer any questions about the registration system you got, also |
diff --git a/Documentation/tracers/mmiotrace.txt b/Documentation/tracers/mmiotrace.txt index cde23b4a12a1..5731c67abc55 100644 --- a/Documentation/tracers/mmiotrace.txt +++ b/Documentation/tracers/mmiotrace.txt | |||
@@ -78,12 +78,10 @@ to view your kernel log and look for "mmiotrace has lost events" warning. If | |||
78 | events were lost, the trace is incomplete. You should enlarge the buffers and | 78 | events were lost, the trace is incomplete. You should enlarge the buffers and |
79 | try again. Buffers are enlarged by first seeing how large the current buffers | 79 | try again. Buffers are enlarged by first seeing how large the current buffers |
80 | are: | 80 | are: |
81 | $ cat /debug/tracing/trace_entries | 81 | $ cat /debug/tracing/buffer_size_kb |
82 | gives you a number. Approximately double this number and write it back, for | 82 | gives you a number. Approximately double this number and write it back, for |
83 | instance: | 83 | instance: |
84 | $ echo 0 > /debug/tracing/tracing_enabled | 84 | $ echo 128000 > /debug/tracing/buffer_size_kb |
85 | $ echo 128000 > /debug/tracing/trace_entries | ||
86 | $ echo 1 > /debug/tracing/tracing_enabled | ||
87 | Then start again from the top. | 85 | Then start again from the top. |
88 | 86 | ||
89 | If you are doing a trace for a driver project, e.g. Nouveau, you should also | 87 | If you are doing a trace for a driver project, e.g. Nouveau, you should also |
diff --git a/Documentation/usb/dma.txt b/Documentation/usb/dma.txt index e8b50b7de9d9..cfdcd16e3abf 100644 --- a/Documentation/usb/dma.txt +++ b/Documentation/usb/dma.txt | |||
@@ -6,8 +6,9 @@ in the kernel usb programming guide (kerneldoc, from the source code). | |||
6 | API OVERVIEW | 6 | API OVERVIEW |
7 | 7 | ||
8 | The big picture is that USB drivers can continue to ignore most DMA issues, | 8 | The big picture is that USB drivers can continue to ignore most DMA issues, |
9 | though they still must provide DMA-ready buffers (see DMA-mapping.txt). | 9 | though they still must provide DMA-ready buffers (see |
10 | That's how they've worked through the 2.4 (and earlier) kernels. | 10 | Documentation/PCI/PCI-DMA-mapping.txt). That's how they've worked through |
11 | the 2.4 (and earlier) kernels. | ||
11 | 12 | ||
12 | OR: they can now be DMA-aware. | 13 | OR: they can now be DMA-aware. |
13 | 14 | ||
@@ -62,8 +63,8 @@ and effects like cache-trashing can impose subtle penalties. | |||
62 | force a consistent memory access ordering by using memory barriers. It's | 63 | force a consistent memory access ordering by using memory barriers. It's |
63 | not using a streaming DMA mapping, so it's good for small transfers on | 64 | not using a streaming DMA mapping, so it's good for small transfers on |
64 | systems where the I/O would otherwise thrash an IOMMU mapping. (See | 65 | systems where the I/O would otherwise thrash an IOMMU mapping. (See |
65 | Documentation/DMA-mapping.txt for definitions of "coherent" and "streaming" | 66 | Documentation/PCI/PCI-DMA-mapping.txt for definitions of "coherent" and |
66 | DMA mappings.) | 67 | "streaming" DMA mappings.) |
67 | 68 | ||
68 | Asking for 1/Nth of a page (as well as asking for N pages) is reasonably | 69 | Asking for 1/Nth of a page (as well as asking for N pages) is reasonably |
69 | space-efficient. | 70 | space-efficient. |
@@ -93,7 +94,7 @@ WORKING WITH EXISTING BUFFERS | |||
93 | Existing buffers aren't usable for DMA without first being mapped into the | 94 | Existing buffers aren't usable for DMA without first being mapped into the |
94 | DMA address space of the device. However, most buffers passed to your | 95 | DMA address space of the device. However, most buffers passed to your |
95 | driver can safely be used with such DMA mapping. (See the first section | 96 | driver can safely be used with such DMA mapping. (See the first section |
96 | of DMA-mapping.txt, titled "What memory is DMA-able?") | 97 | of Documentation/PCI/PCI-DMA-mapping.txt, titled "What memory is DMA-able?") |
97 | 98 | ||
98 | - When you're using scatterlists, you can map everything at once. On some | 99 | - When you're using scatterlists, you can map everything at once. On some |
99 | systems, this kicks in an IOMMU and turns the scatterlists into single | 100 | systems, this kicks in an IOMMU and turns the scatterlists into single |
diff --git a/Documentation/video4linux/v4lgrab.c b/Documentation/video4linux/v4lgrab.c index 079b628481cf..d6e70bef8ad0 100644 --- a/Documentation/video4linux/v4lgrab.c +++ b/Documentation/video4linux/v4lgrab.c | |||
@@ -4,12 +4,21 @@ | |||
4 | * | 4 | * |
5 | * Compile with: | 5 | * Compile with: |
6 | * gcc -s -Wall -Wstrict-prototypes v4lgrab.c -o v4lgrab | 6 | * gcc -s -Wall -Wstrict-prototypes v4lgrab.c -o v4lgrab |
7 | * Use as: | 7 | * Use as: |
8 | * v4lgrab >image.ppm | 8 | * v4lgrab >image.ppm |
9 | * | 9 | * |
10 | * Copyright (C) 1998-05-03, Phil Blundell <philb@gnu.org> | 10 | * Copyright (C) 1998-05-03, Phil Blundell <philb@gnu.org> |
11 | * Copied from http://www.tazenda.demon.co.uk/phil/vgrabber.c | 11 | * Copied from http://www.tazenda.demon.co.uk/phil/vgrabber.c |
12 | * with minor modifications (Dave Forrest, drf5n@virginia.edu). | 12 | * with minor modifications (Dave Forrest, drf5n@virginia.edu). |
13 | * | ||
14 | * | ||
15 | * For some cameras you may need to pre-load libv4l to perform | ||
16 | * the necessary decompression, e.g.: | ||
17 | * | ||
18 | * export LD_PRELOAD=/usr/lib/libv4l/v4l1compat.so | ||
19 | * ./v4lgrab >image.ppm | ||
20 | * | ||
21 | * see http://hansdegoede.livejournal.com/3636.html for details. | ||
13 | * | 22 | * |
14 | */ | 23 | */ |
15 | 24 | ||
@@ -24,7 +33,7 @@ | |||
24 | #include <linux/types.h> | 33 | #include <linux/types.h> |
25 | #include <linux/videodev.h> | 34 | #include <linux/videodev.h> |
26 | 35 | ||
27 | #define FILE "/dev/video0" | 36 | #define VIDEO_DEV "/dev/video0" |
28 | 37 | ||
29 | /* Stole this from tvset.c */ | 38 | /* Stole this from tvset.c */ |
30 | 39 | ||
@@ -90,7 +99,7 @@ int get_brightness_adj(unsigned char *image, long size, int *brightness) { | |||
90 | 99 | ||
91 | int main(int argc, char ** argv) | 100 | int main(int argc, char ** argv) |
92 | { | 101 | { |
93 | int fd = open(FILE, O_RDONLY), f; | 102 | int fd = open(VIDEO_DEV, O_RDONLY), f; |
94 | struct video_capability cap; | 103 | struct video_capability cap; |
95 | struct video_window win; | 104 | struct video_window win; |
96 | struct video_picture vpic; | 105 | struct video_picture vpic; |
@@ -100,13 +109,13 @@ int main(int argc, char ** argv) | |||
100 | unsigned int i, src_depth; | 109 | unsigned int i, src_depth; |
101 | 110 | ||
102 | if (fd < 0) { | 111 | if (fd < 0) { |
103 | perror(FILE); | 112 | perror(VIDEO_DEV); |
104 | exit(1); | 113 | exit(1); |
105 | } | 114 | } |
106 | 115 | ||
107 | if (ioctl(fd, VIDIOCGCAP, &cap) < 0) { | 116 | if (ioctl(fd, VIDIOCGCAP, &cap) < 0) { |
108 | perror("VIDIOGCAP"); | 117 | perror("VIDIOGCAP"); |
109 | fprintf(stderr, "(" FILE " not a video4linux device?)\n"); | 118 | fprintf(stderr, "(" VIDEO_DEV " not a video4linux device?)\n"); |
110 | close(fd); | 119 | close(fd); |
111 | exit(1); | 120 | exit(1); |
112 | } | 121 | } |