Mailbox property: RPI_FIRMWARE_GET_CUSTOMER_OTP
Phil Elwell
phil at raspberrypi.org
Tue Jan 2 06:10:54 PST 2018
Hi Stefan,
On 28/12/2017 17:50, Stefan Wahren wrote:
> Hi,
>
> i made an attempt to write an NVMEM / OTP driver for the Raspberry Pi [1]. Instead of accessing the registers from the ARM core i decided to use the Mailbox property interface of the GPU firmware. Unfortunately a documentation of property RPI_FIRMWARE_GET_CUSTOMER_OTP isn't available here [2].
I don't see any reason why that property couldn't be documented - consider it an oversight.
> So the following questions comes to my mind:
> What is the proper definition of Request/Response?
The request takes two parameters - an index and a length, both in 32-bit word
units. The response contains the index and length, and adds the requested number
of words as read from the customer area of the OTP, such that the buffer should
be at least (2 + length) * 4 bytes long. Attempts to read outside the customer
area will fail, returning the usual error code (0x80000000).
> How long is the OTP register range in bytes?
The customer area of the OTP is 8 words long, addressable using index values 0 to 7.
It is intended for customer applications, and will contains zeroes in an off-the-shelf
Pi.
> Can anyone help?
I hope so.
Phil
> Best regards
> Stefan
>
> [1] - https://github.com/lategoodbye/rpi-zero/tree/bcm2835-otp
> [2] - https://github.com/raspberrypi/firmware/wiki/Mailbox-property-interface
>
More information about the linux-rpi-kernel
mailing list