summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* discover/platform: Add boot device to config dumpJeremy Kerr2014-09-181-0/+3
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* po: Add initial translationsJeremy Kerr2014-09-1813-1/+5444
| | | | | | | Add the initial translation set for de, en, es, fr, it, ja, ko, pt_BR, ru, zh_CN and zh_TW languages. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Correctly size pad for config screenSamuel Mendoza-Jonas2014-09-101-5/+10
| | | | | Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Help string fixesJeremy Kerr2014-09-043-10/+10
| | | | | | | | The Configuration screen help doesn't reflect the option name, so update that to match. Also, fix the wording of the "Rescan devices" help. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Exit safe mode on configuration changeSamuel Mendoza-Jonas2014-09-043-3/+31
| | | | | | | | | | Selecting 'OK' in the configuration or language select screen will send a configuration change to the server and exit safe mode. Exit safe mode explicity and warn the user that they are about to exit it. Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Reject ADD_URL actions without configured networkSamuel Mendoza-Jonas2014-09-042-1/+10
| | | | | Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Implement PXE SYSAPPEND syntaxJeremy Kerr2014-08-253-1/+83
| | | | | | | This change implements SYSAPPEND/IPAPPEND 2, to add a BOOTIF argument to the kernel command line. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Update 'add-url' help messageSamuel Mendoza-Jonas2014-08-252-13/+13
| | | | | | | We should make it clear that we're looking for a PXE-style config file. Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Add new main menu options to help screenJeremy Kerr2014-08-212-1/+25
| | | | | | | The language, rescan and retrieve options are new, so add them to the help text. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Make device labels translateableJeremy Kerr2014-08-212-6/+18
| | | | | | | | | | We're not using gettext for the device label strings; this change adds the necessary macros to do so. Also, we change "Interface" to "Network", to make the label a little more obvious. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover/platform-powerpc: Fix incorrect device tree directoryJeremy Kerr2014-08-071-3/+8
| | | | | | | It's /proc/device-tree, not /proc/device_tree. Use a variable to hold this prefix. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* version.sh: Don't use dashes in version numbersJeremy Kerr2014-08-051-2/+2
| | | | | | ... as they're not valid for RPM. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Add debug flag to configJeremy Kerr2014-08-058-14/+45
| | | | | | | | | | This change adds a debug flag to the config, and groups it under not-user-modifiable parts of struct config. This means we no longer need the pb-sysinfo helper, as the last remaining function (--debug-enabled) can be implemented with pb-config. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Use platform code to read sysinfo type and identifierJeremy Kerr2014-08-055-41/+31
| | | | | | | | | | | | | | | | This change uses the platform-specific code to read the system type and identifier, rather than the pb-sysinfo utility. We introduce a new callback for struct platform: int (*get_sysinfo)(struct platform *, struct system_info *); - which populates struct system_info with appropriate information. This means that the system-specific code is kept in one place; rather than having powerpc-specific device-tree-reading code in the pb-sysinfo shell script. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* lib: Move generic file-handling code to lib/Jeremy Kerr2014-08-057-9/+5
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* utils: Add pb-config utilityJeremy Kerr2014-08-052-2/+124
| | | | | | A simple tool to query platform configuration. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Move platform config to a .roJeremy Kerr2014-08-051-3/+10
| | | | | | | We want to allow an external utility to use the platform config code, so build it into a .ro, which is then linked to the discover code. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover/grub2: distinguish parser.h from grub2/parser.hJeremy Kerr2014-08-054-18/+19
| | | | | | | | | | | | | 'make distcheck' will do a 'make all' srcdir == objdir, then later a 'make check' sith srcdir != objdir. Since gcc's cpp always assumes that a source file's directory is first in the include paths, we may see discover/parser.h included when we wanted the generated discover/grub2/parser.h. This change renames the grub2 lexer and parser files, to work-around this behaviour, and fix 'make distcheck'. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* automake: silence make outputJeremy Kerr2014-08-054-11/+9
| | | | | | | | | Currently, we get a lot of noise out of the build process; automake supports V={0,1}, which we can use to suppress the output a little. This needs a few cleanups for custom commands. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* autotools: Don't link udev into everythingJeremy Kerr2014-08-052-5/+4
| | | | | | | | By default, AC_CHECK_LIB will append to $LIBS, which is used for all link stages. Intstead, we should popuate $UDEV_LIBS, and just use that for the single pb-discover link stage. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* autotools: Use non-recursive makeJeremy Kerr2014-08-0116-458/+415
| | | | | | | | | | | | With the current testing infrastructure, we don't have a strictly hierarchical set of dependencies. This causes problems with a recursive make, and means we have to hack around some of the dependencies. This change generates a single, top-level makefile from all of the Makefile.am fragments. We still need the po/ directory as a separate SUBDIR, but all others can be converted to non-recursive. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* configure: don't put cpp flags in CFLAGSJeremy Kerr2014-08-011-2/+8
| | | | | | -D* should go in CPPFLAGS, not CFLAGS. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: add initialiser for config->safe_modeJeremy Kerr2014-08-011-0/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* test/parser: Add missing stubs for network_(un)register_interfaceJeremy Kerr2014-08-011-0/+16
| | | | | | | The device handler code needs these calls on interface add/remove, so we need to provide stubs for the test framework. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Add missing includeJeremy Kerr2014-08-011-0/+1
| | | | | | We use setlocale() in device-handler.c, so we need locale.h Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Add support for 'add-url' actionSamuel Mendoza-Jonas2014-07-2811-17/+404
| | | | | | | | Creates a menu option to specify a remote conf file url to send to the server for parsing. Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Add support for 'add-url' actionsSamuel Mendoza-Jonas2014-07-281-0/+7
| | | | | Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* lib/pb-protocol: Define new 'add-url' actionSamuel Mendoza-Jonas2014-07-282-0/+21
| | | | | Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Enable 'url' pb-eventsSamuel Mendoza-Jonas2014-07-285-0/+156
| | | | | | | | | | Adds a new option to pb-event; ./pb-event url@dev url=scheme://path/to/petitboot.conf Specifies a remote conf file to parse for boot options Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Use translated strings for boot status messagesJeremy Kerr2014-07-284-13/+59
| | | | | | | Since we're operating in the correct locale now, we can send translated strings in the boot status messages. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Add setlocale calls in discover serverJeremy Kerr2014-07-283-1/+33
| | | | | | | | We want the discover server to respect the configured language, so we'll need to add appropriate setlocale() calls. We use the config->lang setting to use any previously-saved language. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Add language selector & support for language changesJeremy Kerr2014-07-289-7/+491
| | | | | | | This change adds a language selector UI, and allows language changes from incoming configuration messages. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* config: Add lang member to configJeremy Kerr2014-07-284-0/+18
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/common: Add discover_client_enumerate to re-add device dataJeremy Kerr2014-07-282-0/+23
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Move menu initialisation to cui codeJeremy Kerr2014-07-289-155/+144
| | | | | | | | | | | We'll want to re-initialise the petitboot main menu (when the language is changed), which we can't do if the items are populated entirely from the main() function. This change moves the menu initilisation to the cui code, we we can re-init when necessary. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* i18n: Add english translationJeremy Kerr2014-07-283-2/+413
| | | | | | No translation necessary. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Mark help text as translateableJeremy Kerr2014-07-283-2/+6
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Use a separate type for help textJeremy Kerr2014-07-2814-32/+53
| | | | | | | | | | | | Because it's initialised statically, help text won't be directly gettext()-ed. Instead, we need to perform the gettext translation at runtime, and pass untranslated strings into the help_screen code. Instead of trusting callers to pass the untranslated strings though, we encapsulate the help text data into struct help_text, so we know we have an unstranslated string. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* i18n: Mark translatable strings for ncurses UIJeremy Kerr2014-07-2811-81/+140
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add gettext infrastructureJeremy Kerr2014-07-287-5/+61
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Only update our config if the config_set succeeded.Jeremy Kerr2014-07-281-1/+6
| | | | | | | If config_set fails, we don't want to send the failed config out to clients. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Add device hierarchySamuel Mendoza-Jonas2014-07-223-9/+197
| | | | | | | | Boot options are now listed under their matching boot device in the ncurses UI to help differentitate similar boot option names Signed-off-by: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Add safe mode indicatorJeremy Kerr2014-07-222-0/+6
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover/platform-powerpc: Configure safe mode from IPMI bootdev settingJeremy Kerr2014-07-221-0/+6
| | | | | | | An IPMI bootflags of 0x3 indicates a safe-mode boot. Use this to trigger petitboot's safe mode. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover: Add safe modeJeremy Kerr2014-07-225-1/+24
| | | | | | | | | | | Safe mode configures the discover server to not start any device parsing; this can be used to diagnose any problems with early device handing. In safe mode, we don't initialise any of the device sources - udev, network and user events are disabled. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* version.sh: Ensure we're using petitboot's git directoryJeremy Kerr2014-07-221-0/+2
| | | | | | | We don't want the version to be extracted from a higher-level git directory. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: allow tab/backtab to skip through a widget's fieldsJeremy Kerr2014-07-221-2/+19
| | | | | | | | Since we may have a long list of devices on the configuration screen, we'd like a way to jump between widgets. This change repeats the PREV_FIELD/NEXT_FIELD driver request on these events. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Make Network: heading consistent with other labelsJeremy Kerr2014-07-221-1/+1
| | | | | | | The 'Network' label was originally intended as a header, but we should keep it consistent with other field labels. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* ui/ncurses: Expose boot_device configuration through UIJeremy Kerr2014-07-222-22/+170
| | | | | | | | | | | | | | | | Add a configuration setting for the default boot device. We change the autoboot option to a select, as we have three possible behaviours for autoboot: ( ) Don't autoboot ( ) Autoboot from any disk/network device ( ) Only autoboot from a specific disk/network device The latter option will show a list of possible devices to seelct for autoboot behaviour. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* discover/powerpc: Parse & save default boot device parameterJeremy Kerr2014-07-211-0/+46
| | | | | | | This change implement load & save support for the default boot device configuration parameter. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
OpenPOWER on IntegriCloud