]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
asm/arch-meson: add missing meson_sm_write_efuse signature
authorAlexey Romanov <avromanov@sberdevices.ru>
Tue, 10 Jan 2023 10:56:46 +0000 (13:56 +0300)
committerNeil Armstrong <neil.armstrong@linaro.org>
Tue, 10 Jan 2023 14:25:48 +0000 (15:25 +0100)
This function can be used by other modules. Also add comments.

Signed-off-by: Alexey Romanov <avromanov@sberdevices.ru>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
Link: https://lore.kernel.org/r/20230110105650.54580-2-avromanov@sberdevices.ru
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
arch/arm/include/asm/arch-meson/sm.h

index f3ae46a6d6b57da4497953914202c840f2cc95b6..53b751764936585da614660f9cc3dd84ac51cf62 100644 (file)
@@ -6,10 +6,35 @@
 #ifndef __MESON_SM_H__
 #define __MESON_SM_H__
 
+/**
+ * meson_sm_read_efuse - read efuse memory into buffer
+ *
+ * @offset: offset from the start efuse memory
+ * @buffer: pointer to buffer
+ * @size: number of bytes to read
+ * @return: number of bytes read
+ */
 ssize_t meson_sm_read_efuse(uintptr_t offset, void *buffer, size_t size);
 
+/**
+ * meson_sm_write_efuse - write into efuse memory from buffer
+ *
+ * @offset: offset from the start efuse memory
+ * @buffer: pointer to buffer
+ * @size: number of bytes to write
+ * @return: number of bytes written
+ */
+ssize_t meson_sm_write_efuse(uintptr_t offset, void *buffer, size_t size);
+
 #define SM_SERIAL_SIZE 12
 
+/**
+ * meson_sm_get_serial - read chip unique id into buffer
+ *
+ * @buffer: pointer to buffer
+ * @size: buffer size.
+ * @return: zero on success or -errno on failure
+ */
 int meson_sm_get_serial(void *buffer, size_t size);
 
 enum {
@@ -28,6 +53,9 @@ enum {
        REBOOT_REASON_WATCHDOG_REBOOT = 13,
 };
 
+/**
+ * meson_sm_get_reboot_reason - get reboot reason
+ */
 int meson_sm_get_reboot_reason(void);
 
 #endif /* __MESON_SM_H__ */