U-BOOT memory write protected (mw and saveenv is not working)

Good afternoon, dear Nvidia! I have a problem in my JN EMMC edition (32.7.4) - when I altering cbootargs and do saveenv it is not working after rebooting. Then now I tried to use i2c mw and it is not working too. Then I tried to use mw and it is not working too.

Tegra210 (P3450-0000) # md 0x100000 0x10      
00100000: ea00000e ea000015 ea000014 ea000013    ................
00100010: ea000012 ea000011 ea000010 ea00000f    ................
00100020: 00000000 00000000 00000000 00000000    ................
00100030: 00000000 00210001 00210001 00210001    ......!...!...!.
Tegra210 (P3450-0000) # mw 0x100000 0xaabbccdd
Tegra210 (P3450-0000) # md 0x100000 0x10      
00100000: ea00000e ea000015 ea000014 ea000013    ................
00100010: ea000012 ea000011 ea000010 ea00000f    ................
00100020: 00000000 00000000 00000000 00000000    ................
00100030: 00000000 00210001 00210001 00210001    ......!...!...!.
Tegra210 (P3450-0000) # md 0x2778 0x10  
00002778: eafffffe eafffffe eafffffe eafffffe    ................
00002788: eafffffe eafffffe eafffffe eafffffe    ................
00002798: eafffffe eafffffe eafffffe eafffffe    ................
000027a8: eafffffe eafffffe eafffffe eafffffe    ................
Tegra210 (P3450-0000) # mw 0x2778 0xaabbccdd  
Tegra210 (P3450-0000) # md 0x2778 0x10      
00002778: eafffffe eafffffe eafffffe eafffffe    ................
00002788: eafffffe eafffffe eafffffe eafffffe    ................
00002798: eafffffe eafffffe eafffffe eafffffe    ................
000027a8: eafffffe eafffffe eafffffe eafffffe    ................

Why is this happening and how can I fix this?

Then will it work in Linux with commands like i2cset?

I2C mw is not working too - memory is not changing no matter what.

I mean all your tests are done in U-Boot prompt, and I’m asking whether you can modify any i2c values in Linux environment.

I can write to I2C anything I want - I cannot save the result of reading. Usually in uboot you using memory to store and read data but I cannot use memory at all. So then I cannot use i2c read and compare the result of this operation with the correct value.
I Cannot understand why is saveenv and all of memory operation are not working in u-boot. First time meeting something like this.

OK, so I think these are two different things.
I2C is I2C, and U-Boot env is U-Boot env. The former one lives in EEPROM, and the latter one lives in eMMC.
I don’t know why you mix these two together.

Does saveenv throw any error?
Or the command works, but just disappears after reboot?
Do you have another Jetson Nano that comes with an SD card slot for testing?

I didn’t mix this, I only show you that memory is not change after using mw or i2c mw.
saveenv says nothing but after rebooting it returns to previous value as if I didn’t done saveenv at all.

Do you have other modules for testing?
Maybe you can try dumping the UBENV partition, manually modifying it, and writing the image back.

For the i2C issue, did you set the right bus before accessing it?
For example, you need to set it to read from bus 2 of the 0x50 address:

i2c dev 2
i2c md <address> <value>

https://docs.nvidia.com/jetson/archives/l4t-archived/l4t-3274/index.html#page/Tegra%20Linux%20Driver%20Package%20Development%20Guide/jetson_eeprom_layout.html

If you were trying to modify EEPROM, then your command was not right; if you were trying to modify U-Boot env via I2C/EEPROM, these two are totally different things.

I did everything, I already told you that mw is not working too, not only for I2C - I cannot write anything to the memory from U-BOOT shell at all. I’m trying to do simple mw and memory is not changing. The log is in the first message

Then maybe the module is broken.

What module? I didn’t touch u-boot while working under it - here is only Nvidia’s precompiled u-boot from 32.7.4

I mean the board itself.
Like something in the I2C bus no longer functions now.
Really nothing you can do except finding another device for test.

In Linux I2C is working normally and in the u-boot it is working. I told you that in u-boot in not working memory - I cannot write anything to the memory. No matter is it I2C or simple mw memory is not writing - it is write protected somehow. In the first message I showed you that I try to write something in the memory by mw and memory is not changed at all - I2C has nothing to do with it at all - nothing to do with it - nothing to do with it at all.
The problem that memory is not changing, I2C is not question here.

Are you writing into a legal address?
I’m not sure if that’s true for 0x100000.

Don’t these two contradict with each other?

No - I try to use mw and it is not working that’s why I sure that it is the memory problem.
I tried all sorts of region and memory is not working. Usually all of u-boot memory must be available for writing.
Then what memory region should I use?

I’ve done bdinfo and discovered needed areas

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.