[riot-notifications] [RIOT-OS/RIOT] FIDO2 support in RIOT (#16489)

benpicco notifications at github.com
Fri Aug 27 13:57:55 CEST 2021

@benpicco commented on this pull request.

> +#ifndef FIDO2_CTAP_CTAP_MEM_H
+#include <stdint.h>
+#include "fido2/ctap/ctap.h"
+#include "periph/flashpage.h"
+#ifdef __cplusplus
+extern "C" {
+ * @brief Start page for storing resident keys
+ */

Hm maybe we should have that. For `cpu/cortexm_common` it would be

unsigned flashpage_first_free(void)
    const uint32_t *end_fw = &_etext + (&_erelocate - &_srelocate);
    return flashpage_page(&end_fw) + 1;

but then why not start at the end of the flash and subtract as much space as you need (`FLASHPAGE_NUMOF - x`).

But then again why do you need multiple flashpages / a whole flashpage for each struct?
We could reasonably well place a memory region at the end of flash with the linker script, but that would make no guarantees about what number of flash pages you get.
Is this some attempt at wear-leveling? 

You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210827/21bcede4/attachment-0001.htm>

More information about the notifications mailing list