diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2008-03-26 15:12:11 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2008-03-26 15:12:11 +0000 |
commit | 25a9c17f558e74adc5ccaf9f55cd04e09ffb25a8 (patch) | |
tree | 4b3882caea9b422313fab4d35ca2e7cddfa74a81 | |
parent | c6dbb85c9eb513cde3d5809e0a96c77ed655dd4b (diff) | |
download | busybox-w32-25a9c17f558e74adc5ccaf9f55cd04e09ffb25a8.tar.gz busybox-w32-25a9c17f558e74adc5ccaf9f55cd04e09ffb25a8.tar.bz2 busybox-w32-25a9c17f558e74adc5ccaf9f55cd04e09ffb25a8.zip |
fbsplash: cosmetic comment and Config text fixes; rename .ini -> .cfg
-rw-r--r-- | miscutils/Config.in | 14 | ||||
-rw-r--r-- | miscutils/fbsplash.c | 27 | ||||
-rw-r--r-- | miscutils/fbsplash.cfg (renamed from miscutils/fbsplash.ini) | 0 |
3 files changed, 15 insertions, 26 deletions
diff --git a/miscutils/Config.in b/miscutils/Config.in index 04c9a0c54..e740a4451 100644 --- a/miscutils/Config.in +++ b/miscutils/Config.in | |||
@@ -209,14 +209,14 @@ config FBSPLASH | |||
209 | Can be used during boot phase of an embedded device. ~2kb. | 209 | Can be used during boot phase of an embedded device. ~2kb. |
210 | Usage: | 210 | Usage: |
211 | - use kernel option 'vga=xxx' or otherwise enable fb device. | 211 | - use kernel option 'vga=xxx' or otherwise enable fb device. |
212 | - put somewhere the fbsplash.ini file and image in .ppm format. | 212 | - put somewhere fbsplash.cfg file and an image in .ppm format. |
213 | - $ setsid fbsplash [params] & | 213 | - $ setsid fbsplash [params] & |
214 | -c: hide cursor | 214 | -c: hide cursor |
215 | -d /dev/fbN: framebuffer device (if not /dev/fb0) | 215 | -d /dev/fbN: framebuffer device (if not /dev/fb0) |
216 | -s path_of_image_file | 216 | -s path_to_image_file (can be "-" for stdin) |
217 | -i path_of_ini_file | 217 | -i path_to_cfg_file |
218 | -f path_of_fifo (can be "-" for stdin) | 218 | -f path_to_fifo (can be "-" for stdin) |
219 | - if you want to run applet only in presence of kernel parameter: | 219 | - if you want to run it only in presence of kernel parameter: |
220 | grep -q "fbsplash=on" </proc/cmdline && setsid fbsplash [params] & | 220 | grep -q "fbsplash=on" </proc/cmdline && setsid fbsplash [params] & |
221 | - commands for fifo: | 221 | - commands for fifo: |
222 | "NN" (ASCII decimal number) - percentage to show on progress bar | 222 | "NN" (ASCII decimal number) - percentage to show on progress bar |
diff --git a/miscutils/fbsplash.c b/miscutils/fbsplash.c index d82bab499..a40c585a0 100644 --- a/miscutils/fbsplash.c +++ b/miscutils/fbsplash.c | |||
@@ -1,7 +1,5 @@ | |||
1 | /* vi: set sw=4 ts=4: */ | 1 | /* vi: set sw=4 ts=4: */ |
2 | /* | 2 | /* |
3 | * splash implementation for busybox | ||
4 | * | ||
5 | * Copyright (C) 2008 Michele Sanges <michele.sanges@otomelara.it>, | 3 | * Copyright (C) 2008 Michele Sanges <michele.sanges@otomelara.it>, |
6 | * <michele.sanges@gmail.it> | 4 | * <michele.sanges@gmail.it> |
7 | * | 5 | * |
@@ -9,34 +7,25 @@ | |||
9 | * | 7 | * |
10 | * Usage: | 8 | * Usage: |
11 | * - use kernel option 'vga=xxx' or otherwise enable framebuffer device. | 9 | * - use kernel option 'vga=xxx' or otherwise enable framebuffer device. |
12 | * - put somewhere the fbsplash.ini file and image in .ppm format. | 10 | * - put somewhere fbsplash.cfg file and an image in .ppm format. |
13 | * - configure applet by editing .ini file. | ||
14 | * - run applet: $ setsid fbsplash [params] & | 11 | * - run applet: $ setsid fbsplash [params] & |
15 | * -c: hide cursor | 12 | * -c: hide cursor |
16 | * -d /dev/fbN: framebuffer device (if not /dev/fb0) | 13 | * -d /dev/fbN: framebuffer device (if not /dev/fb0) |
17 | * -s path_of_image_file | 14 | * -s path_to_image_file (can be "-" for stdin) |
18 | * -i path_of_ini_file | 15 | * -i path_to_cfg_file |
19 | * -f path_of_fifo (can be "-" for stdin) | 16 | * -f path_to_fifo (can be "-" for stdin) |
20 | * - if you want to run the applet only in presence of a kernel parameter | 17 | * - if you want to run it only in presence of a kernel parameter |
21 | * (for example fbsplash=on), type: | 18 | * (for example fbsplash=on), use: |
22 | * grep -q "fbsplash=on" </proc/cmdline && setsid fbsplash [params] | 19 | * grep -q "fbsplash=on" </proc/cmdline && setsid fbsplash [params] |
23 | * - commands for fifo: | 20 | * - commands for fifo: |
24 | * "NN" (ASCII decimal number) - percentage to show on progress bar. | 21 | * "NN" (ASCII decimal number) - percentage to show on progress bar. |
25 | * "exit" (or just close fifo) - well you guessed it. | 22 | * "exit" (or just close fifo) - well you guessed it. |
26 | */ | 23 | */ |
27 | 24 | ||
28 | /** | ||
29 | * Splash implementation for busybox | ||
30 | * \file: fbsplash.c | ||
31 | * \author Michele Sanges <michele.sanges@otomelara.it> <michele.sanges@gmail.com> | ||
32 | * \version 1.0.0 | ||
33 | * \date 07/03/2008 | ||
34 | */ | ||
35 | |||
36 | #include "libbb.h" | 25 | #include "libbb.h" |
37 | #include <linux/fb.h> | 26 | #include <linux/fb.h> |
38 | 27 | ||
39 | /* If you want logging messages on /tmp/fbsplash_log... */ | 28 | /* If you want logging messages on /tmp/fbsplash.log... */ |
40 | #define DEBUG 0 | 29 | #define DEBUG 0 |
41 | 30 | ||
42 | #define BYTES_PER_PIXEL 2 | 31 | #define BYTES_PER_PIXEL 2 |
@@ -355,7 +344,7 @@ static void init(const char *ini_filename) | |||
355 | case 7: | 344 | case 7: |
356 | G.bdebug_messages = val; | 345 | G.bdebug_messages = val; |
357 | if (G.bdebug_messages) | 346 | if (G.bdebug_messages) |
358 | G.logfile_fd = xfopen("/tmp/fbsplash_log", "w"); | 347 | G.logfile_fd = xfopen("/tmp/fbsplash.log", "w"); |
359 | break; | 348 | break; |
360 | #endif | 349 | #endif |
361 | err: | 350 | err: |
diff --git a/miscutils/fbsplash.ini b/miscutils/fbsplash.cfg index b6cf607eb..b6cf607eb 100644 --- a/miscutils/fbsplash.ini +++ b/miscutils/fbsplash.cfg | |||