diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2011-03-17 15:46:58 -0400 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2011-03-17 15:48:06 -0400 |
commit | 2dd22997679a88874c131f6e6ffb963e6d43b3a6 (patch) | |
tree | bfe1707dda7e755b8b550c6796e2649813bcfbb9 /Documentation | |
parent | 36885ff0e6563687e6152da6d311abbf83c0198f (diff) | |
parent | 7b7adc4a016a1decb806eb71ecab98721fa7f146 (diff) |
Merge remote-tracking branch 'origin' into spi/next
Pull in Linus' tree to pick up changes required for the langwell gpio fixes
Diffstat (limited to 'Documentation')
64 files changed, 1610 insertions, 765 deletions
diff --git a/Documentation/00-INDEX b/Documentation/00-INDEX index 8dfc6708a257..f607367e642f 100644 --- a/Documentation/00-INDEX +++ b/Documentation/00-INDEX | |||
@@ -328,8 +328,6 @@ sysrq.txt | |||
328 | - info on the magic SysRq key. | 328 | - info on the magic SysRq key. |
329 | telephony/ | 329 | telephony/ |
330 | - directory with info on telephony (e.g. voice over IP) support. | 330 | - directory with info on telephony (e.g. voice over IP) support. |
331 | time_interpolators.txt | ||
332 | - info on time interpolators. | ||
333 | uml/ | 331 | uml/ |
334 | - directory with information about User Mode Linux. | 332 | - directory with information about User Mode Linux. |
335 | unicode.txt | 333 | unicode.txt |
@@ -346,8 +344,6 @@ vm/ | |||
346 | - directory with info on the Linux vm code. | 344 | - directory with info on the Linux vm code. |
347 | volatile-considered-harmful.txt | 345 | volatile-considered-harmful.txt |
348 | - Why the "volatile" type class should not be used | 346 | - Why the "volatile" type class should not be used |
349 | voyager.txt | ||
350 | - guide to running Linux on the Voyager architecture. | ||
351 | w1/ | 347 | w1/ |
352 | - directory with documents regarding the 1-wire (w1) subsystem. | 348 | - directory with documents regarding the 1-wire (w1) subsystem. |
353 | watchdog/ | 349 | watchdog/ |
diff --git a/Documentation/ABI/stable/sysfs-firmware-efi-vars b/Documentation/ABI/stable/sysfs-firmware-efi-vars new file mode 100644 index 000000000000..5def20b9019e --- /dev/null +++ b/Documentation/ABI/stable/sysfs-firmware-efi-vars | |||
@@ -0,0 +1,75 @@ | |||
1 | What: /sys/firmware/efi/vars | ||
2 | Date: April 2004 | ||
3 | Contact: Matt Domsch <Matt_Domsch@dell.com> | ||
4 | Description: | ||
5 | This directory exposes interfaces for interactive with | ||
6 | EFI variables. For more information on EFI variables, | ||
7 | see 'Variable Services' in the UEFI specification | ||
8 | (section 7.2 in specification version 2.3 Errata D). | ||
9 | |||
10 | In summary, EFI variables are named, and are classified | ||
11 | into separate namespaces through the use of a vendor | ||
12 | GUID. They also have an arbitrary binary value | ||
13 | associated with them. | ||
14 | |||
15 | The efivars module enumerates these variables and | ||
16 | creates a separate directory for each one found. Each | ||
17 | directory has a name of the form "<key>-<vendor guid>" | ||
18 | and contains the following files: | ||
19 | |||
20 | attributes: A read-only text file enumerating the | ||
21 | EFI variable flags. Potential values | ||
22 | include: | ||
23 | |||
24 | EFI_VARIABLE_NON_VOLATILE | ||
25 | EFI_VARIABLE_BOOTSERVICE_ACCESS | ||
26 | EFI_VARIABLE_RUNTIME_ACCESS | ||
27 | EFI_VARIABLE_HARDWARE_ERROR_RECORD | ||
28 | EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS | ||
29 | |||
30 | See the EFI documentation for an | ||
31 | explanation of each of these variables. | ||
32 | |||
33 | data: A read-only binary file that can be read | ||
34 | to attain the value of the EFI variable | ||
35 | |||
36 | guid: The vendor GUID of the variable. This | ||
37 | should always match the GUID in the | ||
38 | variable's name. | ||
39 | |||
40 | raw_var: A binary file that can be read to obtain | ||
41 | a structure that contains everything | ||
42 | there is to know about the variable. | ||
43 | For structure definition see "struct | ||
44 | efi_variable" in the kernel sources. | ||
45 | |||
46 | This file can also be written to in | ||
47 | order to update the value of a variable. | ||
48 | For this to work however, all fields of | ||
49 | the "struct efi_variable" passed must | ||
50 | match byte for byte with the structure | ||
51 | read out of the file, save for the value | ||
52 | portion. | ||
53 | |||
54 | **Note** the efi_variable structure | ||
55 | read/written with this file contains a | ||
56 | 'long' type that may change widths | ||
57 | depending on your underlying | ||
58 | architecture. | ||
59 | |||
60 | size: As ASCII representation of the size of | ||
61 | the variable's value. | ||
62 | |||
63 | |||
64 | In addition, two other magic binary files are provided | ||
65 | in the top-level directory and are used for adding and | ||
66 | removing variables: | ||
67 | |||
68 | new_var: Takes a "struct efi_variable" and | ||
69 | instructs the EFI firmware to create a | ||
70 | new variable. | ||
71 | |||
72 | del_var: Takes a "struct efi_variable" and | ||
73 | instructs the EFI firmware to remove any | ||
74 | variable that has a matching vendor GUID | ||
75 | and variable key name. | ||
diff --git a/Documentation/ABI/testing/pstore b/Documentation/ABI/testing/pstore new file mode 100644 index 000000000000..f1fb2a004264 --- /dev/null +++ b/Documentation/ABI/testing/pstore | |||
@@ -0,0 +1,35 @@ | |||
1 | Where: /dev/pstore/... | ||
2 | Date: January 2011 | ||
3 | Kernel Version: 2.6.38 | ||
4 | Contact: tony.luck@intel.com | ||
5 | Description: Generic interface to platform dependent persistent storage. | ||
6 | |||
7 | Platforms that provide a mechanism to preserve some data | ||
8 | across system reboots can register with this driver to | ||
9 | provide a generic interface to show records captured in | ||
10 | the dying moments. In the case of a panic the last part | ||
11 | of the console log is captured, but other interesting | ||
12 | data can also be saved. | ||
13 | |||
14 | # mount -t pstore - /dev/pstore | ||
15 | |||
16 | $ ls -l /dev/pstore | ||
17 | total 0 | ||
18 | -r--r--r-- 1 root root 7896 Nov 30 15:38 dmesg-erst-1 | ||
19 | |||
20 | Different users of this interface will result in different | ||
21 | filename prefixes. Currently two are defined: | ||
22 | |||
23 | "dmesg" - saved console log | ||
24 | "mce" - architecture dependent data from fatal h/w error | ||
25 | |||
26 | Once the information in a file has been read, removing | ||
27 | the file will signal to the underlying persistent storage | ||
28 | device that it can reclaim the space for later re-use. | ||
29 | |||
30 | $ rm /dev/pstore/dmesg-erst-1 | ||
31 | |||
32 | The expectation is that all files in /dev/pstore | ||
33 | will be saved elsewhere and erased from persistent store | ||
34 | soon after boot to free up space ready for the next | ||
35 | catastrophe. | ||
diff --git a/Documentation/ABI/testing/sysfs-devices-power b/Documentation/ABI/testing/sysfs-devices-power index 7628cd1bc36a..8ffbc25376a0 100644 --- a/Documentation/ABI/testing/sysfs-devices-power +++ b/Documentation/ABI/testing/sysfs-devices-power | |||
@@ -29,9 +29,8 @@ Description: | |||
29 | "disabled" to it. | 29 | "disabled" to it. |
30 | 30 | ||
31 | For the devices that are not capable of generating system wakeup | 31 | For the devices that are not capable of generating system wakeup |
32 | events this file contains "\n". In that cases the user space | 32 | events this file is not present. In that case the device cannot |
33 | cannot modify the contents of this file and the device cannot be | 33 | be enabled to wake up the system from sleep states. |
34 | enabled to wake up the system. | ||
35 | 34 | ||
36 | What: /sys/devices/.../power/control | 35 | What: /sys/devices/.../power/control |
37 | Date: January 2009 | 36 | Date: January 2009 |
@@ -85,7 +84,7 @@ Description: | |||
85 | The /sys/devices/.../wakeup_count attribute contains the number | 84 | The /sys/devices/.../wakeup_count attribute contains the number |
86 | of signaled wakeup events associated with the device. This | 85 | of signaled wakeup events associated with the device. This |
87 | attribute is read-only. If the device is not enabled to wake up | 86 | attribute is read-only. If the device is not enabled to wake up |
88 | the system from sleep states, this attribute is empty. | 87 | the system from sleep states, this attribute is not present. |
89 | 88 | ||
90 | What: /sys/devices/.../power/wakeup_active_count | 89 | What: /sys/devices/.../power/wakeup_active_count |
91 | Date: September 2010 | 90 | Date: September 2010 |
@@ -95,7 +94,7 @@ Description: | |||
95 | number of times the processing of wakeup events associated with | 94 | number of times the processing of wakeup events associated with |
96 | the device was completed (at the kernel level). This attribute | 95 | the device was completed (at the kernel level). This attribute |
97 | is read-only. If the device is not enabled to wake up the | 96 | is read-only. If the device is not enabled to wake up the |
98 | system from sleep states, this attribute is empty. | 97 | system from sleep states, this attribute is not present. |
99 | 98 | ||
100 | What: /sys/devices/.../power/wakeup_hit_count | 99 | What: /sys/devices/.../power/wakeup_hit_count |
101 | Date: September 2010 | 100 | Date: September 2010 |
@@ -105,7 +104,8 @@ Description: | |||
105 | number of times the processing of a wakeup event associated with | 104 | number of times the processing of a wakeup event associated with |
106 | the device might prevent the system from entering a sleep state. | 105 | the device might prevent the system from entering a sleep state. |
107 | This attribute is read-only. If the device is not enabled to | 106 | This attribute is read-only. If the device is not enabled to |
108 | wake up the system from sleep states, this attribute is empty. | 107 | wake up the system from sleep states, this attribute is not |
108 | present. | ||
109 | 109 | ||
110 | What: /sys/devices/.../power/wakeup_active | 110 | What: /sys/devices/.../power/wakeup_active |
111 | Date: September 2010 | 111 | Date: September 2010 |
@@ -115,7 +115,7 @@ Description: | |||
115 | or 0, depending on whether or not a wakeup event associated with | 115 | or 0, depending on whether or not a wakeup event associated with |
116 | the device is being processed (1). This attribute is read-only. | 116 | the device is being processed (1). This attribute is read-only. |
117 | If the device is not enabled to wake up the system from sleep | 117 | If the device is not enabled to wake up the system from sleep |
118 | states, this attribute is empty. | 118 | states, this attribute is not present. |
119 | 119 | ||
120 | What: /sys/devices/.../power/wakeup_total_time_ms | 120 | What: /sys/devices/.../power/wakeup_total_time_ms |
121 | Date: September 2010 | 121 | Date: September 2010 |
@@ -125,7 +125,7 @@ Description: | |||
125 | the total time of processing wakeup events associated with the | 125 | the total time of processing wakeup events associated with the |
126 | device, in milliseconds. This attribute is read-only. If the | 126 | device, in milliseconds. This attribute is read-only. If the |
127 | device is not enabled to wake up the system from sleep states, | 127 | device is not enabled to wake up the system from sleep states, |
128 | this attribute is empty. | 128 | this attribute is not present. |
129 | 129 | ||
130 | What: /sys/devices/.../power/wakeup_max_time_ms | 130 | What: /sys/devices/.../power/wakeup_max_time_ms |
131 | Date: September 2010 | 131 | Date: September 2010 |
@@ -135,7 +135,7 @@ Description: | |||
135 | the maximum time of processing a single wakeup event associated | 135 | the maximum time of processing a single wakeup event associated |
136 | with the device, in milliseconds. This attribute is read-only. | 136 | with the device, in milliseconds. This attribute is read-only. |
137 | If the device is not enabled to wake up the system from sleep | 137 | If the device is not enabled to wake up the system from sleep |
138 | states, this attribute is empty. | 138 | states, this attribute is not present. |
139 | 139 | ||
140 | What: /sys/devices/.../power/wakeup_last_time_ms | 140 | What: /sys/devices/.../power/wakeup_last_time_ms |
141 | Date: September 2010 | 141 | Date: September 2010 |
@@ -146,7 +146,7 @@ Description: | |||
146 | signaling the last wakeup event associated with the device, in | 146 | signaling the last wakeup event associated with the device, in |
147 | milliseconds. This attribute is read-only. If the device is | 147 | milliseconds. This attribute is read-only. If the device is |
148 | not enabled to wake up the system from sleep states, this | 148 | not enabled to wake up the system from sleep states, this |
149 | attribute is empty. | 149 | attribute is not present. |
150 | 150 | ||
151 | What: /sys/devices/.../power/autosuspend_delay_ms | 151 | What: /sys/devices/.../power/autosuspend_delay_ms |
152 | Date: September 2010 | 152 | Date: September 2010 |
diff --git a/Documentation/ABI/testing/sysfs-firmware-dmi b/Documentation/ABI/testing/sysfs-firmware-dmi new file mode 100644 index 000000000000..ba9da9503c23 --- /dev/null +++ b/Documentation/ABI/testing/sysfs-firmware-dmi | |||
@@ -0,0 +1,110 @@ | |||
1 | What: /sys/firmware/dmi/ | ||
2 | Date: February 2011 | ||
3 | Contact: Mike Waychison <mikew@google.com> | ||
4 | Description: | ||
5 | Many machines' firmware (x86 and ia64) export DMI / | ||
6 | SMBIOS tables to the operating system. Getting at this | ||
7 | information is often valuable to userland, especially in | ||
8 | cases where there are OEM extensions used. | ||
9 | |||
10 | The kernel itself does not rely on the majority of the | ||
11 | information in these tables being correct. It equally | ||
12 | cannot ensure that the data as exported to userland is | ||
13 | without error either. | ||
14 | |||
15 | DMI is structured as a large table of entries, where | ||
16 | each entry has a common header indicating the type and | ||
17 | length of the entry, as well as 'handle' that is | ||
18 | supposed to be unique amongst all entries. | ||
19 | |||
20 | Some entries are required by the specification, but many | ||
21 | others are optional. In general though, users should | ||
22 | never expect to find a specific entry type on their | ||
23 | system unless they know for certain what their firmware | ||
24 | is doing. Machine to machine will vary. | ||
25 | |||
26 | Multiple entries of the same type are allowed. In order | ||
27 | to handle these duplicate entry types, each entry is | ||
28 | assigned by the operating system an 'instance', which is | ||
29 | derived from an entry type's ordinal position. That is | ||
30 | to say, if there are 'N' multiple entries with the same type | ||
31 | 'T' in the DMI tables (adjacent or spread apart, it | ||
32 | doesn't matter), they will be represented in sysfs as | ||
33 | entries "T-0" through "T-(N-1)": | ||
34 | |||
35 | Example entry directories: | ||
36 | |||
37 | /sys/firmware/dmi/entries/17-0 | ||
38 | /sys/firmware/dmi/entries/17-1 | ||
39 | /sys/firmware/dmi/entries/17-2 | ||
40 | /sys/firmware/dmi/entries/17-3 | ||
41 | ... | ||
42 | |||
43 | Instance numbers are used in lieu of the firmware | ||
44 | assigned entry handles as the kernel itself makes no | ||
45 | guarantees that handles as exported are unique, and | ||
46 | there are likely firmware images that get this wrong in | ||
47 | the wild. | ||
48 | |||
49 | Each DMI entry in sysfs has the common header values | ||
50 | exported as attributes: | ||
51 | |||
52 | handle : The 16bit 'handle' that is assigned to this | ||
53 | entry by the firmware. This handle may be | ||
54 | referred to by other entries. | ||
55 | length : The length of the entry, as presented in the | ||
56 | entry itself. Note that this is _not the | ||
57 | total count of bytes associated with the | ||
58 | entry_. This value represents the length of | ||
59 | the "formatted" portion of the entry. This | ||
60 | "formatted" region is sometimes followed by | ||
61 | the "unformatted" region composed of nul | ||
62 | terminated strings, with termination signalled | ||
63 | by a two nul characters in series. | ||
64 | raw : The raw bytes of the entry. This includes the | ||
65 | "formatted" portion of the entry, the | ||
66 | "unformatted" strings portion of the entry, | ||
67 | and the two terminating nul characters. | ||
68 | type : The type of the entry. This value is the same | ||
69 | as found in the directory name. It indicates | ||
70 | how the rest of the entry should be | ||
71 | interpreted. | ||
72 | instance: The instance ordinal of the entry for the | ||
73 | given type. This value is the same as found | ||
74 | in the parent directory name. | ||
75 | position: The position of the entry within the entirety | ||
76 | of the entirety. | ||
77 | |||
78 | === Entry Specialization === | ||
79 | |||
80 | Some entry types may have other information available in | ||
81 | sysfs. | ||
82 | |||
83 | --- Type 15 - System Event Log --- | ||
84 | |||
85 | This entry allows the firmware to export a log of | ||
86 | events the system has taken. This information is | ||
87 | typically backed by nvram, but the implementation | ||
88 | details are abstracted by this table. This entries data | ||
89 | is exported in the directory: | ||
90 | |||
91 | /sys/firmware/dmi/entries/15-0/system_event_log | ||
92 | |||
93 | and has the following attributes (documented in the | ||
94 | SMBIOS / DMI specification under "System Event Log (Type 15)": | ||
95 | |||
96 | area_length | ||
97 | header_start_offset | ||
98 | data_start_offset | ||
99 | access_method | ||
100 | status | ||
101 | change_token | ||
102 | access_method_address | ||
103 | header_format | ||
104 | per_log_type_descriptor_length | ||
105 | type_descriptors_supported_count | ||
106 | |||
107 | As well, the kernel exports the binary attribute: | ||
108 | |||
109 | raw_event_log : The raw binary bits of the event log | ||
110 | as described by the DMI entry. | ||
diff --git a/Documentation/ABI/testing/sysfs-fs-pstore b/Documentation/ABI/testing/sysfs-fs-pstore new file mode 100644 index 000000000000..8e659d854805 --- /dev/null +++ b/Documentation/ABI/testing/sysfs-fs-pstore | |||
@@ -0,0 +1,7 @@ | |||
1 | What: /sys/fs/pstore/kmsg_bytes | ||
2 | Date: January 2011 | ||
3 | Kernel Version: 2.6.38 | ||
4 | Contact: "Tony Luck" <tony.luck@intel.com> | ||
5 | Description: | ||
6 | Controls amount of console log that will be saved | ||
7 | to persistent store on oops/panic. | ||
diff --git a/Documentation/ABI/testing/sysfs-platform-kim b/Documentation/ABI/testing/sysfs-platform-kim new file mode 100644 index 000000000000..c1653271872a --- /dev/null +++ b/Documentation/ABI/testing/sysfs-platform-kim | |||
@@ -0,0 +1,48 @@ | |||
1 | What: /sys/devices/platform/kim/dev_name | ||
2 | Date: January 2010 | ||
3 | KernelVersion: 2.6.38 | ||
4 | Contact: "Pavan Savoy" <pavan_savoy@ti.com> | ||
5 | Description: | ||
6 | Name of the UART device at which the WL128x chip | ||
7 | is connected. example: "/dev/ttyS0". | ||
8 | The device name flows down to architecture specific board | ||
9 | initialization file from the SFI/ATAGS bootloader | ||
10 | firmware. The name exposed is read from the user-space | ||
11 | dameon and opens the device when install is requested. | ||
12 | |||
13 | What: /sys/devices/platform/kim/baud_rate | ||
14 | Date: January 2010 | ||
15 | KernelVersion: 2.6.38 | ||
16 | Contact: "Pavan Savoy" <pavan_savoy@ti.com> | ||
17 | Description: | ||
18 | The maximum reliable baud-rate the host can support. | ||
19 | Different platforms tend to have different high-speed | ||
20 | UART configurations, so the baud-rate needs to be set | ||
21 | locally and also sent across to the WL128x via a HCI-VS | ||
22 | command. The entry is read and made use by the user-space | ||
23 | daemon when the ldisc install is requested. | ||
24 | |||
25 | What: /sys/devices/platform/kim/flow_cntrl | ||
26 | Date: January 2010 | ||
27 | KernelVersion: 2.6.38 | ||
28 | Contact: "Pavan Savoy" <pavan_savoy@ti.com> | ||
29 | Description: | ||
30 | The WL128x makes use of flow control mechanism, and this | ||
31 | entry most often should be 1, the host's UART is required | ||
32 | to have the capability of flow-control, or else this | ||
33 | entry can be made use of for exceptions. | ||
34 | |||
35 | What: /sys/devices/platform/kim/install | ||
36 | Date: January 2010 | ||
37 | KernelVersion: 2.6.38 | ||
38 | Contact: "Pavan Savoy" <pavan_savoy@ti.com> | ||
39 | Description: | ||
40 | When one of the protocols Bluetooth, FM or GPS wants to make | ||
41 | use of the shared UART transport, it registers to the shared | ||
42 | transport driver, which will signal the user-space for opening, | ||
43 | configuring baud and install line discipline via this sysfs | ||
44 | entry. This entry would be polled upon by the user-space | ||
45 | daemon managing the UART, and is notified about the change | ||
46 | by the sysfs_notify. The value would be '1' when UART needs | ||
47 | to be opened/ldisc installed, and would be '0' when UART | ||
48 | is no more required and needs to be closed. | ||
diff --git a/Documentation/CodingStyle b/Documentation/CodingStyle index 8bb37237ebd2..1cd3478e5834 100644 --- a/Documentation/CodingStyle +++ b/Documentation/CodingStyle | |||
@@ -659,7 +659,7 @@ There are a number of driver model diagnostic macros in <linux/device.h> | |||
659 | which you should use to make sure messages are matched to the right device | 659 | which you should use to make sure messages are matched to the right device |
660 | and driver, and are tagged with the right level: dev_err(), dev_warn(), | 660 | and driver, and are tagged with the right level: dev_err(), dev_warn(), |
661 | dev_info(), and so forth. For messages that aren't associated with a | 661 | dev_info(), and so forth. For messages that aren't associated with a |
662 | particular device, <linux/kernel.h> defines pr_debug() and pr_info(). | 662 | particular device, <linux/printk.h> defines pr_debug() and pr_info(). |
663 | 663 | ||
664 | Coming up with good debugging messages can be quite a challenge; and once | 664 | Coming up with good debugging messages can be quite a challenge; and once |
665 | you have them, they can be a huge help for remote troubleshooting. Such | 665 | you have them, they can be a huge help for remote troubleshooting. Such |
@@ -819,6 +819,3 @@ language C, URL: http://www.open-std.org/JTC1/SC22/WG14/ | |||
819 | Kernel CodingStyle, by greg@kroah.com at OLS 2002: | 819 | Kernel CodingStyle, by greg@kroah.com at OLS 2002: |
820 | http://www.kroah.com/linux/talks/ols_2002_kernel_codingstyle_talk/html/ | 820 | http://www.kroah.com/linux/talks/ols_2002_kernel_codingstyle_talk/html/ |
821 | 821 | ||
822 | -- | ||
823 | Last updated on 2007-July-13. | ||
824 | |||
diff --git a/Documentation/RCU/whatisRCU.txt b/Documentation/RCU/whatisRCU.txt index cfaac34c4557..6ef692667e2f 100644 --- a/Documentation/RCU/whatisRCU.txt +++ b/Documentation/RCU/whatisRCU.txt | |||
@@ -849,6 +849,37 @@ All: lockdep-checked RCU-protected pointer access | |||
849 | See the comment headers in the source code (or the docbook generated | 849 | See the comment headers in the source code (or the docbook generated |
850 | from them) for more information. | 850 | from them) for more information. |
851 | 851 | ||
852 | However, given that there are no fewer than four families of RCU APIs | ||
853 | in the Linux kernel, how do you choose which one to use? The following | ||
854 | list can be helpful: | ||
855 | |||
856 | a. Will readers need to block? If so, you need SRCU. | ||
857 | |||
858 | b. What about the -rt patchset? If readers would need to block | ||
859 | in an non-rt kernel, you need SRCU. If readers would block | ||
860 | in a -rt kernel, but not in a non-rt kernel, SRCU is not | ||
861 | necessary. | ||
862 | |||
863 | c. Do you need to treat NMI handlers, hardirq handlers, | ||
864 | and code segments with preemption disabled (whether | ||
865 | via preempt_disable(), local_irq_save(), local_bh_disable(), | ||
866 | or some other mechanism) as if they were explicit RCU readers? | ||
867 | If so, you need RCU-sched. | ||
868 | |||
869 | d. Do you need RCU grace periods to complete even in the face | ||
870 | of softirq monopolization of one or more of the CPUs? For | ||
871 | example, is your code subject to network-based denial-of-service | ||
872 | attacks? If so, you need RCU-bh. | ||
873 | |||
874 | e. Is your workload too update-intensive for normal use of | ||
875 | RCU, but inappropriate for other synchronization mechanisms? | ||
876 | If so, consider SLAB_DESTROY_BY_RCU. But please be careful! | ||
877 | |||
878 | f. Otherwise, use RCU. | ||
879 | |||
880 | Of course, this all assumes that you have determined that RCU is in fact | ||
881 | the right tool for your job. | ||
882 | |||
852 | 883 | ||
853 | 8. ANSWERS TO QUICK QUIZZES | 884 | 8. ANSWERS TO QUICK QUIZZES |
854 | 885 | ||
diff --git a/Documentation/arm/SH-Mobile/Makefile b/Documentation/arm/SH-Mobile/Makefile new file mode 100644 index 000000000000..8771d832cf8c --- /dev/null +++ b/Documentation/arm/SH-Mobile/Makefile | |||
@@ -0,0 +1,8 @@ | |||
1 | BIN := vrl4 | ||
2 | |||
3 | .PHONY: all | ||
4 | all: $(BIN) | ||
5 | |||
6 | .PHONY: clean | ||
7 | clean: | ||
8 | rm -f *.o $(BIN) | ||
diff --git a/Documentation/arm/SH-Mobile/vrl4.c b/Documentation/arm/SH-Mobile/vrl4.c new file mode 100644 index 000000000000..e8a191358ad2 --- /dev/null +++ b/Documentation/arm/SH-Mobile/vrl4.c | |||
@@ -0,0 +1,169 @@ | |||
1 | /* | ||
2 | * vrl4 format generator | ||
3 | * | ||
4 | * Copyright (C) 2010 Simon Horman | ||
5 | * | ||
6 | * This file is subject to the terms and conditions of the GNU General Public | ||
7 | * License. See the file "COPYING" in the main directory of this archive | ||
8 | * for more details. | ||
9 | */ | ||
10 | |||
11 | /* | ||
12 | * usage: vrl4 < zImage > out | ||
13 | * dd if=out of=/dev/sdx bs=512 seek=1 # Write the image to sector 1 | ||
14 | * | ||
15 | * Reads a zImage from stdin and writes a vrl4 image to stdout. | ||
16 | * In practice this means writing a padded vrl4 header to stdout followed | ||
17 | * by the zImage. | ||
18 | * | ||
19 | * The padding places the zImage at ALIGN bytes into the output. | ||
20 | * The vrl4 uses ALIGN + START_BASE as the start_address. | ||
21 | * This is where the mask ROM will jump to after verifying the header. | ||
22 | * | ||
23 | * The header sets copy_size to min(sizeof(zImage), MAX_BOOT_PROG_LEN) + ALIGN. | ||
24 | * That is, the mask ROM will load the padded header (ALIGN bytes) | ||
25 | * And then MAX_BOOT_PROG_LEN bytes of the image, or the entire image, | ||
26 | * whichever is smaller. | ||
27 | * | ||
28 | * The zImage is not modified in any way. | ||
29 | */ | ||
30 | |||
31 | #define _BSD_SOURCE | ||
32 | #include <endian.h> | ||
33 | #include <unistd.h> | ||
34 | #include <stdint.h> | ||
35 | #include <stdio.h> | ||
36 | #include <errno.h> | ||
37 | |||
38 | struct hdr { | ||
39 | uint32_t magic1; | ||
40 | uint32_t reserved1; | ||
41 | uint32_t magic2; | ||
42 | uint32_t reserved2; | ||
43 | uint16_t copy_size; | ||
44 | uint16_t boot_options; | ||
45 | uint32_t reserved3; | ||
46 | uint32_t start_address; | ||
47 | uint32_t reserved4; | ||
48 | uint32_t reserved5; | ||
49 | char reserved6[308]; | ||
50 | }; | ||
51 | |||
52 | #define DECLARE_HDR(h) \ | ||
53 | struct hdr (h) = { \ | ||
54 | .magic1 = htole32(0xea000000), \ | ||
55 | .reserved1 = htole32(0x56), \ | ||
56 | .magic2 = htole32(0xe59ff008), \ | ||
57 | .reserved3 = htole16(0x1) } | ||
58 | |||
59 | /* Align to 512 bytes, the MMCIF sector size */ | ||
60 | #define ALIGN_BITS 9 | ||
61 | #define ALIGN (1 << ALIGN_BITS) | ||
62 | |||
63 | #define START_BASE 0xe55b0000 | ||
64 | |||
65 | /* | ||
66 | * With an alignment of 512 the header uses the first sector. | ||
67 | * There is a 128 sector (64kbyte) limit on the data loaded by the mask ROM. | ||
68 | * So there are 127 sectors left for the boot programme. But in practice | ||
69 | * Only a small portion of a zImage is needed, 16 sectors should be more | ||
70 | * than enough. | ||
71 | * | ||
72 | * Note that this sets how much of the zImage is copied by the mask ROM. | ||
73 | * The entire zImage is present after the header and is loaded | ||
74 | * by the code in the boot program (which is the first portion of the zImage). | ||
75 | */ | ||
76 | #define MAX_BOOT_PROG_LEN (16 * 512) | ||
77 | |||
78 | #define ROUND_UP(x) ((x + ALIGN - 1) & ~(ALIGN - 1)) | ||
79 | |||
80 | ssize_t do_read(int fd, void *buf, size_t count) | ||
81 | { | ||
82 | size_t offset = 0; | ||
83 | ssize_t l; | ||
84 | |||
85 | while (offset < count) { | ||
86 | l = read(fd, buf + offset, count - offset); | ||
87 | if (!l) | ||
88 | break; | ||
89 | if (l < 0) { | ||
90 | if (errno == EAGAIN || errno == EWOULDBLOCK) | ||
91 | continue; | ||
92 | perror("read"); | ||
93 | return -1; | ||
94 | } | ||
95 | offset += l; | ||
96 | } | ||
97 | |||
98 | return offset; | ||
99 | } | ||
100 | |||
101 | ssize_t do_write(int fd, const void *buf, size_t count) | ||
102 | { | ||
103 | size_t offset = 0; | ||
104 | ssize_t l; | ||
105 | |||
106 | while (offset < count) { | ||
107 | l = write(fd, buf + offset, count - offset); | ||
108 | if (l < 0) { | ||
109 | if (errno == EAGAIN || errno == EWOULDBLOCK) | ||
110 | continue; | ||
111 | perror("write"); | ||
112 | return -1; | ||
113 | } | ||
114 | offset += l; | ||
115 | } | ||
116 | |||
117 | return offset; | ||
118 | } | ||
119 | |||
120 | ssize_t write_zero(int fd, size_t len) | ||
121 | { | ||
122 | size_t i = len; | ||
123 | |||
124 | while (i--) { | ||
125 | const char x = 0; | ||
126 | if (do_write(fd, &x, 1) < 0) | ||
127 | return -1; | ||
128 | } | ||
129 | |||
130 | return len; | ||
131 | } | ||
132 | |||
133 | int main(void) | ||
134 | { | ||
135 | DECLARE_HDR(hdr); | ||
136 | char boot_program[MAX_BOOT_PROG_LEN]; | ||
137 | size_t aligned_hdr_len, alligned_prog_len; | ||
138 | ssize_t prog_len; | ||
139 | |||
140 | prog_len = do_read(0, boot_program, sizeof(boot_program)); | ||
141 | if (prog_len <= 0) | ||
142 | return -1; | ||
143 | |||
144 | aligned_hdr_len = ROUND_UP(sizeof(hdr)); | ||
145 | hdr.start_address = htole32(START_BASE + aligned_hdr_len); | ||
146 | alligned_prog_len = ROUND_UP(prog_len); | ||
147 | hdr.copy_size = htole16(aligned_hdr_len + alligned_prog_len); | ||
148 | |||
149 | if (do_write(1, &hdr, sizeof(hdr)) < 0) | ||
150 | return -1; | ||
151 | if (write_zero(1, aligned_hdr_len - sizeof(hdr)) < 0) | ||
152 | return -1; | ||
153 | |||
154 | if (do_write(1, boot_program, prog_len) < 0) | ||
155 | return 1; | ||
156 | |||
157 | /* Write out the rest of the kernel */ | ||
158 | while (1) { | ||
159 | prog_len = do_read(0, boot_program, sizeof(boot_program)); | ||
160 | if (prog_len < 0) | ||
161 | return 1; | ||
162 | if (prog_len == 0) | ||
163 | break; | ||
164 | if (do_write(1, boot_program, prog_len) < 0) | ||
165 | return 1; | ||
166 | } | ||
167 | |||
168 | return 0; | ||
169 | } | ||
diff --git a/Documentation/arm/SH-Mobile/zboot-rom-mmcif.txt b/Documentation/arm/SH-Mobile/zboot-rom-mmcif.txt new file mode 100644 index 000000000000..efff8ae2713d --- /dev/null +++ b/Documentation/arm/SH-Mobile/zboot-rom-mmcif.txt | |||
@@ -0,0 +1,29 @@ | |||
1 | ROM-able zImage boot from MMC | ||
2 | ----------------------------- | ||
3 | |||
4 | An ROM-able zImage compiled with ZBOOT_ROM_MMCIF may be written to MMC and | ||
5 | SuperH Mobile ARM will to boot directly from the MMCIF hardware block. | ||
6 | |||
7 | This is achieved by the mask ROM loading the first portion of the image into | ||
8 | MERAM and then jumping to it. This portion contains loader code which | ||
9 | copies the entire image to SDRAM and jumps to it. From there the zImage | ||
10 | boot code proceeds as normal, uncompressing the image into its final | ||
11 | location and then jumping to it. | ||
12 | |||
13 | This code has been tested on an AP4EB board using the developer 1A eMMC | ||
14 | boot mode which is configured using the following jumper settings. | ||
15 | The board used for testing required a patched mask ROM in order for | ||
16 | this mode to function. | ||
17 | |||
18 | 8 7 6 5 4 3 2 1 | ||
19 | x|x|x|x|x| |x| | ||
20 | S4 -+-+-+-+-+-+-+- | ||
21 | | | | | |x| |x on | ||
22 | |||
23 | The zImage must be written to the MMC card at sector 1 (512 bytes) in | ||
24 | vrl4 format. A utility vrl4 is supplied to accomplish this. | ||
25 | |||
26 | e.g. | ||
27 | vrl4 < zImage | dd of=/dev/sdX bs=512 seek=1 | ||
28 | |||
29 | A dual-voltage MMC 4.0 card was used for testing. | ||
diff --git a/Documentation/arm/Sharp-LH/ADC-LH7-Touchscreen b/Documentation/arm/Sharp-LH/ADC-LH7-Touchscreen deleted file mode 100644 index dc460f055647..000000000000 --- a/Documentation/arm/Sharp-LH/ADC-LH7-Touchscreen +++ /dev/null | |||
@@ -1,61 +0,0 @@ | |||
1 | README on the ADC/Touchscreen Controller | ||
2 | ======================================== | ||
3 | |||
4 | The LH79524 and LH7A404 include a built-in Analog to Digital | ||
5 | controller (ADC) that is used to process input from a touchscreen. | ||
6 | The driver only implements a four-wire touch panel protocol. | ||
7 | |||
8 | The touchscreen driver is maintenance free except for the pen-down or | ||
9 | touch threshold. Some resistive displays and board combinations may | ||
10 | require tuning of this threshold. The driver exposes some of its | ||
11 | internal state in the sys filesystem. If the kernel is configured | ||
12 | with it, CONFIG_SYSFS, and sysfs is mounted at /sys, there will be a | ||
13 | directory | ||
14 | |||
15 | /sys/devices/platform/adc-lh7.0 | ||
16 | |||
17 | containing these files. | ||
18 | |||
19 | -r--r--r-- 1 root root 4096 Jan 1 00:00 samples | ||
20 | -rw-r--r-- 1 root root 4096 Jan 1 00:00 threshold | ||
21 | -r--r--r-- 1 root root 4096 Jan 1 00:00 threshold_range | ||
22 | |||
23 | The threshold is the current touch threshold. It defaults to 750 on | ||
24 | most targets. | ||
25 | |||
26 | # cat threshold | ||
27 | 750 | ||
28 | |||
29 | The threshold_range contains the range of valid values for the | ||
30 | threshold. Values outside of this range will be silently ignored. | ||
31 | |||
32 | # cat threshold_range | ||
33 | 0 1023 | ||
34 | |||
35 | To change the threshold, write a value to the threshold file. | ||
36 | |||
37 | # echo 500 > threshold | ||
38 | # cat threshold | ||
39 | 500 | ||
40 | |||
41 | The samples file contains the most recently sampled values from the | ||
42 | ADC. There are 12. Below are typical of the last sampled values when | ||
43 | the pen has been released. The first two and last two samples are for | ||
44 | detecting whether or not the pen is down. The third through sixth are | ||
45 | X coordinate samples. The seventh through tenth are Y coordinate | ||
46 | samples. | ||
47 | |||
48 | # cat samples | ||
49 | 1023 1023 0 0 0 0 530 529 530 529 1023 1023 | ||
50 | |||
51 | To determine a reasonable threshold, press on the touch panel with an | ||
52 | appropriate stylus and read the values from samples. | ||
53 | |||
54 | # cat samples | ||
55 | 1023 676 92 103 101 102 855 919 922 922 1023 679 | ||
56 | |||
57 | The first and eleventh samples are discarded. Thus, the important | ||
58 | values are the second and twelfth which are used to determine if the | ||
59 | pen is down. When both are below the threshold, the driver registers | ||
60 | that the pen is down. When either is above the threshold, it | ||
61 | registers then pen is up. | ||
diff --git a/Documentation/arm/Sharp-LH/CompactFlash b/Documentation/arm/Sharp-LH/CompactFlash deleted file mode 100644 index 8616d877df9e..000000000000 --- a/Documentation/arm/Sharp-LH/CompactFlash +++ /dev/null | |||
@@ -1,32 +0,0 @@ | |||
1 | README on the Compact Flash for Card Engines | ||
2 | ============================================ | ||
3 | |||
4 | There are three challenges in supporting the CF interface of the Card | ||
5 | Engines. First, every IO operation must be followed with IO to | ||
6 | another memory region. Second, the slot is wired for one-to-one | ||
7 | address mapping *and* it is wired for 16 bit access only. Second, the | ||
8 | interrupt request line from the CF device isn't wired. | ||
9 | |||
10 | The IOBARRIER issue is covered in README.IOBARRIER. This isn't an | ||
11 | onerous problem. Enough said here. | ||
12 | |||
13 | The addressing issue is solved in the | ||
14 | arch/arm/mach-lh7a40x/ide-lpd7a40x.c file with some awkward | ||
15 | work-arounds. We implement a special SELECT_DRIVE routine that is | ||
16 | called before the IDE driver performs its own SELECT_DRIVE. Our code | ||
17 | recognizes that the SELECT register cannot be modified without also | ||
18 | writing a command. It send an IDLE_IMMEDIATE command on selecting a | ||
19 | drive. The function also prevents drive select to the slave drive | ||
20 | since there can be only one. The awkward part is that the IDE driver, | ||
21 | even though we have a select procedure, also attempts to change the | ||
22 | drive by writing directly the SELECT register. This attempt is | ||
23 | explicitly blocked by the OUTB function--not pretty, but effective. | ||
24 | |||
25 | The lack of interrupts is a more serious problem. Even though the CF | ||
26 | card is fast when compared to a normal IDE device, we don't know that | ||
27 | the CF is really flash. A user could use one of the very small hard | ||
28 | drives being shipped with a CF interface. The IDE code includes a | ||
29 | check for interfaces that lack an IRQ. In these cases, submitting a | ||
30 | command to the IDE controller is followed by a call to poll for | ||
31 | completion. If the device isn't immediately ready, it schedules a | ||
32 | timer to poll again later. | ||
diff --git a/Documentation/arm/Sharp-LH/IOBarrier b/Documentation/arm/Sharp-LH/IOBarrier deleted file mode 100644 index 2e953e228f4d..000000000000 --- a/Documentation/arm/Sharp-LH/IOBarrier +++ /dev/null | |||
@@ -1,45 +0,0 @@ | |||
1 | README on the IOBARRIER for CardEngine IO | ||
2 | ========================================= | ||
3 | |||
4 | Due to an unfortunate oversight when the Card Engines were designed, | ||
5 | the signals that control access to some peripherals, most notably the | ||
6 | SMC91C9111 ethernet controller, are not properly handled. | ||
7 | |||
8 | The symptom is that some back to back IO with the peripheral returns | ||
9 | unreliable data. With the SMC chip, you'll see errors about the bank | ||
10 | register being 'screwed'. | ||
11 | |||
12 | The cause is that the AEN signal to the SMC chip does not transition | ||
13 | for every memory access. It is driven through the CPLD from the CS7 | ||
14 | line of the CPU's static memory controller which is optimized to | ||
15 | eliminate unnecessary transitions. Yet, the SMC requires a transition | ||
16 | for every write access. The Sharp website has more information about | ||
17 | the effect this power-conserving feature has on peripheral | ||
18 | interfacing. | ||
19 | |||
20 | The solution is to follow every write access to the SMC chip with an | ||
21 | access to another memory region that will force the CPU to release the | ||
22 | chip select line. It is important to guarantee that this access | ||
23 | forces the CPU off-chip. We map a page of SDRAM as if it were an | ||
24 | uncacheable IO device and read from it after every SMC IO write | ||
25 | operation. | ||
26 | |||
27 | SMC IO | ||
28 | BARRIER IO | ||
29 | |||
30 | Only this sequence is important. It does not matter that there is no | ||
31 | BARRIER IO before the access to the SMC chip because the AEN latch | ||
32 | only needs occurs after the SMC IO write cycle. The routines that | ||
33 | implement this work-around make an additional concession which is to | ||
34 | disable interrupts during the IO sequence. Other hardware devices | ||
35 | (the LogicPD CPLD) have registers in the same physical memory | ||
36 | region as the SMC chip. An interrupt might allow an access to one of | ||
37 | those registers while SMC IO is being performed. | ||
38 | |||
39 | You might be tempted to think that we have to access another device | ||
40 | attached to the static memory controller, but the empirical evidence | ||
41 | indicates that this is not so. Mapping 0x00000000 (flash) and | ||
42 | 0xc0000000 (SDRAM) appear to have the same effect. Using SDRAM seems | ||
43 | to be faster. Choosing to access an undecoded memory region is not | ||
44 | desirable as there is no way to know how that chip select will be used | ||
45 | in the future. | ||
diff --git a/Documentation/arm/Sharp-LH/KEV7A400 b/Documentation/arm/Sharp-LH/KEV7A400 deleted file mode 100644 index be32b14cd535..000000000000 --- a/Documentation/arm/Sharp-LH/KEV7A400 +++ /dev/null | |||
@@ -1,8 +0,0 @@ | |||
1 | README on Implementing Linux for Sharp's KEV7a400 | ||
2 | ================================================= | ||
3 | |||
4 | This product has been discontinued by Sharp. For the time being, the | ||
5 | partially implemented code remains in the kernel. At some point in | ||
6 | the future, either the code will be finished or it will be removed | ||
7 | completely. This depends primarily on how many of the development | ||
8 | boards are in the field. | ||
diff --git a/Documentation/arm/Sharp-LH/LCDPanels b/Documentation/arm/Sharp-LH/LCDPanels deleted file mode 100644 index fb1b21c2f2f4..000000000000 --- a/Documentation/arm/Sharp-LH/LCDPanels +++ /dev/null | |||
@@ -1,59 +0,0 @@ | |||
1 | README on the LCD Panels | ||
2 | ======================== | ||
3 | |||
4 | Configuration options for several LCD panels, available from Logic PD, | ||
5 | are included in the kernel source. This README will help you | ||
6 | understand the configuration data and give you some guidance for | ||
7 | adding support for other panels if you wish. | ||
8 | |||
9 | |||
10 | lcd-panels.h | ||
11 | ------------ | ||
12 | |||
13 | There is no way, at present, to detect which panel is attached to the | ||
14 | system at runtime. Thus the kernel configuration is static. The file | ||
15 | arch/arm/mach-ld7a40x/lcd-panels.h (or similar) defines all of the | ||
16 | panel specific parameters. | ||
17 | |||
18 | It should be possible for this data to be shared among several device | ||
19 | families. The current layout may be insufficiently general, but it is | ||
20 | amenable to improvement. | ||
21 | |||
22 | |||
23 | PIXEL_CLOCK | ||
24 | ----------- | ||
25 | |||
26 | The panel data sheets will give a range of acceptable pixel clocks. | ||
27 | The fundamental LCDCLK input frequency is divided down by a PCD | ||
28 | constant in field '.tim2'. It may happen that it is impossible to set | ||
29 | the pixel clock within this range. A clock which is too slow will | ||
30 | tend to flicker. For the highest quality image, set the clock as high | ||
31 | as possible. | ||
32 | |||
33 | |||
34 | MARGINS | ||
35 | ------- | ||
36 | |||
37 | These values may be difficult to glean from the panel data sheet. In | ||
38 | the case of the Sharp panels, the upper margin is explicitly called | ||
39 | out as a specific number of lines from the top of the frame. The | ||
40 | other values may not matter as much as the panels tend to | ||
41 | automatically center the image. | ||
42 | |||
43 | |||
44 | Sync Sense | ||
45 | ---------- | ||
46 | |||
47 | The sense of the hsync and vsync pulses may be called out in the data | ||
48 | sheet. On one panel, the sense of these pulses determine the height | ||
49 | of the visible region on the panel. Most of the Sharp panels use | ||
50 | negative sense sync pulses set by the TIM2_IHS and TIM2_IVS bits in | ||
51 | '.tim2'. | ||
52 | |||
53 | |||
54 | Pel Layout | ||
55 | ---------- | ||
56 | |||
57 | The Sharp color TFT panels are all configured for 16 bit direct color | ||
58 | modes. The amba-lcd driver sets the pel mode to 565 for 5 bits of | ||
59 | each red and blue and 6 bits of green. | ||
diff --git a/Documentation/arm/Sharp-LH/LPD7A400 b/Documentation/arm/Sharp-LH/LPD7A400 deleted file mode 100644 index 3275b453bfdf..000000000000 --- a/Documentation/arm/Sharp-LH/LPD7A400 +++ /dev/null | |||
@@ -1,15 +0,0 @@ | |||
1 | README on Implementing Linux for the Logic PD LPD7A400-10 | ||
2 | ========================================================= | ||
3 | |||
4 | - CPLD memory mapping | ||
5 | |||
6 | The board designers chose to use high address lines for controlling | ||
7 | access to the CPLD registers. It turns out to be a big waste | ||
8 | because we're using an MMU and must map IO space into virtual | ||
9 | memory. The result is that we have to make a mapping for every | ||
10 | register. | ||
11 | |||
12 | - Serial Console | ||
13 | |||
14 | It may be OK not to use the serial console option if the user passes | ||
15 | the console device name to the kernel. This deserves some exploration. | ||
diff --git a/Documentation/arm/Sharp-LH/LPD7A40X b/Documentation/arm/Sharp-LH/LPD7A40X deleted file mode 100644 index 8c29a27e208f..000000000000 --- a/Documentation/arm/Sharp-LH/LPD7A40X +++ /dev/null | |||
@@ -1,16 +0,0 @@ | |||
1 | README on Implementing Linux for the Logic PD LPD7A40X-10 | ||
2 | ========================================================= | ||
3 | |||
4 | - CPLD memory mapping | ||
5 | |||
6 | The board designers chose to use high address lines for controlling | ||
7 | access to the CPLD registers. It turns out to be a big waste | ||
8 | because we're using an MMU and must map IO space into virtual | ||
9 | memory. The result is that we have to make a mapping for every | ||
10 | register. | ||
11 | |||
12 | - Serial Console | ||
13 | |||
14 | It may be OK not to use the serial console option if the user passes | ||
15 | the console device name to the kernel. This deserves some exploration. | ||
16 | |||
diff --git a/Documentation/arm/Sharp-LH/SDRAM b/Documentation/arm/Sharp-LH/SDRAM deleted file mode 100644 index 93ddc23c2faa..000000000000 --- a/Documentation/arm/Sharp-LH/SDRAM +++ /dev/null | |||
@@ -1,51 +0,0 @@ | |||
1 | README on the SDRAM Controller for the LH7a40X | ||
2 | ============================================== | ||
3 | |||
4 | The standard configuration for the SDRAM controller generates a sparse | ||
5 | memory array. The precise layout is determined by the SDRAM chips. A | ||
6 | default kernel configuration assembles the discontiguous memory | ||
7 | regions into separate memory nodes via the NUMA (Non-Uniform Memory | ||
8 | Architecture) facilities. In this default configuration, the kernel | ||
9 | is forgiving about the precise layout. As long as it is given an | ||
10 | accurate picture of available memory by the bootloader the kernel will | ||
11 | execute correctly. | ||
12 | |||
13 | The SDRC supports a mode where some of the chip select lines are | ||
14 | swapped in order to make SDRAM look like a synchronous ROM. Setting | ||
15 | this bit means that the RAM will present as a contiguous array. Some | ||
16 | programmers prefer this to the discontiguous layout. Be aware that | ||
17 | may be a penalty for this feature where some some configurations of | ||
18 | memory are significantly reduced; i.e. 64MiB of RAM appears as only 32 | ||
19 | MiB. | ||
20 | |||
21 | There are a couple of configuration options to override the default | ||
22 | behavior. When the SROMLL bit is set and memory appears as a | ||
23 | contiguous array, there is no reason to support NUMA. | ||
24 | CONFIG_LH7A40X_CONTIGMEM disables NUMA support. When physical memory | ||
25 | is discontiguous, the memory tables are organized such that there are | ||
26 | two banks per nodes with a small gap between them. This layout wastes | ||
27 | some kernel memory for page tables representing non-existent memory. | ||
28 | CONFIG_LH7A40X_ONE_BANK_PER_NODE optimizes the node tables such that | ||
29 | there are no gaps. These options control the low level organization | ||
30 | of the memory management tables in ways that may prevent the kernel | ||
31 | from booting or may cause the kernel to allocated excessively large | ||
32 | page tables. Be warned. Only change these options if you know what | ||
33 | you are doing. The default behavior is a reasonable compromise that | ||
34 | will suit all users. | ||
35 | |||
36 | -- | ||
37 | |||
38 | A typical 32MiB system with the default configuration options will | ||
39 | find physical memory managed as follows. | ||
40 | |||
41 | node 0: 0xc0000000 4MiB | ||
42 | 0xc1000000 4MiB | ||
43 | node 1: 0xc4000000 4MiB | ||
44 | 0xc5000000 4MiB | ||
45 | node 2: 0xc8000000 4MiB | ||
46 | 0xc9000000 4MiB | ||
47 | node 3: 0xcc000000 4MiB | ||
48 | 0xcd000000 4MiB | ||
49 | |||
50 | Setting CONFIG_LH7A40X_ONE_BANK_PER_NODE will put each bank into a | ||
51 | separate node. | ||
diff --git a/Documentation/arm/Sharp-LH/VectoredInterruptController b/Documentation/arm/Sharp-LH/VectoredInterruptController deleted file mode 100644 index 23047e9861ee..000000000000 --- a/Documentation/arm/Sharp-LH/VectoredInterruptController +++ /dev/null | |||
@@ -1,80 +0,0 @@ | |||
1 | README on the Vectored Interrupt Controller of the LH7A404 | ||
2 | ========================================================== | ||
3 | |||
4 | The 404 revision of the LH7A40X series comes with two vectored | ||
5 | interrupts controllers. While the kernel does use some of the | ||
6 | features of these devices, it is far from the purpose for which they | ||
7 | were designed. | ||
8 | |||
9 | When this README was written, the implementation of the VICs was in | ||
10 | flux. It is possible that some details, especially with priorities, | ||
11 | will change. | ||
12 | |||
13 | The VIC support code is inspired by routines written by Sharp. | ||
14 | |||
15 | |||
16 | Priority Control | ||
17 | ---------------- | ||
18 | |||
19 | The significant reason for using the VIC's vectoring is to control | ||
20 | interrupt priorities. There are two tables in | ||
21 | arch/arm/mach-lh7a40x/irq-lh7a404.c that look something like this. | ||
22 | |||
23 | static unsigned char irq_pri_vic1[] = { IRQ_GPIO3INTR, }; | ||
24 | static unsigned char irq_pri_vic2[] = { | ||
25 | IRQ_T3UI, IRQ_GPIO7INTR, | ||
26 | IRQ_UART1INTR, IRQ_UART2INTR, IRQ_UART3INTR, }; | ||
27 | |||
28 | The initialization code reads these tables and inserts a vector | ||
29 | address and enable for each indicated IRQ. Vectored interrupts have | ||
30 | higher priority than non-vectored interrupts. So, on VIC1, | ||
31 | IRQ_GPIO3INTR will be served before any other non-FIQ interrupt. Due | ||
32 | to the way that the vectoring works, IRQ_T3UI is the next highest | ||
33 | priority followed by the other vectored interrupts on VIC2. After | ||
34 | that, the non-vectored interrupts are scanned in VIC1 then in VIC2. | ||
35 | |||
36 | |||
37 | ISR | ||
38 | --- | ||
39 | |||
40 | The interrupt service routine macro get_irqnr() in | ||
41 | arch/arm/kernel/entry-armv.S scans the VICs for the next active | ||
42 | interrupt. The vectoring makes this code somewhat larger than it was | ||
43 | before using vectoring (refer to the LH7A400 implementation). In the | ||
44 | case where an interrupt is vectored, the implementation will tend to | ||
45 | be faster than the non-vectored version. However, the worst-case path | ||
46 | is longer. | ||
47 | |||
48 | It is worth noting that at present, there is no need to read | ||
49 | VIC2_VECTADDR because the register appears to be shared between the | ||
50 | controllers. The code is written such that if this changes, it ought | ||
51 | to still work properly. | ||
52 | |||
53 | |||
54 | Vector Addresses | ||
55 | ---------------- | ||
56 | |||
57 | The proper use of the vectoring hardware would jump to the ISR | ||
58 | specified by the vectoring address. Linux isn't structured to take | ||
59 | advantage of this feature, though it might be possible to change | ||
60 | things to support it. | ||
61 | |||
62 | In this implementation, the vectoring address is used to speed the | ||
63 | search for the active IRQ. The address is coded such that the lowest | ||
64 | 6 bits store the IRQ number for vectored interrupts. These numbers | ||
65 | correspond to the bits in the interrupt status registers. IRQ zero is | ||
66 | the lowest interrupt bit in VIC1. IRQ 32 is the lowest interrupt bit | ||
67 | in VIC2. Because zero is a valid IRQ number and because we cannot | ||
68 | detect whether or not there is a valid vectoring address if that | ||
69 | address is zero, the eigth bit (0x100) is set for vectored interrupts. | ||
70 | The address for IRQ 0x18 (VIC2) is 0x118. Only the ninth bit is set | ||
71 | for the default handler on VIC1 and only the tenth bit is set for the | ||
72 | default handler on VIC2. | ||
73 | |||
74 | In other words. | ||
75 | |||
76 | 0x000 - no active interrupt | ||
77 | 0x1ii - vectored interrupt 0xii | ||
78 | 0x2xx - unvectored interrupt on VIC1 (xx is don't care) | ||
79 | 0x4xx - unvectored interrupt on VIC2 (xx is don't care) | ||
80 | |||
diff --git a/Documentation/cgroups/cgroups.txt b/Documentation/cgroups/cgroups.txt index 44b8b7af8019..cbdfb7d9455b 100644 --- a/Documentation/cgroups/cgroups.txt +++ b/Documentation/cgroups/cgroups.txt | |||
@@ -349,6 +349,10 @@ To mount a cgroup hierarchy with all available subsystems, type: | |||
349 | The "xxx" is not interpreted by the cgroup code, but will appear in | 349 | The "xxx" is not interpreted by the cgroup code, but will appear in |
350 | /proc/mounts so may be any useful identifying string that you like. | 350 | /proc/mounts so may be any useful identifying string that you like. |
351 | 351 | ||
352 | Note: Some subsystems do not work without some user input first. For instance, | ||
353 | if cpusets are enabled the user will have to populate the cpus and mems files | ||
354 | for each new cgroup created before that group can be used. | ||
355 | |||
352 | To mount a cgroup hierarchy with just the cpuset and memory | 356 | To mount a cgroup hierarchy with just the cpuset and memory |
353 | subsystems, type: | 357 | subsystems, type: |
354 | # mount -t cgroup -o cpuset,memory hier1 /dev/cgroup | 358 | # mount -t cgroup -o cpuset,memory hier1 /dev/cgroup |
@@ -426,6 +430,14 @@ You can attach the current shell task by echoing 0: | |||
426 | 430 | ||
427 | # echo 0 > tasks | 431 | # echo 0 > tasks |
428 | 432 | ||
433 | Note: Since every task is always a member of exactly one cgroup in each | ||
434 | mounted hierarchy, to remove a task from its current cgroup you must | ||
435 | move it into a new cgroup (possibly the root cgroup) by writing to the | ||
436 | new cgroup's tasks file. | ||
437 | |||
438 | Note: If the ns cgroup is active, moving a process to another cgroup can | ||
439 | fail. | ||
440 | |||
429 | 2.3 Mounting hierarchies by name | 441 | 2.3 Mounting hierarchies by name |
430 | -------------------------------- | 442 | -------------------------------- |
431 | 443 | ||
diff --git a/Documentation/devicetree/00-INDEX b/Documentation/devicetree/00-INDEX new file mode 100644 index 000000000000..b78f691fd847 --- /dev/null +++ b/Documentation/devicetree/00-INDEX | |||
@@ -0,0 +1,10 @@ | |||
1 | Documentation for device trees, a data structure by which bootloaders pass | ||
2 | hardware layout to Linux in a device-independent manner, simplifying hardware | ||
3 | probing. This subsystem is maintained by Grant Likely | ||
4 | <grant.likely@secretlab.ca> and has a mailing list at | ||
5 | https://lists.ozlabs.org/listinfo/devicetree-discuss | ||
6 | |||
7 | 00-INDEX | ||
8 | - this file | ||
9 | booting-without-of.txt | ||
10 | - Booting Linux without Open Firmware, describes history and format of device trees. | ||
diff --git a/Documentation/devicetree/bindings/i2c/ce4100-i2c.txt b/Documentation/devicetree/bindings/i2c/ce4100-i2c.txt new file mode 100644 index 000000000000..569b16248514 --- /dev/null +++ b/Documentation/devicetree/bindings/i2c/ce4100-i2c.txt | |||
@@ -0,0 +1,93 @@ | |||
1 | CE4100 I2C | ||
2 | ---------- | ||
3 | |||
4 | CE4100 has one PCI device which is described as the I2C-Controller. This | ||
5 | PCI device has three PCI-bars, each bar contains a complete I2C | ||
6 | controller. So we have a total of three independent I2C-Controllers | ||
7 | which share only an interrupt line. | ||
8 | The driver is probed via the PCI-ID and is gathering the information of | ||
9 | attached devices from the devices tree. | ||
10 | Grant Likely recommended to use the ranges property to map the PCI-Bar | ||
11 | number to its physical address and to use this to find the child nodes | ||
12 | of the specific I2C controller. This were his exact words: | ||
13 | |||
14 | Here's where the magic happens. Each entry in | ||
15 | ranges describes how the parent pci address space | ||
16 | (middle group of 3) is translated to the local | ||
17 | address space (first group of 2) and the size of | ||
18 | each range (last cell). In this particular case, | ||
19 | the first cell of the local address is chosen to be | ||
20 | 1:1 mapped to the BARs, and the second is the | ||
21 | offset from be base of the BAR (which would be | ||
22 | non-zero if you had 2 or more devices mapped off | ||
23 | the same BAR) | ||
24 | |||
25 | ranges allows the address mapping to be described | ||
26 | in a way that the OS can interpret without | ||
27 | requiring custom device driver code. | ||
28 | |||
29 | This is an example which is used on FalconFalls: | ||
30 | ------------------------------------------------ | ||
31 | i2c-controller@b,2 { | ||
32 | #address-cells = <2>; | ||
33 | #size-cells = <1>; | ||
34 | compatible = "pci8086,2e68.2", | ||
35 | "pci8086,2e68", | ||
36 | "pciclass,ff0000", | ||
37 | "pciclass,ff00"; | ||
38 | |||
39 | reg = <0x15a00 0x0 0x0 0x0 0x0>; | ||
40 | interrupts = <16 1>; | ||
41 | |||
42 | /* as described by Grant, the first number in the group of | ||
43 | * three is the bar number followed by the 64bit bar address | ||
44 | * followed by size of the mapping. The bar address | ||
45 | * requires also a valid translation in parents ranges | ||
46 | * property. | ||
47 | */ | ||
48 | ranges = <0 0 0x02000000 0 0xdffe0500 0x100 | ||
49 | 1 0 0x02000000 0 0xdffe0600 0x100 | ||
50 | 2 0 0x02000000 0 0xdffe0700 0x100>; | ||
51 | |||
52 | i2c@0 { | ||
53 | #address-cells = <1>; | ||
54 | #size-cells = <0>; | ||
55 | compatible = "intel,ce4100-i2c-controller"; | ||
56 | |||
57 | /* The first number in the reg property is the | ||
58 | * number of the bar | ||
59 | */ | ||
60 | reg = <0 0 0x100>; | ||
61 | |||
62 | /* This I2C controller has no devices */ | ||
63 | }; | ||
64 | |||
65 | i2c@1 { | ||
66 | #address-cells = <1>; | ||
67 | #size-cells = <0>; | ||
68 | compatible = "intel,ce4100-i2c-controller"; | ||
69 | reg = <1 0 0x100>; | ||
70 | |||
71 | /* This I2C controller has one gpio controller */ | ||
72 | gpio@26 { | ||
73 | #gpio-cells = <2>; | ||
74 | compatible = "ti,pcf8575"; | ||
75 | reg = <0x26>; | ||
76 | gpio-controller; | ||
77 | }; | ||
78 | }; | ||
79 | |||
80 | i2c@2 { | ||
81 | #address-cells = <1>; | ||
82 | #size-cells = <0>; | ||
83 | compatible = "intel,ce4100-i2c-controller"; | ||
84 | reg = <2 0 0x100>; | ||
85 | |||
86 | gpio@26 { | ||
87 | #gpio-cells = <2>; | ||
88 | compatible = "ti,pcf8575"; | ||
89 | reg = <0x26>; | ||
90 | gpio-controller; | ||
91 | }; | ||
92 | }; | ||
93 | }; | ||
diff --git a/Documentation/devicetree/bindings/rtc/rtc-cmos.txt b/Documentation/devicetree/bindings/rtc/rtc-cmos.txt new file mode 100644 index 000000000000..7382989b3052 --- /dev/null +++ b/Documentation/devicetree/bindings/rtc/rtc-cmos.txt | |||
@@ -0,0 +1,28 @@ | |||
1 | Motorola mc146818 compatible RTC | ||
2 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
3 | |||
4 | Required properties: | ||
5 | - compatible : "motorola,mc146818" | ||
6 | - reg : should contain registers location and length. | ||
7 | |||
8 | Optional properties: | ||
9 | - interrupts : should contain interrupt. | ||
10 | - interrupt-parent : interrupt source phandle. | ||
11 | - ctrl-reg : Contains the initial value of the control register also | ||
12 | called "Register B". | ||
13 | - freq-reg : Contains the initial value of the frequency register also | ||
14 | called "Regsiter A". | ||
15 | |||
16 | "Register A" and "B" are usually initialized by the firmware (BIOS for | ||
17 | instance). If this is not done, it can be performed by the driver. | ||
18 | |||
19 | ISA Example: | ||
20 | |||
21 | rtc@70 { | ||
22 | compatible = "motorola,mc146818"; | ||
23 | interrupts = <8 3>; | ||
24 | interrupt-parent = <&ioapic1>; | ||
25 | ctrl-reg = <2>; | ||
26 | freq-reg = <0x26>; | ||
27 | reg = <1 0x70 2>; | ||
28 | }; | ||
diff --git a/Documentation/devicetree/bindings/serial/altera_jtaguart.txt b/Documentation/devicetree/bindings/serial/altera_jtaguart.txt new file mode 100644 index 000000000000..c152f65f9a28 --- /dev/null +++ b/Documentation/devicetree/bindings/serial/altera_jtaguart.txt | |||
@@ -0,0 +1,4 @@ | |||
1 | Altera JTAG UART | ||
2 | |||
3 | Required properties: | ||
4 | - compatible : should be "ALTR,juart-1.0" | ||
diff --git a/Documentation/devicetree/bindings/serial/altera_uart.txt b/Documentation/devicetree/bindings/serial/altera_uart.txt new file mode 100644 index 000000000000..71cae3f70100 --- /dev/null +++ b/Documentation/devicetree/bindings/serial/altera_uart.txt | |||
@@ -0,0 +1,7 @@ | |||
1 | Altera UART | ||
2 | |||
3 | Required properties: | ||
4 | - compatible : should be "ALTR,uart-1.0" | ||
5 | |||
6 | Optional properties: | ||
7 | - clock-frequency : frequency of the clock input to the UART | ||
diff --git a/Documentation/devicetree/bindings/serio/altera_ps2.txt b/Documentation/devicetree/bindings/serio/altera_ps2.txt new file mode 100644 index 000000000000..4d9eecc2ef7d --- /dev/null +++ b/Documentation/devicetree/bindings/serio/altera_ps2.txt | |||
@@ -0,0 +1,4 @@ | |||
1 | Altera UP PS/2 controller | ||
2 | |||
3 | Required properties: | ||
4 | - compatible : should be "ALTR,ps2-1.0". | ||
diff --git a/Documentation/devicetree/bindings/x86/ce4100.txt b/Documentation/devicetree/bindings/x86/ce4100.txt new file mode 100644 index 000000000000..b49ae593a60b --- /dev/null +++ b/Documentation/devicetree/bindings/x86/ce4100.txt | |||
@@ -0,0 +1,38 @@ | |||
1 | CE4100 Device Tree Bindings | ||
2 | --------------------------- | ||
3 | |||
4 | The CE4100 SoC uses for in core peripherals the following compatible | ||
5 | format: <vendor>,<chip>-<device>. | ||
6 | Many of the "generic" devices like HPET or IO APIC have the ce4100 | ||
7 | name in their compatible property because they first appeared in this | ||
8 | SoC. | ||
9 | |||
10 | The CPU node | ||
11 | ------------ | ||
12 | cpu@0 { | ||
13 | device_type = "cpu"; | ||
14 | compatible = "intel,ce4100"; | ||
15 | reg = <0>; | ||
16 | lapic = <&lapic0>; | ||
17 | }; | ||
18 | |||
19 | The reg property describes the CPU number. The lapic property points to | ||
20 | the local APIC timer. | ||
21 | |||
22 | The SoC node | ||
23 | ------------ | ||
24 | |||
25 | This node describes the in-core peripherals. Required property: | ||
26 | compatible = "intel,ce4100-cp"; | ||
27 | |||
28 | The PCI node | ||
29 | ------------ | ||
30 | This node describes the PCI bus on the SoC. Its property should be | ||
31 | compatible = "intel,ce4100-pci", "pci"; | ||
32 | |||
33 | If the OS is using the IO-APIC for interrupt routing then the reported | ||
34 | interrupt numbers for devices is no longer true. In order to obtain the | ||
35 | correct interrupt number, the child node which represents the device has | ||
36 | to contain the interrupt property. Besides the interrupt property it has | ||
37 | to contain at least the reg property containing the PCI bus address and | ||
38 | compatible property according to "PCI Bus Binding Revision 2.1". | ||
diff --git a/Documentation/devicetree/bindings/x86/interrupt.txt b/Documentation/devicetree/bindings/x86/interrupt.txt new file mode 100644 index 000000000000..7d19f494f19a --- /dev/null +++ b/Documentation/devicetree/bindings/x86/interrupt.txt | |||
@@ -0,0 +1,26 @@ | |||
1 | Interrupt chips | ||
2 | --------------- | ||
3 | |||
4 | * Intel I/O Advanced Programmable Interrupt Controller (IO APIC) | ||
5 | |||
6 | Required properties: | ||
7 | -------------------- | ||
8 | compatible = "intel,ce4100-ioapic"; | ||
9 | #interrupt-cells = <2>; | ||
10 | |||
11 | Device's interrupt property: | ||
12 | |||
13 | interrupts = <P S>; | ||
14 | |||
15 | The first number (P) represents the interrupt pin which is wired to the | ||
16 | IO APIC. The second number (S) represents the sense of interrupt which | ||
17 | should be configured and can be one of: | ||
18 | 0 - Edge Rising | ||
19 | 1 - Level Low | ||
20 | 2 - Level High | ||
21 | 3 - Edge Falling | ||
22 | |||
23 | * Local APIC | ||
24 | Required property: | ||
25 | |||
26 | compatible = "intel,ce4100-lapic"; | ||
diff --git a/Documentation/devicetree/bindings/x86/timer.txt b/Documentation/devicetree/bindings/x86/timer.txt new file mode 100644 index 000000000000..c688af58e3bd --- /dev/null +++ b/Documentation/devicetree/bindings/x86/timer.txt | |||
@@ -0,0 +1,6 @@ | |||
1 | Timers | ||
2 | ------ | ||
3 | |||
4 | * High Precision Event Timer (HPET) | ||
5 | Required property: | ||
6 | compatible = "intel,ce4100-hpet"; | ||
diff --git a/Documentation/devicetree/booting-without-of.txt b/Documentation/devicetree/booting-without-of.txt index 28b1c9d3d351..55fd2623445b 100644 --- a/Documentation/devicetree/booting-without-of.txt +++ b/Documentation/devicetree/booting-without-of.txt | |||
@@ -13,6 +13,7 @@ Table of Contents | |||
13 | 13 | ||
14 | I - Introduction | 14 | I - Introduction |
15 | 1) Entry point for arch/powerpc | 15 | 1) Entry point for arch/powerpc |
16 | 2) Entry point for arch/x86 | ||
16 | 17 | ||
17 | II - The DT block format | 18 | II - The DT block format |
18 | 1) Header | 19 | 1) Header |
@@ -225,6 +226,25 @@ it with special cases. | |||
225 | cannot support both configurations with Book E and configurations | 226 | cannot support both configurations with Book E and configurations |
226 | with classic Powerpc architectures. | 227 | with classic Powerpc architectures. |
227 | 228 | ||
229 | 2) Entry point for arch/x86 | ||
230 | ------------------------------- | ||
231 | |||
232 | There is one single 32bit entry point to the kernel at code32_start, | ||
233 | the decompressor (the real mode entry point goes to the same 32bit | ||
234 | entry point once it switched into protected mode). That entry point | ||
235 | supports one calling convention which is documented in | ||
236 | Documentation/x86/boot.txt | ||
237 | The physical pointer to the device-tree block (defined in chapter II) | ||
238 | is passed via setup_data which requires at least boot protocol 2.09. | ||
239 | The type filed is defined as | ||
240 | |||
241 | #define SETUP_DTB 2 | ||
242 | |||
243 | This device-tree is used as an extension to the "boot page". As such it | ||
244 | does not parse / consider data which is already covered by the boot | ||
245 | page. This includes memory size, reserved ranges, command line arguments | ||
246 | or initrd address. It simply holds information which can not be retrieved | ||
247 | otherwise like interrupt routing or a list of devices behind an I2C bus. | ||
228 | 248 | ||
229 | II - The DT block format | 249 | II - The DT block format |
230 | ======================== | 250 | ======================== |
diff --git a/Documentation/dynamic-debug-howto.txt b/Documentation/dynamic-debug-howto.txt index 58ea64a96165..e6c4b757025b 100644 --- a/Documentation/dynamic-debug-howto.txt +++ b/Documentation/dynamic-debug-howto.txt | |||
@@ -205,12 +205,20 @@ of the characters: | |||
205 | 205 | ||
206 | The flags are: | 206 | The flags are: |
207 | 207 | ||
208 | f | ||
209 | Include the function name in the printed message | ||
210 | l | ||
211 | Include line number in the printed message | ||
212 | m | ||
213 | Include module name in the printed message | ||
208 | p | 214 | p |
209 | Causes a printk() message to be emitted to dmesg | 215 | Causes a printk() message to be emitted to dmesg |
216 | t | ||
217 | Include thread ID in messages not generated from interrupt context | ||
210 | 218 | ||
211 | Note the regexp ^[-+=][scp]+$ matches a flags specification. | 219 | Note the regexp ^[-+=][flmpt]+$ matches a flags specification. |
212 | Note also that there is no convenient syntax to remove all | 220 | Note also that there is no convenient syntax to remove all |
213 | the flags at once, you need to use "-psc". | 221 | the flags at once, you need to use "-flmpt". |
214 | 222 | ||
215 | 223 | ||
216 | Debug messages during boot process | 224 | Debug messages during boot process |
diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt index b3f35e5f9c95..f487c6918d78 100644 --- a/Documentation/feature-removal-schedule.txt +++ b/Documentation/feature-removal-schedule.txt | |||
@@ -35,6 +35,17 @@ Who: Luis R. Rodriguez <lrodriguez@atheros.com> | |||
35 | 35 | ||
36 | --------------------------- | 36 | --------------------------- |
37 | 37 | ||
38 | What: AR9170USB | ||
39 | When: 2.6.40 | ||
40 | |||
41 | Why: This driver is deprecated and the firmware is no longer | ||
42 | maintained. The replacement driver "carl9170" has been | ||
43 | around for a while, so the devices are still supported. | ||
44 | |||
45 | Who: Christian Lamparter <chunkeey@googlemail.com> | ||
46 | |||
47 | --------------------------- | ||
48 | |||
38 | What: IRQF_SAMPLE_RANDOM | 49 | What: IRQF_SAMPLE_RANDOM |
39 | Check: IRQF_SAMPLE_RANDOM | 50 | Check: IRQF_SAMPLE_RANDOM |
40 | When: July 2009 | 51 | When: July 2009 |
@@ -604,6 +615,13 @@ Who: Jean Delvare <khali@linux-fr.org> | |||
604 | 615 | ||
605 | ---------------------------- | 616 | ---------------------------- |
606 | 617 | ||
618 | What: xt_connlimit rev 0 | ||
619 | When: 2012 | ||
620 | Who: Jan Engelhardt <jengelh@medozas.de> | ||
621 | Files: net/netfilter/xt_connlimit.c | ||
622 | |||
623 | ---------------------------- | ||
624 | |||
607 | What: noswapaccount kernel command line parameter | 625 | What: noswapaccount kernel command line parameter |
608 | When: 2.6.40 | 626 | When: 2.6.40 |
609 | Why: The original implementation of memsw feature enabled by | 627 | Why: The original implementation of memsw feature enabled by |
@@ -619,3 +637,11 @@ Why: The original implementation of memsw feature enabled by | |||
619 | Who: Michal Hocko <mhocko@suse.cz> | 637 | Who: Michal Hocko <mhocko@suse.cz> |
620 | 638 | ||
621 | ---------------------------- | 639 | ---------------------------- |
640 | |||
641 | What: ipt_addrtype match include file | ||
642 | When: 2012 | ||
643 | Why: superseded by xt_addrtype | ||
644 | Who: Florian Westphal <fw@strlen.de> | ||
645 | Files: include/linux/netfilter_ipv4/ipt_addrtype.h | ||
646 | |||
647 | ---------------------------- | ||
diff --git a/Documentation/filesystems/Locking b/Documentation/filesystems/Locking index 4471a416c274..2e994efe12cb 100644 --- a/Documentation/filesystems/Locking +++ b/Documentation/filesystems/Locking | |||
@@ -166,13 +166,11 @@ prototypes: | |||
166 | void (*kill_sb) (struct super_block *); | 166 | void (*kill_sb) (struct super_block *); |
167 | locking rules: | 167 | locking rules: |
168 | may block | 168 | may block |
169 | get_sb yes | ||
170 | mount yes | 169 | mount yes |
171 | kill_sb yes | 170 | kill_sb yes |
172 | 171 | ||
173 | ->get_sb() returns error or 0 with locked superblock attached to the vfsmount | 172 | ->mount() returns ERR_PTR or the root dentry; its superblock should be locked |
174 | (exclusive on ->s_umount). | 173 | on return. |
175 | ->mount() returns ERR_PTR or the root dentry. | ||
176 | ->kill_sb() takes a write-locked superblock, does all shutdown work on it, | 174 | ->kill_sb() takes a write-locked superblock, does all shutdown work on it, |
177 | unlocks and drops the reference. | 175 | unlocks and drops the reference. |
178 | 176 | ||
diff --git a/Documentation/filesystems/porting b/Documentation/filesystems/porting index dfbcd1b00b0a..0c986c9e8519 100644 --- a/Documentation/filesystems/porting +++ b/Documentation/filesystems/porting | |||
@@ -394,3 +394,10 @@ file) you must return -EOPNOTSUPP if FALLOC_FL_PUNCH_HOLE is set in mode. | |||
394 | Currently you can only have FALLOC_FL_PUNCH_HOLE with FALLOC_FL_KEEP_SIZE set, | 394 | Currently you can only have FALLOC_FL_PUNCH_HOLE with FALLOC_FL_KEEP_SIZE set, |
395 | so the i_size should not change when hole punching, even when puching the end of | 395 | so the i_size should not change when hole punching, even when puching the end of |
396 | a file off. | 396 | a file off. |
397 | |||
398 | -- | ||
399 | [mandatory] | ||
400 | ->get_sb() is gone. Switch to use of ->mount(). Typically it's just | ||
401 | a matter of switching from calling get_sb_... to mount_... and changing the | ||
402 | function type. If you were doing it manually, just switch from setting ->mnt_root | ||
403 | to some pointer to returning that pointer. On errors return ERR_PTR(...). | ||
diff --git a/Documentation/filesystems/sysfs.txt b/Documentation/filesystems/sysfs.txt index 5d1335faec2d..f806e50aaa63 100644 --- a/Documentation/filesystems/sysfs.txt +++ b/Documentation/filesystems/sysfs.txt | |||
@@ -39,10 +39,12 @@ userspace. Top-level directories in sysfs represent the common | |||
39 | ancestors of object hierarchies; i.e. the subsystems the objects | 39 | ancestors of object hierarchies; i.e. the subsystems the objects |
40 | belong to. | 40 | belong to. |
41 | 41 | ||
42 | Sysfs internally stores the kobject that owns the directory in the | 42 | Sysfs internally stores a pointer to the kobject that implements a |
43 | ->d_fsdata pointer of the directory's dentry. This allows sysfs to do | 43 | directory in the sysfs_dirent object associated with the directory. In |
44 | reference counting directly on the kobject when the file is opened and | 44 | the past this kobject pointer has been used by sysfs to do reference |
45 | closed. | 45 | counting directly on the kobject whenever the file is opened or closed. |
46 | With the current sysfs implementation the kobject reference count is | ||
47 | only modified directly by the function sysfs_schedule_callback(). | ||
46 | 48 | ||
47 | 49 | ||
48 | Attributes | 50 | Attributes |
@@ -208,9 +210,9 @@ Other notes: | |||
208 | is 4096. | 210 | is 4096. |
209 | 211 | ||
210 | - show() methods should return the number of bytes printed into the | 212 | - show() methods should return the number of bytes printed into the |
211 | buffer. This is the return value of snprintf(). | 213 | buffer. This is the return value of scnprintf(). |
212 | 214 | ||
213 | - show() should always use snprintf(). | 215 | - show() should always use scnprintf(). |
214 | 216 | ||
215 | - store() should return the number of bytes used from the buffer. If the | 217 | - store() should return the number of bytes used from the buffer. If the |
216 | entire buffer has been used, just return the count argument. | 218 | entire buffer has been used, just return the count argument. |
@@ -229,7 +231,7 @@ A very simple (and naive) implementation of a device attribute is: | |||
229 | static ssize_t show_name(struct device *dev, struct device_attribute *attr, | 231 | static ssize_t show_name(struct device *dev, struct device_attribute *attr, |
230 | char *buf) | 232 | char *buf) |
231 | { | 233 | { |
232 | return snprintf(buf, PAGE_SIZE, "%s\n", dev->name); | 234 | return scnprintf(buf, PAGE_SIZE, "%s\n", dev->name); |
233 | } | 235 | } |
234 | 236 | ||
235 | static ssize_t store_name(struct device *dev, struct device_attribute *attr, | 237 | static ssize_t store_name(struct device *dev, struct device_attribute *attr, |
diff --git a/Documentation/filesystems/vfs.txt b/Documentation/filesystems/vfs.txt index 94cf97b901d7..ef0714aa8e40 100644 --- a/Documentation/filesystems/vfs.txt +++ b/Documentation/filesystems/vfs.txt | |||
@@ -95,10 +95,11 @@ functions: | |||
95 | extern int unregister_filesystem(struct file_system_type *); | 95 | extern int unregister_filesystem(struct file_system_type *); |
96 | 96 | ||
97 | The passed struct file_system_type describes your filesystem. When a | 97 | The passed struct file_system_type describes your filesystem. When a |
98 | request is made to mount a device onto a directory in your filespace, | 98 | request is made to mount a filesystem onto a directory in your namespace, |
99 | the VFS will call the appropriate get_sb() method for the specific | 99 | the VFS will call the appropriate mount() method for the specific |
100 | filesystem. The dentry for the mount point will then be updated to | 100 | filesystem. New vfsmount refering to the tree returned by ->mount() |
101 | point to the root inode for the new filesystem. | 101 | will be attached to the mountpoint, so that when pathname resolution |
102 | reaches the mountpoint it will jump into the root of that vfsmount. | ||
102 | 103 | ||
103 | You can see all filesystems that are registered to the kernel in the | 104 | You can see all filesystems that are registered to the kernel in the |
104 | file /proc/filesystems. | 105 | file /proc/filesystems. |
@@ -107,14 +108,14 @@ file /proc/filesystems. | |||
107 | struct file_system_type | 108 | struct file_system_type |
108 | ----------------------- | 109 | ----------------------- |
109 | 110 | ||
110 | This describes the filesystem. As of kernel 2.6.22, the following | 111 | This describes the filesystem. As of kernel 2.6.39, the following |
111 | members are defined: | 112 | members are defined: |
112 | 113 | ||
113 | struct file_system_type { | 114 | struct file_system_type { |
114 | const char *name; | 115 | const char *name; |
115 | int fs_flags; | 116 | int fs_flags; |
116 | int (*get_sb) (struct file_system_type *, int, | 117 | struct dentry (*mount) (struct file_system_type *, int, |
117 | const char *, void *, struct vfsmount *); | 118 | const char *, void *); |
118 | void (*kill_sb) (struct super_block *); | 119 | void (*kill_sb) (struct super_block *); |
119 | struct module *owner; | 120 | struct module *owner; |
120 | struct file_system_type * next; | 121 | struct file_system_type * next; |
@@ -128,11 +129,11 @@ struct file_system_type { | |||
128 | 129 | ||
129 | fs_flags: various flags (i.e. FS_REQUIRES_DEV, FS_NO_DCACHE, etc.) | 130 | fs_flags: various flags (i.e. FS_REQUIRES_DEV, FS_NO_DCACHE, etc.) |
130 | 131 | ||
131 | get_sb: the method to call when a new instance of this | 132 | mount: the method to call when a new instance of this |
132 | filesystem should be mounted | 133 | filesystem should be mounted |
133 | 134 | ||
134 | kill_sb: the method to call when an instance of this filesystem | 135 | kill_sb: the method to call when an instance of this filesystem |
135 | should be unmounted | 136 | should be shut down |
136 | 137 | ||
137 | owner: for internal VFS use: you should initialize this to THIS_MODULE in | 138 | owner: for internal VFS use: you should initialize this to THIS_MODULE in |
138 | most cases. | 139 | most cases. |
@@ -141,7 +142,7 @@ struct file_system_type { | |||
141 | 142 | ||
142 | s_lock_key, s_umount_key: lockdep-specific | 143 | s_lock_key, s_umount_key: lockdep-specific |
143 | 144 | ||
144 | The get_sb() method has the following arguments: | 145 | The mount() method has the following arguments: |
145 | 146 | ||
146 | struct file_system_type *fs_type: describes the filesystem, partly initialized | 147 | struct file_system_type *fs_type: describes the filesystem, partly initialized |
147 | by the specific filesystem code | 148 | by the specific filesystem code |
@@ -153,32 +154,39 @@ The get_sb() method has the following arguments: | |||
153 | void *data: arbitrary mount options, usually comes as an ASCII | 154 | void *data: arbitrary mount options, usually comes as an ASCII |
154 | string (see "Mount Options" section) | 155 | string (see "Mount Options" section) |
155 | 156 | ||
156 | struct vfsmount *mnt: a vfs-internal representation of a mount point | 157 | The mount() method must return the root dentry of the tree requested by |
158 | caller. An active reference to its superblock must be grabbed and the | ||
159 | superblock must be locked. On failure it should return ERR_PTR(error). | ||
157 | 160 | ||
158 | The get_sb() method must determine if the block device specified | 161 | The arguments match those of mount(2) and their interpretation |
159 | in the dev_name and fs_type contains a filesystem of the type the method | 162 | depends on filesystem type. E.g. for block filesystems, dev_name is |
160 | supports. If it succeeds in opening the named block device, it initializes a | 163 | interpreted as block device name, that device is opened and if it |
161 | struct super_block descriptor for the filesystem contained by the block device. | 164 | contains a suitable filesystem image the method creates and initializes |
162 | On failure it returns an error. | 165 | struct super_block accordingly, returning its root dentry to caller. |
166 | |||
167 | ->mount() may choose to return a subtree of existing filesystem - it | ||
168 | doesn't have to create a new one. The main result from the caller's | ||
169 | point of view is a reference to dentry at the root of (sub)tree to | ||
170 | be attached; creation of new superblock is a common side effect. | ||
163 | 171 | ||
164 | The most interesting member of the superblock structure that the | 172 | The most interesting member of the superblock structure that the |
165 | get_sb() method fills in is the "s_op" field. This is a pointer to | 173 | mount() method fills in is the "s_op" field. This is a pointer to |
166 | a "struct super_operations" which describes the next level of the | 174 | a "struct super_operations" which describes the next level of the |
167 | filesystem implementation. | 175 | filesystem implementation. |
168 | 176 | ||
169 | Usually, a filesystem uses one of the generic get_sb() implementations | 177 | Usually, a filesystem uses one of the generic mount() implementations |
170 | and provides a fill_super() method instead. The generic methods are: | 178 | and provides a fill_super() callback instead. The generic variants are: |
171 | 179 | ||
172 | get_sb_bdev: mount a filesystem residing on a block device | 180 | mount_bdev: mount a filesystem residing on a block device |
173 | 181 | ||
174 | get_sb_nodev: mount a filesystem that is not backed by a device | 182 | mount_nodev: mount a filesystem that is not backed by a device |
175 | 183 | ||
176 | get_sb_single: mount a filesystem which shares the instance between | 184 | mount_single: mount a filesystem which shares the instance between |
177 | all mounts | 185 | all mounts |
178 | 186 | ||
179 | A fill_super() method implementation has the following arguments: | 187 | A fill_super() callback implementation has the following arguments: |
180 | 188 | ||
181 | struct super_block *sb: the superblock structure. The method fill_super() | 189 | struct super_block *sb: the superblock structure. The callback |
182 | must initialize this properly. | 190 | must initialize this properly. |
183 | 191 | ||
184 | void *data: arbitrary mount options, usually comes as an ASCII | 192 | void *data: arbitrary mount options, usually comes as an ASCII |
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt index f4a04c0c7edc..738c6fda3fb0 100644 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt | |||
@@ -2444,6 +2444,10 @@ bytes respectively. Such letter suffixes can also be entirely omitted. | |||
2444 | <deci-seconds>: poll all this frequency | 2444 | <deci-seconds>: poll all this frequency |
2445 | 0: no polling (default) | 2445 | 0: no polling (default) |
2446 | 2446 | ||
2447 | threadirqs [KNL] | ||
2448 | Force threading of all interrupt handlers except those | ||
2449 | marked explicitely IRQF_NO_THREAD. | ||
2450 | |||
2447 | topology= [S390] | 2451 | topology= [S390] |
2448 | Format: {off | on} | 2452 | Format: {off | on} |
2449 | Specify if the kernel should make use of the cpu | 2453 | Specify if the kernel should make use of the cpu |
diff --git a/Documentation/keys-request-key.txt b/Documentation/keys-request-key.txt index 09b55e461740..69686ad12c66 100644 --- a/Documentation/keys-request-key.txt +++ b/Documentation/keys-request-key.txt | |||
@@ -127,14 +127,15 @@ This is because process A's keyrings can't simply be attached to | |||
127 | of them, and (b) it requires the same UID/GID/Groups all the way through. | 127 | of them, and (b) it requires the same UID/GID/Groups all the way through. |
128 | 128 | ||
129 | 129 | ||
130 | ====================== | 130 | ==================================== |
131 | NEGATIVE INSTANTIATION | 131 | NEGATIVE INSTANTIATION AND REJECTION |
132 | ====================== | 132 | ==================================== |
133 | 133 | ||
134 | Rather than instantiating a key, it is possible for the possessor of an | 134 | Rather than instantiating a key, it is possible for the possessor of an |
135 | authorisation key to negatively instantiate a key that's under construction. | 135 | authorisation key to negatively instantiate a key that's under construction. |
136 | This is a short duration placeholder that causes any attempt at re-requesting | 136 | This is a short duration placeholder that causes any attempt at re-requesting |
137 | the key whilst it exists to fail with error ENOKEY. | 137 | the key whilst it exists to fail with error ENOKEY if negated or the specified |
138 | error if rejected. | ||
138 | 139 | ||
139 | This is provided to prevent excessive repeated spawning of /sbin/request-key | 140 | This is provided to prevent excessive repeated spawning of /sbin/request-key |
140 | processes for a key that will never be obtainable. | 141 | processes for a key that will never be obtainable. |
diff --git a/Documentation/keys.txt b/Documentation/keys.txt index e4dbbdb1bd96..6523a9e6f293 100644 --- a/Documentation/keys.txt +++ b/Documentation/keys.txt | |||
@@ -637,6 +637,9 @@ The keyctl syscall functions are: | |||
637 | long keyctl(KEYCTL_INSTANTIATE, key_serial_t key, | 637 | long keyctl(KEYCTL_INSTANTIATE, key_serial_t key, |
638 | const void *payload, size_t plen, | 638 | const void *payload, size_t plen, |
639 | key_serial_t keyring); | 639 | key_serial_t keyring); |
640 | long keyctl(KEYCTL_INSTANTIATE_IOV, key_serial_t key, | ||
641 | const struct iovec *payload_iov, unsigned ioc, | ||
642 | key_serial_t keyring); | ||
640 | 643 | ||
641 | If the kernel calls back to userspace to complete the instantiation of a | 644 | If the kernel calls back to userspace to complete the instantiation of a |
642 | key, userspace should use this call to supply data for the key before the | 645 | key, userspace should use this call to supply data for the key before the |
@@ -652,11 +655,16 @@ The keyctl syscall functions are: | |||
652 | 655 | ||
653 | The payload and plen arguments describe the payload data as for add_key(). | 656 | The payload and plen arguments describe the payload data as for add_key(). |
654 | 657 | ||
658 | The payload_iov and ioc arguments describe the payload data in an iovec | ||
659 | array instead of a single buffer. | ||
660 | |||
655 | 661 | ||
656 | (*) Negatively instantiate a partially constructed key. | 662 | (*) Negatively instantiate a partially constructed key. |
657 | 663 | ||
658 | long keyctl(KEYCTL_NEGATE, key_serial_t key, | 664 | long keyctl(KEYCTL_NEGATE, key_serial_t key, |
659 | unsigned timeout, key_serial_t keyring); | 665 | unsigned timeout, key_serial_t keyring); |
666 | long keyctl(KEYCTL_REJECT, key_serial_t key, | ||
667 | unsigned timeout, unsigned error, key_serial_t keyring); | ||
660 | 668 | ||
661 | If the kernel calls back to userspace to complete the instantiation of a | 669 | If the kernel calls back to userspace to complete the instantiation of a |
662 | key, userspace should use this call mark the key as negative before the | 670 | key, userspace should use this call mark the key as negative before the |
@@ -669,6 +677,10 @@ The keyctl syscall functions are: | |||
669 | that keyring, however all the constraints applying in KEYCTL_LINK apply in | 677 | that keyring, however all the constraints applying in KEYCTL_LINK apply in |
670 | this case too. | 678 | this case too. |
671 | 679 | ||
680 | If the key is rejected, future searches for it will return the specified | ||
681 | error code until the rejected key expires. Negating the key is the same | ||
682 | as rejecting the key with ENOKEY as the error code. | ||
683 | |||
672 | 684 | ||
673 | (*) Set the default request-key destination keyring. | 685 | (*) Set the default request-key destination keyring. |
674 | 686 | ||
@@ -1062,6 +1074,13 @@ The structure has a number of fields, some of which are mandatory: | |||
1062 | viable. | 1074 | viable. |
1063 | 1075 | ||
1064 | 1076 | ||
1077 | (*) int (*vet_description)(const char *description); | ||
1078 | |||
1079 | This optional method is called to vet a key description. If the key type | ||
1080 | doesn't approve of the key description, it may return an error, otherwise | ||
1081 | it should return 0. | ||
1082 | |||
1083 | |||
1065 | (*) int (*instantiate)(struct key *key, const void *data, size_t datalen); | 1084 | (*) int (*instantiate)(struct key *key, const void *data, size_t datalen); |
1066 | 1085 | ||
1067 | This method is called to attach a payload to a key during construction. | 1086 | This method is called to attach a payload to a key during construction. |
@@ -1231,10 +1250,11 @@ hand the request off to (perhaps a path held in placed in another key by, for | |||
1231 | example, the KDE desktop manager). | 1250 | example, the KDE desktop manager). |
1232 | 1251 | ||
1233 | The program (or whatever it calls) should finish construction of the key by | 1252 | The program (or whatever it calls) should finish construction of the key by |
1234 | calling KEYCTL_INSTANTIATE, which also permits it to cache the key in one of | 1253 | calling KEYCTL_INSTANTIATE or KEYCTL_INSTANTIATE_IOV, which also permits it to |
1235 | the keyrings (probably the session ring) before returning. Alternatively, the | 1254 | cache the key in one of the keyrings (probably the session ring) before |
1236 | key can be marked as negative with KEYCTL_NEGATE; this also permits the key to | 1255 | returning. Alternatively, the key can be marked as negative with KEYCTL_NEGATE |
1237 | be cached in one of the keyrings. | 1256 | or KEYCTL_REJECT; this also permits the key to be cached in one of the |
1257 | keyrings. | ||
1238 | 1258 | ||
1239 | If it returns with the key remaining in the unconstructed state, the key will | 1259 | If it returns with the key remaining in the unconstructed state, the key will |
1240 | be marked as being negative, it will be added to the session keyring, and an | 1260 | be marked as being negative, it will be added to the session keyring, and an |
diff --git a/Documentation/kref.txt b/Documentation/kref.txt index ae203f91ee9b..48ba715d5a63 100644 --- a/Documentation/kref.txt +++ b/Documentation/kref.txt | |||
@@ -156,7 +156,7 @@ static struct my_data *get_entry() | |||
156 | struct my_data *entry = NULL; | 156 | struct my_data *entry = NULL; |
157 | mutex_lock(&mutex); | 157 | mutex_lock(&mutex); |
158 | if (!list_empty(&q)) { | 158 | if (!list_empty(&q)) { |
159 | entry = container_of(q.next, struct my_q_entry, link); | 159 | entry = container_of(q.next, struct my_data, link); |
160 | kref_get(&entry->refcount); | 160 | kref_get(&entry->refcount); |
161 | } | 161 | } |
162 | mutex_unlock(&mutex); | 162 | mutex_unlock(&mutex); |
diff --git a/Documentation/memory-barriers.txt b/Documentation/memory-barriers.txt index 631ad2f1b229..f0d3a8026a56 100644 --- a/Documentation/memory-barriers.txt +++ b/Documentation/memory-barriers.txt | |||
@@ -21,6 +21,7 @@ Contents: | |||
21 | - SMP barrier pairing. | 21 | - SMP barrier pairing. |
22 | - Examples of memory barrier sequences. | 22 | - Examples of memory barrier sequences. |
23 | - Read memory barriers vs load speculation. | 23 | - Read memory barriers vs load speculation. |
24 | - Transitivity | ||
24 | 25 | ||
25 | (*) Explicit kernel barriers. | 26 | (*) Explicit kernel barriers. |
26 | 27 | ||
@@ -959,6 +960,63 @@ the speculation will be cancelled and the value reloaded: | |||
959 | retrieved : : +-------+ | 960 | retrieved : : +-------+ |
960 | 961 | ||
961 | 962 | ||
963 | TRANSITIVITY | ||
964 | ------------ | ||
965 | |||
966 | Transitivity is a deeply intuitive notion about ordering that is not | ||
967 | always provided by real computer systems. The following example | ||
968 | demonstrates transitivity (also called "cumulativity"): | ||
969 | |||
970 | CPU 1 CPU 2 CPU 3 | ||
971 | ======================= ======================= ======================= | ||
972 | { X = 0, Y = 0 } | ||
973 | STORE X=1 LOAD X STORE Y=1 | ||
974 | <general barrier> <general barrier> | ||
975 | LOAD Y LOAD X | ||
976 | |||
977 | Suppose that CPU 2's load from X returns 1 and its load from Y returns 0. | ||
978 | This indicates that CPU 2's load from X in some sense follows CPU 1's | ||
979 | store to X and that CPU 2's load from Y in some sense preceded CPU 3's | ||
980 | store to Y. The question is then "Can CPU 3's load from X return 0?" | ||
981 | |||
982 | Because CPU 2's load from X in some sense came after CPU 1's store, it | ||
983 | is natural to expect that CPU 3's load from X must therefore return 1. | ||
984 | This expectation is an example of transitivity: if a load executing on | ||
985 | CPU A follows a load from the same variable executing on CPU B, then | ||
986 | CPU A's load must either return the same value that CPU B's load did, | ||
987 | or must return some later value. | ||
988 | |||
989 | In the Linux kernel, use of general memory barriers guarantees | ||
990 | transitivity. Therefore, in the above example, if CPU 2's load from X | ||
991 | returns 1 and its load from Y returns 0, then CPU 3's load from X must | ||
992 | also return 1. | ||
993 | |||
994 | However, transitivity is -not- guaranteed for read or write barriers. | ||
995 | For example, suppose that CPU 2's general barrier in the above example | ||
996 | is changed to a read barrier as shown below: | ||
997 | |||
998 | CPU 1 CPU 2 CPU 3 | ||
999 | ======================= ======================= ======================= | ||
1000 | { X = 0, Y = 0 } | ||
1001 | STORE X=1 LOAD X STORE Y=1 | ||
1002 | <read barrier> <general barrier> | ||
1003 | LOAD Y LOAD X | ||
1004 | |||
1005 | This substitution destroys transitivity: in this example, it is perfectly | ||
1006 | legal for CPU 2's load from X to return 1, its load from Y to return 0, | ||
1007 | and CPU 3's load from X to return 0. | ||
1008 | |||
1009 | The key point is that although CPU 2's read barrier orders its pair | ||
1010 | of loads, it does not guarantee to order CPU 1's store. Therefore, if | ||
1011 | this example runs on a system where CPUs 1 and 2 share a store buffer | ||
1012 | or a level of cache, CPU 2 might have early access to CPU 1's writes. | ||
1013 | General barriers are therefore required to ensure that all CPUs agree | ||
1014 | on the combined order of CPU 1's and CPU 2's accesses. | ||
1015 | |||
1016 | To reiterate, if your code requires transitivity, use general barriers | ||
1017 | throughout. | ||
1018 | |||
1019 | |||
962 | ======================== | 1020 | ======================== |
963 | EXPLICIT KERNEL BARRIERS | 1021 | EXPLICIT KERNEL BARRIERS |
964 | ======================== | 1022 | ======================== |
diff --git a/Documentation/memory-hotplug.txt b/Documentation/memory-hotplug.txt index 57e7e9cc1870..8f485d72cf25 100644 --- a/Documentation/memory-hotplug.txt +++ b/Documentation/memory-hotplug.txt | |||
@@ -126,36 +126,51 @@ config options. | |||
126 | -------------------------------- | 126 | -------------------------------- |
127 | 4 sysfs files for memory hotplug | 127 | 4 sysfs files for memory hotplug |
128 | -------------------------------- | 128 | -------------------------------- |
129 | All sections have their device information under /sys/devices/system/memory as | 129 | All sections have their device information in sysfs. Each section is part of |
130 | a memory block under /sys/devices/system/memory as | ||
130 | 131 | ||
131 | /sys/devices/system/memory/memoryXXX | 132 | /sys/devices/system/memory/memoryXXX |
132 | (XXX is section id.) | 133 | (XXX is the section id.) |
133 | 134 | ||
134 | Now, XXX is defined as start_address_of_section / section_size. | 135 | Now, XXX is defined as (start_address_of_section / section_size) of the first |
136 | section contained in the memory block. The files 'phys_index' and | ||
137 | 'end_phys_index' under each directory report the beginning and end section id's | ||
138 | for the memory block covered by the sysfs directory. It is expected that all | ||
139 | memory sections in this range are present and no memory holes exist in the | ||
140 | range. Currently there is no way to determine if there is a memory hole, but | ||
141 | the existence of one should not affect the hotplug capabilities of the memory | ||
142 | block. | ||
135 | 143 | ||
136 | For example, assume 1GiB section size. A device for a memory starting at | 144 | For example, assume 1GiB section size. A device for a memory starting at |
137 | 0x100000000 is /sys/device/system/memory/memory4 | 145 | 0x100000000 is /sys/device/system/memory/memory4 |
138 | (0x100000000 / 1Gib = 4) | 146 | (0x100000000 / 1Gib = 4) |
139 | This device covers address range [0x100000000 ... 0x140000000) | 147 | This device covers address range [0x100000000 ... 0x140000000) |
140 | 148 | ||
141 | Under each section, you can see 4 files. | 149 | Under each section, you can see 4 or 5 files, the end_phys_index file being |
150 | a recent addition and not present on older kernels. | ||
142 | 151 | ||
143 | /sys/devices/system/memory/memoryXXX/phys_index | 152 | /sys/devices/system/memory/memoryXXX/start_phys_index |
153 | /sys/devices/system/memory/memoryXXX/end_phys_index | ||
144 | /sys/devices/system/memory/memoryXXX/phys_device | 154 | /sys/devices/system/memory/memoryXXX/phys_device |
145 | /sys/devices/system/memory/memoryXXX/state | 155 | /sys/devices/system/memory/memoryXXX/state |
146 | /sys/devices/system/memory/memoryXXX/removable | 156 | /sys/devices/system/memory/memoryXXX/removable |
147 | 157 | ||
148 | 'phys_index' : read-only and contains section id, same as XXX. | 158 | 'phys_index' : read-only and contains section id of the first section |
149 | 'state' : read-write | 159 | in the memory block, same as XXX. |
150 | at read: contains online/offline state of memory. | 160 | 'end_phys_index' : read-only and contains section id of the last section |
151 | at write: user can specify "online", "offline" command | 161 | in the memory block. |
152 | 'phys_device': read-only: designed to show the name of physical memory device. | 162 | 'state' : read-write |
153 | This is not well implemented now. | 163 | at read: contains online/offline state of memory. |
154 | 'removable' : read-only: contains an integer value indicating | 164 | at write: user can specify "online", "offline" command |
155 | whether the memory section is removable or not | 165 | which will be performed on al sections in the block. |
156 | removable. A value of 1 indicates that the memory | 166 | 'phys_device' : read-only: designed to show the name of physical memory |
157 | section is removable and a value of 0 indicates that | 167 | device. This is not well implemented now. |
158 | it is not removable. | 168 | 'removable' : read-only: contains an integer value indicating |
169 | whether the memory block is removable or not | ||
170 | removable. A value of 1 indicates that the memory | ||
171 | block is removable and a value of 0 indicates that | ||
172 | it is not removable. A memory block is removable only if | ||
173 | every section in the block is removable. | ||
159 | 174 | ||
160 | NOTE: | 175 | NOTE: |
161 | These directories/files appear after physical memory hotplug phase. | 176 | These directories/files appear after physical memory hotplug phase. |
diff --git a/Documentation/networking/batman-adv.txt b/Documentation/networking/batman-adv.txt index 77f0cdd5b0dd..18afcd8afd51 100644 --- a/Documentation/networking/batman-adv.txt +++ b/Documentation/networking/batman-adv.txt | |||
@@ -1,4 +1,4 @@ | |||
1 | [state: 21-11-2010] | 1 | [state: 27-01-2011] |
2 | 2 | ||
3 | BATMAN-ADV | 3 | BATMAN-ADV |
4 | ---------- | 4 | ---------- |
@@ -67,15 +67,16 @@ All mesh wide settings can be found in batman's own interface | |||
67 | folder: | 67 | folder: |
68 | 68 | ||
69 | # ls /sys/class/net/bat0/mesh/ | 69 | # ls /sys/class/net/bat0/mesh/ |
70 | # aggregated_ogms bonding fragmentation orig_interval | 70 | # aggregated_ogms gw_bandwidth hop_penalty |
71 | # vis_mode | 71 | # bonding gw_mode orig_interval |
72 | # fragmentation gw_sel_class vis_mode | ||
72 | 73 | ||
73 | 74 | ||
74 | There is a special folder for debugging informations: | 75 | There is a special folder for debugging informations: |
75 | 76 | ||
76 | # ls /sys/kernel/debug/batman_adv/bat0/ | 77 | # ls /sys/kernel/debug/batman_adv/bat0/ |
77 | # originators socket transtable_global transtable_local | 78 | # gateways socket transtable_global vis_data |
78 | # vis_data | 79 | # originators softif_neigh transtable_local |
79 | 80 | ||
80 | 81 | ||
81 | Some of the files contain all sort of status information regard- | 82 | Some of the files contain all sort of status information regard- |
@@ -230,9 +231,8 @@ CONTACT | |||
230 | Please send us comments, experiences, questions, anything :) | 231 | Please send us comments, experiences, questions, anything :) |
231 | 232 | ||
232 | IRC: #batman on irc.freenode.org | 233 | IRC: #batman on irc.freenode.org |
233 | Mailing-list: b.a.t.m.a.n@b.a.t.m.a.n@lists.open-mesh.org | 234 | Mailing-list: b.a.t.m.a.n@open-mesh.org (optional subscription |
234 | (optional subscription at | 235 | at https://lists.open-mesh.org/mm/listinfo/b.a.t.m.a.n) |
235 | https://lists.open-mesh.org/mm/listinfo/b.a.t.m.a.n) | ||
236 | 236 | ||
237 | You can also contact the Authors: | 237 | You can also contact the Authors: |
238 | 238 | ||
diff --git a/Documentation/networking/bonding.txt b/Documentation/networking/bonding.txt index 25d2f4141d27..b36e741e94db 100644 --- a/Documentation/networking/bonding.txt +++ b/Documentation/networking/bonding.txt | |||
@@ -2558,18 +2558,15 @@ enslaved. | |||
2558 | 16. Resources and Links | 2558 | 16. Resources and Links |
2559 | ======================= | 2559 | ======================= |
2560 | 2560 | ||
2561 | The latest version of the bonding driver can be found in the latest | 2561 | The latest version of the bonding driver can be found in the latest |
2562 | version of the linux kernel, found on http://kernel.org | 2562 | version of the linux kernel, found on http://kernel.org |
2563 | 2563 | ||
2564 | The latest version of this document can be found in either the latest | 2564 | The latest version of this document can be found in the latest kernel |
2565 | kernel source (named Documentation/networking/bonding.txt), or on the | 2565 | source (named Documentation/networking/bonding.txt). |
2566 | bonding sourceforge site: | ||
2567 | 2566 | ||
2568 | http://www.sourceforge.net/projects/bonding | 2567 | Discussions regarding the usage of the bonding driver take place on the |
2569 | 2568 | bonding-devel mailing list, hosted at sourceforge.net. If you have questions or | |
2570 | Discussions regarding the bonding driver take place primarily on the | 2569 | problems, post them to the list. The list address is: |
2571 | bonding-devel mailing list, hosted at sourceforge.net. If you have | ||
2572 | questions or problems, post them to the list. The list address is: | ||
2573 | 2570 | ||
2574 | bonding-devel@lists.sourceforge.net | 2571 | bonding-devel@lists.sourceforge.net |
2575 | 2572 | ||
@@ -2578,6 +2575,17 @@ be found at: | |||
2578 | 2575 | ||
2579 | https://lists.sourceforge.net/lists/listinfo/bonding-devel | 2576 | https://lists.sourceforge.net/lists/listinfo/bonding-devel |
2580 | 2577 | ||
2578 | Discussions regarding the developpement of the bonding driver take place | ||
2579 | on the main Linux network mailing list, hosted at vger.kernel.org. The list | ||
2580 | address is: | ||
2581 | |||
2582 | netdev@vger.kernel.org | ||
2583 | |||
2584 | The administrative interface (to subscribe or unsubscribe) can | ||
2585 | be found at: | ||
2586 | |||
2587 | http://vger.kernel.org/vger-lists.html#netdev | ||
2588 | |||
2581 | Donald Becker's Ethernet Drivers and diag programs may be found at : | 2589 | Donald Becker's Ethernet Drivers and diag programs may be found at : |
2582 | - http://web.archive.org/web/*/http://www.scyld.com/network/ | 2590 | - http://web.archive.org/web/*/http://www.scyld.com/network/ |
2583 | 2591 | ||
diff --git a/Documentation/networking/ip-sysctl.txt b/Documentation/networking/ip-sysctl.txt index ac3b4a726a1a..d3d653a5f9b9 100644 --- a/Documentation/networking/ip-sysctl.txt +++ b/Documentation/networking/ip-sysctl.txt | |||
@@ -280,6 +280,17 @@ tcp_max_orphans - INTEGER | |||
280 | more aggressively. Let me to remind again: each orphan eats | 280 | more aggressively. Let me to remind again: each orphan eats |
281 | up to ~64K of unswappable memory. | 281 | up to ~64K of unswappable memory. |
282 | 282 | ||
283 | tcp_max_ssthresh - INTEGER | ||
284 | Limited Slow-Start for TCP with large congestion windows (cwnd) defined in | ||
285 | RFC3742. Limited slow-start is a mechanism to limit growth of the cwnd | ||
286 | on the region where cwnd is larger than tcp_max_ssthresh. TCP increases cwnd | ||
287 | by at most tcp_max_ssthresh segments, and by at least tcp_max_ssthresh/2 | ||
288 | segments per RTT when the cwnd is above tcp_max_ssthresh. | ||
289 | If TCP connection increased cwnd to thousands (or tens of thousands) segments, | ||
290 | and thousands of packets were being dropped during slow-start, you can set | ||
291 | tcp_max_ssthresh to improve performance for new TCP connection. | ||
292 | Default: 0 (off) | ||
293 | |||
283 | tcp_max_syn_backlog - INTEGER | 294 | tcp_max_syn_backlog - INTEGER |
284 | Maximal number of remembered connection requests, which are | 295 | Maximal number of remembered connection requests, which are |
285 | still did not receive an acknowledgment from connecting client. | 296 | still did not receive an acknowledgment from connecting client. |
diff --git a/Documentation/networking/phonet.txt b/Documentation/networking/phonet.txt index 24ad2adba6e5..81003581f47a 100644 --- a/Documentation/networking/phonet.txt +++ b/Documentation/networking/phonet.txt | |||
@@ -154,9 +154,28 @@ connections, one per accept()'d socket. | |||
154 | write(cfd, msg, msglen); | 154 | write(cfd, msg, msglen); |
155 | } | 155 | } |
156 | 156 | ||
157 | Connections are established between two endpoints by a "third party" | 157 | Connections are traditionally established between two endpoints by a |
158 | application. This means that both endpoints are passive; so connect() | 158 | "third party" application. This means that both endpoints are passive. |
159 | is not possible. | 159 | |
160 | |||
161 | As of Linux kernel version 2.6.39, it is also possible to connect | ||
162 | two endpoints directly, using connect() on the active side. This is | ||
163 | intended to support the newer Nokia Wireless Modem API, as found in | ||
164 | e.g. the Nokia Slim Modem in the ST-Ericsson U8500 platform: | ||
165 | |||
166 | struct sockaddr_spn spn; | ||
167 | int fd; | ||
168 | |||
169 | fd = socket(PF_PHONET, SOCK_SEQPACKET, PN_PROTO_PIPE); | ||
170 | memset(&spn, 0, sizeof(spn)); | ||
171 | spn.spn_family = AF_PHONET; | ||
172 | spn.spn_obj = ...; | ||
173 | spn.spn_dev = ...; | ||
174 | spn.spn_resource = 0xD9; | ||
175 | connect(fd, (struct sockaddr *)&spn, sizeof(spn)); | ||
176 | /* normal I/O here ... */ | ||
177 | close(fd); | ||
178 | |||
160 | 179 | ||
161 | WARNING: | 180 | WARNING: |
162 | When polling a connected pipe socket for writability, there is an | 181 | When polling a connected pipe socket for writability, there is an |
@@ -181,45 +200,9 @@ The pipe protocol provides two socket options at the SOL_PNPIPE level: | |||
181 | interface index of the network interface created by PNPIPE_ENCAP, | 200 | interface index of the network interface created by PNPIPE_ENCAP, |
182 | or zero if encapsulation is off. | 201 | or zero if encapsulation is off. |
183 | 202 | ||
184 | 203 | PNPIPE_HANDLE is a read-only integer value. It contains the underlying | |
185 | Phonet Pipe-controller Implementation | 204 | identifier ("pipe handle") of the pipe. This is only defined for |
186 | ------------------------------------- | 205 | socket descriptors that are already connected or being connected. |
187 | |||
188 | Phonet Pipe-controller is enabled by selecting the CONFIG_PHONET_PIPECTRLR Kconfig | ||
189 | option. It is useful when communicating with those Nokia Modems which do not | ||
190 | implement Pipe controller in them e.g. Nokia Slim Modem used in ST-Ericsson | ||
191 | U8500 platform. | ||
192 | |||
193 | The implementation is based on the Data Connection Establishment Sequence | ||
194 | depicted in 'Nokia Wireless Modem API - Wireless_modem_user_guide.pdf' | ||
195 | document. | ||
196 | |||
197 | It allows a phonet sequenced socket (host-pep) to initiate a Pipe connection | ||
198 | between itself and a remote pipe-end point (e.g. modem). | ||
199 | |||
200 | The implementation adds socket options at SOL_PNPIPE level: | ||
201 | |||
202 | PNPIPE_PIPE_HANDLE | ||
203 | It accepts an integer argument for setting value of pipe handle. | ||
204 | |||
205 | PNPIPE_ENABLE accepts one integer value (int). If set to zero, the pipe | ||
206 | is disabled. If the value is non-zero, the pipe is enabled. If the pipe | ||
207 | is not (yet) connected, ENOTCONN is error is returned. | ||
208 | |||
209 | The implementation also adds socket 'connect'. On calling the 'connect', pipe | ||
210 | will be created between the source socket and the destination, and the pipe | ||
211 | state will be set to PIPE_DISABLED. | ||
212 | |||
213 | After a pipe has been created and enabled successfully, the Pipe data can be | ||
214 | exchanged between the host-pep and remote-pep (modem). | ||
215 | |||
216 | User-space would typically follow below sequence with Pipe controller:- | ||
217 | -socket | ||
218 | -bind | ||
219 | -setsockopt for PNPIPE_PIPE_HANDLE | ||
220 | -connect | ||
221 | -setsockopt for PNPIPE_ENCAP_IP | ||
222 | -setsockopt for PNPIPE_ENABLE | ||
223 | 206 | ||
224 | 207 | ||
225 | Authors | 208 | Authors |
diff --git a/Documentation/power/devices.txt b/Documentation/power/devices.txt index 57080cd74575..f023ba6bba62 100644 --- a/Documentation/power/devices.txt +++ b/Documentation/power/devices.txt | |||
@@ -1,6 +1,6 @@ | |||
1 | Device Power Management | 1 | Device Power Management |
2 | 2 | ||
3 | Copyright (c) 2010 Rafael J. Wysocki <rjw@sisk.pl>, Novell Inc. | 3 | Copyright (c) 2010-2011 Rafael J. Wysocki <rjw@sisk.pl>, Novell Inc. |
4 | Copyright (c) 2010 Alan Stern <stern@rowland.harvard.edu> | 4 | Copyright (c) 2010 Alan Stern <stern@rowland.harvard.edu> |
5 | 5 | ||
6 | 6 | ||
@@ -159,18 +159,18 @@ matter, and the kernel is responsible for keeping track of it. By contrast, | |||
159 | whether or not a wakeup-capable device should issue wakeup events is a policy | 159 | whether or not a wakeup-capable device should issue wakeup events is a policy |
160 | decision, and it is managed by user space through a sysfs attribute: the | 160 | decision, and it is managed by user space through a sysfs attribute: the |
161 | power/wakeup file. User space can write the strings "enabled" or "disabled" to | 161 | power/wakeup file. User space can write the strings "enabled" or "disabled" to |
162 | set or clear the should_wakeup flag, respectively. Reads from the file will | 162 | set or clear the "should_wakeup" flag, respectively. This file is only present |
163 | return the corresponding string if can_wakeup is true, but if can_wakeup is | 163 | for wakeup-capable devices (i.e. devices whose "can_wakeup" flags are set) |
164 | false then reads will return an empty string, to indicate that the device | 164 | and is created (or removed) by device_set_wakeup_capable(). Reads from the |
165 | doesn't support wakeup events. (But even though the file appears empty, writes | 165 | file will return the corresponding string. |
166 | will still affect the should_wakeup flag.) | ||
167 | 166 | ||
168 | The device_may_wakeup() routine returns true only if both flags are set. | 167 | The device_may_wakeup() routine returns true only if both flags are set. |
169 | Drivers should check this routine when putting devices in a low-power state | 168 | This information is used by subsystems, like the PCI bus type code, to see |
170 | during a system sleep transition, to see whether or not to enable the devices' | 169 | whether or not to enable the devices' wakeup mechanisms. If device wakeup |
171 | wakeup mechanisms. However for runtime power management, wakeup events should | 170 | mechanisms are enabled or disabled directly by drivers, they also should use |
172 | be enabled whenever the device and driver both support them, regardless of the | 171 | device_may_wakeup() to decide what to do during a system sleep transition. |
173 | should_wakeup flag. | 172 | However for runtime power management, wakeup events should be enabled whenever |
173 | the device and driver both support them, regardless of the should_wakeup flag. | ||
174 | 174 | ||
175 | 175 | ||
176 | /sys/devices/.../power/control files | 176 | /sys/devices/.../power/control files |
@@ -249,23 +249,18 @@ various phases always run after tasks have been frozen and before they are | |||
249 | unfrozen. Furthermore, the *_noirq phases run at a time when IRQ handlers have | 249 | unfrozen. Furthermore, the *_noirq phases run at a time when IRQ handlers have |
250 | been disabled (except for those marked with the IRQ_WAKEUP flag). | 250 | been disabled (except for those marked with the IRQ_WAKEUP flag). |
251 | 251 | ||
252 | Most phases use bus, type, and class callbacks (that is, methods defined in | 252 | All phases use bus, type, or class callbacks (that is, methods defined in |
253 | dev->bus->pm, dev->type->pm, and dev->class->pm). The prepare and complete | 253 | dev->bus->pm, dev->type->pm, or dev->class->pm). These callbacks are mutually |
254 | phases are exceptions; they use only bus callbacks. When multiple callbacks | 254 | exclusive, so if the device type provides a struct dev_pm_ops object pointed to |
255 | are used in a phase, they are invoked in the order: <class, type, bus> during | 255 | by its pm field (i.e. both dev->type and dev->type->pm are defined), the |
256 | power-down transitions and in the opposite order during power-up transitions. | 256 | callbacks included in that object (i.e. dev->type->pm) will be used. Otherwise, |
257 | For example, during the suspend phase the PM core invokes | 257 | if the class provides a struct dev_pm_ops object pointed to by its pm field |
258 | 258 | (i.e. both dev->class and dev->class->pm are defined), the PM core will use the | |
259 | dev->class->pm.suspend(dev); | 259 | callbacks from that object (i.e. dev->class->pm). Finally, if the pm fields of |
260 | dev->type->pm.suspend(dev); | 260 | both the device type and class objects are NULL (or those objects do not exist), |
261 | dev->bus->pm.suspend(dev); | 261 | the callbacks provided by the bus (that is, the callbacks from dev->bus->pm) |
262 | 262 | will be used (this allows device types to override callbacks provided by bus | |
263 | before moving on to the next device, whereas during the resume phase the core | 263 | types or classes if necessary). |
264 | invokes | ||
265 | |||
266 | dev->bus->pm.resume(dev); | ||
267 | dev->type->pm.resume(dev); | ||
268 | dev->class->pm.resume(dev); | ||
269 | 264 | ||
270 | These callbacks may in turn invoke device- or driver-specific methods stored in | 265 | These callbacks may in turn invoke device- or driver-specific methods stored in |
271 | dev->driver->pm, but they don't have to. | 266 | dev->driver->pm, but they don't have to. |
@@ -507,6 +502,49 @@ routines. Nevertheless, different callback pointers are used in case there is a | |||
507 | situation where it actually matters. | 502 | situation where it actually matters. |
508 | 503 | ||
509 | 504 | ||
505 | Device Power Domains | ||
506 | -------------------- | ||
507 | Sometimes devices share reference clocks or other power resources. In those | ||
508 | cases it generally is not possible to put devices into low-power states | ||
509 | individually. Instead, a set of devices sharing a power resource can be put | ||
510 | into a low-power state together at the same time by turning off the shared | ||
511 | power resource. Of course, they also need to be put into the full-power state | ||
512 | together, by turning the shared power resource on. A set of devices with this | ||
513 | property is often referred to as a power domain. | ||
514 | |||
515 | Support for power domains is provided through the pwr_domain field of struct | ||
516 | device. This field is a pointer to an object of type struct dev_power_domain, | ||
517 | defined in include/linux/pm.h, providing a set of power management callbacks | ||
518 | analogous to the subsystem-level and device driver callbacks that are executed | ||
519 | for the given device during all power transitions, in addition to the respective | ||
520 | subsystem-level callbacks. Specifically, the power domain "suspend" callbacks | ||
521 | (i.e. ->runtime_suspend(), ->suspend(), ->freeze(), ->poweroff(), etc.) are | ||
522 | executed after the analogous subsystem-level callbacks, while the power domain | ||
523 | "resume" callbacks (i.e. ->runtime_resume(), ->resume(), ->thaw(), ->restore, | ||
524 | etc.) are executed before the analogous subsystem-level callbacks. Error codes | ||
525 | returned by the "suspend" and "resume" power domain callbacks are ignored. | ||
526 | |||
527 | Power domain ->runtime_idle() callback is executed before the subsystem-level | ||
528 | ->runtime_idle() callback and the result returned by it is not ignored. Namely, | ||
529 | if it returns error code, the subsystem-level ->runtime_idle() callback will not | ||
530 | be called and the helper function rpm_idle() executing it will return error | ||
531 | code. This mechanism is intended to help platforms where saving device state | ||
532 | is a time consuming operation and should only be carried out if all devices | ||
533 | in the power domain are idle, before turning off the shared power resource(s). | ||
534 | Namely, the power domain ->runtime_idle() callback may return error code until | ||
535 | the pm_runtime_idle() helper (or its asychronous version) has been called for | ||
536 | all devices in the power domain (it is recommended that the returned error code | ||
537 | be -EBUSY in those cases), preventing the subsystem-level ->runtime_idle() | ||
538 | callback from being run prematurely. | ||
539 | |||
540 | The support for device power domains is only relevant to platforms needing to | ||
541 | use the same subsystem-level (e.g. platform bus type) and device driver power | ||
542 | management callbacks in many different power domain configurations and wanting | ||
543 | to avoid incorporating the support for power domains into the subsystem-level | ||
544 | callbacks. The other platforms need not implement it or take it into account | ||
545 | in any way. | ||
546 | |||
547 | |||
510 | System Devices | 548 | System Devices |
511 | -------------- | 549 | -------------- |
512 | System devices (sysdevs) follow a slightly different API, which can be found in | 550 | System devices (sysdevs) follow a slightly different API, which can be found in |
diff --git a/Documentation/power/runtime_pm.txt b/Documentation/power/runtime_pm.txt index ffe55ffa540a..654097b130b4 100644 --- a/Documentation/power/runtime_pm.txt +++ b/Documentation/power/runtime_pm.txt | |||
@@ -1,6 +1,6 @@ | |||
1 | Run-time Power Management Framework for I/O Devices | 1 | Run-time Power Management Framework for I/O Devices |
2 | 2 | ||
3 | (C) 2009 Rafael J. Wysocki <rjw@sisk.pl>, Novell Inc. | 3 | (C) 2009-2011 Rafael J. Wysocki <rjw@sisk.pl>, Novell Inc. |
4 | (C) 2010 Alan Stern <stern@rowland.harvard.edu> | 4 | (C) 2010 Alan Stern <stern@rowland.harvard.edu> |
5 | 5 | ||
6 | 1. Introduction | 6 | 1. Introduction |
@@ -44,11 +44,12 @@ struct dev_pm_ops { | |||
44 | }; | 44 | }; |
45 | 45 | ||
46 | The ->runtime_suspend(), ->runtime_resume() and ->runtime_idle() callbacks are | 46 | The ->runtime_suspend(), ->runtime_resume() and ->runtime_idle() callbacks are |
47 | executed by the PM core for either the bus type, or device type (if the bus | 47 | executed by the PM core for either the device type, or the class (if the device |
48 | type's callback is not defined), or device class (if the bus type's and device | 48 | type's struct dev_pm_ops object does not exist), or the bus type (if the |
49 | type's callbacks are not defined) of given device. The bus type, device type | 49 | device type's and class' struct dev_pm_ops objects do not exist) of the given |
50 | and device class callbacks are referred to as subsystem-level callbacks in what | 50 | device (this allows device types to override callbacks provided by bus types or |
51 | follows. | 51 | classes if necessary). The bus type, device type and class callbacks are |
52 | referred to as subsystem-level callbacks in what follows. | ||
52 | 53 | ||
53 | By default, the callbacks are always invoked in process context with interrupts | 54 | By default, the callbacks are always invoked in process context with interrupts |
54 | enabled. However, subsystems can use the pm_runtime_irq_safe() helper function | 55 | enabled. However, subsystems can use the pm_runtime_irq_safe() helper function |
diff --git a/Documentation/power/states.txt b/Documentation/power/states.txt index 34800cc521bf..4416b28630df 100644 --- a/Documentation/power/states.txt +++ b/Documentation/power/states.txt | |||
@@ -62,12 +62,12 @@ setup via another operating system for it to use. Despite the | |||
62 | inconvenience, this method requires minimal work by the kernel, since | 62 | inconvenience, this method requires minimal work by the kernel, since |
63 | the firmware will also handle restoring memory contents on resume. | 63 | the firmware will also handle restoring memory contents on resume. |
64 | 64 | ||
65 | For suspend-to-disk, a mechanism called swsusp called 'swsusp' (Swap | 65 | For suspend-to-disk, a mechanism called 'swsusp' (Swap Suspend) is used |
66 | Suspend) is used to write memory contents to free swap space. | 66 | to write memory contents to free swap space. swsusp has some restrictive |
67 | swsusp has some restrictive requirements, but should work in most | 67 | requirements, but should work in most cases. Some, albeit outdated, |
68 | cases. Some, albeit outdated, documentation can be found in | 68 | documentation can be found in Documentation/power/swsusp.txt. |
69 | Documentation/power/swsusp.txt. Alternatively, userspace can do most | 69 | Alternatively, userspace can do most of the actual suspend to disk work, |
70 | of the actual suspend to disk work, see userland-swsusp.txt. | 70 | see userland-swsusp.txt. |
71 | 71 | ||
72 | Once memory state is written to disk, the system may either enter a | 72 | Once memory state is written to disk, the system may either enter a |
73 | low-power state (like ACPI S4), or it may simply power down. Powering | 73 | low-power state (like ACPI S4), or it may simply power down. Powering |
diff --git a/Documentation/powerpc/00-INDEX b/Documentation/powerpc/00-INDEX index e3960b8c8689..5620fb5ac425 100644 --- a/Documentation/powerpc/00-INDEX +++ b/Documentation/powerpc/00-INDEX | |||
@@ -5,8 +5,6 @@ please mail me. | |||
5 | 5 | ||
6 | 00-INDEX | 6 | 00-INDEX |
7 | - this file | 7 | - this file |
8 | booting-without-of.txt | ||
9 | - Booting the Linux/ppc kernel without Open Firmware | ||
10 | cpu_features.txt | 8 | cpu_features.txt |
11 | - info on how we support a variety of CPUs with minimal compile-time | 9 | - info on how we support a variety of CPUs with minimal compile-time |
12 | options. | 10 | options. |
@@ -16,8 +14,6 @@ hvcs.txt | |||
16 | - IBM "Hypervisor Virtual Console Server" Installation Guide | 14 | - IBM "Hypervisor Virtual Console Server" Installation Guide |
17 | mpc52xx.txt | 15 | mpc52xx.txt |
18 | - Linux 2.6.x on MPC52xx family | 16 | - Linux 2.6.x on MPC52xx family |
19 | mpc52xx-device-tree-bindings.txt | ||
20 | - MPC5200 Device Tree Bindings | ||
21 | sound.txt | 17 | sound.txt |
22 | - info on sound support under Linux/PPC | 18 | - info on sound support under Linux/PPC |
23 | zImage_layout.txt | 19 | zImage_layout.txt |
diff --git a/Documentation/rtc.txt b/Documentation/rtc.txt index 9104c1062084..250160469d83 100644 --- a/Documentation/rtc.txt +++ b/Documentation/rtc.txt | |||
@@ -178,38 +178,29 @@ RTC class framework, but can't be supported by the older driver. | |||
178 | setting the longer alarm time and enabling its IRQ using a single | 178 | setting the longer alarm time and enabling its IRQ using a single |
179 | request (using the same model as EFI firmware). | 179 | request (using the same model as EFI firmware). |
180 | 180 | ||
181 | * RTC_UIE_ON, RTC_UIE_OFF ... if the RTC offers IRQs, it probably | 181 | * RTC_UIE_ON, RTC_UIE_OFF ... if the RTC offers IRQs, the RTC framework |
182 | also offers update IRQs whenever the "seconds" counter changes. | 182 | will emulate this mechanism. |
183 | If needed, the RTC framework can emulate this mechanism. | ||
184 | 183 | ||
185 | * RTC_PIE_ON, RTC_PIE_OFF, RTC_IRQP_SET, RTC_IRQP_READ ... another | 184 | * RTC_PIE_ON, RTC_PIE_OFF, RTC_IRQP_SET, RTC_IRQP_READ ... these icotls |
186 | feature often accessible with an IRQ line is a periodic IRQ, issued | 185 | are emulated via a kernel hrtimer. |
187 | at settable frequencies (usually 2^N Hz). | ||
188 | 186 | ||
189 | In many cases, the RTC alarm can be a system wake event, used to force | 187 | In many cases, the RTC alarm can be a system wake event, used to force |
190 | Linux out of a low power sleep state (or hibernation) back to a fully | 188 | Linux out of a low power sleep state (or hibernation) back to a fully |
191 | operational state. For example, a system could enter a deep power saving | 189 | operational state. For example, a system could enter a deep power saving |
192 | state until it's time to execute some scheduled tasks. | 190 | state until it's time to execute some scheduled tasks. |
193 | 191 | ||
194 | Note that many of these ioctls need not actually be implemented by your | 192 | Note that many of these ioctls are handled by the common rtc-dev interface. |
195 | driver. The common rtc-dev interface handles many of these nicely if your | 193 | Some common examples: |
196 | driver returns ENOIOCTLCMD. Some common examples: | ||
197 | 194 | ||
198 | * RTC_RD_TIME, RTC_SET_TIME: the read_time/set_time functions will be | 195 | * RTC_RD_TIME, RTC_SET_TIME: the read_time/set_time functions will be |
199 | called with appropriate values. | 196 | called with appropriate values. |
200 | 197 | ||
201 | * RTC_ALM_SET, RTC_ALM_READ, RTC_WKALM_SET, RTC_WKALM_RD: the | 198 | * RTC_ALM_SET, RTC_ALM_READ, RTC_WKALM_SET, RTC_WKALM_RD: gets or sets |
202 | set_alarm/read_alarm functions will be called. | 199 | the alarm rtc_timer. May call the set_alarm driver function. |
203 | 200 | ||
204 | * RTC_IRQP_SET, RTC_IRQP_READ: the irq_set_freq function will be called | 201 | * RTC_IRQP_SET, RTC_IRQP_READ: These are emulated by the generic code. |
205 | to set the frequency while the framework will handle the read for you | ||
206 | since the frequency is stored in the irq_freq member of the rtc_device | ||
207 | structure. Your driver needs to initialize the irq_freq member during | ||
208 | init. Make sure you check the requested frequency is in range of your | ||
209 | hardware in the irq_set_freq function. If it isn't, return -EINVAL. If | ||
210 | you cannot actually change the frequency, do not define irq_set_freq. | ||
211 | 202 | ||
212 | * RTC_PIE_ON, RTC_PIE_OFF: the irq_set_state function will be called. | 203 | * RTC_PIE_ON, RTC_PIE_OFF: These are also emulated by the generic code. |
213 | 204 | ||
214 | If all else fails, check out the rtc-test.c driver! | 205 | If all else fails, check out the rtc-test.c driver! |
215 | 206 | ||
diff --git a/Documentation/serial/n_gsm.txt b/Documentation/serial/n_gsm.txt new file mode 100644 index 000000000000..397f41a1f153 --- /dev/null +++ b/Documentation/serial/n_gsm.txt | |||
@@ -0,0 +1,89 @@ | |||
1 | n_gsm.c GSM 0710 tty multiplexor HOWTO | ||
2 | =================================================== | ||
3 | |||
4 | This line discipline implements the GSM 07.10 multiplexing protocol | ||
5 | detailed in the following 3GPP document : | ||
6 | http://www.3gpp.org/ftp/Specs/archive/07_series/07.10/0710-720.zip | ||
7 | |||
8 | This document give some hints on how to use this driver with GPRS and 3G | ||
9 | modems connected to a physical serial port. | ||
10 | |||
11 | How to use it | ||
12 | ------------- | ||
13 | 1- initialize the modem in 0710 mux mode (usually AT+CMUX= command) through | ||
14 | its serial port. Depending on the modem used, you can pass more or less | ||
15 | parameters to this command, | ||
16 | 2- switch the serial line to using the n_gsm line discipline by using | ||
17 | TIOCSETD ioctl, | ||
18 | 3- configure the mux using GSMIOC_GETCONF / GSMIOC_SETCONF ioctl, | ||
19 | |||
20 | Major parts of the initialization program : | ||
21 | (a good starting point is util-linux-ng/sys-utils/ldattach.c) | ||
22 | #include <linux/gsmmux.h> | ||
23 | #define N_GSM0710 21 /* GSM 0710 Mux */ | ||
24 | #define DEFAULT_SPEED B115200 | ||
25 | #define SERIAL_PORT /dev/ttyS0 | ||
26 | |||
27 | int ldisc = N_GSM0710; | ||
28 | struct gsm_config c; | ||
29 | struct termios configuration; | ||
30 | |||
31 | /* open the serial port connected to the modem */ | ||
32 | fd = open(SERIAL_PORT, O_RDWR | O_NOCTTY | O_NDELAY); | ||
33 | |||
34 | /* configure the serial port : speed, flow control ... */ | ||
35 | |||
36 | /* send the AT commands to switch the modem to CMUX mode | ||
37 | and check that it's succesful (should return OK) */ | ||
38 | write(fd, "AT+CMUX=0\r", 10); | ||
39 | |||
40 | /* experience showed that some modems need some time before | ||
41 | being able to answer to the first MUX packet so a delay | ||
42 | may be needed here in some case */ | ||
43 | sleep(3); | ||
44 | |||
45 | /* use n_gsm line discipline */ | ||
46 | ioctl(fd, TIOCSETD, &ldisc); | ||
47 | |||
48 | /* get n_gsm configuration */ | ||
49 | ioctl(fd, GSMIOC_GETCONF, &c); | ||
50 | /* we are initiator and need encoding 0 (basic) */ | ||
51 | c.initiator = 1; | ||
52 | c.encapsulation = 0; | ||
53 | /* our modem defaults to a maximum size of 127 bytes */ | ||
54 | c.mru = 127; | ||
55 | c.mtu = 127; | ||
56 | /* set the new configuration */ | ||
57 | ioctl(fd, GSMIOC_SETCONF, &c); | ||
58 | |||
59 | /* and wait for ever to keep the line discipline enabled */ | ||
60 | daemon(0,0); | ||
61 | pause(); | ||
62 | |||
63 | 4- create the devices corresponding to the "virtual" serial ports (take care, | ||
64 | each modem has its configuration and some DLC have dedicated functions, | ||
65 | for example GPS), starting with minor 1 (DLC0 is reserved for the management | ||
66 | of the mux) | ||
67 | |||
68 | MAJOR=`cat /proc/devices |grep gsmtty | awk '{print $1}` | ||
69 | for i in `seq 1 4`; do | ||
70 | mknod /dev/ttygsm$i c $MAJOR $i | ||
71 | done | ||
72 | |||
73 | 5- use these devices as plain serial ports. | ||
74 | for example, it's possible : | ||
75 | - and to use gnokii to send / receive SMS on ttygsm1 | ||
76 | - to use ppp to establish a datalink on ttygsm2 | ||
77 | |||
78 | 6- first close all virtual ports before closing the physical port. | ||
79 | |||
80 | Additional Documentation | ||
81 | ------------------------ | ||
82 | More practical details on the protocol and how it's supported by industrial | ||
83 | modems can be found in the following documents : | ||
84 | http://www.telit.com/module/infopool/download.php?id=616 | ||
85 | http://www.u-blox.com/images/downloads/Product_Docs/LEON-G100-G200-MuxImplementation_ApplicationNote_%28GSM%20G1-CS-10002%29.pdf | ||
86 | http://www.sierrawireless.com/Support/Downloads/AirPrime/WMP_Series/~/media/Support_Downloads/AirPrime/Application_notes/CMUX_Feature_Application_Note-Rev004.ashx | ||
87 | http://wm.sim.com/sim/News/photo/2010721161442.pdf | ||
88 | |||
89 | 11-03-08 - Eric B茅nard - <eric@eukrea.com> | ||
diff --git a/Documentation/spinlocks.txt b/Documentation/spinlocks.txt index 178c831b907d..2e3c64b1a6a5 100644 --- a/Documentation/spinlocks.txt +++ b/Documentation/spinlocks.txt | |||
@@ -86,7 +86,7 @@ to change the variables it has to get an exclusive write lock. | |||
86 | 86 | ||
87 | The routines look the same as above: | 87 | The routines look the same as above: |
88 | 88 | ||
89 | rwlock_t xxx_lock = RW_LOCK_UNLOCKED; | 89 | rwlock_t xxx_lock = __RW_LOCK_UNLOCKED(xxx_lock); |
90 | 90 | ||
91 | unsigned long flags; | 91 | unsigned long flags; |
92 | 92 | ||
@@ -196,25 +196,3 @@ appropriate: | |||
196 | 196 | ||
197 | For static initialization, use DEFINE_SPINLOCK() / DEFINE_RWLOCK() or | 197 | For static initialization, use DEFINE_SPINLOCK() / DEFINE_RWLOCK() or |
198 | __SPIN_LOCK_UNLOCKED() / __RW_LOCK_UNLOCKED() as appropriate. | 198 | __SPIN_LOCK_UNLOCKED() / __RW_LOCK_UNLOCKED() as appropriate. |
199 | |||
200 | SPIN_LOCK_UNLOCKED and RW_LOCK_UNLOCKED are deprecated. These interfere | ||
201 | with lockdep state tracking. | ||
202 | |||
203 | Most of the time, you can simply turn: | ||
204 | static spinlock_t xxx_lock = SPIN_LOCK_UNLOCKED; | ||
205 | into: | ||
206 | static DEFINE_SPINLOCK(xxx_lock); | ||
207 | |||
208 | Static structure member variables go from: | ||
209 | |||
210 | struct foo bar { | ||
211 | .lock = SPIN_LOCK_UNLOCKED; | ||
212 | }; | ||
213 | |||
214 | to: | ||
215 | |||
216 | struct foo bar { | ||
217 | .lock = __SPIN_LOCK_UNLOCKED(bar.lock); | ||
218 | }; | ||
219 | |||
220 | Declaration of static rw_locks undergo a similar transformation. | ||
diff --git a/Documentation/sysctl/fs.txt b/Documentation/sysctl/fs.txt index 62682500878a..4af0614147ef 100644 --- a/Documentation/sysctl/fs.txt +++ b/Documentation/sysctl/fs.txt | |||
@@ -88,20 +88,19 @@ you might want to raise the limit. | |||
88 | 88 | ||
89 | file-max & file-nr: | 89 | file-max & file-nr: |
90 | 90 | ||
91 | The kernel allocates file handles dynamically, but as yet it | ||
92 | doesn't free them again. | ||
93 | |||
94 | The value in file-max denotes the maximum number of file- | 91 | The value in file-max denotes the maximum number of file- |
95 | handles that the Linux kernel will allocate. When you get lots | 92 | handles that the Linux kernel will allocate. When you get lots |
96 | of error messages about running out of file handles, you might | 93 | of error messages about running out of file handles, you might |
97 | want to increase this limit. | 94 | want to increase this limit. |
98 | 95 | ||
99 | Historically, the three values in file-nr denoted the number of | 96 | Historically,the kernel was able to allocate file handles |
100 | allocated file handles, the number of allocated but unused file | 97 | dynamically, but not to free them again. The three values in |
101 | handles, and the maximum number of file handles. Linux 2.6 always | 98 | file-nr denote the number of allocated file handles, the number |
102 | reports 0 as the number of free file handles -- this is not an | 99 | of allocated but unused file handles, and the maximum number of |
103 | error, it just means that the number of allocated file handles | 100 | file handles. Linux 2.6 always reports 0 as the number of free |
104 | exactly matches the number of used file handles. | 101 | file handles -- this is not an error, it just means that the |
102 | number of allocated file handles exactly matches the number of | ||
103 | used file handles. | ||
105 | 104 | ||
106 | Attempts to allocate more file descriptors than file-max are | 105 | Attempts to allocate more file descriptors than file-max are |
107 | reported with printk, look for "VFS: file-max limit <number> | 106 | reported with printk, look for "VFS: file-max limit <number> |
diff --git a/Documentation/trace/ftrace-design.txt b/Documentation/trace/ftrace-design.txt index dc52bd442c92..79fcafc7fd64 100644 --- a/Documentation/trace/ftrace-design.txt +++ b/Documentation/trace/ftrace-design.txt | |||
@@ -247,6 +247,13 @@ You need very few things to get the syscalls tracing in an arch. | |||
247 | - Support the TIF_SYSCALL_TRACEPOINT thread flags. | 247 | - Support the TIF_SYSCALL_TRACEPOINT thread flags. |
248 | - Put the trace_sys_enter() and trace_sys_exit() tracepoints calls from ptrace | 248 | - Put the trace_sys_enter() and trace_sys_exit() tracepoints calls from ptrace |
249 | in the ptrace syscalls tracing path. | 249 | in the ptrace syscalls tracing path. |
250 | - If the system call table on this arch is more complicated than a simple array | ||
251 | of addresses of the system calls, implement an arch_syscall_addr to return | ||
252 | the address of a given system call. | ||
253 | - If the symbol names of the system calls do not match the function names on | ||
254 | this arch, define ARCH_HAS_SYSCALL_MATCH_SYM_NAME in asm/ftrace.h and | ||
255 | implement arch_syscall_match_sym_name with the appropriate logic to return | ||
256 | true if the function name corresponds with the symbol name. | ||
250 | - Tag this arch as HAVE_SYSCALL_TRACEPOINTS. | 257 | - Tag this arch as HAVE_SYSCALL_TRACEPOINTS. |
251 | 258 | ||
252 | 259 | ||
diff --git a/Documentation/trace/ftrace.txt b/Documentation/trace/ftrace.txt index 557c1edeccaf..1ebc24cf9a55 100644 --- a/Documentation/trace/ftrace.txt +++ b/Documentation/trace/ftrace.txt | |||
@@ -80,11 +80,11 @@ of ftrace. Here is a list of some of the key files: | |||
80 | tracers listed here can be configured by | 80 | tracers listed here can be configured by |
81 | echoing their name into current_tracer. | 81 | echoing their name into current_tracer. |
82 | 82 | ||
83 | tracing_enabled: | 83 | tracing_on: |
84 | 84 | ||
85 | This sets or displays whether the current_tracer | 85 | This sets or displays whether writing to the trace |
86 | is activated and tracing or not. Echo 0 into this | 86 | ring buffer is enabled. Echo 0 into this file to disable |
87 | file to disable the tracer or 1 to enable it. | 87 | the tracer or 1 to enable it. |
88 | 88 | ||
89 | trace: | 89 | trace: |
90 | 90 | ||
@@ -202,10 +202,6 @@ Here is the list of current tracers that may be configured. | |||
202 | to draw a graph of function calls similar to C code | 202 | to draw a graph of function calls similar to C code |
203 | source. | 203 | source. |
204 | 204 | ||
205 | "sched_switch" | ||
206 | |||
207 | Traces the context switches and wakeups between tasks. | ||
208 | |||
209 | "irqsoff" | 205 | "irqsoff" |
210 | 206 | ||
211 | Traces the areas that disable interrupts and saves | 207 | Traces the areas that disable interrupts and saves |
@@ -273,39 +269,6 @@ format, the function name that was traced "path_put" and the | |||
273 | parent function that called this function "path_walk". The | 269 | parent function that called this function "path_walk". The |
274 | timestamp is the time at which the function was entered. | 270 | timestamp is the time at which the function was entered. |
275 | 271 | ||
276 | The sched_switch tracer also includes tracing of task wakeups | ||
277 | and context switches. | ||
278 | |||
279 | ksoftirqd/1-7 [01] 1453.070013: 7:115:R + 2916:115:S | ||
280 | ksoftirqd/1-7 [01] 1453.070013: 7:115:R + 10:115:S | ||
281 | ksoftirqd/1-7 [01] 1453.070013: 7:115:R ==> 10:115:R | ||
282 | events/1-10 [01] 1453.070013: 10:115:S ==> 2916:115:R | ||
283 | kondemand/1-2916 [01] 1453.070013: 2916:115:S ==> 7:115:R | ||
284 | ksoftirqd/1-7 [01] 1453.070013: 7:115:S ==> 0:140:R | ||
285 | |||
286 | Wake ups are represented by a "+" and the context switches are | ||
287 | shown as "==>". The format is: | ||
288 | |||
289 | Context switches: | ||
290 | |||
291 | Previous task Next Task | ||
292 | |||
293 | <pid>:<prio>:<state> ==> <pid>:<prio>:<state> | ||
294 | |||
295 | Wake ups: | ||
296 | |||
297 | Current task Task waking up | ||
298 | |||
299 | <pid>:<prio>:<state> + <pid>:<prio>:<state> | ||
300 | |||
301 | The prio is the internal kernel priority, which is the inverse | ||
302 | of the priority that is usually displayed by user-space tools. | ||
303 | Zero represents the highest priority (99). Prio 100 starts the | ||
304 | "nice" priorities with 100 being equal to nice -20 and 139 being | ||
305 | nice 19. The prio "140" is reserved for the idle task which is | ||
306 | the lowest priority thread (pid 0). | ||
307 | |||
308 | |||
309 | Latency trace format | 272 | Latency trace format |
310 | -------------------- | 273 | -------------------- |
311 | 274 | ||
@@ -491,78 +454,10 @@ x494] <- /root/a.out[+0x4a8] <- /lib/libc-2.7.so[+0x1e1a6] | |||
491 | latencies, as described in "Latency | 454 | latencies, as described in "Latency |
492 | trace format". | 455 | trace format". |
493 | 456 | ||
494 | sched_switch | 457 | overwrite - This controls what happens when the trace buffer is |
495 | ------------ | 458 | full. If "1" (default), the oldest events are |
496 | 459 | discarded and overwritten. If "0", then the newest | |
497 | This tracer simply records schedule switches. Here is an example | 460 | events are discarded. |
498 | of how to use it. | ||
499 | |||
500 | # echo sched_switch > current_tracer | ||
501 | # echo 1 > tracing_enabled | ||
502 | # sleep 1 | ||
503 | # echo 0 > tracing_enabled | ||
504 | # cat trace | ||
505 | |||
506 | # tracer: sched_switch | ||
507 | # | ||
508 | # TASK-PID CPU# TIMESTAMP FUNCTION | ||
509 | # | | | | | | ||
510 | bash-3997 [01] 240.132281: 3997:120:R + 4055:120:R | ||
511 | bash-3997 [01] 240.132284: 3997:120:R ==> 4055:120:R | ||
512 | sleep-4055 [01] 240.132371: 4055:120:S ==> 3997:120:R | ||
513 | bash-3997 [01] 240.132454: 3997:120:R + 4055:120:S | ||
514 | bash-3997 [01] 240.132457: 3997:120:R ==> 4055:120:R | ||
515 | sleep-4055 [01] 240.132460: 4055:120:D ==> 3997:120:R | ||
516 | bash-3997 [01] 240.132463: 3997:120:R + 4055:120:D | ||
517 | bash-3997 [01] 240.132465: 3997:120:R ==> 4055:120:R | ||
518 | <idle>-0 [00] 240.132589: 0:140:R + 4:115:S | ||
519 | <idle>-0 [00] 240.132591: 0:140:R ==> 4:115:R | ||
520 | ksoftirqd/0-4 [00] 240.132595: 4:115:S ==> 0:140:R | ||
521 | <idle>-0 [00] 240.132598: 0:140:R + 4:115:S | ||
522 | <idle>-0 [00] 240.132599: 0:140:R ==> 4:115:R | ||
523 | ksoftirqd/0-4 [00] 240.132603: 4:115:S ==> 0:140:R | ||
524 | sleep-4055 [01] 240.133058: 4055:120:S ==> 3997:120:R | ||
525 | [...] | ||
526 | |||
527 | |||
528 | As we have discussed previously about this format, the header | ||
529 | shows the name of the trace and points to the options. The | ||
530 | "FUNCTION" is a misnomer since here it represents the wake ups | ||
531 | and context switches. | ||
532 | |||
533 | The sched_switch file only lists the wake ups (represented with | ||
534 | '+') and context switches ('==>') with the previous task or | ||
535 | current task first followed by the next task or task waking up. | ||
536 | The format for both of these is PID:KERNEL-PRIO:TASK-STATE. | ||
537 | Remember that the KERNEL-PRIO is the inverse of the actual | ||
538 | priority with zero (0) being the highest priority and the nice | ||
539 | values starting at 100 (nice -20). Below is a quick chart to map | ||
540 | the kernel priority to user land priorities. | ||
541 | |||
542 | Kernel Space User Space | ||
543 | =============================================================== | ||
544 | 0(high) to 98(low) user RT priority 99(high) to 1(low) | ||
545 | with SCHED_RR or SCHED_FIFO | ||
546 | --------------------------------------------------------------- | ||
547 | 99 sched_priority is not used in scheduling | ||
548 | decisions(it must be specified as 0) | ||
549 | --------------------------------------------------------------- | ||
550 | 100(high) to 139(low) user nice -20(high) to 19(low) | ||
551 | --------------------------------------------------------------- | ||
552 | 140 idle task priority | ||
553 | --------------------------------------------------------------- | ||
554 | |||
555 | The task states are: | ||
556 | |||
557 | R - running : wants to run, may not actually be running | ||
558 | S - sleep : process is waiting to be woken up (handles signals) | ||
559 | D - disk sleep (uninterruptible sleep) : process must be woken up | ||
560 | (ignores signals) | ||
561 | T - stopped : process suspended | ||
562 | t - traced : process is being traced (with something like gdb) | ||
563 | Z - zombie : process waiting to be cleaned up | ||
564 | X - unknown | ||
565 | |||
566 | 461 | ||
567 | ftrace_enabled | 462 | ftrace_enabled |
568 | -------------- | 463 | -------------- |
@@ -607,10 +502,10 @@ an example: | |||
607 | # echo irqsoff > current_tracer | 502 | # echo irqsoff > current_tracer |
608 | # echo latency-format > trace_options | 503 | # echo latency-format > trace_options |
609 | # echo 0 > tracing_max_latency | 504 | # echo 0 > tracing_max_latency |
610 | # echo 1 > tracing_enabled | 505 | # echo 1 > tracing_on |
611 | # ls -ltr | 506 | # ls -ltr |
612 | [...] | 507 | [...] |
613 | # echo 0 > tracing_enabled | 508 | # echo 0 > tracing_on |
614 | # cat trace | 509 | # cat trace |
615 | # tracer: irqsoff | 510 | # tracer: irqsoff |
616 | # | 511 | # |
@@ -715,10 +610,10 @@ is much like the irqsoff tracer. | |||
715 | # echo preemptoff > current_tracer | 610 | # echo preemptoff > current_tracer |
716 | # echo latency-format > trace_options | 611 | # echo latency-format > trace_options |
717 | # echo 0 > tracing_max_latency | 612 | # echo 0 > tracing_max_latency |
718 | # echo 1 > tracing_enabled | 613 | # echo 1 > tracing_on |
719 | # ls -ltr | 614 | # ls -ltr |
720 | [...] | 615 | [...] |
721 | # echo 0 > tracing_enabled | 616 | # echo 0 > tracing_on |
722 | # cat trace | 617 | # cat trace |
723 | # tracer: preemptoff | 618 | # tracer: preemptoff |
724 | # | 619 | # |
@@ -863,10 +758,10 @@ tracers. | |||
863 | # echo preemptirqsoff > current_tracer | 758 | # echo preemptirqsoff > current_tracer |
864 | # echo latency-format > trace_options | 759 | # echo latency-format > trace_options |
865 | # echo 0 > tracing_max_latency | 760 | # echo 0 > tracing_max_latency |
866 | # echo 1 > tracing_enabled | 761 | # echo 1 > tracing_on |
867 | # ls -ltr | 762 | # ls -ltr |
868 | [...] | 763 | [...] |
869 | # echo 0 > tracing_enabled | 764 | # echo 0 > tracing_on |
870 | # cat trace | 765 | # cat trace |
871 | # tracer: preemptirqsoff | 766 | # tracer: preemptirqsoff |
872 | # | 767 | # |
@@ -1026,9 +921,9 @@ Instead of performing an 'ls', we will run 'sleep 1' under | |||
1026 | # echo wakeup > current_tracer | 921 | # echo wakeup > current_tracer |
1027 | # echo latency-format > trace_options | 922 | # echo latency-format > trace_options |
1028 | # echo 0 > tracing_max_latency | 923 | # echo 0 > tracing_max_latency |
1029 | # echo 1 > tracing_enabled | 924 | # echo 1 > tracing_on |
1030 | # chrt -f 5 sleep 1 | 925 | # chrt -f 5 sleep 1 |
1031 | # echo 0 > tracing_enabled | 926 | # echo 0 > tracing_on |
1032 | # cat trace | 927 | # cat trace |
1033 | # tracer: wakeup | 928 | # tracer: wakeup |
1034 | # | 929 | # |
@@ -1140,9 +1035,9 @@ ftrace_enabled is set; otherwise this tracer is a nop. | |||
1140 | 1035 | ||
1141 | # sysctl kernel.ftrace_enabled=1 | 1036 | # sysctl kernel.ftrace_enabled=1 |
1142 | # echo function > current_tracer | 1037 | # echo function > current_tracer |
1143 | # echo 1 > tracing_enabled | 1038 | # echo 1 > tracing_on |
1144 | # usleep 1 | 1039 | # usleep 1 |
1145 | # echo 0 > tracing_enabled | 1040 | # echo 0 > tracing_on |
1146 | # cat trace | 1041 | # cat trace |
1147 | # tracer: function | 1042 | # tracer: function |
1148 | # | 1043 | # |
@@ -1180,7 +1075,7 @@ int trace_fd; | |||
1180 | [...] | 1075 | [...] |
1181 | int main(int argc, char *argv[]) { | 1076 | int main(int argc, char *argv[]) { |
1182 | [...] | 1077 | [...] |
1183 | trace_fd = open(tracing_file("tracing_enabled"), O_WRONLY); | 1078 | trace_fd = open(tracing_file("tracing_on"), O_WRONLY); |
1184 | [...] | 1079 | [...] |
1185 | if (condition_hit()) { | 1080 | if (condition_hit()) { |
1186 | write(trace_fd, "0", 1); | 1081 | write(trace_fd, "0", 1); |
@@ -1631,9 +1526,9 @@ If I am only interested in sys_nanosleep and hrtimer_interrupt: | |||
1631 | # echo sys_nanosleep hrtimer_interrupt \ | 1526 | # echo sys_nanosleep hrtimer_interrupt \ |
1632 | > set_ftrace_filter | 1527 | > set_ftrace_filter |
1633 | # echo function > current_tracer | 1528 | # echo function > current_tracer |
1634 | # echo 1 > tracing_enabled | 1529 | # echo 1 > tracing_on |
1635 | # usleep 1 | 1530 | # usleep 1 |
1636 | # echo 0 > tracing_enabled | 1531 | # echo 0 > tracing_on |
1637 | # cat trace | 1532 | # cat trace |
1638 | # tracer: ftrace | 1533 | # tracer: ftrace |
1639 | # | 1534 | # |
@@ -1879,9 +1774,9 @@ different. The trace is live. | |||
1879 | # echo function > current_tracer | 1774 | # echo function > current_tracer |
1880 | # cat trace_pipe > /tmp/trace.out & | 1775 | # cat trace_pipe > /tmp/trace.out & |
1881 | [1] 4153 | 1776 | [1] 4153 |
1882 | # echo 1 > tracing_enabled | 1777 | # echo 1 > tracing_on |
1883 | # usleep 1 | 1778 | # usleep 1 |
1884 | # echo 0 > tracing_enabled | 1779 | # echo 0 > tracing_on |
1885 | # cat trace | 1780 | # cat trace |
1886 | # tracer: function | 1781 | # tracer: function |
1887 | # | 1782 | # |
diff --git a/Documentation/trace/kprobetrace.txt b/Documentation/trace/kprobetrace.txt index 5f77d94598dd..6d27ab8d6e9f 100644 --- a/Documentation/trace/kprobetrace.txt +++ b/Documentation/trace/kprobetrace.txt | |||
@@ -42,11 +42,25 @@ Synopsis of kprobe_events | |||
42 | +|-offs(FETCHARG) : Fetch memory at FETCHARG +|- offs address.(**) | 42 | +|-offs(FETCHARG) : Fetch memory at FETCHARG +|- offs address.(**) |
43 | NAME=FETCHARG : Set NAME as the argument name of FETCHARG. | 43 | NAME=FETCHARG : Set NAME as the argument name of FETCHARG. |
44 | FETCHARG:TYPE : Set TYPE as the type of FETCHARG. Currently, basic types | 44 | FETCHARG:TYPE : Set TYPE as the type of FETCHARG. Currently, basic types |
45 | (u8/u16/u32/u64/s8/s16/s32/s64) and string are supported. | 45 | (u8/u16/u32/u64/s8/s16/s32/s64), "string" and bitfield |
46 | are supported. | ||
46 | 47 | ||
47 | (*) only for return probe. | 48 | (*) only for return probe. |
48 | (**) this is useful for fetching a field of data structures. | 49 | (**) this is useful for fetching a field of data structures. |
49 | 50 | ||
51 | Types | ||
52 | ----- | ||
53 | Several types are supported for fetch-args. Kprobe tracer will access memory | ||
54 | by given type. Prefix 's' and 'u' means those types are signed and unsigned | ||
55 | respectively. Traced arguments are shown in decimal (signed) or hex (unsigned). | ||
56 | String type is a special type, which fetches a "null-terminated" string from | ||
57 | kernel space. This means it will fail and store NULL if the string container | ||
58 | has been paged out. | ||
59 | Bitfield is another special type, which takes 3 parameters, bit-width, bit- | ||
60 | offset, and container-size (usually 32). The syntax is; | ||
61 | |||
62 | b<bit-width>@<bit-offset>/<container-size> | ||
63 | |||
50 | 64 | ||
51 | Per-Probe Event Filtering | 65 | Per-Probe Event Filtering |
52 | ------------------------- | 66 | ------------------------- |
diff --git a/Documentation/usb/usbmon.txt b/Documentation/usb/usbmon.txt index 66f92d1194c1..a4efa0462f05 100644 --- a/Documentation/usb/usbmon.txt +++ b/Documentation/usb/usbmon.txt | |||
@@ -12,6 +12,10 @@ Controller Drivers (HCD). So, if HCD is buggy, the traces reported by | |||
12 | usbmon may not correspond to bus transactions precisely. This is the same | 12 | usbmon may not correspond to bus transactions precisely. This is the same |
13 | situation as with tcpdump. | 13 | situation as with tcpdump. |
14 | 14 | ||
15 | Two APIs are currently implemented: "text" and "binary". The binary API | ||
16 | is available through a character device in /dev namespace and is an ABI. | ||
17 | The text API is deprecated since 2.6.35, but available for convenience. | ||
18 | |||
15 | * How to use usbmon to collect raw text traces | 19 | * How to use usbmon to collect raw text traces |
16 | 20 | ||
17 | Unlike the packet socket, usbmon has an interface which provides traces | 21 | Unlike the packet socket, usbmon has an interface which provides traces |
@@ -162,39 +166,11 @@ Here is the list of words, from left to right: | |||
162 | not machine words, but really just a byte stream split into words to make | 166 | not machine words, but really just a byte stream split into words to make |
163 | it easier to read. Thus, the last word may contain from one to four bytes. | 167 | it easier to read. Thus, the last word may contain from one to four bytes. |
164 | The length of collected data is limited and can be less than the data length | 168 | The length of collected data is limited and can be less than the data length |
165 | report in Data Length word. | 169 | reported in the Data Length word. In the case of an Isochronous input (Zi) |
166 | 170 | completion where the received data is sparse in the buffer, the length of | |
167 | Here is an example of code to read the data stream in a well known programming | 171 | the collected data can be greater than the Data Length value (because Data |
168 | language: | 172 | Length counts only the bytes that were received whereas the Data words |
169 | 173 | contain the entire transfer buffer). | |
170 | class ParsedLine { | ||
171 | int data_len; /* Available length of data */ | ||
172 | byte data[]; | ||
173 | |||
174 | void parseData(StringTokenizer st) { | ||
175 | int availwords = st.countTokens(); | ||
176 | data = new byte[availwords * 4]; | ||
177 | data_len = 0; | ||
178 | while (st.hasMoreTokens()) { | ||
179 | String data_str = st.nextToken(); | ||
180 | int len = data_str.length() / 2; | ||
181 | int i; | ||
182 | int b; // byte is signed, apparently?! XXX | ||
183 | for (i = 0; i < len; i++) { | ||
184 | // data[data_len] = Byte.parseByte( | ||
185 | // data_str.substring(i*2, i*2 + 2), | ||
186 | // 16); | ||
187 | b = Integer.parseInt( | ||
188 | data_str.substring(i*2, i*2 + 2), | ||
189 | 16); | ||
190 | if (b >= 128) | ||
191 | b *= -1; | ||
192 | data[data_len] = (byte) b; | ||
193 | data_len++; | ||
194 | } | ||
195 | } | ||
196 | } | ||
197 | } | ||
198 | 174 | ||
199 | Examples: | 175 | Examples: |
200 | 176 | ||
diff --git a/Documentation/zh_CN/SecurityBugs b/Documentation/zh_CN/SecurityBugs new file mode 100644 index 000000000000..d21eb07fe943 --- /dev/null +++ b/Documentation/zh_CN/SecurityBugs | |||
@@ -0,0 +1,50 @@ | |||
1 | Chinese translated version of Documentation/SecurityBugs | ||
2 | |||
3 | If you have any comment or update to the content, please contact the | ||
4 | original document maintainer directly. However, if you have a problem | ||
5 | communicating in English you can also ask the Chinese maintainer for | ||
6 | help. Contact the Chinese maintainer if this translation is outdated | ||
7 | or if there is a problem with the translation. | ||
8 | |||
9 | Chinese maintainer: Harry Wei <harryxiyou@gmail.com> | ||
10 | --------------------------------------------------------------------- | ||
11 | Documentation/SecurityBugs 鐨勪腑鏂囩炕璇 | ||
12 | |||
13 | 濡傛灉鎯宠瘎璁烘垨鏇存柊鏈枃鐨勫唴瀹癸紝璇风洿鎺ヨ仈绯诲師鏂囨。鐨勭淮鎶よ呫傚鏋滀綘浣跨敤鑻辨枃 | ||
14 | 浜ゆ祦鏈夊洶闅剧殑璇濓紝涔熷彲浠ュ悜涓枃鐗堢淮鎶よ呮眰鍔┿傚鏋滄湰缈昏瘧鏇存柊涓嶅強鏃舵垨鑰呯炕 | ||
15 | 璇戝瓨鍦ㄩ棶棰橈紝璇疯仈绯讳腑鏂囩増缁存姢鑰呫 | ||
16 | |||
17 | 涓枃鐗堢淮鎶よ咃細 璐惧▉濞 Harry Wei <harryxiyou@gmail.com> | ||
18 | 涓枃鐗堢炕璇戣咃細 璐惧▉濞 Harry Wei <harryxiyou@gmail.com> | ||
19 | 涓枃鐗堟牎璇戣咃細 璐惧▉濞 Harry Wei <harryxiyou@gmail.com> | ||
20 | |||
21 | |||
22 | 浠ヤ笅涓烘鏂 | ||
23 | --------------------------------------------------------------------- | ||
24 | Linux鍐呮牳寮鍙戣呰涓哄畨鍏ㄩ潪甯搁噸瑕併傚洜姝わ紝鎴戜滑鎯宠鐭ラ亾褰撲竴涓湁鍏充簬 | ||
25 | 瀹夊叏鐨勬紡娲炶鍙戠幇鐨勬椂鍊欙紝骞朵笖瀹冨彲鑳戒細琚敖蹇殑淇鎴栬呭叕寮銆傝鎶婅繖涓畨鍏 | ||
26 | 婕忔礊鎶ュ憡缁橪inux鍐呮牳瀹夊叏鍥㈤槦銆 | ||
27 | |||
28 | 1) 鑱旂郴 | ||
29 | |||
30 | linux鍐呮牳瀹夊叏鍥㈤槦鍙互閫氳繃email<security@kernel.org>鏉ヨ仈绯汇傝繖鏄 | ||
31 | 涓缁勭嫭绔嬬殑瀹夊叏宸ヤ綔浜哄憳锛屽彲浠ュ府鍔╂敼鍠勬紡娲炴姤鍛婂苟涓斿叕甯冨拰鍙栨秷涓涓慨澶嶃傚畨 | ||
32 | 鍏ㄥ洟闃熸湁鍙兘浼氫粠閮ㄥ垎鐨勭淮鎶よ呴偅閲屽紩杩涢澶栫殑甯姪鏉ヤ簡瑙e苟涓斾慨澶嶅畨鍏ㄦ紡娲炪 | ||
33 | 褰撻亣鍒颁换浣曟紡娲烇紝鎵鑳芥彁渚涚殑淇℃伅瓒婂灏辫秺鑳借瘖鏂拰淇銆傚鏋滀綘涓嶆竻妤氫粈涔 | ||
34 | 鏄湁甯姪鐨勪俊鎭紝閭e氨璇烽噸娓╀竴涓婻EPORTING-BUGS鏂囦欢涓殑姒傝堪杩囩▼銆備换 | ||
35 | 浣曟敾鍑绘х殑浠g爜閮芥槸闈炲父鏈夌敤鐨勶紝鏈粡鎶ュ憡鑰呯殑鍚屾剰涓嶄細琚彇娑堬紝闄ら潪瀹冨凡缁 | ||
36 | 琚叕甯冧簬浼椼 | ||
37 | |||
38 | 2) 鍏紑 | ||
39 | |||
40 | Linux鍐呮牳瀹夊叏鍥㈤槦鐨勫畻鏃ㄥ氨鏄拰婕忔礊鎻愪氦鑰呬竴璧峰鐞嗘紡娲炵殑瑙e喅鏂规鐩 | ||
41 | 鍒板叕寮銆傛垜浠枩娆㈠敖蹇湴瀹屽叏鍏紑婕忔礊銆傚綋涓涓紡娲炴垨鑰呬慨澶嶈繕娌℃湁琚畬鍏ㄥ湴鐞 | ||
42 | 瑙o紝瑙e喅鏂规娌℃湁閫氳繃娴嬭瘯鎴栬呬緵搴斿晢鍗忚皟锛屽彲浠ュ悎鐞嗗湴寤惰繜鍏紑銆傜劧鑰岋紝鎴戜滑 | ||
43 | 鏈熸湜杩欎簺寤惰繜灏藉彲鑳界殑鐭簺锛屾槸鍙暟鐨勫嚑澶╋紝鑰屼笉鏄嚑涓槦鏈熸垨鑰呭嚑涓湀銆傚叕寮 | ||
44 | 鏃ユ湡鏄氳繃瀹夊叏鍥㈤槦鍜屾紡娲炴彁渚涜呬互鍙婁緵搴斿晢娲借皥鍚庣殑缁撴灉銆傚叕寮鏃堕棿琛ㄦ槸浠庡緢 | ||
45 | 鐭紙鐗规畩鐨勶紝瀹冨凡缁忚鍏紬鎵鐭ラ亾锛夊埌鍑犱釜鏄熸湡銆備綔涓轰竴涓熀鏈殑榛樿鏀跨瓥锛屾垜 | ||
46 | 浠墍鏈熸湜閫氱煡鍏紬鐨勬棩鏈熸槸7澶╃殑瀹夋帓銆 | ||
47 | |||
48 | 3) 淇濆瘑鍗忚 | ||
49 | |||
50 | Linux鍐呮牳瀹夊叏鍥㈤槦涓嶆槸涓涓寮忕殑鍥綋锛屽洜姝や笉鑳藉姞鍏ヤ换浣曠殑淇濆瘑鍗忚銆 | ||
diff --git a/Documentation/zh_CN/SubmitChecklist b/Documentation/zh_CN/SubmitChecklist new file mode 100644 index 000000000000..951415bbab0c --- /dev/null +++ b/Documentation/zh_CN/SubmitChecklist | |||
@@ -0,0 +1,109 @@ | |||
1 | Chinese translated version of Documentation/SubmitChecklist | ||
2 | |||
3 | If you have any comment or update to the content, please contact the | ||
4 | original document maintainer directly. However, if you have a problem | ||
5 | communicating in English you can also ask the Chinese maintainer for | ||
6 | help. Contact the Chinese maintainer if this translation is outdated | ||
7 | or if there is a problem with the translation. | ||
8 | |||
9 | Chinese maintainer: Harry Wei <harryxiyou@gmail.com> | ||
10 | --------------------------------------------------------------------- | ||
11 | Documentation/SubmitChecklist 的中文翻译 | ||
12 | |||
13 | 如果想评论或更新本文的内容,请直接联系原文档的维护者。如果你使用英文 | ||
14 | 交流有困难的话,也可以向中文版维护者求助。如果本翻译更新不及时或者翻 | ||
15 | 译存在问题,请联系中文版维护者。 | ||
16 | |||
17 | 中文版维护者: 贾威威 Harry Wei <harryxiyou@gmail.com> | ||
18 | 中文版翻译者: 贾威威 Harry Wei <harryxiyou@gmail.com> | ||
19 | 中文版校译者: 贾威威 Harry Wei <harryxiyou@gmail.com> | ||
20 | |||
21 | |||
22 | 以下为正文 | ||
23 | --------------------------------------------------------------------- | ||
24 | Linux内核提交清单 | ||
25 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
26 | |||
27 | 这里有一些内核开发者应该做的基本事情,如果他们想看到自己的内核补丁提交 | ||
28 | 被接受的更快。 | ||
29 | |||
30 | 这些都是超出Documentation/SubmittingPatches文档里所提供的以及其他 | ||
31 | 关于提交Linux内核补丁的说明。 | ||
32 | |||
33 | 1:如果你使用了一个功能那么就#include定义/声明那个功能的那个文件。 | ||
34 | 不要依靠其他间接引入定义/声明那个功能的头文件。 | ||
35 | |||
36 | 2:构建简洁适用或者更改CONFIG选项 =y,=m,或者=n。 | ||
37 | 不要有编译警告/错误, 不要有链接警告/错误。 | ||
38 | |||
39 | 2b:通过 allnoconfig, allmodconfig | ||
40 | |||
41 | 2c:当使用 0=builddir 成功地构建 | ||
42 | |||
43 | 3:通过使用本地交叉编译工具或者其他一些构建产所,在多CPU框架上构建。 | ||
44 | |||
45 | 4:ppc64 是一个很好的检查交叉编译的框架,因为它往往把‘unsigned long’ | ||
46 | 当64位值来使用。 | ||
47 | |||
48 | 5:按照Documentation/CodingStyle文件里的详细描述,检查你补丁的整体风格。 | ||
49 | 使用补丁风格检查琐碎的违规(scripts/checkpatch.pl),审核员优先提交。 | ||
50 | 你应该调整遗留在你补丁中的所有违规。 | ||
51 | |||
52 | 6:任何更新或者改动CONFIG选项都不能打乱配置菜单。 | ||
53 | |||
54 | 7:所有的Kconfig选项更新都要有说明文字。 | ||
55 | |||
56 | 8:已经认真地总结了相关的Kconfig组合。这是很难通过测试做好的--脑力在这里下降。 | ||
57 | |||
58 | 9:检查具有简洁性。 | ||
59 | |||
60 | 10:使用'make checkstack'和'make namespacecheck'检查,然后修改所找到的问题。 | ||
61 | 注意:堆栈检查不会明确地出现问题,但是任何的一个函数在堆栈上使用多于512字节 | ||
62 | 都要准备修改。 | ||
63 | |||
64 | 11:包含kernel-doc到全局内核APIs文件。(不要求静态的函数,但是包含也无所谓。) | ||
65 | 使用'make htmldocs'或者'make mandocs'来检查kernel-doc,然后修改任何 | ||
66 | 发现的问题。 | ||
67 | |||
68 | 12:已经通过CONFIG_PREEMPT, CONFIG_DEBUG_PREEMPT, | ||
69 | CONFIG_DEBUG_SLAB, CONFIG_DEBUG_PAGEALLOC, CONFIG_DEBUG_MUTEXES, | ||
70 | CONFIG_DEBUG_SPINLOCK, CONFIG_DEBUG_SPINLOCK_SLEEP测试,并且同时都 | ||
71 | 使能。 | ||
72 | |||
73 | 13:已经都构建并且使用或者不使用 CONFIG_SMP 和 CONFIG_PREEMPT测试执行时间。 | ||
74 | |||
75 | 14:如果补丁影响IO/Disk,等等:已经通过使用或者不使用 CONFIG_LBDAF 测试。 | ||
76 | |||
77 | 15:所有的codepaths已经行使所有lockdep启用功能。 | ||
78 | |||
79 | 16:所有的/proc记录更新都要作成文件放在Documentation/目录下。 | ||
80 | |||
81 | 17:所有的内核启动参数更新都被记录到Documentation/kernel-parameters.txt文件中。 | ||
82 | |||
83 | 18:所有的模块参数更新都用MODULE_PARM_DESC()记录。 | ||
84 | |||
85 | 19:所有的用户空间接口更新都被记录到Documentation/ABI/。查看Documentation/ABI/README | ||
86 | 可以获得更多的信息。改变用户空间接口的补丁应该被邮件抄送给linux-api@vger.kernel.org。 | ||
87 | |||
88 | 20:检查它是不是都通过`make headers_check'。 | ||
89 | |||
90 | 21:已经通过至少引入slab和page-allocation失败检查。查看Documentation/fault-injection/。 | ||
91 | |||
92 | 22:新加入的源码已经通过`gcc -W'(使用"make EXTRA_CFLAGS=-W")编译。这样将产生很多烦恼, | ||
93 | 但是对于寻找漏洞很有益处,例如:"warning: comparison between signed and unsigned"。 | ||
94 | |||
95 | 23:当它被合并到-mm补丁集后再测试,用来确定它是否还和补丁队列中的其他补丁一起工作以及在VM,VFS | ||
96 | 和其他子系统中各个变化。 | ||
97 | |||
98 | 24:所有的内存屏障{e.g., barrier(), rmb(), wmb()}需要在源代码中的一个注释来解释他们都是干什么的 | ||
99 | 以及原因。 | ||
100 | |||
101 | 25:如果有任何输入输出控制的补丁被添加,也要更新Documentation/ioctl/ioctl-number.txt。 | ||
102 | |||
103 | 26:如果你的更改代码依靠或者使用任何的内核APIs或者与下面的kconfig符号有关系的功能,你就要 | ||
104 | 使用相关的kconfig符号关闭, and/or =m(如果选项提供)[在同一时间不是所用的都启用,仅仅各个或者自由 | ||
105 | 组合他们]: | ||
106 | |||
107 | CONFIG_SMP, CONFIG_SYSFS, CONFIG_PROC_FS, CONFIG_INPUT, CONFIG_PCI, | ||
108 | CONFIG_BLOCK, CONFIG_PM, CONFIG_HOTPLUG, CONFIG_MAGIC_SYSRQ, | ||
109 | CONFIG_NET, CONFIG_INET=n (后一个使用 CONFIG_NET=y) | ||
diff --git a/Documentation/zh_CN/SubmittingPatches b/Documentation/zh_CN/SubmittingPatches index 9a1a6e1ed09e..0f4385a62a49 100644 --- a/Documentation/zh_CN/SubmittingPatches +++ b/Documentation/zh_CN/SubmittingPatches | |||
@@ -100,7 +100,7 @@ http://userweb.kernel.org/~akpm/stuff/patch-scripts.tar.gz | |||
100 | 100 | ||
101 | 灏嗘敼鍔ㄦ媶鍒嗭紝閫昏緫绫讳技鐨勬斁鍒板悓涓涓ˉ涓佹枃浠堕噷銆 | 101 | 灏嗘敼鍔ㄦ媶鍒嗭紝閫昏緫绫讳技鐨勬斁鍒板悓涓涓ˉ涓佹枃浠堕噷銆 |
102 | 102 | ||
103 | 渚嬪锛屽鏋滀綘鐨勬敼鍔ㄩ噷鍚屾椂鏈塨ug淇鍜屾ц兘浼樺寲锛岄偅涔堟妸杩欎簺鏀瑰姩墠鍒嗗埌涓や釜鎴 | 103 | 渚嬪锛屽鏋滀綘鐨勬敼鍔ㄩ噷鍚屾椂鏈塨ug淇鍜屾ц兘浼樺寲锛岄偅涔堟妸杩欎簺鏀瑰姩媶鍒嗗埌涓や釜鎴 |
104 | 鑰呮洿澶氱殑琛ヤ竵鏂囦欢涓傚鏋滀綘鐨勬敼鍔ㄥ寘鍚API鐨勪慨鏀癸紝骞朵笖淇敼浜嗛┍鍔ㄧ▼搴忔潵閫 | 104 | 鑰呮洿澶氱殑琛ヤ竵鏂囦欢涓傚鏋滀綘鐨勬敼鍔ㄥ寘鍚API鐨勪慨鏀癸紝骞朵笖淇敼浜嗛┍鍔ㄧ▼搴忔潵閫 |
105 | 搴旇繖浜涙柊鐨凙PI锛岄偅涔堟妸杩欎簺淇敼鍒嗘垚涓や釜琛ヤ竵銆 | 105 | 搴旇繖浜涙柊鐨凙PI锛岄偅涔堟妸杩欎簺淇敼鍒嗘垚涓や釜琛ヤ竵銆 |
106 | 106 | ||
@@ -230,7 +230,7 @@ pref("mailnews.display.disable_format_flowed_support", true); | |||
230 | 浜涘師鍥狅紝淇閿欒锛岄噸鏂版彁浜ゆ洿鏂板悗鐨勬敼鍔紝鏄綘鑷繁鐨勫伐浣溿 | 230 | 浜涘師鍥狅紝淇閿欒锛岄噸鏂版彁浜ゆ洿鏂板悗鐨勬敼鍔紝鏄綘鑷繁鐨勫伐浣溿 |
231 | 231 | ||
232 | Linus涓嶇粰鍑轰换浣曡瘎璁哄氨鈥滀涪寮冣濅綘鐨勮ˉ涓佹槸甯歌鐨勪簨鎯呫傚湪绯荤粺涓繖鏍风殑浜嬫儏寰 | 232 | Linus涓嶇粰鍑轰换浣曡瘎璁哄氨鈥滀涪寮冣濅綘鐨勮ˉ涓佹槸甯歌鐨勪簨鎯呫傚湪绯荤粺涓繖鏍风殑浜嬫儏寰 |
233 | 骞冲父銆傚鏋滀粬娌℃湁鎺ュ彈浣犵殑琛ヤ竵锛屼篃璁告槸鐢变簬浠ヤ笅鍘鏈锛 | 233 | 骞冲父銆傚鏋滀粬娌℃湁鎺ュ彈浣犵殑琛ヤ竵锛屼篃璁告槸鐢变簬浠ヤ笅鍘鍥锛 |
234 | * 浣犵殑琛ヤ竵涓嶈兘鍦ㄦ渶鏂扮増鏈殑鍐呮牳涓婂共鍑鐨勬墦涓娿 | 234 | * 浣犵殑琛ヤ竵涓嶈兘鍦ㄦ渶鏂扮増鏈殑鍐呮牳涓婂共鍑鐨勬墦涓娿 |
235 | * 浣犵殑琛ヤ竵鍦 linux-kernel 閭欢鍒楄〃涓病鏈夊緱鍒板厖鍒嗙殑璁ㄨ銆 | 235 | * 浣犵殑琛ヤ竵鍦 linux-kernel 閭欢鍒楄〃涓病鏈夊緱鍒板厖鍒嗙殑璁ㄨ銆 |
236 | * 椋庢牸闂锛堝弬鐓х2灏忚妭锛 | 236 | * 椋庢牸闂锛堝弬鐓х2灏忚妭锛 |
diff --git a/Documentation/zh_CN/magic-number.txt b/Documentation/zh_CN/magic-number.txt new file mode 100644 index 000000000000..4c4ce853577b --- /dev/null +++ b/Documentation/zh_CN/magic-number.txt | |||
@@ -0,0 +1,167 @@ | |||
1 | Chinese translated version of Documentation/magic-number.txt | ||
2 | |||
3 | If you have any comment or update to the content, please post to LKML directly. | ||
4 | However, if you have problem communicating in English you can also ask the | ||
5 | Chinese maintainer for help. Contact the Chinese maintainer, if this | ||
6 | translation is outdated or there is problem with translation. | ||
7 | |||
8 | Chinese maintainer: Jia Wei Wei <harryxiyou@gmail.com> | ||
9 | --------------------------------------------------------------------- | ||
10 | Documentation/magic-number.txt鐨勪腑鏂囩炕璇 | ||
11 | |||
12 | 濡傛灉鎯宠瘎璁烘垨鏇存柊鏈枃鐨勫唴瀹癸紝璇风洿鎺ュ彂淇″埌LKML銆傚鏋滀綘浣跨敤鑻辨枃浜ゆ祦鏈夊洶闅剧殑璇濓紝涔熷彲 | ||
13 | 浠ュ悜涓枃鐗堢淮鎶よ呮眰鍔┿傚鏋滄湰缈昏瘧鏇存柊涓嶅強鏃舵垨鑰呯炕璇戝瓨鍦ㄩ棶棰橈紝璇疯仈绯讳腑鏂囩増缁存姢鑰呫 | ||
14 | |||
15 | 涓枃鐗堢淮鎶よ咃細 璐惧▉濞 Jia Wei Wei <harryxiyou@gmail.com> | ||
16 | 涓枃鐗堢炕璇戣咃細 璐惧▉濞 Jia Wei Wei <harryxiyou@gmail.com> | ||
17 | 涓枃鐗堟牎璇戣咃細 璐惧▉濞 Jia Wei Wei <harryxiyou@gmail.com> | ||
18 | |||
19 | 浠ヤ笅涓烘鏂 | ||
20 | --------------------------------------------------------------------- | ||
21 | 杩欎釜鏂囦欢鏄湁鍏冲綋鍓嶄娇鐢ㄧ殑榄旀湳鍊兼敞鍐岃〃銆傚綋浣犵粰涓涓粨鏋勬坊鍔犱簡涓涓瓟鏈硷紝浣犱篃搴旇鎶婅繖涓瓟鏈兼坊鍔犲埌杩欎釜鏂囦欢锛屽洜涓烘垜浠渶濂芥妸鐢ㄤ簬鍚勭缁撴瀯鐨勯瓟鏈肩粺涓璧锋潵銆 | ||
22 | |||
23 | 浣跨敤榄旀湳鍊兼潵淇濇姢鍐呮牳鏁版嵁缁撴瀯鏄竴涓潪甯稿ソ鐨勪富鎰忋傝繖灏卞厑璁镐綘鍦ㄨ繍琛屾湡妫鏌(a)涓涓粨鏋勬槸鍚﹀凡缁忚鏀诲嚮锛屾垨鑰(b)浣犲凡缁忕粰涓涓緥琛岀▼搴忛氳繃浜嗕竴涓敊璇殑缁撴瀯銆傚悗涓绉嶆儏鍐电壒鍒湴鏈夌敤---鐗瑰埆鏄綋浣犻氳繃涓涓┖鎸囬拡鎸囧悜缁撴瀯浣撶殑鏃跺欍倀ty婧愮爜锛屼緥濡傦紝缁忓父閫氳繃鐗瑰畾椹卞姩浣跨敤杩欑鏂规硶骞朵笖鍙嶅鍦版帓鍒楃壒瀹氭柟闈㈢殑缁撴瀯銆 | ||
24 | |||
25 | 浣跨敤榄旀湳鍊肩殑鏂规硶鏄湪缁撴瀯鐨勫紑濮嬪澹版槑鐨勶紝濡備笅锛 | ||
26 | |||
27 | struct tty_ldisc { | ||
28 | int magic; | ||
29 | ... | ||
30 | }; | ||
31 | |||
32 | 褰撲綘浠ュ悗缁欏唴鏍告坊鍔犲寮哄姛鑳界殑鏃跺欙紝璇烽伒瀹堣繖鏉¤鍒欙紒杩欐牱灏变細鑺傜渷鏁颁笉娓呯殑璋冭瘯鏃堕棿锛岀壒鍒槸涓浜涘彜鎬殑鎯呭喌锛屼緥濡傦紝鏁扮粍瓒呭嚭鑼冨洿骞朵笖閲嶆柊鍐欎簡瓒呭嚭閮ㄥ垎銆傞伒瀹堣繖涓鍒欙紝鈥繖浜涙儏鍐靛彲浠ヨ蹇熷湴锛屽畨鍏ㄥ湴閬垮厤銆 | ||
33 | |||
34 | Theodore Ts'o | ||
35 | 31 Mar 94 | ||
36 | |||
37 | 缁欏綋鍓嶇殑Linux 2.1.55娣诲姞榄旀湳琛ㄣ | ||
38 | |||
39 | Michael Chastain | ||
40 | <mailto:mec@shout.net> | ||
41 | 22 Sep 1997 | ||
42 | |||
43 | 鐜板湪搴旇鏈鏂扮殑Linux 2.1.112.鍥犱负鍦ㄧ壒鎬у喕缁撴湡闂达紝涓嶈兘鍦2.2.x鍓嶆敼鍙樹换浣曚笢瑗裤傝繖浜涙潯鐩鏁板煙鎵鎺掑簭銆 | ||
44 | |||
45 | Krzysztof G.Baranowski | ||
46 | <mailto: kgb@knm.org.pl> | ||
47 | 29 Jul 1998 | ||
48 | |||
49 | 鏇存柊榄旀湳琛ㄥ埌Linux 2.5.45銆傚垰濂借秺杩囩壒鎬у喕缁擄紝浣嗘槸鏈夊彲鑳借繕浼氭湁涓浜涙柊鐨勯瓟鏈煎湪2.6.x涔嬪墠铻嶅叆鍒板唴鏍镐腑銆 | ||
50 | |||
51 | Petr Baudis | ||
52 | <pasky@ucw.cz> | ||
53 | 03 Nov 2002 | ||
54 | |||
55 | 鏇存柊榄旀湳琛ㄥ埌Linux 2.5.74銆 | ||
56 | |||
57 | Fabian Frederick | ||
58 | <ffrederick@users.sourceforge.net> | ||
59 | 09 Jul 2003 | ||
60 | |||
61 | 榄旀湳鍚 鍦板潃 缁撴瀯 鎵鍦ㄦ枃浠 | ||
62 | =========================================================================== | ||
63 | PG_MAGIC 'P' pg_{read,write}_hdr include/linux/pg.h | ||
64 | CMAGIC 0x0111 user include/linux/a.out.h | ||
65 | MKISS_DRIVER_MAGIC 0x04bf mkiss_channel drivers/net/mkiss.h | ||
66 | RISCOM8_MAGIC 0x0907 riscom_port drivers/char/riscom8.h | ||
67 | SPECIALIX_MAGIC 0x0907 specialix_port drivers/char/specialix_io8.h | ||
68 | HDLC_MAGIC 0x239e n_hdlc drivers/char/n_hdlc.c | ||
69 | APM_BIOS_MAGIC 0x4101 apm_user arch/i386/kernel/apm.c | ||
70 | CYCLADES_MAGIC 0x4359 cyclades_port include/linux/cyclades.h | ||
71 | DB_MAGIC 0x4442 fc_info drivers/net/iph5526_novram.c | ||
72 | DL_MAGIC 0x444d fc_info drivers/net/iph5526_novram.c | ||
73 | FASYNC_MAGIC 0x4601 fasync_struct include/linux/fs.h | ||
74 | FF_MAGIC 0x4646 fc_info drivers/net/iph5526_novram.c | ||
75 | ISICOM_MAGIC 0x4d54 isi_port include/linux/isicom.h | ||
76 | PTY_MAGIC 0x5001 drivers/char/pty.c | ||
77 | PPP_MAGIC 0x5002 ppp include/linux/if_pppvar.h | ||
78 | SERIAL_MAGIC 0x5301 async_struct include/linux/serial.h | ||
79 | SSTATE_MAGIC 0x5302 serial_state include/linux/serial.h | ||
80 | SLIP_MAGIC 0x5302 slip drivers/net/slip.h | ||
81 | STRIP_MAGIC 0x5303 strip drivers/net/strip.c | ||
82 | X25_ASY_MAGIC 0x5303 x25_asy drivers/net/x25_asy.h | ||
83 | SIXPACK_MAGIC 0x5304 sixpack drivers/net/hamradio/6pack.h | ||
84 | AX25_MAGIC 0x5316 ax_disp drivers/net/mkiss.h | ||
85 | ESP_MAGIC 0x53ee esp_struct drivers/char/esp.h | ||
86 | TTY_MAGIC 0x5401 tty_struct include/linux/tty.h | ||
87 | MGSL_MAGIC 0x5401 mgsl_info drivers/char/synclink.c | ||
88 | TTY_DRIVER_MAGIC 0x5402 tty_driver include/linux/tty_driver.h | ||
89 | MGSLPC_MAGIC 0x5402 mgslpc_info drivers/char/pcmcia/synclink_cs.c | ||
90 | TTY_LDISC_MAGIC 0x5403 tty_ldisc include/linux/tty_ldisc.h | ||
91 | USB_SERIAL_MAGIC 0x6702 usb_serial drivers/usb/serial/usb-serial.h | ||
92 | FULL_DUPLEX_MAGIC 0x6969 drivers/net/tulip/de2104x.c | ||
93 | USB_BLUETOOTH_MAGIC 0x6d02 usb_bluetooth drivers/usb/class/bluetty.c | ||
94 | RFCOMM_TTY_MAGIC 0x6d02 net/bluetooth/rfcomm/tty.c | ||
95 | USB_SERIAL_PORT_MAGIC 0x7301 usb_serial_port drivers/usb/serial/usb-serial.h | ||
96 | CG_MAGIC 0x00090255 ufs_cylinder_group include/linux/ufs_fs.h | ||
97 | A2232_MAGIC 0x000a2232 gs_port drivers/char/ser_a2232.h | ||
98 | RPORT_MAGIC 0x00525001 r_port drivers/char/rocket_int.h | ||
99 | LSEMAGIC 0x05091998 lse drivers/fc4/fc.c | ||
100 | GDTIOCTL_MAGIC 0x06030f07 gdth_iowr_str drivers/scsi/gdth_ioctl.h | ||
101 | RIEBL_MAGIC 0x09051990 drivers/net/atarilance.c | ||
102 | RIO_MAGIC 0x12345678 gs_port drivers/char/rio/rio_linux.c | ||
103 | SX_MAGIC 0x12345678 gs_port drivers/char/sx.h | ||
104 | NBD_REQUEST_MAGIC 0x12560953 nbd_request include/linux/nbd.h | ||
105 | RED_MAGIC2 0x170fc2a5 (any) mm/slab.c | ||
106 | BAYCOM_MAGIC 0x19730510 baycom_state drivers/net/baycom_epp.c | ||
107 | ISDN_X25IFACE_MAGIC 0x1e75a2b9 isdn_x25iface_proto_data | ||
108 | drivers/isdn/isdn_x25iface.h | ||
109 | ECP_MAGIC 0x21504345 cdkecpsig include/linux/cdk.h | ||
110 | LSOMAGIC 0x27091997 lso drivers/fc4/fc.c | ||
111 | LSMAGIC 0x2a3b4d2a ls drivers/fc4/fc.c | ||
112 | WANPIPE_MAGIC 0x414C4453 sdla_{dump,exec} include/linux/wanpipe.h | ||
113 | CS_CARD_MAGIC 0x43525553 cs_card sound/oss/cs46xx.c | ||
114 | LABELCL_MAGIC 0x4857434c labelcl_info_s include/asm/ia64/sn/labelcl.h | ||
115 | ISDN_ASYNC_MAGIC 0x49344C01 modem_info include/linux/isdn.h | ||
116 | CTC_ASYNC_MAGIC 0x49344C01 ctc_tty_info drivers/s390/net/ctctty.c | ||
117 | ISDN_NET_MAGIC 0x49344C02 isdn_net_local_s drivers/isdn/i4l/isdn_net_lib.h | ||
118 | SAVEKMSG_MAGIC2 0x4B4D5347 savekmsg arch/*/amiga/config.c | ||
119 | STLI_BOARDMAGIC 0x4bc6c825 stlibrd include/linux/istallion.h | ||
120 | CS_STATE_MAGIC 0x4c4f4749 cs_state sound/oss/cs46xx.c | ||
121 | SLAB_C_MAGIC 0x4f17a36d kmem_cache mm/slab.c | ||
122 | COW_MAGIC 0x4f4f4f4d cow_header_v1 arch/um/drivers/ubd_user.c | ||
123 | I810_CARD_MAGIC 0x5072696E i810_card sound/oss/i810_audio.c | ||
124 | TRIDENT_CARD_MAGIC 0x5072696E trident_card sound/oss/trident.c | ||
125 | ROUTER_MAGIC 0x524d4157 wan_device include/linux/wanrouter.h | ||
126 | SCC_MAGIC 0x52696368 gs_port drivers/char/scc.h | ||
127 | SAVEKMSG_MAGIC1 0x53415645 savekmsg arch/*/amiga/config.c | ||
128 | GDA_MAGIC 0x58464552 gda arch/mips/include/asm/sn/gda.h | ||
129 | RED_MAGIC1 0x5a2cf071 (any) mm/slab.c | ||
130 | STL_PORTMAGIC 0x5a7182c9 stlport include/linux/stallion.h | ||
131 | EEPROM_MAGIC_VALUE 0x5ab478d2 lanai_dev drivers/atm/lanai.c | ||
132 | HDLCDRV_MAGIC 0x5ac6e778 hdlcdrv_state include/linux/hdlcdrv.h | ||
133 | EPCA_MAGIC 0x5c6df104 channel include/linux/epca.h | ||
134 | PCXX_MAGIC 0x5c6df104 channel drivers/char/pcxx.h | ||
135 | KV_MAGIC 0x5f4b565f kernel_vars_s arch/mips/include/asm/sn/klkernvars.h | ||
136 | I810_STATE_MAGIC 0x63657373 i810_state sound/oss/i810_audio.c | ||
137 | TRIDENT_STATE_MAGIC 0x63657373 trient_state sound/oss/trident.c | ||
138 | M3_CARD_MAGIC 0x646e6f50 m3_card sound/oss/maestro3.c | ||
139 | FW_HEADER_MAGIC 0x65726F66 fw_header drivers/atm/fore200e.h | ||
140 | SLOT_MAGIC 0x67267321 slot drivers/hotplug/cpqphp.h | ||
141 | SLOT_MAGIC 0x67267322 slot drivers/hotplug/acpiphp.h | ||
142 | LO_MAGIC 0x68797548 nbd_device include/linux/nbd.h | ||
143 | OPROFILE_MAGIC 0x6f70726f super_block drivers/oprofile/oprofilefs.h | ||
144 | M3_STATE_MAGIC 0x734d724d m3_state sound/oss/maestro3.c | ||
145 | STL_PANELMAGIC 0x7ef621a1 stlpanel include/linux/stallion.h | ||
146 | VMALLOC_MAGIC 0x87654320 snd_alloc_track sound/core/memory.c | ||
147 | KMALLOC_MAGIC 0x87654321 snd_alloc_track sound/core/memory.c | ||
148 | PWC_MAGIC 0x89DC10AB pwc_device drivers/usb/media/pwc.h | ||
149 | NBD_REPLY_MAGIC 0x96744668 nbd_reply include/linux/nbd.h | ||
150 | STL_BOARDMAGIC 0xa2267f52 stlbrd include/linux/stallion.h | ||
151 | ENI155_MAGIC 0xa54b872d midway_eprom drivers/atm/eni.h | ||
152 | SCI_MAGIC 0xbabeface gs_port drivers/char/sh-sci.h | ||
153 | CODA_MAGIC 0xC0DAC0DA coda_file_info include/linux/coda_fs_i.h | ||
154 | DPMEM_MAGIC 0xc0ffee11 gdt_pci_sram drivers/scsi/gdth.h | ||
155 | STLI_PORTMAGIC 0xe671c7a1 stliport include/linux/istallion.h | ||
156 | YAM_MAGIC 0xF10A7654 yam_port drivers/net/hamradio/yam.c | ||
157 | CCB_MAGIC 0xf2691ad2 ccb drivers/scsi/ncr53c8xx.c | ||
158 | QUEUE_MAGIC_FREE 0xf7e1c9a3 queue_entry drivers/scsi/arm/queue.c | ||
159 | QUEUE_MAGIC_USED 0xf7e1cc33 queue_entry drivers/scsi/arm/queue.c | ||
160 | HTB_CMAGIC 0xFEFAFEF1 htb_class net/sched/sch_htb.c | ||
161 | NMI_MAGIC 0x48414d4d455201 nmi_s arch/mips/include/asm/sn/nmi.h | ||
162 | |||
163 | 璇锋敞鎰忥紝鍦ㄥ0闊宠蹇嗙鐞嗕腑浠嶇劧鏈夋瘡涓浜涜瀹氫箟鐨勯┍鍔ㄩ瓟鏈笺傛煡鐪媔nclude/sound/sndmagic.h鏉ヨ幏鍙栦粬浠畬鏁寸殑鍒楄〃淇℃伅銆傚緢澶歄SS澹伴煶椹卞姩鎷ユ湁鑷繁浠庡0鍗CI ID鏋勫缓鐨勯瓟鏈-浠栦滑涔熸病鏈夎鍒楀湪杩欓噷銆 | ||
164 | |||
165 | IrDA瀛愮郴缁熶篃浣跨敤浜嗗ぇ閲忕殑鑷繁鐨勯瓟鏈硷紝鏌ョ湅include/net/irda/irda.h鏉ヨ幏鍙栦粬浠畬鏁寸殑淇℃伅銆 | ||
166 | |||
167 | HFS鏄彟澶栦竴涓瘮杈冨ぇ鐨勪娇鐢ㄩ瓟鏈肩殑鏂囦欢绯荤粺-浣犲彲浠ュ湪fs/hfs/hfs.h涓壘鍒颁粬浠 | ||