From 049cdd0dd3d27e771907fff82967df78d88f0aa7 Mon Sep 17 00:00:00 2001 From: Alessandro Gatti Date: Fri, 14 Nov 2025 03:33:47 +0100 Subject: [PATCH] cc3200/mods/pybpin: Reduce footprint of AF pin structures. This commit performs a minor change to the "pin_af_t" structure, changing the data type used to store alternate function pin name QSTRs in order to have a smaller impact on the .rodata section of the firmware. The data type used to store the QSTR name of the pin is changed from "qstr" to "qstr_short_t", that is able to store the same name string index but in half the size. Other pin-related structures in the port that also store QSTRs do not benefit from a narrower data type, as their members are mostly word-aligned and thus the linker is forced to insert padding bytes between entries. Signed-off-by: Alessandro Gatti --- ports/cc3200/mods/pybpin.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/cc3200/mods/pybpin.h b/ports/cc3200/mods/pybpin.h index 74f0af2b3c..5e55d2cf95 100644 --- a/ports/cc3200/mods/pybpin.h +++ b/ports/cc3200/mods/pybpin.h @@ -88,7 +88,7 @@ enum { }; typedef struct { - qstr name; + qstr_short_t name; int8_t idx; uint8_t fn; uint8_t unit;