rollback a "find/replace" side effect : restore original variable name
authorNathael Pajani <nathael.pajani@ed3l.fr>
Thu, 3 Nov 2022 16:28:39 +0000 (17:28 +0100)
committerNathael Pajani <nathael.pajani@ed3l.fr>
Tue, 8 Nov 2022 16:14:24 +0000 (17:14 +0100)
eeprom/main.c

index e2f1f47..62a1129 100644 (file)
@@ -85,7 +85,7 @@ const struct pio i2c_eeprom_cs = LPC_GPIO_0_15;
 #define UEXT_MOD_HAS_SPI  (1 << 2)
 
 struct module_desc {
-       uint16_t uart_number;
+       uint16_t serial_number;
        uint8_t version;
        uint8_t header_size;
        uint8_t capabilities; /* Bit mask of UEXT_MOD_HAS_* */
@@ -149,7 +149,7 @@ void module_desc_dump(uint8_t uart_num)
        /* Send the content of the header and the module name */
        uprintf(uart_num, "Module : %s\n", buff);
        uprintf(uart_num, "serial number: %d, version: %d, capabilities: 0x%04x\n",
-                                               desc.uart_number, desc.version, desc.capabilities);
+                                               desc.serial_number, desc.version, desc.capabilities);
        mod_gpio_demo_eeprom_cs_release();
 }
 
@@ -157,7 +157,7 @@ int module_desc_set(char* name, uint8_t module_version, uint16_t serial_num, uin
 {
        int ret = 0;
        struct module_desc desc = {
-               .uart_number = serial_num,
+               .serial_number = serial_num,
                .version = module_version,
                .capabilities = (UEXT_MOD_HAS_UART | UEXT_MOD_HAS_I2C | UEXT_MOD_HAS_SPI),
                .name_offset = sizeof(struct module_desc),