ONE-TIME PROGRAMMABLE MEMORY CONTROLLER, RELATED PROCESSING SYSTEM, INTEGRATED CIRCUIT AND METHOD
20230409320 ยท 2023-12-21
Inventors
- Antonino Giuseppe Fontana (Lentini, IT)
- Giuseppe Guarnaccia (San Gregorio di Catania (CT), IT)
- Stefano Catalano (Catania, IT)
Cpc classification
International classification
Abstract
In an embodiment a One-Time Programmable (OTP) memory controller includes a data register, a given number K of shadow-registers, wherein the number K is smaller than a given number N of memory slots of an OTP memory area, a communication interface configured to receive a read request requesting the data of a given memory slot and a control circuit configured to receive a preload start signal and a shadow-register preload enable signal, wherein the control circuit is configured to manage a preload phase and a data-read phase.
Claims
1. A One-Time Programmable (OTP) memory controller comprising: a data register; a given number K of shadow-registers, wherein the number K is smaller than a given number N of memory slots of an OTP memory area; a communication interface configured to receive a read request requesting the data of a given memory slot; and a control circuit configured to receive a preload start signal and a shadow-register preload enable signal, wherein the control circuit is configured to manage a preload phase and a data-read phase, wherein, in response to the preload start signal, the control circuit is configured to perform the preload phase by: determining a mapping between the given number K of shadow-registers and the given number N of memory slots, determining, for each of the shadow-registers, whether the respective shadow-register is preloadable as a function of the shadow-register preload enable signal, in response to determining that a shadow-register is preloadable, transferring data from the memory slot mapped to the shadow-register to the respective shadow-register, and once the shadow-register is preloaded based on the shadow-register preload enable signal, asserting a preload end signal and start the data-read phase, and wherein the control circuit is configured to perform the data-read phase by: selecting the respective memory location indicated in the read request, determining whether the selected memory location is mapped to a shadow register, in response to determining that the selected memory location is mapped to the shadow register, selecting the shadow-register mapped to the selected memory location and determining whether the selected shadow-register has been pre-loaded, in response to determining that the selected shadow-register has been pre-loaded, transmitting the data stored to the selected shadow register via the communication interface, in response to determining that the selected shadow-register has not been pre-loaded, transferring data from a selected memory slot to the selected shadow-register and then transmit the data stored to the selected shadow register via the communication interface, and in response to determining that the selected memory location is not mapped to a shadow register, transferring data from the selected memory slot to the data register and then transmit the data stored to the data register via the communication interface.
2. The OTP memory controller according to claim 1, wherein the control circuit is configured to: receive a shadow-register mapping signal; and determine the mapping between the given number K of shadow-registers and the given number N of memory slots as a function of the shadow-register mapping signal.
3. The OTP memory controller according to claim 1, wherein the shadow-register preload enable signal comprises the given number N of bits, and wherein each bit indicates whether a respective memory slot is preloadable.
4. The OTP memory controller according to claim 1, wherein the shadow-register preload enable signal comprises the given number K of bits, and wherein each bit indicates whether a respective shadow-registers is preloadable.
5. The OTP memory controller according claim 1, wherein the control circuit is configured to perform a data-write phase by: receiving a write request via the communication interface and selecting the respective memory location indicated in the write request, wherein the write request comprises respective data to be stored to the selected memory location; determining whether the selected memory location is mapped to a shadow register; in response to determining that the selected memory location is mapped to a shadow register, selecting the shadow-register mapped to the selected memory location, storing the data to be stored to the selected shadow-register and programming the data stored to the selected shadow-register to the selected memory location; and in response to determining that the selected memory location is not mapped to a shadow register, storing the data to be stored to the data register and programming the data stored to the data register to the selected memory location.
6. A processing system comprising: a power supply circuit configured to receive an input voltage and provide a first supply voltage and a second supply voltage, wherein the power supply circuit is configured to selectively enable the first supply voltage when a low-power control signal is de-asserted and disable the first supply voltage when the low-power control signal is asserted; a first sub-circuit configured to receive the first supply voltage, wherein the first sub-circuit comprises: the OTP memory area comprising the given number N of memory slots; and the OTP memory controller according to claim 1, wherein the OTP memory controller is configured to manage the OTP memory area; and a second sub-circuit configured to receive the second supply voltage.
7. The processing system according to claim 6, further comprising a power supply monitoring circuit configured to assert the preload start signal when the first supply voltage exceeds a given threshold voltage.
8. The processing system according to claim 7, further comprising: a digital processing circuit; a first resource connected to the digital processing circuit and configured to receive first configuration data; and a reset management circuit configured to, in response to the preload end signal, start the digital processing circuit.
9. The processing system according to claim 8, wherein the second sub-circuit comprises: a power management circuit configured to generate the low-power control signal, and a second resource connected to the digital processing circuit and configured to receive second configuration data.
10. The processing system according to claim 9, wherein the power management circuit is configured to: in response to a request received from the digital processing circuit, assert the low-power control signal, and in response to an event signal, de-assert the low-power control signal.
11. The processing system according to claim 6, wherein the OTP memory controller is configured to map a first memory slot of the OTP memory storing first configuration data to a first shadow-register and a second memory slot of the OTP memory storing second configuration data to a second shadow-register.
12. The processing system according to claim 6, wherein the processing system is configured to: in response to switching-on the processing system, assert the preload start signal via the power supply monitoring circuit and set the preload enable signal in order to preload first configuration data from a first memory slot to a first shadow-register and second configuration data from a second memory slot to a second shadow-register and, in response to the preload end signal, transfer the first configuration data from the first shadow-register to a first resource and the second configuration data from the second shadow-register to the second resource; send via a digital processing circuit a request to a power management circuit in order to assert the low-power control signal thereby disabling the first supply voltage and switching off the first sub-circuit; in response to an event signal, de-assert the low-power control signal via the power management circuit thereby enabling the first supply voltage and switching on the first sub-circuit; and in response to switching on the first sub-circuit, assert the preload start signal via the power supply monitoring circuit and set the preload enable signal in order to preload the first configuration data from the first memory slot to the first shadow-register and disable the preloading of the second configuration data from the second memory slot to the second shadow-register and, in response to the preload end signal, transfer the first configuration data from the first shadow-register to the first resource and inhibit the transfer of the second configuration data from the second shadow-register to the second resource.
13. The processing system according to claim 6, wherein the processing system is configured to set the shadow-register mapping signal in order to map a first memory slot of the OTP memory storing first configuration data to a first shadow-register and a second memory slot of the OTP memory storing second configuration data to a second shadow-register.
14. The processing system according to claim 6, further comprising a circuit configured to generate the preload enable signal.
15. The processing system according to claim 14, wherein the circuit is configured to generate the preload enable signal as a function of at least one of: a first signal received from a first resource, wherein the first signal indicates whether the first resource has stored first configuration data; a second signal received from a second resource, wherein the second signal indicates whether the second resource has stored second configuration data; a third signal received from a configuration circuit configured to transfer first configuration data from a first shadow-register to the first resource and the second configuration data from a second shadow-register to the second resource, wherein the third signal indicates whether the first configuration data have been transferred from the first shadow-register to the first resource and/or whether the second configuration data have been transferred from the second shadow-register to the second resource; or a fourth signal received from a digital processing circuit, wherein the fourth signal indicates whether to pre-load the first configuration data and/or whether to pre-load the second configuration data.
16. The processing system according to claim 14 wherein the second sub-circuit comprises the circuit.
17. A method for operating a processing system, the method comprising: switching-on the processing system; in response to switching-on the processing system, asserting, by a power supply monitoring circuit of the processing system, a preload start signal and setting a preload enable signal in order to preload first configuration data from a first memory slot to a first shadow-register and second configuration data from a second memory slot to a second shadow-register; in response to a preload end signal, transferring the first configuration data from the first shadow-register to a first resource and the second configuration data from the second shadow-register to a second resource; sending, by a digital processing circuit of the processing system, a request to a power management circuit in order to assert a low-power control signal thereby disabling a first supply voltage and switching-off a first sub-circuit; in response to an event signal, de-asserting, by the power management circuit, the low-power control signal thereby enabling the first supply voltage and switching-on the first sub-circuit; and in response to switching-on the first sub-circuit, asserting the preload start signal via the power supply monitoring circuit and setting the preload enable signal in order to preload the first configuration data from the first memory slot to the first shadow-register and disable the preloading of the second configuration data from the second memory slot to the second shadow-register and, in response to the preload end signal, transferring the first configuration data from the first shadow-register to the first resource and inhibiting the transfer of the second configuration data from the second shadow-register to the second resource.
18. A One-Time Programmable (OTP) memory controller comprising: a data register; a given number K of shadow-registers, wherein the number K is smaller than a given number N of memory slots of an OTP memory area; a communication interface configured to receive a read request requesting the data of a given memory slot; and a control circuit configured to receive a preload start signal and a shadow-register preload enable signal, wherein the control circuit is configured to manage a preload phase and a data-read phase, wherein, in response to the preload start signal, the control circuit is configured to perform the preload phase by: determining a mapping between the given number K of shadow-registers and the given number N of memory slots, determining, for each of the shadow-registers, whether the respective shadow-register is preloadable as a function of the shadow-register preload enable signal, in response to determining that a shadow-register is preloadable, transferring data from the memory slot mapped to the shadow-register to the respective shadow-register, and once the shadow-register is preloaded based on the shadow-register preload enable signal, asserting a preload end signal and start the data-read phase.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
[0060] Embodiments of the present disclosure will now be described with reference to the annexed drawings, which are provided purely by way of non-limiting example and in which:
[0061]
[0062]
[0063]
[0064]
[0065]
[0066]
[0067]
[0068]
DETAILED DESCRIPTION OF ILLUSTRATIVE EMBODIMENTS
[0069] In the following description, numerous specific details are given to provide a thorough understanding of embodiments. The embodiments can be practiced without one or several specific details, or with other methods, components, materials, etc. In other instances, well-known structures, materials, or operations are not shown or described in detail to avoid obscuring aspects of the embodiments.
[0070] Reference throughout this specification to one embodiment or an embodiment means that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment. Thus, the appearances of the phrases in one embodiment or in an embodiment in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0071] The headings provided herein are for convenience only and do not interpret the scope or meaning of the embodiments.
[0072] In the following
[0073] As mentioned before, various embodiments of the present disclosure provide solutions for managing an OTP memory. Reference can be made to the previous description of
[0074]
[0075] As mentioned before, the present disclosure relates specifically to processing system 10a adapted to be switched off at least in part. For example, for this purpose, the processing system 10a comprise typically two sub-circuits: [0076] a first sub-circuit 32.sub.1 comprising circuits to be switched off; and [0077] a second sub-circuit 32.sub.2 comprising circuits, which are maintained enabled/switched-on, so called always-on domain.
[0078] In the embodiment considered, the processing system 10a comprises thus a power supply circuit 117 configured to generate a first supply voltages VDD.sub.1 for the first sub-circuit 32.sub.1 and a second supply voltages VDD.sub.2 for the first sub-circuit 32.sub.2. For example, for this purpose the power supply circuit 117 may receive an input voltage Vin, such as a voltage provided by a battery. Specifically, once the supply voltage Vin is received, the power supply circuit 117 generates the supply voltage VDD.sub.2. For example, the voltage VDD.sub.2 may correspond to the voltage Vin. However, the power supply circuit 117 may also comprise a voltage source, such as an electronic converter, configured to generate a regulated voltage VDD.sub.2 based on the input voltage Vin. Moreover, the power supply circuit 117 is configured to generate the voltage VDD.sub.1. However, in this case, the power supply circuit 117 is configured to provide the voltage VDD.sub.1 only when a signal POFF has a given logic level/is de-asserted, e.g., when the signal POFF is set to low. For example, in the simplest case, the voltage VDD.sub.1 may be provided via an electronic switch, which is connected to the voltage VDD.sub.2 and closed when the signal POFF has the given logic level/is de-asserted. In general, the voltages VDD.sub.1 and VDD.sub.2 may have the same value or different values, e.g., the value of voltage VDD.sub.2 may be smaller than the value of the voltage VDD.sub.1.
[0079] For example, in the embodiment considered, the first sub-circuit 32.sub.1 comprises a processing core 102a, one or more resources 106.sub.1, an OTP memory 120a and a hardware configuration circuit 108a. For a more detailed description of the connection between these circuits may be made reference to the description of
[0080] Specifically, in the embodiment considered, the first sub-circuit 32.sub.1 comprises also a power supply monitoring circuit 115 configured to assert a signal POK when the supply voltage VDD.sub.1 exceeds a given threshold value, i.e., when the first sub-circuit 32.sub.1 is supplied. In response to this signal POK, the OTP memory 120a preloads the shadow-registers 1208 of the OTP memory 120a and once having preloaded the shadow-registers 1208, the OTP memory 120a asserts the signal OTP_DONE (see also the description of
[0081] In the embodiment considered, the signals POK and OTP_DONE are provided to a reset management circuit 116. Specifically, in the embodiment considered, the reset management circuit 116 is configured to: [0082] in response to the signal POK, start a reset phase by asserting a reset signal RST provided to the processing core 102a and possibly one or more further reset signals used to reset the registers of one or more of other circuits of the first sub-circuit 32.sub.1, such as one or more resources/peripherals 106.sub.1; [0083] in response to the signal OTP_DONE, start a configuration phase by asserting a signal SCFG, wherein the hardware configuration circuit 108a reads, in response to the signal SCFG, one or more data from the OTP memory 120; and [0084] once the hardware configuration circuit 108a has read the data from the OTP memory 120, e.g., in response to a signal ECFG provided by the hardware configuration circuit 108 (not shown in
[0085] Accordingly, in order to implement a low-power mode, the second sub-circuit 32.sub.2 may comprise a power management circuit 118. Specifically, in the embodiment considered, the power management circuit 118 is configured to assert the signal POFF in response to a request received from the first sub-circuit 32.sub.1, for example a request received from the processing core 102a. For example, for this purpose, the power management circuit 118 may be connected to the communication channel 114 or 114b, whereby the processing core 102a may request a switch-off by sending via software instructions a (write) request to the power management circuit 118. Accordingly, once having received the request, and the signal POFF is asserted, the power supply circuit 117 disables/switches off the voltage VDD.sub.1 of the first sub-circuit 321, thereby switching off the respective circuits.
[0086] Conversely, in order to de-assert the signal POFF, the power management circuit 118 may monitor one or more signals indicating given events, such as one or more trigger signals, e.g.: [0087] a first trigger/event signal TRIG1 received via a terminal of the processing system 10a, such as a pin or pad of a respective integrated circuit; and/or [0088] a second trigger/event signal TRIG2 provided by a resource/peripheral in the sub-circuit 32.sub.2, such as a timer circuit, such as a watchdog timer, a communication interface, an analog comparator, etc.
[0089] Accordingly, in various embodiments, each resource/peripheral 106 of the processing system 10a may be either in the sub-circuit 32.sub.1 or the sub-circuit 32.sub.2. In various embodiments, the processing system 10a may be configured to permit for one or more of the resources/peripherals 106 a selection whether the respective resource/peripheral 106 belongs to the first sub-circuit 32.sub.1 (and are thus switched off) or to the second sub-circuit 32.sub.2 (and may thus be used to generate the trigger signal TRIG2).
[0090] Accordingly, in response to the event/trigger signal TRIG1 and/or TRIG2, the power management circuit 118 de-asserts the signal POFF, whereby the power-supply circuit 117 switches on again the supply voltage VDD.sub.1, whereby the first sub-circuit 32.sub.1 is started again, thereby preloading the data to the shadow-registers 1208 and executing the reset, configuration and software runtime phase.
[0091] Accordingly, as shown in
[0092] However, as shown in
[0093] Accordingly, in various embodiments, the OTP memory 120a permits to specify which data should be preloaded, in response to the signal POK, from the OTP memory areas 1200 to the shadow-registers 1208.
[0094]
[0095] In the embodiment considered, the OTP memory 120a comprises: [0096] a memory area 1200 having a given number N of memory slots, i.e, slots OTP1, . . . , OTPN; [0097] a given number of K shadow-registers SREG, i.e, registers SREG1, . . . , SREGK, wherein the number K is smaller than the number N; [0098] a (shared) register 1206; [0099] a communication interface 1202, such as a communication interface for connecting the OTP memory 120a to the peripheral bus 114b; [0100] a control circuit 1204a.
[0101] In various embodiments, the OTP memory 120a may also comprise the optional interfaces 1210 and/or 1212.
[0102] Specifically, as schematically shown in
[0106] Accordingly, in case the control circuit 1204a is also configured to write data to the OTP memory area 1200, e.g., by storing via the communication interface 1202 (or another communication interface of the OTP memory 120a) respective data to a shadow-register SREG or the shared register 1206, the control circuit may be configured to transfer the respective data to a given memory slot by: [0107] reading the P bits from the register, [0108] generating M bits by encoding the P bits of data or adding ECC bits to the P bits; and [0109] storing the P bits to the respective memory slot.
[0110] For example, when each bit of the P bits of data should be programmable individually (bit-programmable), the M bits comprise preferably redundant bits for each of the P bits, such as at least two further redundant bits. Conversely, in case only the complete word may be written (word programmable), also other ECC schemes may be used.
[0111] In addition to managing the read and write requests received via the interface(s) of the OTP memory 120a, the control circuit 1204a also manages a preload mechanism. Specifically, in the embodiment considered, the OTP memory 120a, and in particular the control circuit 1204a of the OTP memory 120a, receives for this purpose the signal POK and a shadow-register selection signal SSA.
[0112] Specifically, in the embodiment considered, the signal SSA indicates the mapping of the K shadow-registers SREG to the N memory slots of the memory area 1200.
[0113] For example,
[0114] For example, in
[0120] Accordingly, in the embodiment considered, up to 5 bits may be asserted of the signal SSA.
[0121] In the embodiment considered, the control circuit 1204a may thus use the signal SSA in order to determine the mapping between memory slots and the shadow-registers. For example, when receiving a read request requesting the data stored to a given memory slot, the control circuit 1204a may use the signal SSA in order to determine whether the data of the respective slot are also stored to a shadow-register and: [0122] when the signal SSA indicates that the data of the respective slot are also stored to a shadow-register, transmit the data stored to the shadow-register, i.e., without performing a further read operation to the memory area 1200; and [0123] when the signal SSA indicates that the data of the respective slot are not stored to a shadow-register, transfer the data of the memory slot to the shared register 1206 and then transmit the data stored to the shared register 1206.
[0124] Accordingly, in the embodiment considered, the duration of the preload phase may be reduced, by enabling via the signal SSA only the preloading of data, which are also expected to be used by the processing system 10a during the next operation interval when the sub-circuit 32.sub.1 is switched on.
[0125] However, the inventors have observed that the use of the signal SSA alone may have several disadvantages. For example, on the one hand, this implies that given memory slots, which are not required for the boot of the processing system 10a may be read later on and even several times, whereby access times are significantly increased, because the data of the respective memory slot are not stored to a respective shadow-register.
[0126] Moreover, as mentioned before, the location of given data in the shadow-registers should also be fixed, e.g., because the OTP memory 120a may also provide the data of one or more of the shadow-registers directly. For example, a shadow-register may be arranged to store the MAC address of an Ethernet communication interface 106, whereby this shadow-register is directly connected to the Ethernet communication interface 106. In this context, the signal SSA may also be a static signal prior to the synthesis operation of the control circuit 1204a, whereby the respective combination logic circuit may be implemented in an optimized manner via the logic synthesis operation.
[0127] Accordingly, in various embodiments, the shadow-register selection signal SSA is used as a static signal, and is thus also identified as static shadow array signal. For example, based on the application, this signal may be hardwired within the processing system 10a or may be a static signal prior to the logic synthesis operation, thereby specifying permanently a given mapping of the shadow-registers 1208 to the memory area 1200. Conversely, the OTP memory 120a, in particular the control circuit 1204a, is configured to receive a further signal DSA specifying, which of the shadow-registers 1208 should be preloaded in response to the signal POK, i.e., the signal DSA specifies dynamically the preloading of the shadow-registers and is also identified as dynamic shadow array signal.
[0128] For example,
[0129] For example, for the exemplary situation shown in
[0130] Conversely,
[0131] For example, for the exemplary situation shown in
[0132] Accordingly, as shown in
[0133]
[0134] Specifically, as mentioned before, the signal SSA may be hardwired or may just be a static signal used for the logic synthesis operation, e.g., in the context of a VHDL or Verilog model. Alternatively, in various embodiments, the signal SSA may be determined as a function of the data stored to a non-volatile memory. For example, in various embodiments, the control circuit 1204a is configured to determine the signal SSA based on the content of one or more memory slots of the OTP memory area 1200.
[0135] Conversely, in the embodiment considered, the signal DSA is provided by a circuit 122.
[0136] Specifically, as mentioned before, the data stored to the shadow-registers of the OTP memory 120a may be read by a processing core 102a and/or the hardware configuration circuit 108a.
[0137] For example, as schematically shown in
[0138] Accordingly, in various embodiments, the circuit 122 may comprise for one or more bits of the signal DSA a respective register (or a respective set of redundant registers), and the hardware configuration circuit 108a may be configured to de-assert the bits associated with the configuration data CD.sub.2, whereby the respective memory slots of the OTP memory 120a are not preloaded at the next re-activation of the sub-circuit 32.sub.1. Conversely, when the complete processing system is switched off, also the registers of the circuit 122 will lose the stored data, whereby the signal DSA is reset. For example, in various embodiments, the circuit 122 is configured to provide, once having been reset, as signal DSA the same bit sequence as the signal SSA. For example, for this purpose, the signal SSA may also be provided to the circuit 122.
[0139] Similarly, the processing core 102a may be configured to program one or more of the registers of the circuit 122 in order to set the signal DSA. For example, for this purpose, the circuit 122 may be connected to the communication system 114, e.g., via the communication system 114b.
[0140] Additionally or alternatively, as schematically shown in
[0141] Generally, the above solutions may also be combined. For example, as schematically shown in
[0144] For example, in this way, when the processing system 10a is switched on, the signal SSA may indicate that the memory slot comprising a MAC address should be preloaded to a given shadow-register 1208. Accordingly, in response to the signal POK, the control circuit 1204a uses the signals SSA and DSA to preload the shadow-registers. Specifically, due to the fact that the signal DSA has its reset value, the control circuit 1204a preloads the MAC address from the memory area 1200 to the respective shadow-register 1208. Once having finished the preloading of the shadow-registers, the control circuit 1204a asserts the signal OTP_DONE.
[0145] In case the hardware configuration circuit 108a is provided/used, the reset management circuit 116 may then assert the signal SCFG. In response to this signal, the hardware configuration circuit 108a reads the MAC address from the OTP memory and transmits the MAC address to an Ethernet communication interface 106 within the sub-circuit 32.sub.2 of the processing system 10a. Moreover, the hardware configuration circuit 108a may program a respective flag in the circuit 122.
[0146] Alternatively, the shadow-register 1208 may also be connected directly to the Ethernet communication interface 106. In this case, the Ethernet communication interface 106 may directly signal to the circuit 122 that the MAC address is valid.
[0147] Accordingly, when the processing system 10a actives the low power mode, wherein the sub-circuit 32.sub.1 is switched off, the Ethernet communication interface 106 will maintain the MAC address. Accordingly, once the sub-circuit 32.sub.1 is switched on again, the signal SSA again indicates that the memory slot comprising a MAC address should be preloaded to the same shadow-register 1208. Accordingly, in response to the signal POK, the control circuit 1204a uses the signals SSA and DSA to preload the shadow-registers. Specifically, this time the bit associated with the memory slot containing the MAC address is de-asserted, whereby, the control circuit 1204a omits the preloading of the MAC address from the memory area 1200 to the respective shadow-register 1208. Once having finished the preloading of the shadow-registers, the control circuit 1204a asserts again the signal OTP_DONE.
[0148] In case the hardware configuration circuit 108a is provided/used, the reset management circuit 116 may then assert again the signal SCFG. As shown in
[0149] Alternatively, when the shadow-register 1208 is connected directly to the Ethernet communication interface 106, the Ethernet communication interface 106 may simply not request the data from the shadow-register because the MAC address is still valid.
[0150] Of course, without prejudice to the principle of the invention, the details of construction and the embodiments may vary widely with respect to what has been described and illustrated herein purely by way of example, without thereby departing from the scope of the present invention, as defined by the ensuing claims. For example, while in the previous description a software programmable processing core comprising a micro-processor has been used, also any other digital processing core may be used.