public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stefan Roese <sr@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] Setting ipaddr via setenv() - H_INTERACTIVE vs H_PROGRAMMATIC
Date: Tue, 1 Mar 2016 11:35:50 +0100	[thread overview]
Message-ID: <56D57086.6000304@denx.de> (raw)

Hi Joe,

I'm currently stumbling over a problem in some board specific code
(not in mainline yet), that sets the "ipaddr" env variable via
setenv(). But as I now noticed, the callback on_ipaddr() doesn't
set net_ip to this new value. As flags has H_PROGRAMMATIC set and
op_ipaddr() skips setting this value in this case.

I fail to see why we need this check in on_ipaddr(). Could you
please explain why this is needed? Why would someone use setenv()
for the "ipaddr" and not want to also update the net_ip value.
This results in the "ipaddr" value being updated but net_ip
still being configured to the old value.

Or if this is really needed, what is the correct way to update
the ipaddr (env variable and net_ip value) from the U-Boot code?

Thanks,
Stefan

             reply	other threads:[~2016-03-01 10:35 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-01 10:35 Stefan Roese [this message]
2016-03-01 19:40 ` [U-Boot] Setting ipaddr via setenv() - H_INTERACTIVE vs H_PROGRAMMATIC Joe Hershberger
2016-03-02  6:21   ` Stefan Roese
2016-03-02  6:46     ` Joe Hershberger
2016-03-02  7:01       ` Stefan Roese
2016-03-03  1:58         ` Joe Hershberger

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=56D57086.6000304@denx.de \
    --to=sr@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