在 2017年12月29日星期五 CST 下午5:35:51,Jun Nie 写道:
> Hi Bernhard,
> 
> Resend this mail with CCing mail list so that more people can see this
> issue and may have answer. Also correct register access code I use as
> I send wrong version code in last mail.
> 
> I see sunxi-tool patch a3ce5f9f and you also mentioned that writing value is
> OK with register based method in google group. Do you have eFuse writing
> code that works? I can write OEM_PROGRAM and THERMAL_SENSOR with below
> code. But when I write ROTPK_HASH, eFuse is not changed.

Could you try to check the value of ROTPK_HASH with the "read by register"
way?

> 
> https://linux-sunxi.org/SID_Register_Guide#eFUSE
> 
> 151         iowrite32be(val, sid->base + SUN8I_SID_PRKEY);
> 152         /* Set word, lock access, and set read command */
> 153         reg_val = (offset & SUN8I_SID_OFFSET_MASK)
> 154                   << SUN8I_SID_OFFSET_SHIFT;
> 155         writel(reg_val, sid->base + SUN8I_SID_PRCTL);
> 156         reg_val |= SUN8I_SID_OP_LOCK | SUN8I_SID_WRITE;
> 157         writel(reg_val, sid->base + SUN8I_SID_PRCTL);
> 158
> 159         ret = readl_poll_timeout(sid->base + SUN8I_SID_PRCTL, reg_val,
> 160                                  !(reg_val & SUN8I_SID_WRITE), 100,
> 250000); 161         if (ret)
> 162                 return ret;
> 163
> 164         writel(0, sid->base + SUN8I_SID_PRCTL);
> 
> Best Regards.
> Jun


-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to