aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/ABI/stable/sysfs-class-backlight36
-rw-r--r--Documentation/ABI/testing/sysfs-class-lcd23
-rw-r--r--Documentation/ABI/testing/sysfs-class-led28
-rw-r--r--Documentation/ABI/testing/sysfs-gpio1
-rw-r--r--Documentation/ABI/testing/sysfs-platform-asus-laptop52
-rw-r--r--Documentation/ABI/testing/sysfs-platform-eeepc-laptop50
-rw-r--r--Documentation/Intel-IOMMU.txt6
-rw-r--r--Documentation/accounting/getdelays.c12
-rw-r--r--Documentation/auxdisplay/cfag12864b-example.c22
-rw-r--r--Documentation/fb/ep93xx-fb.txt135
-rw-r--r--Documentation/fb/matroxfb.txt4
-rw-r--r--Documentation/filesystems/ncpfs.txt6
-rw-r--r--Documentation/filesystems/proc.txt5
-rw-r--r--Documentation/gpio.txt17
-rw-r--r--Documentation/hwmon/acpi_power_meter51
-rw-r--r--Documentation/i2c/busses/i2c-piix42
-rw-r--r--Documentation/i2c/chips/pca953958
-rw-r--r--Documentation/i2c/chips/pcf857465
-rw-r--r--Documentation/i2c/chips/pcf857569
-rw-r--r--Documentation/ia64/aliasing-test.c8
-rw-r--r--Documentation/kernel-parameters.txt2
-rw-r--r--Documentation/laptops/asus-laptop.txt258
-rw-r--r--Documentation/laptops/thinkpad-acpi.txt8
-rw-r--r--Documentation/leds-class.txt9
-rw-r--r--Documentation/lguest/lguest.c26
-rw-r--r--Documentation/pcmcia/crc32hash.c2
-rw-r--r--Documentation/power/power_supply_class.txt7
-rw-r--r--Documentation/power/regulator/design.txt33
-rw-r--r--Documentation/power/regulator/machine.txt4
-rw-r--r--Documentation/power/regulator/overview.txt4
-rw-r--r--Documentation/power/regulator/regulator.txt5
-rw-r--r--Documentation/powerpc/dts-bindings/fsl/esdhc.txt2
-rw-r--r--Documentation/powerpc/dts-bindings/mtd-physmap.txt42
-rw-r--r--Documentation/rtc.txt26
-rw-r--r--Documentation/spi/spi-summary2
-rw-r--r--Documentation/spi/spidev_test.c4
-rw-r--r--Documentation/sysctl/kernel.txt8
-rw-r--r--Documentation/usb/authorization.txt10
-rw-r--r--Documentation/usb/usbmon.txt8
-rw-r--r--Documentation/video4linux/v4lgrab.c2
-rw-r--r--Documentation/vm/page-types.c52
-rw-r--r--Documentation/vm/slabinfo.c68
-rw-r--r--Documentation/watchdog/src/watchdog-test.c2
-rw-r--r--Documentation/x86/earlyprintk.txt39
44 files changed, 938 insertions, 335 deletions
diff --git a/Documentation/ABI/stable/sysfs-class-backlight b/Documentation/ABI/stable/sysfs-class-backlight
new file mode 100644
index 000000000000..4d637e1c4ff7
--- /dev/null
+++ b/Documentation/ABI/stable/sysfs-class-backlight
@@ -0,0 +1,36 @@
1What: /sys/class/backlight/<backlight>/bl_power
2Date: April 2005
3KernelVersion: 2.6.12
4Contact: Richard Purdie <rpurdie@rpsys.net>
5Description:
6 Control BACKLIGHT power, values are FB_BLANK_* from fb.h
7 - FB_BLANK_UNBLANK (0) : power on.
8 - FB_BLANK_POWERDOWN (4) : power off
9Users: HAL
10
11What: /sys/class/backlight/<backlight>/brightness
12Date: April 2005
13KernelVersion: 2.6.12
14Contact: Richard Purdie <rpurdie@rpsys.net>
15Description:
16 Control the brightness for this <backlight>. Values
17 are between 0 and max_brightness. This file will also
18 show the brightness level stored in the driver, which
19 may not be the actual brightness (see actual_brightness).
20Users: HAL
21
22What: /sys/class/backlight/<backlight>/actual_brightness
23Date: March 2006
24KernelVersion: 2.6.17
25Contact: Richard Purdie <rpurdie@rpsys.net>
26Description:
27 Show the actual brightness by querying the hardware.
28Users: HAL
29
30What: /sys/class/backlight/<backlight>/max_brightness
31Date: April 2005
32KernelVersion: 2.6.12
33Contact: Richard Purdie <rpurdie@rpsys.net>
34Description:
35 Maximum brightness for <backlight>.
36Users: HAL
diff --git a/Documentation/ABI/testing/sysfs-class-lcd b/Documentation/ABI/testing/sysfs-class-lcd
new file mode 100644
index 000000000000..35906bf7aa70
--- /dev/null
+++ b/Documentation/ABI/testing/sysfs-class-lcd
@@ -0,0 +1,23 @@
1What: /sys/class/lcd/<lcd>/lcd_power
2Date: April 2005
3KernelVersion: 2.6.12
4Contact: Richard Purdie <rpurdie@rpsys.net>
5Description:
6 Control LCD power, values are FB_BLANK_* from fb.h
7 - FB_BLANK_UNBLANK (0) : power on.
8 - FB_BLANK_POWERDOWN (4) : power off
9
10What: /sys/class/lcd/<lcd>/contrast
11Date: April 2005
12KernelVersion: 2.6.12
13Contact: Richard Purdie <rpurdie@rpsys.net>
14Description:
15 Current contrast of this LCD device. Value is between 0 and
16 /sys/class/lcd/<lcd>/max_contrast.
17
18What: /sys/class/lcd/<lcd>/max_contrast
19Date: April 2005
20KernelVersion: 2.6.12
21Contact: Richard Purdie <rpurdie@rpsys.net>
22Description:
23 Maximum contrast for this LCD device.
diff --git a/Documentation/ABI/testing/sysfs-class-led b/Documentation/ABI/testing/sysfs-class-led
new file mode 100644
index 000000000000..9e4541d71cb6
--- /dev/null
+++ b/Documentation/ABI/testing/sysfs-class-led
@@ -0,0 +1,28 @@
1What: /sys/class/leds/<led>/brightness
2Date: March 2006
3KernelVersion: 2.6.17
4Contact: Richard Purdie <rpurdie@rpsys.net>
5Description:
6 Set the brightness of the LED. Most LEDs don't
7 have hardware brightness support so will just be turned on for
8 non-zero brightness settings. The value is between 0 and
9 /sys/class/leds/<led>/max_brightness.
10
11What: /sys/class/leds/<led>/max_brightness
12Date: March 2006
13KernelVersion: 2.6.17
14Contact: Richard Purdie <rpurdie@rpsys.net>
15Description:
16 Maximum brightness level for this led, default is 255 (LED_FULL).
17
18What: /sys/class/leds/<led>/trigger
19Date: March 2006
20KernelVersion: 2.6.17
21Contact: Richard Purdie <rpurdie@rpsys.net>
22Description:
23 Set the trigger for this LED. A trigger is a kernel based source
24 of led events.
25 You can change triggers in a similar manner to the way an IO
26 scheduler is chosen. Trigger specific parameters can appear in
27 /sys/class/leds/<led> once a given trigger is selected.
28
diff --git a/Documentation/ABI/testing/sysfs-gpio b/Documentation/ABI/testing/sysfs-gpio
index 8aab8092ad35..80f4c94c7bef 100644
--- a/Documentation/ABI/testing/sysfs-gpio
+++ b/Documentation/ABI/testing/sysfs-gpio
@@ -19,6 +19,7 @@ Description:
19 /gpioN ... for each exported GPIO #N 19 /gpioN ... for each exported GPIO #N
20 /value ... always readable, writes fail for input GPIOs 20 /value ... always readable, writes fail for input GPIOs
21 /direction ... r/w as: in, out (default low); write: high, low 21 /direction ... r/w as: in, out (default low); write: high, low
22 /edge ... r/w as: none, falling, rising, both
22 /gpiochipN ... for each gpiochip; #N is its first GPIO 23 /gpiochipN ... for each gpiochip; #N is its first GPIO
23 /base ... (r/o) same as N 24 /base ... (r/o) same as N
24 /label ... (r/o) descriptive, not necessarily unique 25 /label ... (r/o) descriptive, not necessarily unique
diff --git a/Documentation/ABI/testing/sysfs-platform-asus-laptop b/Documentation/ABI/testing/sysfs-platform-asus-laptop
new file mode 100644
index 000000000000..a1cb660c50cf
--- /dev/null
+++ b/Documentation/ABI/testing/sysfs-platform-asus-laptop
@@ -0,0 +1,52 @@
1What: /sys/devices/platform/asus-laptop/display
2Date: January 2007
3KernelVersion: 2.6.20
4Contact: "Corentin Chary" <corentincj@iksaif.net>
5Description:
6 This file allows display switching. The value
7 is composed by 4 bits and defined as follow:
8 4321
9 |||`- LCD
10 ||`-- CRT
11 |`--- TV
12 `---- DVI
13 Ex: - 0 (0000b) means no display
14 - 3 (0011b) CRT+LCD.
15
16What: /sys/devices/platform/asus-laptop/gps
17Date: January 2007
18KernelVersion: 2.6.20
19Contact: "Corentin Chary" <corentincj@iksaif.net>
20Description:
21 Control the gps device. 1 means on, 0 means off.
22Users: Lapsus
23
24What: /sys/devices/platform/asus-laptop/ledd
25Date: January 2007
26KernelVersion: 2.6.20
27Contact: "Corentin Chary" <corentincj@iksaif.net>
28Description:
29 Some models like the W1N have a LED display that can be
30 used to display several informations.
31 To control the LED display, use the following :
32 echo 0x0T000DDD > /sys/devices/platform/asus-laptop/
33 where T control the 3 letters display, and DDD the 3 digits display.
34 The DDD table can be found in Documentation/laptops/asus-laptop.txt
35
36What: /sys/devices/platform/asus-laptop/bluetooth
37Date: January 2007
38KernelVersion: 2.6.20
39Contact: "Corentin Chary" <corentincj@iksaif.net>
40Description:
41 Control the bluetooth device. 1 means on, 0 means off.
42 This may control the led, the device or both.
43Users: Lapsus
44
45What: /sys/devices/platform/asus-laptop/wlan
46Date: January 2007
47KernelVersion: 2.6.20
48Contact: "Corentin Chary" <corentincj@iksaif.net>
49Description:
50 Control the bluetooth device. 1 means on, 0 means off.
51 This may control the led, the device or both.
52Users: Lapsus
diff --git a/Documentation/ABI/testing/sysfs-platform-eeepc-laptop b/Documentation/ABI/testing/sysfs-platform-eeepc-laptop
new file mode 100644
index 000000000000..7445dfb321b5
--- /dev/null
+++ b/Documentation/ABI/testing/sysfs-platform-eeepc-laptop
@@ -0,0 +1,50 @@
1What: /sys/devices/platform/eeepc-laptop/disp
2Date: May 2008
3KernelVersion: 2.6.26
4Contact: "Corentin Chary" <corentincj@iksaif.net>
5Description:
6 This file allows display switching.
7 - 1 = LCD
8 - 2 = CRT
9 - 3 = LCD+CRT
10 If you run X11, you should use xrandr instead.
11
12What: /sys/devices/platform/eeepc-laptop/camera
13Date: May 2008
14KernelVersion: 2.6.26
15Contact: "Corentin Chary" <corentincj@iksaif.net>
16Description:
17 Control the camera. 1 means on, 0 means off.
18
19What: /sys/devices/platform/eeepc-laptop/cardr
20Date: May 2008
21KernelVersion: 2.6.26
22Contact: "Corentin Chary" <corentincj@iksaif.net>
23Description:
24 Control the card reader. 1 means on, 0 means off.
25
26What: /sys/devices/platform/eeepc-laptop/cpufv
27Date: Jun 2009
28KernelVersion: 2.6.31
29Contact: "Corentin Chary" <corentincj@iksaif.net>
30Description:
31 Change CPU clock configuration.
32 On the Eee PC 1000H there are three available clock configuration:
33 * 0 -> Super Performance Mode
34 * 1 -> High Performance Mode
35 * 2 -> Power Saving Mode
36 On Eee PC 701 there is only 2 available clock configurations.
37 Available configuration are listed in available_cpufv file.
38 Reading this file will show the raw hexadecimal value which
39 is defined as follow:
40 | 8 bit | 8 bit |
41 | `---- Current mode
42 `------------ Availables modes
43 For example, 0x301 means: mode 1 selected, 3 available modes.
44
45What: /sys/devices/platform/eeepc-laptop/available_cpufv
46Date: Jun 2009
47KernelVersion: 2.6.31
48Contact: "Corentin Chary" <corentincj@iksaif.net>
49Description:
50 List available cpufv modes.
diff --git a/Documentation/Intel-IOMMU.txt b/Documentation/Intel-IOMMU.txt
index 21bc416d887e..cf9431db8731 100644
--- a/Documentation/Intel-IOMMU.txt
+++ b/Documentation/Intel-IOMMU.txt
@@ -56,11 +56,7 @@ Graphics Problems?
56------------------ 56------------------
57If you encounter issues with graphics devices, you can try adding 57If you encounter issues with graphics devices, you can try adding
58option intel_iommu=igfx_off to turn off the integrated graphics engine. 58option intel_iommu=igfx_off to turn off the integrated graphics engine.
59 59If this fixes anything, please ensure you file a bug reporting the problem.
60If it happens to be a PCI device included in the INCLUDE_ALL Engine,
61then try enabling CONFIG_DMAR_GFX_WA to setup a 1-1 map. We hear
62graphics drivers may be in process of using DMA api's in the near
63future and at that time this option can be yanked out.
64 60
65Some exceptions to IOVA 61Some exceptions to IOVA
66----------------------- 62-----------------------
diff --git a/Documentation/accounting/getdelays.c b/Documentation/accounting/getdelays.c
index aa73e72fd793..6e25c2659e0a 100644
--- a/Documentation/accounting/getdelays.c
+++ b/Documentation/accounting/getdelays.c
@@ -116,7 +116,7 @@ error:
116} 116}
117 117
118 118
119int send_cmd(int sd, __u16 nlmsg_type, __u32 nlmsg_pid, 119static int send_cmd(int sd, __u16 nlmsg_type, __u32 nlmsg_pid,
120 __u8 genl_cmd, __u16 nla_type, 120 __u8 genl_cmd, __u16 nla_type,
121 void *nla_data, int nla_len) 121 void *nla_data, int nla_len)
122{ 122{
@@ -160,7 +160,7 @@ int send_cmd(int sd, __u16 nlmsg_type, __u32 nlmsg_pid,
160 * Probe the controller in genetlink to find the family id 160 * Probe the controller in genetlink to find the family id
161 * for the TASKSTATS family 161 * for the TASKSTATS family
162 */ 162 */
163int get_family_id(int sd) 163static int get_family_id(int sd)
164{ 164{
165 struct { 165 struct {
166 struct nlmsghdr n; 166 struct nlmsghdr n;
@@ -190,7 +190,7 @@ int get_family_id(int sd)
190 return id; 190 return id;
191} 191}
192 192
193void print_delayacct(struct taskstats *t) 193static void print_delayacct(struct taskstats *t)
194{ 194{
195 printf("\n\nCPU %15s%15s%15s%15s\n" 195 printf("\n\nCPU %15s%15s%15s%15s\n"
196 " %15llu%15llu%15llu%15llu\n" 196 " %15llu%15llu%15llu%15llu\n"
@@ -216,7 +216,7 @@ void print_delayacct(struct taskstats *t)
216 (unsigned long long)t->freepages_delay_total); 216 (unsigned long long)t->freepages_delay_total);
217} 217}
218 218
219void task_context_switch_counts(struct taskstats *t) 219static void task_context_switch_counts(struct taskstats *t)
220{ 220{
221 printf("\n\nTask %15s%15s\n" 221 printf("\n\nTask %15s%15s\n"
222 " %15llu%15llu\n", 222 " %15llu%15llu\n",
@@ -224,7 +224,7 @@ void task_context_switch_counts(struct taskstats *t)
224 (unsigned long long)t->nvcsw, (unsigned long long)t->nivcsw); 224 (unsigned long long)t->nvcsw, (unsigned long long)t->nivcsw);
225} 225}
226 226
227void print_cgroupstats(struct cgroupstats *c) 227static void print_cgroupstats(struct cgroupstats *c)
228{ 228{
229 printf("sleeping %llu, blocked %llu, running %llu, stopped %llu, " 229 printf("sleeping %llu, blocked %llu, running %llu, stopped %llu, "
230 "uninterruptible %llu\n", (unsigned long long)c->nr_sleeping, 230 "uninterruptible %llu\n", (unsigned long long)c->nr_sleeping,
@@ -235,7 +235,7 @@ void print_cgroupstats(struct cgroupstats *c)
235} 235}
236 236
237 237
238void print_ioacct(struct taskstats *t) 238static void print_ioacct(struct taskstats *t)
239{ 239{
240 printf("%s: read=%llu, write=%llu, cancelled_write=%llu\n", 240 printf("%s: read=%llu, write=%llu, cancelled_write=%llu\n",
241 t->ac_comm, 241 t->ac_comm,
diff --git a/Documentation/auxdisplay/cfag12864b-example.c b/Documentation/auxdisplay/cfag12864b-example.c
index 2caeea5e4993..1d2c010bae12 100644
--- a/Documentation/auxdisplay/cfag12864b-example.c
+++ b/Documentation/auxdisplay/cfag12864b-example.c
@@ -62,7 +62,7 @@ unsigned char cfag12864b_buffer[CFAG12864B_SIZE];
62 * Unable to open: return = -1 62 * Unable to open: return = -1
63 * Unable to mmap: return = -2 63 * Unable to mmap: return = -2
64 */ 64 */
65int cfag12864b_init(char *path) 65static int cfag12864b_init(char *path)
66{ 66{
67 cfag12864b_fd = open(path, O_RDWR); 67 cfag12864b_fd = open(path, O_RDWR);
68 if (cfag12864b_fd == -1) 68 if (cfag12864b_fd == -1)
@@ -81,7 +81,7 @@ int cfag12864b_init(char *path)
81/* 81/*
82 * exit a cfag12864b framebuffer device 82 * exit a cfag12864b framebuffer device
83 */ 83 */
84void cfag12864b_exit(void) 84static void cfag12864b_exit(void)
85{ 85{
86 munmap(cfag12864b_mem, CFAG12864B_SIZE); 86 munmap(cfag12864b_mem, CFAG12864B_SIZE);
87 close(cfag12864b_fd); 87 close(cfag12864b_fd);
@@ -90,7 +90,7 @@ void cfag12864b_exit(void)
90/* 90/*
91 * set (x, y) pixel 91 * set (x, y) pixel
92 */ 92 */
93void cfag12864b_set(unsigned char x, unsigned char y) 93static void cfag12864b_set(unsigned char x, unsigned char y)
94{ 94{
95 if (CFAG12864B_CHECK(x, y)) 95 if (CFAG12864B_CHECK(x, y))
96 cfag12864b_buffer[CFAG12864B_ADDRESS(x, y)] |= 96 cfag12864b_buffer[CFAG12864B_ADDRESS(x, y)] |=
@@ -100,7 +100,7 @@ void cfag12864b_set(unsigned char x, unsigned char y)
100/* 100/*
101 * unset (x, y) pixel 101 * unset (x, y) pixel
102 */ 102 */
103void cfag12864b_unset(unsigned char x, unsigned char y) 103static void cfag12864b_unset(unsigned char x, unsigned char y)
104{ 104{
105 if (CFAG12864B_CHECK(x, y)) 105 if (CFAG12864B_CHECK(x, y))
106 cfag12864b_buffer[CFAG12864B_ADDRESS(x, y)] &= 106 cfag12864b_buffer[CFAG12864B_ADDRESS(x, y)] &=
@@ -113,7 +113,7 @@ void cfag12864b_unset(unsigned char x, unsigned char y)
113 * Pixel off: return = 0 113 * Pixel off: return = 0
114 * Pixel on: return = 1 114 * Pixel on: return = 1
115 */ 115 */
116unsigned char cfag12864b_isset(unsigned char x, unsigned char y) 116static unsigned char cfag12864b_isset(unsigned char x, unsigned char y)
117{ 117{
118 if (CFAG12864B_CHECK(x, y)) 118 if (CFAG12864B_CHECK(x, y))
119 if (cfag12864b_buffer[CFAG12864B_ADDRESS(x, y)] & 119 if (cfag12864b_buffer[CFAG12864B_ADDRESS(x, y)] &
@@ -126,7 +126,7 @@ unsigned char cfag12864b_isset(unsigned char x, unsigned char y)
126/* 126/*
127 * not (x, y) pixel 127 * not (x, y) pixel
128 */ 128 */
129void cfag12864b_not(unsigned char x, unsigned char y) 129static void cfag12864b_not(unsigned char x, unsigned char y)
130{ 130{
131 if (cfag12864b_isset(x, y)) 131 if (cfag12864b_isset(x, y))
132 cfag12864b_unset(x, y); 132 cfag12864b_unset(x, y);
@@ -137,7 +137,7 @@ void cfag12864b_not(unsigned char x, unsigned char y)
137/* 137/*
138 * fill (set all pixels) 138 * fill (set all pixels)
139 */ 139 */
140void cfag12864b_fill(void) 140static void cfag12864b_fill(void)
141{ 141{
142 unsigned short i; 142 unsigned short i;
143 143
@@ -148,7 +148,7 @@ void cfag12864b_fill(void)
148/* 148/*
149 * clear (unset all pixels) 149 * clear (unset all pixels)
150 */ 150 */
151void cfag12864b_clear(void) 151static void cfag12864b_clear(void)
152{ 152{
153 unsigned short i; 153 unsigned short i;
154 154
@@ -162,7 +162,7 @@ void cfag12864b_clear(void)
162 * Pixel off: src[i] = 0 162 * Pixel off: src[i] = 0
163 * Pixel on: src[i] > 0 163 * Pixel on: src[i] > 0
164 */ 164 */
165void cfag12864b_format(unsigned char * matrix) 165static void cfag12864b_format(unsigned char * matrix)
166{ 166{
167 unsigned char i, j, n; 167 unsigned char i, j, n;
168 168
@@ -182,7 +182,7 @@ void cfag12864b_format(unsigned char * matrix)
182/* 182/*
183 * blit buffer to lcd 183 * blit buffer to lcd
184 */ 184 */
185void cfag12864b_blit(void) 185static void cfag12864b_blit(void)
186{ 186{
187 memcpy(cfag12864b_mem, cfag12864b_buffer, CFAG12864B_SIZE); 187 memcpy(cfag12864b_mem, cfag12864b_buffer, CFAG12864B_SIZE);
188} 188}
@@ -198,7 +198,7 @@ void cfag12864b_blit(void)
198 198
199#define EXAMPLES 6 199#define EXAMPLES 6
200 200
201void example(unsigned char n) 201static void example(unsigned char n)
202{ 202{
203 unsigned short i, j; 203 unsigned short i, j;
204 unsigned char matrix[CFAG12864B_WIDTH * CFAG12864B_HEIGHT]; 204 unsigned char matrix[CFAG12864B_WIDTH * CFAG12864B_HEIGHT];
diff --git a/Documentation/fb/ep93xx-fb.txt b/Documentation/fb/ep93xx-fb.txt
new file mode 100644
index 000000000000..5af1bd9effae
--- /dev/null
+++ b/Documentation/fb/ep93xx-fb.txt
@@ -0,0 +1,135 @@
1================================
2Driver for EP93xx LCD controller
3================================
4
5The EP93xx LCD controller can drive both standard desktop monitors and
6embedded LCD displays. If you have a standard desktop monitor then you
7can use the standard Linux video mode database. In your board file:
8
9 static struct ep93xxfb_mach_info some_board_fb_info = {
10 .num_modes = EP93XXFB_USE_MODEDB,
11 .bpp = 16,
12 };
13
14If you have an embedded LCD display then you need to define a video
15mode for it as follows:
16
17 static struct fb_videomode some_board_video_modes[] = {
18 {
19 .name = "some_lcd_name",
20 /* Pixel clock, porches, etc */
21 },
22 };
23
24Note that the pixel clock value is in pico-seconds. You can use the
25KHZ2PICOS macro to convert the pixel clock value. Most other values
26are in pixel clocks. See Documentation/fb/framebuffer.txt for further
27details.
28
29The ep93xxfb_mach_info structure for your board should look like the
30following:
31
32 static struct ep93xxfb_mach_info some_board_fb_info = {
33 .num_modes = ARRAY_SIZE(some_board_video_modes),
34 .modes = some_board_video_modes,
35 .default_mode = &some_board_video_modes[0],
36 .bpp = 16,
37 };
38
39The framebuffer device can be registered by adding the following to
40your board initialisation function:
41
42 ep93xx_register_fb(&some_board_fb_info);
43
44=====================
45Video Attribute Flags
46=====================
47
48The ep93xxfb_mach_info structure has a flags field which can be used
49to configure the controller. The video attributes flags are fully
50documented in section 7 of the EP93xx users' guide. The following
51flags are available:
52
53EP93XXFB_PCLK_FALLING Clock data on the falling edge of the
54 pixel clock. The default is to clock
55 data on the rising edge.
56
57EP93XXFB_SYNC_BLANK_HIGH Blank signal is active high. By
58 default the blank signal is active low.
59
60EP93XXFB_SYNC_HORIZ_HIGH Horizontal sync is active high. By
61 default the horizontal sync is active low.
62
63EP93XXFB_SYNC_VERT_HIGH Vertical sync is active high. By
64 default the vertical sync is active high.
65
66The physical address of the framebuffer can be controlled using the
67following flags:
68
69EP93XXFB_USE_SDCSN0 Use SDCSn[0] for the framebuffer. This
70 is the default setting.
71
72EP93XXFB_USE_SDCSN1 Use SDCSn[1] for the framebuffer.
73
74EP93XXFB_USE_SDCSN2 Use SDCSn[2] for the framebuffer.
75
76EP93XXFB_USE_SDCSN3 Use SDCSn[3] for the framebuffer.
77
78==================
79Platform callbacks
80==================
81
82The EP93xx framebuffer driver supports three optional platform
83callbacks: setup, teardown and blank. The setup and teardown functions
84are called when the framebuffer driver is installed and removed
85respectively. The blank function is called whenever the display is
86blanked or unblanked.
87
88The setup and teardown devices pass the platform_device structure as
89an argument. The fb_info and ep93xxfb_mach_info structures can be
90obtained as follows:
91
92 static int some_board_fb_setup(struct platform_device *pdev)
93 {
94 struct ep93xxfb_mach_info *mach_info = pdev->dev.platform_data;
95 struct fb_info *fb_info = platform_get_drvdata(pdev);
96
97 /* Board specific framebuffer setup */
98 }
99
100======================
101Setting the video mode
102======================
103
104The video mode is set using the following syntax:
105
106 video=XRESxYRES[-BPP][@REFRESH]
107
108If the EP93xx video driver is built-in then the video mode is set on
109the Linux kernel command line, for example:
110
111 video=ep93xx-fb:800x600-16@60
112
113If the EP93xx video driver is built as a module then the video mode is
114set when the module is installed:
115
116 modprobe ep93xx-fb video=320x240
117
118==============
119Screenpage bug
120==============
121
122At least on the EP9315 there is a silicon bug which causes bit 27 of
123the VIDSCRNPAGE (framebuffer physical offset) to be tied low. There is
124an unofficial errata for this bug at:
125 http://marc.info/?l=linux-arm-kernel&m=110061245502000&w=2
126
127By default the EP93xx framebuffer driver checks if the allocated physical
128address has bit 27 set. If it does, then the memory is freed and an
129error is returned. The check can be disabled by adding the following
130option when loading the driver:
131
132 ep93xx-fb.check_screenpage_bug=0
133
134In some cases it may be possible to reconfigure your SDRAM layout to
135avoid this bug. See section 13 of the EP93xx users' guide for details.
diff --git a/Documentation/fb/matroxfb.txt b/Documentation/fb/matroxfb.txt
index ad7a67707d62..e5ce8a1a978b 100644
--- a/Documentation/fb/matroxfb.txt
+++ b/Documentation/fb/matroxfb.txt
@@ -186,9 +186,7 @@ noinverse - show true colors on screen. It is default.
186dev:X - bind driver to device X. Driver numbers device from 0 up to N, 186dev:X - bind driver to device X. Driver numbers device from 0 up to N,
187 where device 0 is first `known' device found, 1 second and so on. 187 where device 0 is first `known' device found, 1 second and so on.
188 lspci lists devices in this order. 188 lspci lists devices in this order.
189 Default is `every' known device for driver with multihead support 189 Default is `every' known device.
190 and first working device (usually dev:0) for driver without
191 multihead support.
192nohwcursor - disables hardware cursor (use software cursor instead). 190nohwcursor - disables hardware cursor (use software cursor instead).
193hwcursor - enables hardware cursor. It is default. If you are using 191hwcursor - enables hardware cursor. It is default. If you are using
194 non-accelerated mode (`noaccel' or `fbset -accel false'), software 192 non-accelerated mode (`noaccel' or `fbset -accel false'), software
diff --git a/Documentation/filesystems/ncpfs.txt b/Documentation/filesystems/ncpfs.txt
index f12c30c93f2f..5af164f4b37b 100644
--- a/Documentation/filesystems/ncpfs.txt
+++ b/Documentation/filesystems/ncpfs.txt
@@ -7,6 +7,6 @@ ftp.gwdg.de/pub/linux/misc/ncpfs, but sunsite and its many mirrors
7will have it as well. 7will have it as well.
8 8
9Related products are linware and mars_nwe, which will give Linux partial 9Related products are linware and mars_nwe, which will give Linux partial
10NetWare server functionality. Linware's home site is 10NetWare server functionality.
11klokan.sh.cvut.cz/pub/linux/linware; mars_nwe can be found on 11
12ftp.gwdg.de/pub/linux/misc/ncpfs. 12mars_nwe can be found on ftp.gwdg.de/pub/linux/misc/ncpfs.
diff --git a/Documentation/filesystems/proc.txt b/Documentation/filesystems/proc.txt
index 75988ba26a51..b5aee7838a00 100644
--- a/Documentation/filesystems/proc.txt
+++ b/Documentation/filesystems/proc.txt
@@ -176,6 +176,7 @@ read the file /proc/PID/status:
176 CapBnd: ffffffffffffffff 176 CapBnd: ffffffffffffffff
177 voluntary_ctxt_switches: 0 177 voluntary_ctxt_switches: 0
178 nonvoluntary_ctxt_switches: 1 178 nonvoluntary_ctxt_switches: 1
179 Stack usage: 12 kB
179 180
180This shows you nearly the same information you would get if you viewed it with 181This shows you nearly the same information you would get if you viewed it with
181the ps command. In fact, ps uses the proc file system to obtain its 182the ps command. In fact, ps uses the proc file system to obtain its
@@ -229,6 +230,7 @@ Table 1-2: Contents of the statm files (as of 2.6.30-rc7)
229 Mems_allowed_list Same as previous, but in "list format" 230 Mems_allowed_list Same as previous, but in "list format"
230 voluntary_ctxt_switches number of voluntary context switches 231 voluntary_ctxt_switches number of voluntary context switches
231 nonvoluntary_ctxt_switches number of non voluntary context switches 232 nonvoluntary_ctxt_switches number of non voluntary context switches
233 Stack usage: stack usage high water mark (round up to page size)
232.............................................................................. 234..............................................................................
233 235
234Table 1-3: Contents of the statm files (as of 2.6.8-rc3) 236Table 1-3: Contents of the statm files (as of 2.6.8-rc3)
@@ -307,7 +309,7 @@ address perms offset dev inode pathname
30708049000-0804a000 rw-p 00001000 03:00 8312 /opt/test 30908049000-0804a000 rw-p 00001000 03:00 8312 /opt/test
3080804a000-0806b000 rw-p 00000000 00:00 0 [heap] 3100804a000-0806b000 rw-p 00000000 00:00 0 [heap]
309a7cb1000-a7cb2000 ---p 00000000 00:00 0 311a7cb1000-a7cb2000 ---p 00000000 00:00 0
310a7cb2000-a7eb2000 rw-p 00000000 00:00 0 312a7cb2000-a7eb2000 rw-p 00000000 00:00 0 [threadstack:001ff4b4]
311a7eb2000-a7eb3000 ---p 00000000 00:00 0 313a7eb2000-a7eb3000 ---p 00000000 00:00 0
312a7eb3000-a7ed5000 rw-p 00000000 00:00 0 314a7eb3000-a7ed5000 rw-p 00000000 00:00 0
313a7ed5000-a8008000 r-xp 00000000 03:00 4222 /lib/libc.so.6 315a7ed5000-a8008000 r-xp 00000000 03:00 4222 /lib/libc.so.6
@@ -343,6 +345,7 @@ is not associated with a file:
343 [stack] = the stack of the main process 345 [stack] = the stack of the main process
344 [vdso] = the "virtual dynamic shared object", 346 [vdso] = the "virtual dynamic shared object",
345 the kernel system call handler 347 the kernel system call handler
348 [threadstack:xxxxxxxx] = the stack of the thread, xxxxxxxx is the stack size
346 349
347 or if empty, the mapping is anonymous. 350 or if empty, the mapping is anonymous.
348 351
diff --git a/Documentation/gpio.txt b/Documentation/gpio.txt
index e4b6985044a2..fa4dc077ae0e 100644
--- a/Documentation/gpio.txt
+++ b/Documentation/gpio.txt
@@ -524,6 +524,13 @@ and have the following read/write attributes:
524 is configured as an output, this value may be written; 524 is configured as an output, this value may be written;
525 any nonzero value is treated as high. 525 any nonzero value is treated as high.
526 526
527 "edge" ... reads as either "none", "rising", "falling", or
528 "both". Write these strings to select the signal edge(s)
529 that will make poll(2) on the "value" file return.
530
531 This file exists only if the pin can be configured as an
532 interrupt generating input pin.
533
527GPIO controllers have paths like /sys/class/gpio/chipchip42/ (for the 534GPIO controllers have paths like /sys/class/gpio/chipchip42/ (for the
528controller implementing GPIOs starting at #42) and have the following 535controller implementing GPIOs starting at #42) and have the following
529read-only attributes: 536read-only attributes:
@@ -555,6 +562,11 @@ requested using gpio_request():
555 /* reverse gpio_export() */ 562 /* reverse gpio_export() */
556 void gpio_unexport(); 563 void gpio_unexport();
557 564
565 /* create a sysfs link to an exported GPIO node */
566 int gpio_export_link(struct device *dev, const char *name,
567 unsigned gpio)
568
569
558After a kernel driver requests a GPIO, it may only be made available in 570After a kernel driver requests a GPIO, it may only be made available in
559the sysfs interface by gpio_export(). The driver can control whether the 571the sysfs interface by gpio_export(). The driver can control whether the
560signal direction may change. This helps drivers prevent userspace code 572signal direction may change. This helps drivers prevent userspace code
@@ -563,3 +575,8 @@ from accidentally clobbering important system state.
563This explicit exporting can help with debugging (by making some kinds 575This explicit exporting can help with debugging (by making some kinds
564of experiments easier), or can provide an always-there interface that's 576of experiments easier), or can provide an always-there interface that's
565suitable for documenting as part of a board support package. 577suitable for documenting as part of a board support package.
578
579After the GPIO has been exported, gpio_export_link() allows creating
580symlinks from elsewhere in sysfs to the GPIO sysfs node. Drivers can
581use this to provide the interface under their own device in sysfs with
582a descriptive name.
diff --git a/Documentation/hwmon/acpi_power_meter b/Documentation/hwmon/acpi_power_meter
new file mode 100644
index 000000000000..c80399a00c50
--- /dev/null
+++ b/Documentation/hwmon/acpi_power_meter
@@ -0,0 +1,51 @@
1Kernel driver power_meter
2=========================
3
4This driver talks to ACPI 4.0 power meters.
5
6Supported systems:
7 * Any recent system with ACPI 4.0.
8 Prefix: 'power_meter'
9 Datasheet: http://acpi.info/, section 10.4.
10
11Author: Darrick J. Wong
12
13Description
14-----------
15
16This driver implements sensor reading support for the power meters exposed in
17the ACPI 4.0 spec (Chapter 10.4). These devices have a simple set of
18features--a power meter that returns average power use over a configurable
19interval, an optional capping mechanism, and a couple of trip points. The
20sysfs interface conforms with the specification outlined in the "Power" section
21of Documentation/hwmon/sysfs-interface.
22
23Special Features
24----------------
25
26The power[1-*]_is_battery knob indicates if the power supply is a battery.
27Both power[1-*]_average_{min,max} must be set before the trip points will work.
28When both of them are set, an ACPI event will be broadcast on the ACPI netlink
29socket and a poll notification will be sent to the appropriate
30power[1-*]_average sysfs file.
31
32The power[1-*]_{model_number, serial_number, oem_info} fields display arbitrary
33strings that ACPI provides with the meter. The measures/ directory contains
34symlinks to the devices that this meter measures.
35
36Some computers have the ability to enforce a power cap in hardware. If this is
37the case, the power[1-*]_cap and related sysfs files will appear. When the
38average power consumption exceeds the cap, an ACPI event will be broadcast on
39the netlink event socket and a poll notification will be sent to the
40appropriate power[1-*]_alarm file to indicate that capping has begun, and the
41hardware has taken action to reduce power consumption. Most likely this will
42result in reduced performance.
43
44There are a few other ACPI notifications that can be sent by the firmware. In
45all cases the ACPI event will be broadcast on the ACPI netlink event socket as
46well as sent as a poll notification to a sysfs file. The events are as
47follows:
48
49power[1-*]_cap will be notified if the firmware changes the power cap.
50power[1-*]_interval will be notified if the firmware changes the averaging
51interval.
diff --git a/Documentation/i2c/busses/i2c-piix4 b/Documentation/i2c/busses/i2c-piix4
index f889481762b5..c5b37c570554 100644
--- a/Documentation/i2c/busses/i2c-piix4
+++ b/Documentation/i2c/busses/i2c-piix4
@@ -8,6 +8,8 @@ Supported adapters:
8 Datasheet: Only available via NDA from ServerWorks 8 Datasheet: Only available via NDA from ServerWorks
9 * ATI IXP200, IXP300, IXP400, SB600, SB700 and SB800 southbridges 9 * ATI IXP200, IXP300, IXP400, SB600, SB700 and SB800 southbridges
10 Datasheet: Not publicly available 10 Datasheet: Not publicly available
11 * AMD SB900
12 Datasheet: Not publicly available
11 * Standard Microsystems (SMSC) SLC90E66 (Victory66) southbridge 13 * Standard Microsystems (SMSC) SLC90E66 (Victory66) southbridge
12 Datasheet: Publicly available at the SMSC website http://www.smsc.com 14 Datasheet: Publicly available at the SMSC website http://www.smsc.com
13 15
diff --git a/Documentation/i2c/chips/pca9539 b/Documentation/i2c/chips/pca9539
deleted file mode 100644
index 6aff890088b1..000000000000
--- a/Documentation/i2c/chips/pca9539
+++ /dev/null
@@ -1,58 +0,0 @@
1Kernel driver pca9539
2=====================
3
4NOTE: this driver is deprecated and will be dropped soon, use
5drivers/gpio/pca9539.c instead.
6
7Supported chips:
8 * Philips PCA9539
9 Prefix: 'pca9539'
10 Addresses scanned: none
11 Datasheet:
12 http://www.semiconductors.philips.com/acrobat/datasheets/PCA9539_2.pdf
13
14Author: Ben Gardner <bgardner@wabtec.com>
15
16
17Description
18-----------
19
20The Philips PCA9539 is a 16 bit low power I/O device.
21All 16 lines can be individually configured as an input or output.
22The input sense can also be inverted.
23The 16 lines are split between two bytes.
24
25
26Detection
27---------
28
29The PCA9539 is difficult to detect and not commonly found in PC machines,
30so you have to pass the I2C bus and address of the installed PCA9539
31devices explicitly to the driver at load time via the force=... parameter.
32
33
34Sysfs entries
35-------------
36
37Each is a byte that maps to the 8 I/O bits.
38A '0' suffix is for bits 0-7, while '1' is for bits 8-15.
39
40input[01] - read the current value
41output[01] - sets the output value
42direction[01] - direction of each bit: 1=input, 0=output
43invert[01] - toggle the input bit sense
44
45input reads the actual state of the line and is always available.
46The direction defaults to input for all channels.
47
48
49General Remarks
50---------------
51
52Note that each output, direction, and invert entry controls 8 lines.
53You should use the read, modify, write sequence.
54For example. to set output bit 0 of 1.
55 val=$(cat output0)
56 val=$(( $val | 1 ))
57 echo $val > output0
58
diff --git a/Documentation/i2c/chips/pcf8574 b/Documentation/i2c/chips/pcf8574
deleted file mode 100644
index 235815c075ff..000000000000
--- a/Documentation/i2c/chips/pcf8574
+++ /dev/null
@@ -1,65 +0,0 @@
1Kernel driver pcf8574
2=====================
3
4Supported chips:
5 * Philips PCF8574
6 Prefix: 'pcf8574'
7 Addresses scanned: none
8 Datasheet: Publicly available at the Philips Semiconductors website
9 http://www.semiconductors.philips.com/pip/PCF8574P.html
10
11 * Philips PCF8574A
12 Prefix: 'pcf8574a'
13 Addresses scanned: none
14 Datasheet: Publicly available at the Philips Semiconductors website
15 http://www.semiconductors.philips.com/pip/PCF8574P.html
16
17Authors:
18 Frodo Looijaard <frodol@dds.nl>,
19 Philip Edelbrock <phil@netroedge.com>,
20 Dan Eaton <dan.eaton@rocketlogix.com>,
21 Aurelien Jarno <aurelien@aurel32.net>,
22 Jean Delvare <khali@linux-fr.org>,
23
24
25Description
26-----------
27The PCF8574(A) is an 8-bit I/O expander for the I2C bus produced by Philips
28Semiconductors. It is designed to provide a byte I2C interface to up to 16
29separate devices (8 x PCF8574 and 8 x PCF8574A).
30
31This device consists of a quasi-bidirectional port. Each of the eight I/Os
32can be independently used as an input or output. To setup an I/O as an
33input, you have to write a 1 to the corresponding output.
34
35For more informations see the datasheet.
36
37
38Accessing PCF8574(A) via /sys interface
39-------------------------------------
40
41The PCF8574(A) is plainly impossible to detect ! Stupid chip.
42So, you have to pass the I2C bus and address of the installed PCF857A
43and PCF8574A devices explicitly to the driver at load time via the
44force=... parameter.
45
46On detection (i.e. insmod, modprobe et al.), directories are being
47created for each detected PCF8574(A):
48
49/sys/bus/i2c/devices/<0>-<1>/
50where <0> is the bus the chip was detected on (e. g. i2c-0)
51and <1> the chip address ([20..27] or [38..3f]):
52
53(example: /sys/bus/i2c/devices/1-0020/)
54
55Inside these directories, there are two files each:
56read and write (and one file with chip name).
57
58The read file is read-only. Reading gives you the current I/O input
59if the corresponding output is set as 1, otherwise the current output
60value, that is to say 0.
61
62The write file is read/write. Writing a value outputs it on the I/O
63port. Reading returns the last written value. As it is not possible
64to read this value from the chip, you need to write at least once to
65this file before you can read back from it.
diff --git a/Documentation/i2c/chips/pcf8575 b/Documentation/i2c/chips/pcf8575
deleted file mode 100644
index 40b268eb276f..000000000000
--- a/Documentation/i2c/chips/pcf8575
+++ /dev/null
@@ -1,69 +0,0 @@
1About the PCF8575 chip and the pcf8575 kernel driver
2====================================================
3
4The PCF8575 chip is produced by the following manufacturers:
5
6 * Philips NXP
7 http://www.nxp.com/#/pip/cb=[type=product,path=50807/41735/41850,final=PCF8575_3]|pip=[pip=PCF8575_3][0]
8
9 * Texas Instruments
10 http://focus.ti.com/docs/prod/folders/print/pcf8575.html
11
12
13Some vendors sell small PCB's with the PCF8575 mounted on it. You can connect
14such a board to a Linux host via e.g. an USB to I2C interface. Examples of
15PCB boards with a PCF8575:
16
17 * SFE Breakout Board for PCF8575 I2C Expander by RobotShop
18 http://www.robotshop.ca/home/products/robot-parts/electronics/adapters-converters/sfe-pcf8575-i2c-expander-board.html
19
20 * Breakout Board for PCF8575 I2C Expander by Spark Fun Electronics
21 http://www.sparkfun.com/commerce/product_info.php?products_id=8130
22
23
24Description
25-----------
26The PCF8575 chip is a 16-bit I/O expander for the I2C bus. Up to eight of
27these chips can be connected to the same I2C bus. You can find this
28chip on some custom designed hardware, but you won't find it on PC
29motherboards.
30
31The PCF8575 chip consists of a 16-bit quasi-bidirectional port and an I2C-bus
32interface. Each of the sixteen I/O's can be independently used as an input or
33an output. To set up an I/O pin as an input, you have to write a 1 to the
34corresponding output.
35
36For more information please see the datasheet.
37
38
39Detection
40---------
41
42There is no method known to detect whether a chip on a given I2C address is
43a PCF8575 or whether it is any other I2C device, so you have to pass the I2C
44bus and address of the installed PCF8575 devices explicitly to the driver at
45load time via the force=... parameter.
46
47/sys interface
48--------------
49
50For each address on which a PCF8575 chip was found or forced the following
51files will be created under /sys:
52* /sys/bus/i2c/devices/<bus>-<address>/read
53* /sys/bus/i2c/devices/<bus>-<address>/write
54where bus is the I2C bus number (0, 1, ...) and address is the four-digit
55hexadecimal representation of the 7-bit I2C address of the PCF8575
56(0020 .. 0027).
57
58The read file is read-only. Reading it will trigger an I2C read and will hence
59report the current input state for the pins configured as inputs, and the
60current output value for the pins configured as outputs.
61
62The write file is read-write. Writing a value to it will configure all pins
63as output for which the corresponding bit is zero. Reading the write file will
64return the value last written, or -EAGAIN if no value has yet been written to
65the write file.
66
67On module initialization the configuration of the chip is not changed -- the
68chip is left in the state it was already configured in through either power-up
69or through previous I2C write actions.
diff --git a/Documentation/ia64/aliasing-test.c b/Documentation/ia64/aliasing-test.c
index d23610fb2ff9..3dfb76ca6931 100644
--- a/Documentation/ia64/aliasing-test.c
+++ b/Documentation/ia64/aliasing-test.c
@@ -24,7 +24,7 @@
24 24
25int sum; 25int sum;
26 26
27int map_mem(char *path, off_t offset, size_t length, int touch) 27static int map_mem(char *path, off_t offset, size_t length, int touch)
28{ 28{
29 int fd, rc; 29 int fd, rc;
30 void *addr; 30 void *addr;
@@ -62,7 +62,7 @@ int map_mem(char *path, off_t offset, size_t length, int touch)
62 return 0; 62 return 0;
63} 63}
64 64
65int scan_tree(char *path, char *file, off_t offset, size_t length, int touch) 65static int scan_tree(char *path, char *file, off_t offset, size_t length, int touch)
66{ 66{
67 struct dirent **namelist; 67 struct dirent **namelist;
68 char *name, *path2; 68 char *name, *path2;
@@ -119,7 +119,7 @@ skip:
119 119
120char buf[1024]; 120char buf[1024];
121 121
122int read_rom(char *path) 122static int read_rom(char *path)
123{ 123{
124 int fd, rc; 124 int fd, rc;
125 size_t size = 0; 125 size_t size = 0;
@@ -146,7 +146,7 @@ int read_rom(char *path)
146 return size; 146 return size;
147} 147}
148 148
149int scan_rom(char *path, char *file) 149static int scan_rom(char *path, char *file)
150{ 150{
151 struct dirent **namelist; 151 struct dirent **namelist;
152 char *name, *path2; 152 char *name, *path2;
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index c363840cdcea..6fa7292947e5 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -671,7 +671,7 @@ and is between 256 and 4096 characters. It is defined in the file
671 earlyprintk= [X86,SH,BLACKFIN] 671 earlyprintk= [X86,SH,BLACKFIN]
672 earlyprintk=vga 672 earlyprintk=vga
673 earlyprintk=serial[,ttySn[,baudrate]] 673 earlyprintk=serial[,ttySn[,baudrate]]
674 earlyprintk=dbgp 674 earlyprintk=dbgp[debugController#]
675 675
676 Append ",keep" to not disable it when the real console 676 Append ",keep" to not disable it when the real console
677 takes over. 677 takes over.
diff --git a/Documentation/laptops/asus-laptop.txt b/Documentation/laptops/asus-laptop.txt
new file mode 100644
index 000000000000..c1c5be84e4b1
--- /dev/null
+++ b/Documentation/laptops/asus-laptop.txt
@@ -0,0 +1,258 @@
1Asus Laptop Extras
2
3Version 0.1
4August 6, 2009
5
6Corentin Chary <corentincj@iksaif.net>
7http://acpi4asus.sf.net/
8
9 This driver provides support for extra features of ACPI-compatible ASUS laptops.
10 It may also support some MEDION, JVC or VICTOR laptops (such as MEDION 9675 or
11 VICTOR XP7210 for example). It makes all the extra buttons generate standard
12 ACPI events that go through /proc/acpi/events and input events (like keyboards).
13 On some models adds support for changing the display brightness and output,
14 switching the LCD backlight on and off, and most importantly, allows you to
15 blink those fancy LEDs intended for reporting mail and wireless status.
16
17This driver supercedes the old asus_acpi driver.
18
19Requirements
20------------
21
22 Kernel 2.6.X sources, configured for your computer, with ACPI support.
23 You also need CONFIG_INPUT and CONFIG_ACPI.
24
25Status
26------
27
28 The features currently supported are the following (see below for
29 detailed description):
30
31 - Fn key combinations
32 - Bluetooth enable and disable
33 - Wlan enable and disable
34 - GPS enable and disable
35 - Video output switching
36 - Ambient Light Sensor on and off
37 - LED control
38 - LED Display control
39 - LCD brightness control
40 - LCD on and off
41
42 A compatibility table by model and feature is maintained on the web
43 site, http://acpi4asus.sf.net/.
44
45Usage
46-----
47
48 Try "modprobe asus_acpi". Check your dmesg (simply type dmesg). You should
49 see some lines like this :
50
51 Asus Laptop Extras version 0.42
52 L2D model detected.
53
54 If it is not the output you have on your laptop, send it (and the laptop's
55 DSDT) to me.
56
57 That's all, now, all the events generated by the hotkeys of your laptop
58 should be reported in your /proc/acpi/event entry. You can check with
59 "acpi_listen".
60
61 Hotkeys are also reported as input keys (like keyboards) you can check
62 which key are supported using "xev" under X11.
63
64 You can get informations on the version of your DSDT table by reading the
65 /sys/devices/platform/asus-laptop/infos entry. If you have a question or a
66 bug report to do, please include the output of this entry.
67
68LEDs
69----
70
71 You can modify LEDs be echoing values to /sys/class/leds/asus::*/brightness :
72 echo 1 > /sys/class/leds/asus::mail/brightness
73 will switch the mail LED on.
74 You can also know if they are on/off by reading their content and use
75 kernel triggers like ide-disk or heartbeat.
76
77Backlight
78---------
79
80 You can control lcd backlight power and brightness with
81 /sys/class/backlight/asus-laptop/. Brightness Values are between 0 and 15.
82
83Wireless devices
84---------------
85
86 You can turn the internal Bluetooth adapter on/off with the bluetooth entry
87 (only on models with Bluetooth). This usually controls the associated LED.
88 Same for Wlan adapter.
89
90Display switching
91-----------------
92
93 Note: the display switching code is currently considered EXPERIMENTAL.
94
95 Switching works for the following models:
96 L3800C
97 A2500H
98 L5800C
99 M5200N
100 W1000N (albeit with some glitches)
101 M6700R
102 A6JC
103 F3J
104
105 Switching doesn't work for the following:
106 M3700N
107 L2X00D (locks the laptop under certain conditions)
108
109 To switch the displays, echo values from 0 to 15 to
110 /sys/devices/platform/asus-laptop/display. The significance of those values
111 is as follows:
112
113 +-------+-----+-----+-----+-----+-----+
114 | Bin | Val | DVI | TV | CRT | LCD |
115 +-------+-----+-----+-----+-----+-----+
116 + 0000 + 0 + + + + +
117 +-------+-----+-----+-----+-----+-----+
118 + 0001 + 1 + + + + X +
119 +-------+-----+-----+-----+-----+-----+
120 + 0010 + 2 + + + X + +
121 +-------+-----+-----+-----+-----+-----+
122 + 0011 + 3 + + + X + X +
123 +-------+-----+-----+-----+-----+-----+
124 + 0100 + 4 + + X + + +
125 +-------+-----+-----+-----+-----+-----+
126 + 0101 + 5 + + X + + X +
127 +-------+-----+-----+-----+-----+-----+
128 + 0110 + 6 + + X + X + +
129 +-------+-----+-----+-----+-----+-----+
130 + 0111 + 7 + + X + X + X +
131 +-------+-----+-----+-----+-----+-----+
132 + 1000 + 8 + X + + + +
133 +-------+-----+-----+-----+-----+-----+
134 + 1001 + 9 + X + + + X +
135 +-------+-----+-----+-----+-----+-----+
136 + 1010 + 10 + X + + X + +
137 +-------+-----+-----+-----+-----+-----+
138 + 1011 + 11 + X + + X + X +
139 +-------+-----+-----+-----+-----+-----+
140 + 1100 + 12 + X + X + + +
141 +-------+-----+-----+-----+-----+-----+
142 + 1101 + 13 + X + X + + X +
143 +-------+-----+-----+-----+-----+-----+
144 + 1110 + 14 + X + X + X + +
145 +-------+-----+-----+-----+-----+-----+
146 + 1111 + 15 + X + X + X + X +
147 +-------+-----+-----+-----+-----+-----+
148
149 In most cases, the appropriate displays must be plugged in for the above
150 combinations to work. TV-Out may need to be initialized at boot time.
151
152 Debugging:
153 1) Check whether the Fn+F8 key:
154 a) does not lock the laptop (try disabling CONFIG_X86_UP_APIC or boot with
155 noapic / nolapic if it does)
156 b) generates events (0x6n, where n is the value corresponding to the
157 configuration above)
158 c) actually works
159 Record the disp value at every configuration.
160 2) Echo values from 0 to 15 to /sys/devices/platform/asus-laptop/display.
161 Record its value, note any change. If nothing changes, try a broader range,
162 up to 65535.
163 3) Send ANY output (both positive and negative reports are needed, unless your
164 machine is already listed above) to the acpi4asus-user mailing list.
165
166 Note: on some machines (e.g. L3C), after the module has been loaded, only 0x6n
167 events are generated and no actual switching occurs. In such a case, a line
168 like:
169
170 echo $((10#$arg-60)) > /sys/devices/platform/asus-laptop/display
171
172 will usually do the trick ($arg is the 0000006n-like event passed to acpid).
173
174 Note: there is currently no reliable way to read display status on xxN
175 (Centrino) models.
176
177LED display
178-----------
179
180 Some models like the W1N have a LED display that can be used to display
181 several informations.
182
183 LED display works for the following models:
184 W1000N
185 W1J
186
187 To control the LED display, use the following :
188
189 echo 0x0T000DDD > /sys/devices/platform/asus-laptop/
190
191 where T control the 3 letters display, and DDD the 3 digits display,
192 according to the tables below.
193
194 DDD (digits)
195 000 to 999 = display digits
196 AAA = ---
197 BBB to FFF = turn-off
198
199 T (type)
200 0 = off
201 1 = dvd
202 2 = vcd
203 3 = mp3
204 4 = cd
205 5 = tv
206 6 = cpu
207 7 = vol
208
209 For example "echo 0x01000001 >/sys/devices/platform/asus-laptop/ledd"
210 would display "DVD001".
211
212Driver options:
213---------------
214
215 Options can be passed to the asus-laptop driver using the standard
216 module argument syntax (<param>=<value> when passing the option to the
217 module or asus-laptop.<param>=<value> on the kernel boot line when
218 asus-laptop is statically linked into the kernel).
219
220 wapf: WAPF defines the behavior of the Fn+Fx wlan key
221 The significance of values is yet to be found, but
222 most of the time:
223 - 0x0 should do nothing
224 - 0x1 should allow to control the device with Fn+Fx key.
225 - 0x4 should send an ACPI event (0x88) while pressing the Fn+Fx key
226 - 0x5 like 0x1 or 0x4
227
228 The default value is 0x1.
229
230Unsupported models
231------------------
232
233 These models will never be supported by this module, as they use a completely
234 different mechanism to handle LEDs and extra stuff (meaning we have no clue
235 how it works):
236
237 - ASUS A1300 (A1B), A1370D
238 - ASUS L7300G
239 - ASUS L8400
240
241Patches, Errors, Questions:
242--------------------------
243
244 I appreciate any success or failure
245 reports, especially if they add to or correct the compatibility table.
246 Please include the following information in your report:
247
248 - Asus model name
249 - a copy of your ACPI tables, using the "acpidump" utility
250 - a copy of /sys/devices/platform/asus-laptop/infos
251 - which driver features work and which don't
252 - the observed behavior of non-working features
253
254 Any other comments or patches are also more than welcome.
255
256 acpi4asus-user@lists.sourceforge.net
257 http://sourceforge.net/projects/acpi4asus
258
diff --git a/Documentation/laptops/thinkpad-acpi.txt b/Documentation/laptops/thinkpad-acpi.txt
index e2ddcdeb61b6..6d03487ef1c7 100644
--- a/Documentation/laptops/thinkpad-acpi.txt
+++ b/Documentation/laptops/thinkpad-acpi.txt
@@ -219,7 +219,7 @@ The following commands can be written to the /proc/acpi/ibm/hotkey file:
219 echo 0xffffffff > /proc/acpi/ibm/hotkey -- enable all hot keys 219 echo 0xffffffff > /proc/acpi/ibm/hotkey -- enable all hot keys
220 echo 0 > /proc/acpi/ibm/hotkey -- disable all possible hot keys 220 echo 0 > /proc/acpi/ibm/hotkey -- disable all possible hot keys
221 ... any other 8-hex-digit mask ... 221 ... any other 8-hex-digit mask ...
222 echo reset > /proc/acpi/ibm/hotkey -- restore the original mask 222 echo reset > /proc/acpi/ibm/hotkey -- restore the recommended mask
223 223
224The following commands have been deprecated and will cause the kernel 224The following commands have been deprecated and will cause the kernel
225to log a warning: 225to log a warning:
@@ -240,9 +240,13 @@ sysfs notes:
240 Returns 0. 240 Returns 0.
241 241
242 hotkey_bios_mask: 242 hotkey_bios_mask:
243 DEPRECATED, DON'T USE, WILL BE REMOVED IN THE FUTURE.
244
243 Returns the hot keys mask when thinkpad-acpi was loaded. 245 Returns the hot keys mask when thinkpad-acpi was loaded.
244 Upon module unload, the hot keys mask will be restored 246 Upon module unload, the hot keys mask will be restored
245 to this value. 247 to this value. This is always 0x80c, because those are
248 the hotkeys that were supported by ancient firmware
249 without mask support.
246 250
247 hotkey_enable: 251 hotkey_enable:
248 DEPRECATED, WILL BE REMOVED SOON. 252 DEPRECATED, WILL BE REMOVED SOON.
diff --git a/Documentation/leds-class.txt b/Documentation/leds-class.txt
index 6399557cdab3..8fd5ca2ae32d 100644
--- a/Documentation/leds-class.txt
+++ b/Documentation/leds-class.txt
@@ -1,3 +1,4 @@
1
1LED handling under Linux 2LED handling under Linux
2======================== 3========================
3 4
@@ -5,10 +6,10 @@ If you're reading this and thinking about keyboard leds, these are
5handled by the input subsystem and the led class is *not* needed. 6handled by the input subsystem and the led class is *not* needed.
6 7
7In its simplest form, the LED class just allows control of LEDs from 8In its simplest form, the LED class just allows control of LEDs from
8userspace. LEDs appear in /sys/class/leds/. The brightness file will 9userspace. LEDs appear in /sys/class/leds/. The maximum brightness of the
9set the brightness of the LED (taking a value 0-255). Most LEDs don't 10LED is defined in max_brightness file. The brightness file will set the brightness
10have hardware brightness support so will just be turned on for non-zero 11of the LED (taking a value 0-max_brightness). Most LEDs don't have hardware
11brightness settings. 12brightness support so will just be turned on for non-zero brightness settings.
12 13
13The class also introduces the optional concept of an LED trigger. A trigger 14The class also introduces the optional concept of an LED trigger. A trigger
14is a kernel based source of led events. Triggers can either be simple or 15is a kernel based source of led events. Triggers can either be simple or
diff --git a/Documentation/lguest/lguest.c b/Documentation/lguest/lguest.c
index 950cde6d6e58..ba9373f82ab5 100644
--- a/Documentation/lguest/lguest.c
+++ b/Documentation/lguest/lguest.c
@@ -42,6 +42,7 @@
42#include <signal.h> 42#include <signal.h>
43#include "linux/lguest_launcher.h" 43#include "linux/lguest_launcher.h"
44#include "linux/virtio_config.h" 44#include "linux/virtio_config.h"
45#include <linux/virtio_ids.h>
45#include "linux/virtio_net.h" 46#include "linux/virtio_net.h"
46#include "linux/virtio_blk.h" 47#include "linux/virtio_blk.h"
47#include "linux/virtio_console.h" 48#include "linux/virtio_console.h"
@@ -133,6 +134,9 @@ struct device {
133 /* Is it operational */ 134 /* Is it operational */
134 bool running; 135 bool running;
135 136
137 /* Does Guest want an intrrupt on empty? */
138 bool irq_on_empty;
139
136 /* Device-specific data. */ 140 /* Device-specific data. */
137 void *priv; 141 void *priv;
138}; 142};
@@ -623,10 +627,13 @@ static void trigger_irq(struct virtqueue *vq)
623 return; 627 return;
624 vq->pending_used = 0; 628 vq->pending_used = 0;
625 629
626 /* If they don't want an interrupt, don't send one, unless empty. */ 630 /* If they don't want an interrupt, don't send one... */
627 if ((vq->vring.avail->flags & VRING_AVAIL_F_NO_INTERRUPT) 631 if (vq->vring.avail->flags & VRING_AVAIL_F_NO_INTERRUPT) {
628 && lg_last_avail(vq) != vq->vring.avail->idx) 632 /* ... unless they've asked us to force one on empty. */
629 return; 633 if (!vq->dev->irq_on_empty
634 || lg_last_avail(vq) != vq->vring.avail->idx)
635 return;
636 }
630 637
631 /* Send the Guest an interrupt tell them we used something up. */ 638 /* Send the Guest an interrupt tell them we used something up. */
632 if (write(lguest_fd, buf, sizeof(buf)) != 0) 639 if (write(lguest_fd, buf, sizeof(buf)) != 0)
@@ -1042,6 +1049,15 @@ static void create_thread(struct virtqueue *vq)
1042 close(vq->eventfd); 1049 close(vq->eventfd);
1043} 1050}
1044 1051
1052static bool accepted_feature(struct device *dev, unsigned int bit)
1053{
1054 const u8 *features = get_feature_bits(dev) + dev->feature_len;
1055
1056 if (dev->feature_len < bit / CHAR_BIT)
1057 return false;
1058 return features[bit / CHAR_BIT] & (1 << (bit % CHAR_BIT));
1059}
1060
1045static void start_device(struct device *dev) 1061static void start_device(struct device *dev)
1046{ 1062{
1047 unsigned int i; 1063 unsigned int i;
@@ -1055,6 +1071,8 @@ static void start_device(struct device *dev)
1055 verbose(" %02x", get_feature_bits(dev) 1071 verbose(" %02x", get_feature_bits(dev)
1056 [dev->feature_len+i]); 1072 [dev->feature_len+i]);
1057 1073
1074 dev->irq_on_empty = accepted_feature(dev, VIRTIO_F_NOTIFY_ON_EMPTY);
1075
1058 for (vq = dev->vq; vq; vq = vq->next) { 1076 for (vq = dev->vq; vq; vq = vq->next) {
1059 if (vq->service) 1077 if (vq->service)
1060 create_thread(vq); 1078 create_thread(vq);
diff --git a/Documentation/pcmcia/crc32hash.c b/Documentation/pcmcia/crc32hash.c
index 4210e5abab8a..44f8beea7260 100644
--- a/Documentation/pcmcia/crc32hash.c
+++ b/Documentation/pcmcia/crc32hash.c
@@ -8,7 +8,7 @@ $ ./crc32hash "Dual Speed"
8#include <ctype.h> 8#include <ctype.h>
9#include <stdlib.h> 9#include <stdlib.h>
10 10
11unsigned int crc32(unsigned char const *p, unsigned int len) 11static unsigned int crc32(unsigned char const *p, unsigned int len)
12{ 12{
13 int i; 13 int i;
14 unsigned int crc = 0; 14 unsigned int crc = 0;
diff --git a/Documentation/power/power_supply_class.txt b/Documentation/power/power_supply_class.txt
index c6cd4956047c..9f16c5178b66 100644
--- a/Documentation/power/power_supply_class.txt
+++ b/Documentation/power/power_supply_class.txt
@@ -76,6 +76,11 @@ STATUS - this attribute represents operating status (charging, full,
76discharging (i.e. powering a load), etc.). This corresponds to 76discharging (i.e. powering a load), etc.). This corresponds to
77BATTERY_STATUS_* values, as defined in battery.h. 77BATTERY_STATUS_* values, as defined in battery.h.
78 78
79CHARGE_TYPE - batteries can typically charge at different rates.
80This defines trickle and fast charges. For batteries that
81are already charged or discharging, 'n/a' can be displayed (or
82'unknown', if the status is not known).
83
79HEALTH - represents health of the battery, values corresponds to 84HEALTH - represents health of the battery, values corresponds to
80POWER_SUPPLY_HEALTH_*, defined in battery.h. 85POWER_SUPPLY_HEALTH_*, defined in battery.h.
81 86
@@ -108,6 +113,8 @@ relative, time-based measurements.
108ENERGY_FULL, ENERGY_EMPTY - same as above but for energy. 113ENERGY_FULL, ENERGY_EMPTY - same as above but for energy.
109 114
110CAPACITY - capacity in percents. 115CAPACITY - capacity in percents.
116CAPACITY_LEVEL - capacity level. This corresponds to
117POWER_SUPPLY_CAPACITY_LEVEL_*.
111 118
112TEMP - temperature of the power supply. 119TEMP - temperature of the power supply.
113TEMP_AMBIENT - ambient temperature. 120TEMP_AMBIENT - ambient temperature.
diff --git a/Documentation/power/regulator/design.txt b/Documentation/power/regulator/design.txt
new file mode 100644
index 000000000000..f9b56b72b782
--- /dev/null
+++ b/Documentation/power/regulator/design.txt
@@ -0,0 +1,33 @@
1Regulator API design notes
2==========================
3
4This document provides a brief, partially structured, overview of some
5of the design considerations which impact the regulator API design.
6
7Safety
8------
9
10 - Errors in regulator configuration can have very serious consequences
11 for the system, potentially including lasting hardware damage.
12 - It is not possible to automatically determine the power confugration
13 of the system - software-equivalent variants of the same chip may
14 have different power requirments, and not all components with power
15 requirements are visible to software.
16
17 => The API should make no changes to the hardware state unless it has
18 specific knowledge that these changes are safe to do perform on
19 this particular system.
20
21Consumer use cases
22------------------
23
24 - The overwhelming majority of devices in a system will have no
25 requirement to do any runtime configuration of their power beyond
26 being able to turn it on or off.
27
28 - Many of the power supplies in the system will be shared between many
29 different consumers.
30
31 => The consumer API should be structured so that these use cases are
32 very easy to handle and so that consumers will work with shared
33 supplies without any additional effort.
diff --git a/Documentation/power/regulator/machine.txt b/Documentation/power/regulator/machine.txt
index ce3487d99abe..63728fed620b 100644
--- a/Documentation/power/regulator/machine.txt
+++ b/Documentation/power/regulator/machine.txt
@@ -87,7 +87,7 @@ static struct platform_device regulator_devices[] = {
87}, 87},
88}; 88};
89/* register regulator 1 device */ 89/* register regulator 1 device */
90platform_device_register(&wm8350_regulator_devices[0]); 90platform_device_register(&regulator_devices[0]);
91 91
92/* register regulator 2 device */ 92/* register regulator 2 device */
93platform_device_register(&wm8350_regulator_devices[1]); 93platform_device_register(&regulator_devices[1]);
diff --git a/Documentation/power/regulator/overview.txt b/Documentation/power/regulator/overview.txt
index 0cded696ca01..ffd185bb6054 100644
--- a/Documentation/power/regulator/overview.txt
+++ b/Documentation/power/regulator/overview.txt
@@ -29,7 +29,7 @@ Some terms used in this document:-
29 29
30 30
31 o PMIC - Power Management IC. An IC that contains numerous regulators 31 o PMIC - Power Management IC. An IC that contains numerous regulators
32 and often contains other susbsystems. 32 and often contains other subsystems.
33 33
34 34
35 o Consumer - Electronic device that is supplied power by a regulator. 35 o Consumer - Electronic device that is supplied power by a regulator.
@@ -168,4 +168,4 @@ relevant to non SoC devices and is split into the following four interfaces:-
168 userspace via sysfs. This could be used to help monitor device power 168 userspace via sysfs. This could be used to help monitor device power
169 consumption and status. 169 consumption and status.
170 170
171 See Documentation/ABI/testing/regulator-sysfs.txt 171 See Documentation/ABI/testing/sysfs-class-regulator
diff --git a/Documentation/power/regulator/regulator.txt b/Documentation/power/regulator/regulator.txt
index 4200accb9bba..3f8b528f237e 100644
--- a/Documentation/power/regulator/regulator.txt
+++ b/Documentation/power/regulator/regulator.txt
@@ -10,8 +10,9 @@ Registration
10 10
11Drivers can register a regulator by calling :- 11Drivers can register a regulator by calling :-
12 12
13struct regulator_dev *regulator_register(struct device *dev, 13struct regulator_dev *regulator_register(struct regulator_desc *regulator_desc,
14 struct regulator_desc *regulator_desc); 14 struct device *dev, struct regulator_init_data *init_data,
15 void *driver_data);
15 16
16This will register the regulators capabilities and operations to the regulator 17This will register the regulators capabilities and operations to the regulator
17core. 18core.
diff --git a/Documentation/powerpc/dts-bindings/fsl/esdhc.txt b/Documentation/powerpc/dts-bindings/fsl/esdhc.txt
index 3ed3797b5086..8a0040738969 100644
--- a/Documentation/powerpc/dts-bindings/fsl/esdhc.txt
+++ b/Documentation/powerpc/dts-bindings/fsl/esdhc.txt
@@ -10,6 +10,8 @@ Required properties:
10 - interrupts : should contain eSDHC interrupt. 10 - interrupts : should contain eSDHC interrupt.
11 - interrupt-parent : interrupt source phandle. 11 - interrupt-parent : interrupt source phandle.
12 - clock-frequency : specifies eSDHC base clock frequency. 12 - clock-frequency : specifies eSDHC base clock frequency.
13 - sdhci,wp-inverted : (optional) specifies that eSDHC controller
14 reports inverted write-protect state;
13 - sdhci,1-bit-only : (optional) specifies that a controller can 15 - sdhci,1-bit-only : (optional) specifies that a controller can
14 only handle 1-bit data transfers. 16 only handle 1-bit data transfers.
15 17
diff --git a/Documentation/powerpc/dts-bindings/mtd-physmap.txt b/Documentation/powerpc/dts-bindings/mtd-physmap.txt
index 667c9bde8699..80152cb567d9 100644
--- a/Documentation/powerpc/dts-bindings/mtd-physmap.txt
+++ b/Documentation/powerpc/dts-bindings/mtd-physmap.txt
@@ -1,18 +1,19 @@
1CFI or JEDEC memory-mapped NOR flash 1CFI or JEDEC memory-mapped NOR flash, MTD-RAM (NVRAM...)
2 2
3Flash chips (Memory Technology Devices) are often used for solid state 3Flash chips (Memory Technology Devices) are often used for solid state
4file systems on embedded devices. 4file systems on embedded devices.
5 5
6 - compatible : should contain the specific model of flash chip(s) 6 - compatible : should contain the specific model of mtd chip(s)
7 used, if known, followed by either "cfi-flash" or "jedec-flash" 7 used, if known, followed by either "cfi-flash", "jedec-flash"
8 - reg : Address range(s) of the flash chip(s) 8 or "mtd-ram".
9 - reg : Address range(s) of the mtd chip(s)
9 It's possible to (optionally) define multiple "reg" tuples so that 10 It's possible to (optionally) define multiple "reg" tuples so that
10 non-identical NOR chips can be described in one flash node. 11 non-identical chips can be described in one node.
11 - bank-width : Width (in bytes) of the flash bank. Equal to the 12 - bank-width : Width (in bytes) of the bank. Equal to the
12 device width times the number of interleaved chips. 13 device width times the number of interleaved chips.
13 - device-width : (optional) Width of a single flash chip. If 14 - device-width : (optional) Width of a single mtd chip. If
14 omitted, assumed to be equal to 'bank-width'. 15 omitted, assumed to be equal to 'bank-width'.
15 - #address-cells, #size-cells : Must be present if the flash has 16 - #address-cells, #size-cells : Must be present if the device has
16 sub-nodes representing partitions (see below). In this case 17 sub-nodes representing partitions (see below). In this case
17 both #address-cells and #size-cells must be equal to 1. 18 both #address-cells and #size-cells must be equal to 1.
18 19
@@ -22,24 +23,24 @@ are defined:
22 - vendor-id : Contains the flash chip's vendor id (1 byte). 23 - vendor-id : Contains the flash chip's vendor id (1 byte).
23 - device-id : Contains the flash chip's device id (1 byte). 24 - device-id : Contains the flash chip's device id (1 byte).
24 25
25In addition to the information on the flash bank itself, the 26In addition to the information on the mtd bank itself, the
26device tree may optionally contain additional information 27device tree may optionally contain additional information
27describing partitions of the flash address space. This can be 28describing partitions of the address space. This can be
28used on platforms which have strong conventions about which 29used on platforms which have strong conventions about which
29portions of the flash are used for what purposes, but which don't 30portions of a flash are used for what purposes, but which don't
30use an on-flash partition table such as RedBoot. 31use an on-flash partition table such as RedBoot.
31 32
32Each partition is represented as a sub-node of the flash device. 33Each partition is represented as a sub-node of the mtd device.
33Each node's name represents the name of the corresponding 34Each node's name represents the name of the corresponding
34partition of the flash device. 35partition of the mtd device.
35 36
36Flash partitions 37Flash partitions
37 - reg : The partition's offset and size within the flash bank. 38 - reg : The partition's offset and size within the mtd bank.
38 - label : (optional) The label / name for this flash partition. 39 - label : (optional) The label / name for this partition.
39 If omitted, the label is taken from the node name (excluding 40 If omitted, the label is taken from the node name (excluding
40 the unit address). 41 the unit address).
41 - read-only : (optional) This parameter, if present, is a hint to 42 - read-only : (optional) This parameter, if present, is a hint to
42 Linux that this flash partition should only be mounted 43 Linux that this partition should only be mounted
43 read-only. This is usually used for flash partitions 44 read-only. This is usually used for flash partitions
44 containing early-boot firmware images or data which should not 45 containing early-boot firmware images or data which should not
45 be clobbered. 46 be clobbered.
@@ -78,3 +79,12 @@ Here an example with multiple "reg" tuples:
78 reg = <0 0x04000000>; 79 reg = <0 0x04000000>;
79 }; 80 };
80 }; 81 };
82
83An example using SRAM:
84
85 sram@2,0 {
86 compatible = "samsung,k6f1616u6a", "mtd-ram";
87 reg = <2 0 0x00200000>;
88 bank-width = <2>;
89 };
90
diff --git a/Documentation/rtc.txt b/Documentation/rtc.txt
index 8deffcd68cb8..9104c1062084 100644
--- a/Documentation/rtc.txt
+++ b/Documentation/rtc.txt
@@ -135,6 +135,30 @@ a high functionality RTC is integrated into the SOC. That system might read
135the system clock from the discrete RTC, but use the integrated one for all 135the system clock from the discrete RTC, but use the integrated one for all
136other tasks, because of its greater functionality. 136other tasks, because of its greater functionality.
137 137
138SYSFS INTERFACE
139---------------
140
141The sysfs interface under /sys/class/rtc/rtcN provides access to various
142rtc attributes without requiring the use of ioctls. All dates and times
143are in the RTC's timezone, rather than in system time.
144
145date: RTC-provided date
146hctosys: 1 if the RTC provided the system time at boot via the
147 CONFIG_RTC_HCTOSYS kernel option, 0 otherwise
148max_user_freq: The maximum interrupt rate an unprivileged user may request
149 from this RTC.
150name: The name of the RTC corresponding to this sysfs directory
151since_epoch: The number of seconds since the epoch according to the RTC
152time: RTC-provided time
153wakealarm: The time at which the clock will generate a system wakeup
154 event. This is a one shot wakeup event, so must be reset
155 after wake if a daily wakeup is required. Format is either
156 seconds since the epoch or, if there's a leading +, seconds
157 in the future.
158
159IOCTL INTERFACE
160---------------
161
138The ioctl() calls supported by /dev/rtc are also supported by the RTC class 162The ioctl() calls supported by /dev/rtc are also supported by the RTC class
139framework. However, because the chips and systems are not standardized, 163framework. However, because the chips and systems are not standardized,
140some PC/AT functionality might not be provided. And in the same way, some 164some PC/AT functionality might not be provided. And in the same way, some
@@ -185,6 +209,8 @@ driver returns ENOIOCTLCMD. Some common examples:
185 hardware in the irq_set_freq function. If it isn't, return -EINVAL. If 209 hardware in the irq_set_freq function. If it isn't, return -EINVAL. If
186 you cannot actually change the frequency, do not define irq_set_freq. 210 you cannot actually change the frequency, do not define irq_set_freq.
187 211
212 * RTC_PIE_ON, RTC_PIE_OFF: the irq_set_state function will be called.
213
188If all else fails, check out the rtc-test.c driver! 214If all else fails, check out the rtc-test.c driver!
189 215
190 216
diff --git a/Documentation/spi/spi-summary b/Documentation/spi/spi-summary
index 4a02d2508bc8..deab51ddc33e 100644
--- a/Documentation/spi/spi-summary
+++ b/Documentation/spi/spi-summary
@@ -350,7 +350,7 @@ SPI protocol drivers somewhat resemble platform device drivers:
350 .resume = CHIP_resume, 350 .resume = CHIP_resume,
351 }; 351 };
352 352
353The driver core will autmatically attempt to bind this driver to any SPI 353The driver core will automatically attempt to bind this driver to any SPI
354device whose board_info gave a modalias of "CHIP". Your probe() code 354device whose board_info gave a modalias of "CHIP". Your probe() code
355might look like this unless you're creating a device which is managing 355might look like this unless you're creating a device which is managing
356a bus (appearing under /sys/class/spi_master). 356a bus (appearing under /sys/class/spi_master).
diff --git a/Documentation/spi/spidev_test.c b/Documentation/spi/spidev_test.c
index c1a5aad3c75a..10abd3773e49 100644
--- a/Documentation/spi/spidev_test.c
+++ b/Documentation/spi/spidev_test.c
@@ -69,7 +69,7 @@ static void transfer(int fd)
69 puts(""); 69 puts("");
70} 70}
71 71
72void print_usage(const char *prog) 72static void print_usage(const char *prog)
73{ 73{
74 printf("Usage: %s [-DsbdlHOLC3]\n", prog); 74 printf("Usage: %s [-DsbdlHOLC3]\n", prog);
75 puts(" -D --device device to use (default /dev/spidev1.1)\n" 75 puts(" -D --device device to use (default /dev/spidev1.1)\n"
@@ -85,7 +85,7 @@ void print_usage(const char *prog)
85 exit(1); 85 exit(1);
86} 86}
87 87
88void parse_opts(int argc, char *argv[]) 88static void parse_opts(int argc, char *argv[])
89{ 89{
90 while (1) { 90 while (1) {
91 static const struct option lopts[] = { 91 static const struct option lopts[] = {
diff --git a/Documentation/sysctl/kernel.txt b/Documentation/sysctl/kernel.txt
index 3e5b63ebb821..b3d8b4922740 100644
--- a/Documentation/sysctl/kernel.txt
+++ b/Documentation/sysctl/kernel.txt
@@ -313,6 +313,14 @@ send before ratelimiting kicks in.
313 313
314============================================================== 314==============================================================
315 315
316printk_delay:
317
318Delay each printk message in printk_delay milliseconds
319
320Value from 0 - 10000 is allowed.
321
322==============================================================
323
316randomize-va-space: 324randomize-va-space:
317 325
318This option can be used to select the type of process address 326This option can be used to select the type of process address
diff --git a/Documentation/usb/authorization.txt b/Documentation/usb/authorization.txt
index 381b22ee7834..c069b6884c77 100644
--- a/Documentation/usb/authorization.txt
+++ b/Documentation/usb/authorization.txt
@@ -16,20 +16,20 @@ Usage:
16 16
17Authorize a device to connect: 17Authorize a device to connect:
18 18
19$ echo 1 > /sys/usb/devices/DEVICE/authorized 19$ echo 1 > /sys/bus/usb/devices/DEVICE/authorized
20 20
21Deauthorize a device: 21Deauthorize a device:
22 22
23$ echo 0 > /sys/usb/devices/DEVICE/authorized 23$ echo 0 > /sys/bus/usb/devices/DEVICE/authorized
24 24
25Set new devices connected to hostX to be deauthorized by default (ie: 25Set new devices connected to hostX to be deauthorized by default (ie:
26lock down): 26lock down):
27 27
28$ echo 0 > /sys/bus/devices/usbX/authorized_default 28$ echo 0 > /sys/bus/usb/devices/usbX/authorized_default
29 29
30Remove the lock down: 30Remove the lock down:
31 31
32$ echo 1 > /sys/bus/devices/usbX/authorized_default 32$ echo 1 > /sys/bus/usb/devices/usbX/authorized_default
33 33
34By default, Wired USB devices are authorized by default to 34By default, Wired USB devices are authorized by default to
35connect. Wireless USB hosts deauthorize by default all new connected 35connect. Wireless USB hosts deauthorize by default all new connected
@@ -47,7 +47,7 @@ USB port):
47boot up 47boot up
48rc.local -> 48rc.local ->
49 49
50 for host in /sys/bus/devices/usb* 50 for host in /sys/bus/usb/devices/usb*
51 do 51 do
52 echo 0 > $host/authorized_default 52 echo 0 > $host/authorized_default
53 done 53 done
diff --git a/Documentation/usb/usbmon.txt b/Documentation/usb/usbmon.txt
index 6c3c625b7f30..66f92d1194c1 100644
--- a/Documentation/usb/usbmon.txt
+++ b/Documentation/usb/usbmon.txt
@@ -33,7 +33,7 @@ if usbmon is built into the kernel.
33 33
34Verify that bus sockets are present. 34Verify that bus sockets are present.
35 35
36# ls /sys/kernel/debug/usbmon 36# ls /sys/kernel/debug/usb/usbmon
370s 0u 1s 1t 1u 2s 2t 2u 3s 3t 3u 4s 4t 4u 370s 0u 1s 1t 1u 2s 2t 2u 3s 3t 3u 4s 4t 4u
38# 38#
39 39
@@ -58,11 +58,11 @@ Bus=03 means it's bus 3.
58 58
593. Start 'cat' 593. Start 'cat'
60 60
61# cat /sys/kernel/debug/usbmon/3u > /tmp/1.mon.out 61# cat /sys/kernel/debug/usb/usbmon/3u > /tmp/1.mon.out
62 62
63to listen on a single bus, otherwise, to listen on all buses, type: 63to listen on a single bus, otherwise, to listen on all buses, type:
64 64
65# cat /sys/kernel/debug/usbmon/0u > /tmp/1.mon.out 65# cat /sys/kernel/debug/usb/usbmon/0u > /tmp/1.mon.out
66 66
67This process will be reading until killed. Naturally, the output can be 67This process will be reading until killed. Naturally, the output can be
68redirected to a desirable location. This is preferred, because it is going 68redirected to a desirable location. This is preferred, because it is going
@@ -305,7 +305,7 @@ Before the call, hdr, data, and alloc should be filled. Upon return, the area
305pointed by hdr contains the next event structure, and the data buffer contains 305pointed by hdr contains the next event structure, and the data buffer contains
306the data, if any. The event is removed from the kernel buffer. 306the data, if any. The event is removed from the kernel buffer.
307 307
308The MON_IOCX_GET copies 48 bytes, MON_IOCX_GETX copies 64 bytes. 308The MON_IOCX_GET copies 48 bytes to hdr area, MON_IOCX_GETX copies 64 bytes.
309 309
310 MON_IOCX_MFETCH, defined as _IOWR(MON_IOC_MAGIC, 7, struct mon_mfetch_arg) 310 MON_IOCX_MFETCH, defined as _IOWR(MON_IOC_MAGIC, 7, struct mon_mfetch_arg)
311 311
diff --git a/Documentation/video4linux/v4lgrab.c b/Documentation/video4linux/v4lgrab.c
index 05769cff1009..c8ded175796e 100644
--- a/Documentation/video4linux/v4lgrab.c
+++ b/Documentation/video4linux/v4lgrab.c
@@ -89,7 +89,7 @@
89 } \ 89 } \
90} 90}
91 91
92int get_brightness_adj(unsigned char *image, long size, int *brightness) { 92static int get_brightness_adj(unsigned char *image, long size, int *brightness) {
93 long i, tot = 0; 93 long i, tot = 0;
94 for (i=0;i<size*3;i++) 94 for (i=0;i<size*3;i++)
95 tot += image[i]; 95 tot += image[i];
diff --git a/Documentation/vm/page-types.c b/Documentation/vm/page-types.c
index 0833f44ba16b..3eda8ea00852 100644
--- a/Documentation/vm/page-types.c
+++ b/Documentation/vm/page-types.c
@@ -158,12 +158,12 @@ static uint64_t page_flags[HASH_SIZE];
158 type __min2 = (y); \ 158 type __min2 = (y); \
159 __min1 < __min2 ? __min1 : __min2; }) 159 __min1 < __min2 ? __min1 : __min2; })
160 160
161unsigned long pages2mb(unsigned long pages) 161static unsigned long pages2mb(unsigned long pages)
162{ 162{
163 return (pages * page_size) >> 20; 163 return (pages * page_size) >> 20;
164} 164}
165 165
166void fatal(const char *x, ...) 166static void fatal(const char *x, ...)
167{ 167{
168 va_list ap; 168 va_list ap;
169 169
@@ -178,7 +178,7 @@ void fatal(const char *x, ...)
178 * page flag names 178 * page flag names
179 */ 179 */
180 180
181char *page_flag_name(uint64_t flags) 181static char *page_flag_name(uint64_t flags)
182{ 182{
183 static char buf[65]; 183 static char buf[65];
184 int present; 184 int present;
@@ -197,7 +197,7 @@ char *page_flag_name(uint64_t flags)
197 return buf; 197 return buf;
198} 198}
199 199
200char *page_flag_longname(uint64_t flags) 200static char *page_flag_longname(uint64_t flags)
201{ 201{
202 static char buf[1024]; 202 static char buf[1024];
203 int i, n; 203 int i, n;
@@ -221,7 +221,7 @@ char *page_flag_longname(uint64_t flags)
221 * page list and summary 221 * page list and summary
222 */ 222 */
223 223
224void show_page_range(unsigned long offset, uint64_t flags) 224static void show_page_range(unsigned long offset, uint64_t flags)
225{ 225{
226 static uint64_t flags0; 226 static uint64_t flags0;
227 static unsigned long index; 227 static unsigned long index;
@@ -241,12 +241,12 @@ void show_page_range(unsigned long offset, uint64_t flags)
241 count = 1; 241 count = 1;
242} 242}
243 243
244void show_page(unsigned long offset, uint64_t flags) 244static void show_page(unsigned long offset, uint64_t flags)
245{ 245{
246 printf("%lu\t%s\n", offset, page_flag_name(flags)); 246 printf("%lu\t%s\n", offset, page_flag_name(flags));
247} 247}
248 248
249void show_summary(void) 249static void show_summary(void)
250{ 250{
251 int i; 251 int i;
252 252
@@ -272,7 +272,7 @@ void show_summary(void)
272 * page flag filters 272 * page flag filters
273 */ 273 */
274 274
275int bit_mask_ok(uint64_t flags) 275static int bit_mask_ok(uint64_t flags)
276{ 276{
277 int i; 277 int i;
278 278
@@ -289,7 +289,7 @@ int bit_mask_ok(uint64_t flags)
289 return 1; 289 return 1;
290} 290}
291 291
292uint64_t expand_overloaded_flags(uint64_t flags) 292static uint64_t expand_overloaded_flags(uint64_t flags)
293{ 293{
294 /* SLOB/SLUB overload several page flags */ 294 /* SLOB/SLUB overload several page flags */
295 if (flags & BIT(SLAB)) { 295 if (flags & BIT(SLAB)) {
@@ -308,7 +308,7 @@ uint64_t expand_overloaded_flags(uint64_t flags)
308 return flags; 308 return flags;
309} 309}
310 310
311uint64_t well_known_flags(uint64_t flags) 311static uint64_t well_known_flags(uint64_t flags)
312{ 312{
313 /* hide flags intended only for kernel hacker */ 313 /* hide flags intended only for kernel hacker */
314 flags &= ~KPF_HACKERS_BITS; 314 flags &= ~KPF_HACKERS_BITS;
@@ -325,7 +325,7 @@ uint64_t well_known_flags(uint64_t flags)
325 * page frame walker 325 * page frame walker
326 */ 326 */
327 327
328int hash_slot(uint64_t flags) 328static int hash_slot(uint64_t flags)
329{ 329{
330 int k = HASH_KEY(flags); 330 int k = HASH_KEY(flags);
331 int i; 331 int i;
@@ -352,7 +352,7 @@ int hash_slot(uint64_t flags)
352 exit(EXIT_FAILURE); 352 exit(EXIT_FAILURE);
353} 353}
354 354
355void add_page(unsigned long offset, uint64_t flags) 355static void add_page(unsigned long offset, uint64_t flags)
356{ 356{
357 flags = expand_overloaded_flags(flags); 357 flags = expand_overloaded_flags(flags);
358 358
@@ -371,7 +371,7 @@ void add_page(unsigned long offset, uint64_t flags)
371 total_pages++; 371 total_pages++;
372} 372}
373 373
374void walk_pfn(unsigned long index, unsigned long count) 374static void walk_pfn(unsigned long index, unsigned long count)
375{ 375{
376 unsigned long batch; 376 unsigned long batch;
377 unsigned long n; 377 unsigned long n;
@@ -404,7 +404,7 @@ void walk_pfn(unsigned long index, unsigned long count)
404 } 404 }
405} 405}
406 406
407void walk_addr_ranges(void) 407static void walk_addr_ranges(void)
408{ 408{
409 int i; 409 int i;
410 410
@@ -428,7 +428,7 @@ void walk_addr_ranges(void)
428 * user interface 428 * user interface
429 */ 429 */
430 430
431const char *page_flag_type(uint64_t flag) 431static const char *page_flag_type(uint64_t flag)
432{ 432{
433 if (flag & KPF_HACKERS_BITS) 433 if (flag & KPF_HACKERS_BITS)
434 return "(r)"; 434 return "(r)";
@@ -437,7 +437,7 @@ const char *page_flag_type(uint64_t flag)
437 return " "; 437 return " ";
438} 438}
439 439
440void usage(void) 440static void usage(void)
441{ 441{
442 int i, j; 442 int i, j;
443 443
@@ -482,7 +482,7 @@ void usage(void)
482 "(r) raw mode bits (o) overloaded bits\n"); 482 "(r) raw mode bits (o) overloaded bits\n");
483} 483}
484 484
485unsigned long long parse_number(const char *str) 485static unsigned long long parse_number(const char *str)
486{ 486{
487 unsigned long long n; 487 unsigned long long n;
488 488
@@ -494,16 +494,16 @@ unsigned long long parse_number(const char *str)
494 return n; 494 return n;
495} 495}
496 496
497void parse_pid(const char *str) 497static void parse_pid(const char *str)
498{ 498{
499 opt_pid = parse_number(str); 499 opt_pid = parse_number(str);
500} 500}
501 501
502void parse_file(const char *name) 502static void parse_file(const char *name)
503{ 503{
504} 504}
505 505
506void add_addr_range(unsigned long offset, unsigned long size) 506static void add_addr_range(unsigned long offset, unsigned long size)
507{ 507{
508 if (nr_addr_ranges >= MAX_ADDR_RANGES) 508 if (nr_addr_ranges >= MAX_ADDR_RANGES)
509 fatal("too much addr ranges\n"); 509 fatal("too much addr ranges\n");
@@ -513,7 +513,7 @@ void add_addr_range(unsigned long offset, unsigned long size)
513 nr_addr_ranges++; 513 nr_addr_ranges++;
514} 514}
515 515
516void parse_addr_range(const char *optarg) 516static void parse_addr_range(const char *optarg)
517{ 517{
518 unsigned long offset; 518 unsigned long offset;
519 unsigned long size; 519 unsigned long size;
@@ -547,7 +547,7 @@ void parse_addr_range(const char *optarg)
547 add_addr_range(offset, size); 547 add_addr_range(offset, size);
548} 548}
549 549
550void add_bits_filter(uint64_t mask, uint64_t bits) 550static void add_bits_filter(uint64_t mask, uint64_t bits)
551{ 551{
552 if (nr_bit_filters >= MAX_BIT_FILTERS) 552 if (nr_bit_filters >= MAX_BIT_FILTERS)
553 fatal("too much bit filters\n"); 553 fatal("too much bit filters\n");
@@ -557,7 +557,7 @@ void add_bits_filter(uint64_t mask, uint64_t bits)
557 nr_bit_filters++; 557 nr_bit_filters++;
558} 558}
559 559
560uint64_t parse_flag_name(const char *str, int len) 560static uint64_t parse_flag_name(const char *str, int len)
561{ 561{
562 int i; 562 int i;
563 563
@@ -577,7 +577,7 @@ uint64_t parse_flag_name(const char *str, int len)
577 return parse_number(str); 577 return parse_number(str);
578} 578}
579 579
580uint64_t parse_flag_names(const char *str, int all) 580static uint64_t parse_flag_names(const char *str, int all)
581{ 581{
582 const char *p = str; 582 const char *p = str;
583 uint64_t flags = 0; 583 uint64_t flags = 0;
@@ -596,7 +596,7 @@ uint64_t parse_flag_names(const char *str, int all)
596 return flags; 596 return flags;
597} 597}
598 598
599void parse_bits_mask(const char *optarg) 599static void parse_bits_mask(const char *optarg)
600{ 600{
601 uint64_t mask; 601 uint64_t mask;
602 uint64_t bits; 602 uint64_t bits;
@@ -621,7 +621,7 @@ void parse_bits_mask(const char *optarg)
621} 621}
622 622
623 623
624struct option opts[] = { 624static struct option opts[] = {
625 { "raw" , 0, NULL, 'r' }, 625 { "raw" , 0, NULL, 'r' },
626 { "pid" , 1, NULL, 'p' }, 626 { "pid" , 1, NULL, 'p' },
627 { "file" , 1, NULL, 'f' }, 627 { "file" , 1, NULL, 'f' },
diff --git a/Documentation/vm/slabinfo.c b/Documentation/vm/slabinfo.c
index df3227605d59..92e729f4b676 100644
--- a/Documentation/vm/slabinfo.c
+++ b/Documentation/vm/slabinfo.c
@@ -87,7 +87,7 @@ int page_size;
87 87
88regex_t pattern; 88regex_t pattern;
89 89
90void fatal(const char *x, ...) 90static void fatal(const char *x, ...)
91{ 91{
92 va_list ap; 92 va_list ap;
93 93
@@ -97,7 +97,7 @@ void fatal(const char *x, ...)
97 exit(EXIT_FAILURE); 97 exit(EXIT_FAILURE);
98} 98}
99 99
100void usage(void) 100static void usage(void)
101{ 101{
102 printf("slabinfo 5/7/2007. (c) 2007 sgi.\n\n" 102 printf("slabinfo 5/7/2007. (c) 2007 sgi.\n\n"
103 "slabinfo [-ahnpvtsz] [-d debugopts] [slab-regexp]\n" 103 "slabinfo [-ahnpvtsz] [-d debugopts] [slab-regexp]\n"
@@ -131,7 +131,7 @@ void usage(void)
131 ); 131 );
132} 132}
133 133
134unsigned long read_obj(const char *name) 134static unsigned long read_obj(const char *name)
135{ 135{
136 FILE *f = fopen(name, "r"); 136 FILE *f = fopen(name, "r");
137 137
@@ -151,7 +151,7 @@ unsigned long read_obj(const char *name)
151/* 151/*
152 * Get the contents of an attribute 152 * Get the contents of an attribute
153 */ 153 */
154unsigned long get_obj(const char *name) 154static unsigned long get_obj(const char *name)
155{ 155{
156 if (!read_obj(name)) 156 if (!read_obj(name))
157 return 0; 157 return 0;
@@ -159,7 +159,7 @@ unsigned long get_obj(const char *name)
159 return atol(buffer); 159 return atol(buffer);
160} 160}
161 161
162unsigned long get_obj_and_str(const char *name, char **x) 162static unsigned long get_obj_and_str(const char *name, char **x)
163{ 163{
164 unsigned long result = 0; 164 unsigned long result = 0;
165 char *p; 165 char *p;
@@ -178,7 +178,7 @@ unsigned long get_obj_and_str(const char *name, char **x)
178 return result; 178 return result;
179} 179}
180 180
181void set_obj(struct slabinfo *s, const char *name, int n) 181static void set_obj(struct slabinfo *s, const char *name, int n)
182{ 182{
183 char x[100]; 183 char x[100];
184 FILE *f; 184 FILE *f;
@@ -192,7 +192,7 @@ void set_obj(struct slabinfo *s, const char *name, int n)
192 fclose(f); 192 fclose(f);
193} 193}
194 194
195unsigned long read_slab_obj(struct slabinfo *s, const char *name) 195static unsigned long read_slab_obj(struct slabinfo *s, const char *name)
196{ 196{
197 char x[100]; 197 char x[100];
198 FILE *f; 198 FILE *f;
@@ -215,7 +215,7 @@ unsigned long read_slab_obj(struct slabinfo *s, const char *name)
215/* 215/*
216 * Put a size string together 216 * Put a size string together
217 */ 217 */
218int store_size(char *buffer, unsigned long value) 218static int store_size(char *buffer, unsigned long value)
219{ 219{
220 unsigned long divisor = 1; 220 unsigned long divisor = 1;
221 char trailer = 0; 221 char trailer = 0;
@@ -247,7 +247,7 @@ int store_size(char *buffer, unsigned long value)
247 return n; 247 return n;
248} 248}
249 249
250void decode_numa_list(int *numa, char *t) 250static void decode_numa_list(int *numa, char *t)
251{ 251{
252 int node; 252 int node;
253 int nr; 253 int nr;
@@ -272,7 +272,7 @@ void decode_numa_list(int *numa, char *t)
272 } 272 }
273} 273}
274 274
275void slab_validate(struct slabinfo *s) 275static void slab_validate(struct slabinfo *s)
276{ 276{
277 if (strcmp(s->name, "*") == 0) 277 if (strcmp(s->name, "*") == 0)
278 return; 278 return;
@@ -280,7 +280,7 @@ void slab_validate(struct slabinfo *s)
280 set_obj(s, "validate", 1); 280 set_obj(s, "validate", 1);
281} 281}
282 282
283void slab_shrink(struct slabinfo *s) 283static void slab_shrink(struct slabinfo *s)
284{ 284{
285 if (strcmp(s->name, "*") == 0) 285 if (strcmp(s->name, "*") == 0)
286 return; 286 return;
@@ -290,7 +290,7 @@ void slab_shrink(struct slabinfo *s)
290 290
291int line = 0; 291int line = 0;
292 292
293void first_line(void) 293static void first_line(void)
294{ 294{
295 if (show_activity) 295 if (show_activity)
296 printf("Name Objects Alloc Free %%Fast Fallb O\n"); 296 printf("Name Objects Alloc Free %%Fast Fallb O\n");
@@ -302,7 +302,7 @@ void first_line(void)
302/* 302/*
303 * Find the shortest alias of a slab 303 * Find the shortest alias of a slab
304 */ 304 */
305struct aliasinfo *find_one_alias(struct slabinfo *find) 305static struct aliasinfo *find_one_alias(struct slabinfo *find)
306{ 306{
307 struct aliasinfo *a; 307 struct aliasinfo *a;
308 struct aliasinfo *best = NULL; 308 struct aliasinfo *best = NULL;
@@ -318,18 +318,18 @@ struct aliasinfo *find_one_alias(struct slabinfo *find)
318 return best; 318 return best;
319} 319}
320 320
321unsigned long slab_size(struct slabinfo *s) 321static unsigned long slab_size(struct slabinfo *s)
322{ 322{
323 return s->slabs * (page_size << s->order); 323 return s->slabs * (page_size << s->order);
324} 324}
325 325
326unsigned long slab_activity(struct slabinfo *s) 326static unsigned long slab_activity(struct slabinfo *s)
327{ 327{
328 return s->alloc_fastpath + s->free_fastpath + 328 return s->alloc_fastpath + s->free_fastpath +
329 s->alloc_slowpath + s->free_slowpath; 329 s->alloc_slowpath + s->free_slowpath;
330} 330}
331 331
332void slab_numa(struct slabinfo *s, int mode) 332static void slab_numa(struct slabinfo *s, int mode)
333{ 333{
334 int node; 334 int node;
335 335
@@ -374,7 +374,7 @@ void slab_numa(struct slabinfo *s, int mode)
374 line++; 374 line++;
375} 375}
376 376
377void show_tracking(struct slabinfo *s) 377static void show_tracking(struct slabinfo *s)
378{ 378{
379 printf("\n%s: Kernel object allocation\n", s->name); 379 printf("\n%s: Kernel object allocation\n", s->name);
380 printf("-----------------------------------------------------------------------\n"); 380 printf("-----------------------------------------------------------------------\n");
@@ -392,7 +392,7 @@ void show_tracking(struct slabinfo *s)
392 392
393} 393}
394 394
395void ops(struct slabinfo *s) 395static void ops(struct slabinfo *s)
396{ 396{
397 if (strcmp(s->name, "*") == 0) 397 if (strcmp(s->name, "*") == 0)
398 return; 398 return;
@@ -405,14 +405,14 @@ void ops(struct slabinfo *s)
405 printf("\n%s has no kmem_cache operations\n", s->name); 405 printf("\n%s has no kmem_cache operations\n", s->name);
406} 406}
407 407
408const char *onoff(int x) 408static const char *onoff(int x)
409{ 409{
410 if (x) 410 if (x)
411 return "On "; 411 return "On ";
412 return "Off"; 412 return "Off";
413} 413}
414 414
415void slab_stats(struct slabinfo *s) 415static void slab_stats(struct slabinfo *s)
416{ 416{
417 unsigned long total_alloc; 417 unsigned long total_alloc;
418 unsigned long total_free; 418 unsigned long total_free;
@@ -477,7 +477,7 @@ void slab_stats(struct slabinfo *s)
477 s->deactivate_to_tail, (s->deactivate_to_tail * 100) / total); 477 s->deactivate_to_tail, (s->deactivate_to_tail * 100) / total);
478} 478}
479 479
480void report(struct slabinfo *s) 480static void report(struct slabinfo *s)
481{ 481{
482 if (strcmp(s->name, "*") == 0) 482 if (strcmp(s->name, "*") == 0)
483 return; 483 return;
@@ -518,7 +518,7 @@ void report(struct slabinfo *s)
518 slab_stats(s); 518 slab_stats(s);
519} 519}
520 520
521void slabcache(struct slabinfo *s) 521static void slabcache(struct slabinfo *s)
522{ 522{
523 char size_str[20]; 523 char size_str[20];
524 char dist_str[40]; 524 char dist_str[40];
@@ -593,7 +593,7 @@ void slabcache(struct slabinfo *s)
593/* 593/*
594 * Analyze debug options. Return false if something is amiss. 594 * Analyze debug options. Return false if something is amiss.
595 */ 595 */
596int debug_opt_scan(char *opt) 596static int debug_opt_scan(char *opt)
597{ 597{
598 if (!opt || !opt[0] || strcmp(opt, "-") == 0) 598 if (!opt || !opt[0] || strcmp(opt, "-") == 0)
599 return 1; 599 return 1;
@@ -642,7 +642,7 @@ int debug_opt_scan(char *opt)
642 return 1; 642 return 1;
643} 643}
644 644
645int slab_empty(struct slabinfo *s) 645static int slab_empty(struct slabinfo *s)
646{ 646{
647 if (s->objects > 0) 647 if (s->objects > 0)
648 return 0; 648 return 0;
@@ -657,7 +657,7 @@ int slab_empty(struct slabinfo *s)
657 return 1; 657 return 1;
658} 658}
659 659
660void slab_debug(struct slabinfo *s) 660static void slab_debug(struct slabinfo *s)
661{ 661{
662 if (strcmp(s->name, "*") == 0) 662 if (strcmp(s->name, "*") == 0)
663 return; 663 return;
@@ -717,7 +717,7 @@ void slab_debug(struct slabinfo *s)
717 set_obj(s, "trace", 1); 717 set_obj(s, "trace", 1);
718} 718}
719 719
720void totals(void) 720static void totals(void)
721{ 721{
722 struct slabinfo *s; 722 struct slabinfo *s;
723 723
@@ -976,7 +976,7 @@ void totals(void)
976 b1, b2, b3); 976 b1, b2, b3);
977} 977}
978 978
979void sort_slabs(void) 979static void sort_slabs(void)
980{ 980{
981 struct slabinfo *s1,*s2; 981 struct slabinfo *s1,*s2;
982 982
@@ -1005,7 +1005,7 @@ void sort_slabs(void)
1005 } 1005 }
1006} 1006}
1007 1007
1008void sort_aliases(void) 1008static void sort_aliases(void)
1009{ 1009{
1010 struct aliasinfo *a1,*a2; 1010 struct aliasinfo *a1,*a2;
1011 1011
@@ -1030,7 +1030,7 @@ void sort_aliases(void)
1030 } 1030 }
1031} 1031}
1032 1032
1033void link_slabs(void) 1033static void link_slabs(void)
1034{ 1034{
1035 struct aliasinfo *a; 1035 struct aliasinfo *a;
1036 struct slabinfo *s; 1036 struct slabinfo *s;
@@ -1048,7 +1048,7 @@ void link_slabs(void)
1048 } 1048 }
1049} 1049}
1050 1050
1051void alias(void) 1051static void alias(void)
1052{ 1052{
1053 struct aliasinfo *a; 1053 struct aliasinfo *a;
1054 char *active = NULL; 1054 char *active = NULL;
@@ -1079,7 +1079,7 @@ void alias(void)
1079} 1079}
1080 1080
1081 1081
1082void rename_slabs(void) 1082static void rename_slabs(void)
1083{ 1083{
1084 struct slabinfo *s; 1084 struct slabinfo *s;
1085 struct aliasinfo *a; 1085 struct aliasinfo *a;
@@ -1102,12 +1102,12 @@ void rename_slabs(void)
1102 } 1102 }
1103} 1103}
1104 1104
1105int slab_mismatch(char *slab) 1105static int slab_mismatch(char *slab)
1106{ 1106{
1107 return regexec(&pattern, slab, 0, NULL, 0); 1107 return regexec(&pattern, slab, 0, NULL, 0);
1108} 1108}
1109 1109
1110void read_slab_dir(void) 1110static void read_slab_dir(void)
1111{ 1111{
1112 DIR *dir; 1112 DIR *dir;
1113 struct dirent *de; 1113 struct dirent *de;
@@ -1209,7 +1209,7 @@ void read_slab_dir(void)
1209 fatal("Too many aliases\n"); 1209 fatal("Too many aliases\n");
1210} 1210}
1211 1211
1212void output_slabs(void) 1212static void output_slabs(void)
1213{ 1213{
1214 struct slabinfo *slab; 1214 struct slabinfo *slab;
1215 1215
diff --git a/Documentation/watchdog/src/watchdog-test.c b/Documentation/watchdog/src/watchdog-test.c
index 65f6c19cb865..a750532ffcf8 100644
--- a/Documentation/watchdog/src/watchdog-test.c
+++ b/Documentation/watchdog/src/watchdog-test.c
@@ -18,7 +18,7 @@ int fd;
18 * the PC Watchdog card to reset its internal timer so it doesn't trigger 18 * the PC Watchdog card to reset its internal timer so it doesn't trigger
19 * a computer reset. 19 * a computer reset.
20 */ 20 */
21void keep_alive(void) 21static void keep_alive(void)
22{ 22{
23 int dummy; 23 int dummy;
24 24
diff --git a/Documentation/x86/earlyprintk.txt b/Documentation/x86/earlyprintk.txt
index 607b1a016064..f19802c0f485 100644
--- a/Documentation/x86/earlyprintk.txt
+++ b/Documentation/x86/earlyprintk.txt
@@ -7,7 +7,7 @@ and two USB cables, connected like this:
7 7
8 [host/target] <-------> [USB debug key] <-------> [client/console] 8 [host/target] <-------> [USB debug key] <-------> [client/console]
9 9
101. There are three specific hardware requirements: 101. There are a number of specific hardware requirements:
11 11
12 a.) Host/target system needs to have USB debug port capability. 12 a.) Host/target system needs to have USB debug port capability.
13 13
@@ -42,7 +42,35 @@ and two USB cables, connected like this:
42 This is a small blue plastic connector with two USB connections, 42 This is a small blue plastic connector with two USB connections,
43 it draws power from its USB connections. 43 it draws power from its USB connections.
44 44
45 c.) Thirdly, you need a second client/console system with a regular USB port. 45 c.) You need a second client/console system with a high speed USB 2.0
46 port.
47
48 d.) The Netchip device must be plugged directly into the physical
49 debug port on the "host/target" system. You cannot use a USB hub in
50 between the physical debug port and the "host/target" system.
51
52 The EHCI debug controller is bound to a specific physical USB
53 port and the Netchip device will only work as an early printk
54 device in this port. The EHCI host controllers are electrically
55 wired such that the EHCI debug controller is hooked up to the
56 first physical and there is no way to change this via software.
57 You can find the physical port through experimentation by trying
58 each physical port on the system and rebooting. Or you can try
59 and use lsusb or look at the kernel info messages emitted by the
60 usb stack when you plug a usb device into various ports on the
61 "host/target" system.
62
63 Some hardware vendors do not expose the usb debug port with a
64 physical connector and if you find such a device send a complaint
65 to the hardware vendor, because there is no reason not to wire
66 this port into one of the physically accessible ports.
67
68 e.) It is also important to note, that many versions of the Netchip
69 device require the "client/console" system to be plugged into the
70 right and side of the device (with the product logo facing up and
71 readable left to right). The reason being is that the 5 volt
72 power supply is taken from only one side of the device and it
73 must be the side that does not get rebooted.
46 74
472. Software requirements: 752. Software requirements:
48 76
@@ -56,6 +84,13 @@ and two USB cables, connected like this:
56 (If you are using Grub, append it to the 'kernel' line in 84 (If you are using Grub, append it to the 'kernel' line in
57 /etc/grub.conf) 85 /etc/grub.conf)
58 86
87 On systems with more than one EHCI debug controller you must
88 specify the correct EHCI debug controller number. The ordering
89 comes from the PCI bus enumeration of the EHCI controllers. The
90 default with no number argument is "0" the first EHCI debug
91 controller. To use the second EHCI debug controller, you would
92 use the command line: "earlyprintk=dbgp1"
93
59 NOTE: normally earlyprintk console gets turned off once the 94 NOTE: normally earlyprintk console gets turned off once the
60 regular console is alive - use "earlyprintk=dbgp,keep" to keep 95 regular console is alive - use "earlyprintk=dbgp,keep" to keep
61 this channel open beyond early bootup. This can be useful for 96 this channel open beyond early bootup. This can be useful for