[U-Boot] [PATCH] net: bootp fix vci string on SPL-Boot

If CONFIG_CMD_DHCP is enabled, the vci (vendor-class-identifier) string isn't inserted into the bootp-packet during SPL stage because the
CONFIG_BOOTP_VCI_STRING instead CONFIG_SPL_NET_VCI_STRING
We fix this with testing for CONFIG_SPL_BUILD and testing for existing CONFIG_SPL_NET_VCI_STRING.
Signed-off-by: Hannes Schmelzer oe5hpm@oevsv.at
---
net/bootp.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/net/bootp.c b/net/bootp.c index 43466af..b547786 100644 --- a/net/bootp.c +++ b/net/bootp.c @@ -498,7 +498,9 @@ static int dhcp_extended(u8 *e, int message_type, struct in_addr server_ip, } #endif
-#ifdef CONFIG_BOOTP_VCI_STRING +#if defined(CONFIG_SPL_BUILD) && defined(CONFIG_SPL_NET_VCI_STRING) + put_vci(e, CONFIG_SPL_NET_VCI_STRING); +#elif defined(CONFIG_BOOTP_VCI_STRING) put_vci(e, CONFIG_BOOTP_VCI_STRING); #endif

Hi Hannes,
On Tue, Aug 25, 2015 at 5:17 AM, Hannes Schmelzer oe5hpm@oevsv.at wrote:
If CONFIG_CMD_DHCP is enabled, the vci (vendor-class-identifier) string isn't inserted into the bootp-packet during SPL stage because the
CONFIG_BOOTP_VCI_STRING instead CONFIG_SPL_NET_VCI_STRING
We fix this with testing for CONFIG_SPL_BUILD and testing for existing CONFIG_SPL_NET_VCI_STRING.
Signed-off-by: Hannes Schmelzer oe5hpm@oevsv.at
Acked-by: Joe Hershberger joe.hershberger@ni.com

Hi,
just checked my upstream branch and noticed that this patch is outstanding. How about merge?
regards, Hannes
On 25.08.2015 18:01, Joe Hershberger wrote:
Hi Hannes,
On Tue, Aug 25, 2015 at 5:17 AM, Hannes Schmelzer oe5hpm@oevsv.at wrote:
If CONFIG_CMD_DHCP is enabled, the vci (vendor-class-identifier) string isn't inserted into the bootp-packet during SPL stage because the
CONFIG_BOOTP_VCI_STRING instead CONFIG_SPL_NET_VCI_STRING
We fix this with testing for CONFIG_SPL_BUILD and testing for existing CONFIG_SPL_NET_VCI_STRING.
Signed-off-by: Hannes Schmelzer oe5hpm@oevsv.at
Acked-by: Joe Hershberger joe.hershberger@ni.com

Hi Hannes,
On Tue, Sep 29, 2015 at 3:19 AM, Hannes Schmelzer hannes@schmelzer.or.at wrote:
Hi,
just checked my upstream branch and noticed that this patch is outstanding. How about merge?
Do you think this is a critical bug fix? I was planning to wait for next release since the patch came after the merge window.
regards, Hannes
On 25.08.2015 18:01, Joe Hershberger wrote:
Hi Hannes,
On Tue, Aug 25, 2015 at 5:17 AM, Hannes Schmelzer oe5hpm@oevsv.at wrote:
If CONFIG_CMD_DHCP is enabled, the vci (vendor-class-identifier) string isn't inserted into the bootp-packet during SPL stage because the
CONFIG_BOOTP_VCI_STRING instead CONFIG_SPL_NET_VCI_STRING
We fix this with testing for CONFIG_SPL_BUILD and testing for existing CONFIG_SPL_NET_VCI_STRING.
Signed-off-by: Hannes Schmelzer oe5hpm@oevsv.at
Acked-by: Joe Hershberger joe.hershberger@ni.com

Hi Hannes,
Hi Joe,
On Tue, Sep 29, 2015 at 3:19 AM, Hannes Schmelzer hannes@schmelzer.or.at wrote:
Hi,
just checked my upstream branch and noticed that this patch is
outstanding.
How about merge?
Do you think this is a critical bug fix? I was planning to wait for next release since the patch came after the merge window.
Absolutely not critical. no problem to wait for next release.
regards, Hannes
On 25.08.2015 18:01, Joe Hershberger wrote:
Hi Hannes,
On Tue, Aug 25, 2015 at 5:17 AM, Hannes Schmelzer oe5hpm@oevsv.at
wrote:
If CONFIG_CMD_DHCP is enabled, the vci (vendor-class-identifier)
string
isn't inserted into the bootp-packet during SPL stage because the
CONFIG_BOOTP_VCI_STRING instead CONFIG_SPL_NET_VCI_STRING
We fix this with testing for CONFIG_SPL_BUILD and testing for
existing
CONFIG_SPL_NET_VCI_STRING.
Signed-off-by: Hannes Schmelzer oe5hpm@oevsv.at
Acked-by: Joe Hershberger joe.hershberger@ni.com

On Tue, Aug 25, 2015 at 12:17:59PM +0200, Hannes Schmelzer wrote:
If CONFIG_CMD_DHCP is enabled, the vci (vendor-class-identifier) string isn't inserted into the bootp-packet during SPL stage because the
CONFIG_BOOTP_VCI_STRING instead CONFIG_SPL_NET_VCI_STRING
We fix this with testing for CONFIG_SPL_BUILD and testing for existing CONFIG_SPL_NET_VCI_STRING.
Signed-off-by: Hannes Schmelzer oe5hpm@oevsv.at
Reviewed-by: Tom Rini trini@konsulko.com

On Tue, Aug 25, 2015 at 5:17 AM, Hannes Schmelzer oe5hpm@oevsv.at wrote:
If CONFIG_CMD_DHCP is enabled, the vci (vendor-class-identifier) string isn't inserted into the bootp-packet during SPL stage because the
CONFIG_BOOTP_VCI_STRING instead CONFIG_SPL_NET_VCI_STRING
We fix this with testing for CONFIG_SPL_BUILD and testing for existing CONFIG_SPL_NET_VCI_STRING.
Signed-off-by: Hannes Schmelzer oe5hpm@oevsv.at
Applied to u-boot-net/master, thanks! -Joe
participants (5)
-
Hannes Schmelzer
-
Hannes Schmelzer
-
Hannes Schmelzer
-
Joe Hershberger
-
Tom Rini