On 31 May 2018 at 21:19, Kevin Hilman khilman@baylibre.com wrote:
On Thu, May 31, 2018 at 9:53 AM, Kevin Hilman khilman@baylibre.com wrote:
On Thu, May 31, 2018 at 8:38 AM, Neil Williams neil.williams@linaro.org
wrote:
[...]
It's just possible that the interrupt_char could be causing this
problem,
you've got a newline set - that could end up being carried over into the shell and U-Boot has a nasty habit of repeating the last command if a newline is entered with no other content.
It's not only just possible, that was it! :) Simple fix[1] makes it happy again, and no boot_character_delay needed. I'll submit a patch shortly.
I've got one more hiccup. I have a particular vendor uboot which requires either <enter> or Ctrl-C. No other chars work. :( The <enter> causes the "extra prompt problem", and I'm not seeing how to send ctrl chars with interrupt_char. I tried \x03 and LAVA didn't like that:
This has already been seen before, at some stage, because there's a relevant comment in boot/__init__.py:
# vendor u-boot builds may require one or more control characters
https://git.linaro.org/lava/lava.git/tree/lava_dispatcher/actions/boot/__ini...
It's just that the support has been implemented more frequently for iPXE.
Infrastructure error: Cannot parse job definition: unacceptable character #x0003: special characters are not allowed in "<unicode string>", position 2829
I see there is interrupt_ctrl_list, but that doesn't seem to be used by base.jinja2 for uboot. Is there any reason not to do this[1] so that interrupt_ctrl_list defaults to empty, but could be set from the device-type, or device dict? I tested that patch and it allowed me to add this to the device dict, and it worked and avoids the "extra prompt" problem.
{% set interrupt_ctrl_list = ['c'] %}
Kevin
[1] diff --git a/lava_scheduler_app/tests/device-types/base.jinja2 b/lava_scheduler_app/tests/device-types/base.jinja2 index 13b053080f45..798545591dd2 100644 --- a/lava_scheduler_app/tests/device-types/base.jinja2 +++ b/lava_scheduler_app/tests/device-types/base.jinja2 @@ -66,6 +66,7 @@ constants: u-boot: interrupt-prompt: '{{ uboot_autoboot_prompt | default("Hit any key to stop autoboot") }}' interrupt-character: '{{ uboot_interrupt_character | default(" ") }}'
- interrupt_ctrl_list: {{ interrupt_ctrl_list | default([]) }} final-message: '{{ uboot_final_message | default("Starting
kernel") }}' error-messages: - 'Resetting CPU'
Email line-mangling not withstanding, if you'd like to submit a review for that change, I don't see a problem. Empty is the correct default for it to let the interrupt character be used for other devices.