public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Detlev Zundel <dzu@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] Unable to run scripts with autoscr command
Date: Fri, 17 Feb 2012 16:31:41 +0100	[thread overview]
Message-ID: <m2r4xtwk6a.fsf@ohwell.denx.de> (raw)
In-Reply-To: <CAEVEsMY6TtXBsohFGyCxDhStnhrCgOo0VMgh7ZXpNspdMJdcVQ@mail.gmail.com> (Asif Sulikeri's message of "Fri, 17 Feb 2012 16:52:21 +0530")

Hi Asif,

> Im using u-boot version U-Boot 1.3.4 (Dec  9 2010 - 17:45:52)
> DM365-IPNC-1.0.14 on a davinci_dm365 board,

what is the "DM365-IPNC-1.0.14" version about?  I cannot see such a
version (or tag) in mainline U-Boot.

> I'm trying to run script under U-boot using "autoscr" command, since I
> don't see any "source" command ported into this version of U-boot yet,

Yes, it was renamed at some point:

commit 74de7aefd79690bae8cf5a5120f5962d444be089
Author: Wolfgang Denk <wd@denx.de>
Date:   Wed Apr 1 23:34:12 2009 +0200

    Add "source" command; prepare removal of "autoscr" command
    
    According to the doc/feature-removal-schedule.txt, the "autoscr"
    command will be replaced by the "source" command in approximately 6
    months from now.
    
    This patch prepares this change and starts a 6 month transition
    period as follows:
    
    - The new "source" command has been added, which implements exactly
      the same functionlaity as the old "autoscr" command before
    - The old "autoscr" command name is kept as an alias for compatibility
    - Command sequences, script files atc. have been adapted to use the
      new "source" command
    - Related environment variables ("autoscript", "autoscript_uname")
      have *not* been adapted yet; these will be renamed resp. removed in
      a separate patch when the support for the "autoscr" command get's
      finally dropped.
    
    Signed-off-by: Wolfgang Denk <wd@denx.de>

[dzu at pollux u-boot-testing (master)]$ git describe --contains 74de7aefd79690bae8cf5a5120f5962d444be089
v2009.06-rc1~110
[dzu at pollux u-boot-testing (master)]$ 

So indeed, this cannot be in your version 1.3.4

> but autoscr isn't executing commands like -if -then -while in the script,
> gives the following error: *Unknown command 'if' - try 'help'*
>
>
> *After this I tried enabling the hush shell by setting the following in the
> config file for respective board,*

This is indeed the problem, the used shell is not powerful enough to do
such scripting.  Using the hush shell will indeed solve the original
problem.

>
> #define CFG_HUSH_PARSER
> #define CFG_PROMPT_HUSH_PS2     "=> "
> #undef CONFIG_BOOT_RETRY_TIME
> #undef CONFIG_RESET_TO_RETRY
> #define CONFIG_AUTOSCRIPT               1
> #define CONFIG_CMD_AUTOSCRIPT
>
> *but after this when I reboot the board, I get indefinite repetative
> display of the u-boot prompt as below:*
>
> Jumping to entry point at 0x81080000
> DM36x initialization passed!
> TI UBL Base Version: 1.50
> Boot Loader BootMode = NAND
> Starting NAND Copy...
> Valid magicnum, 0xA1ACED66, found in block 0x00000008.
> Boot Mode Task Completed
>
> IPNC UBL Version: 1.1.0
> Platform: DM365
>
> Jumping to entry point at 0x81080000
> DM36x initialization passed!
> TI UBL Base Version: 1.50
> Boot Loader BootMode = NAND
> Starting NAND Copy...
> Valid magicnum, 0xA1ACED66, found in block 0x00000008.
> Boot Mode Task Completed
>
> IPNC UBL Version: 1.1.0
> Platform: DM365
>
> Jumping to entry point at 0x81080000
> DM36x initialization passed!
> TI UBL Base Version: 1.50
> Boot Loader BootMode = NAND
> Starting NAND Copy...
> Valid magicnum, 0xA1ACED66, found in block 0x00000008.
> Boot Mode Task Completed
>
> IPNC UBL Version: 1.1.0
> Platform: DM365
>
> Jumping to entry point at 0x81080000
> DM36x initialization passed!
> TI UBL Base Version: 1.50
> Boot Loader BootMode = NAND
> Starting NAND Copy...
> Valid magicnum, 0xA1ACED66, found in block 0x00000008.
> Boot Mode Task Completed
>
> IPNC UBL Version: 1.1.0
> Platform: DM365
>
> Jumping to entry point at 0x81080000
> DM36x initialization passed!
> TI UBL Base Version: 1.50
> Boot Loader BootMode = NAND
> Starting NAND Copy...
> Valid magicnum, 0xA1ACED66, found in block 0x00000008.
> Boot Mode Task Completed
>
> IPNC UBL Version: 1.1.0
> Platform: DM365
>
> .......
>
> what might be the problem, early help would be much appreciated.

It seems that by changing your configuration somehow the increase in
code size has broken the compilation.

Did you see any errors or warnings while compiling?

On the other hand, davinci_dm365evm is a supported configuration in
mainline, so why not try current code.  This way we would be in a much
better position to help you.

Thanks
  Detlev

-- 
Wissenschaft ohne Verstand ist doppelte Narrheit.
                                    --- Baltasar Gracian
--
DENX Software Engineering GmbH,      MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich,  Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-40 Fax: (+49)-8142-66989-80 Email: dzu at denx.de

  reply	other threads:[~2012-02-17 15:31 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-17 11:22 [U-Boot] Unable to run scripts with autoscr command Asif Sulikeri
2012-02-17 15:31 ` Detlev Zundel [this message]
2012-02-20 10:15   ` Asif Sulikeri
2012-02-24  5:25     ` Asif Sulikeri
2012-02-24  5:31       ` Graeme Russ
2012-02-24  5:43         ` Asif Sulikeri
2012-02-25  1:14           ` Graeme Russ
2012-02-27  5:57             ` Asif Sulikeri
2012-02-27  6:03               ` Graeme Russ
2012-02-27  6:26                 ` Asif Sulikeri
2012-02-27  6:42                   ` Graeme Russ
2012-02-27  8:19                     ` Asif Sulikeri
2012-02-27 11:56                       ` Graeme Russ

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m2r4xtwk6a.fsf@ohwell.denx.de \
    --to=dzu@denx.de \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox