Skip to contentSkip to conversation

VxWorks: fixup MAC address for VxWorks

PATCH In review Miao Yan 3 participants 5 messages Dec 2, 2015 – Dec 14, 2015

lore
Share & tools
lore

Miao Yan

author
#0 lore raw

PATCH 1/1 VxWorks: fixup MAC address for VxWorks

VxWorks 7 kernels retrieve 'local-mac-addr' from dtb and use that for NIC MAC address. As a result, when booting the same kernel image on multiple boards, there will be address conflicts.

So fixup MAC address when booting VxWorks 7 kernels

---
 common/bootm_os.c | 2 ++
 1 file changed, 2 insertions(+)
common/bootm_os.c +2 -0
index 72477f0..cb83f4a 100644
@@ -288,6 +288,8 @@ void do_bootvx_fdt(bootm_headers_t *images)
 		if (ret)
 			return;
 
+		fdt_fixup_ethernet(*of_flat_tree);
+
 		ret = fdt_add_subnode(*of_flat_tree, 0, "chosen");
 		if ((ret >= 0 || ret == -FDT_ERR_EXISTS)) {
 			bootline = getenv("bootargs");
Signature · 1 line
2.6.3.444.gfd13a2e
#1 lore raw

PATCH 1/1 VxWorks: fixup MAC address for VxWorks

Quoted 17 lines · Miao Yan

VxWorks 7 kernels retrieve 'local-mac-addr' from dtb and use that for NIC MAC address. As a result, when booting the same kernel image on multiple boards, there will be address conflicts.

So fixup MAC address when booting VxWorks 7 kernels

---
 common/bootm_os.c | 2 ++
 1 file changed, 2 insertions(+)
common/bootm_os.c +0 -0
index 72477f0..cb83f4a 100644

common/bootm_os.c void do_bootvx_fdt(bootm_headers_t *images)

Quoted 9 lines
common/bootm_os.c +2 -1
@@ -288,6 +288,8 @@ void do_bootvx_fdt(bootm_headers_t *images)
                if (ret)
                        return;
 
+               fdt_fixup_ethernet(*of_flat_tree);
+
                ret = fdt_add_subnode(*of_flat_tree, 0, "chosen");
                if ((ret >= 0 || ret == -FDT_ERR_EXISTS)) {
                        bootline = getenv("bootargs");
--
author
#2 lore raw

PATCH 1/1 VxWorks: fixup MAC address for VxWorks

2015-12-02 20:44 GMT+08:00 Bin Meng <[email protected]>:

Quoted 21 lines · Miao Yan
Quoted 20 lines

VxWorks 7 kernels retrieve 'local-mac-addr' from dtb and use that for NIC MAC address. As a result, when booting the same kernel image on multiple boards, there will be address conflicts.

So fixup MAC address when booting VxWorks 7 kernels

---
 common/bootm_os.c | 2 ++
 1 file changed, 2 insertions(+)
common/bootm_os.c +0 -0
index 72477f0..cb83f4a 100644
@@ -288,6 +288,8 @@ void do_bootvx_fdt(bootm_headers_t *images)
                if (ret)
                        return;
 
Quoted 8 lines

common/bootm_os.c void do_bootvx_fdt(bootm_headers_t *images)

Quoted 6 lines
common/bootm_os.c +2 -1
+               fdt_fixup_ethernet(*of_flat_tree);
+
                ret = fdt_add_subnode(*of_flat_tree, 0, "chosen");
                if ((ret >= 0 || ret == -FDT_ERR_EXISTS)) {
                        bootline = getenv("bootargs");
--

Hi Tom,

Could this be in next release ? Thanks.

Miao

#3 lore raw

PATCH 1/1 VxWorks: fixup MAC address for VxWorks

Quoted 31 lines · Miao Yan

2015-12-02 20:44 GMT+08:00 Bin Meng <[email protected]>:

Quoted 21 lines · Miao Yan
Quoted 20 lines

VxWorks 7 kernels retrieve 'local-mac-addr' from dtb and use that for NIC MAC address. As a result, when booting the same kernel image on multiple boards, there will be address conflicts.

So fixup MAC address when booting VxWorks 7 kernels

---
 common/bootm_os.c | 2 ++
 1 file changed, 2 insertions(+)
common/bootm_os.c +0 -0
index 72477f0..cb83f4a 100644
@@ -288,6 +288,8 @@ void do_bootvx_fdt(bootm_headers_t *images)
                if (ret)
                        return;
 
Quoted 8 lines

common/bootm_os.c void do_bootvx_fdt(bootm_headers_t *images)

Quoted 6 lines
common/bootm_os.c +2 -1
+               fdt_fixup_ethernet(*of_flat_tree);
+
                ret = fdt_add_subnode(*of_flat_tree, 0, "chosen");
                if ((ret >= 0 || ret == -FDT_ERR_EXISTS)) {
                        bootline = getenv("bootargs");
--
Quoted 3 lines

Hi Tom,

Could this be in next release ? Thanks.

Yes, soon, thanks for the fix!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20151208/98d11ba0/attachment.sig>
#4 lore raw
In reply to Miao Yan
Quoted 9 lines · Miao Yan

VxWorks 7 kernels retrieve 'local-mac-addr' from dtb and use that for NIC MAC address. As a result, when booting the same kernel image on multiple boards, there will be address conflicts.

So fixup MAC address when booting VxWorks 7 kernels

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20151214/fdb8f0fa/attachment.sig>