kasjer commented on code in PR #2827:
URL: https://github.com/apache/mynewt-core/pull/2827#discussion_r875527960


##########
hw/mcu/dialog/da1469x/src/hal_flash.c:
##########
@@ -24,6 +24,7 @@
 #include "mcu/da1469x_hal.h"
 #include "hal/hal_flash_int.h"
 #include "mcu/mcu.h"
+#include <os/util.h>

Review Comment:
   This probably should be moved to hal_bsp.c



##########
hw/bsp/dialog_da1469x-dk-pro/src/hal_bsp.c:
##########
@@ -41,6 +41,15 @@ static const struct hal_bsp_mem_dump dump_cfg[] = {
  */
 static char hw_id[] = "DA1469X_HW_ID";
 
+
+/*
+ * Configure empty RDIDs for use by flash init.
+ */
+#if MYNEWT_VAL(RAM_RESIDENT)
+const struct qspi_flash_config rdids[] = 0;
+const int qspi_flash_config_array_size = ARRAY_SIZE(rdids);

Review Comment:
   ```
   Error: 
repos/apache-mynewt-core/hw/bsp/dialog_da1469x-dk-pro/src/hal_bsp.c:49:42: 
error: invalid initializer
    const struct qspi_flash_config rdids[] = 0;
                                             ^
   repos/apache-mynewt-core/hw/bsp/dialog_da1469x-dk-pro/src/hal_bsp.c:50:42: 
error: implicit declaration of function 'ARRAY_SIZE'; did you mean 'RAM_SIZE'? 
[-Werror=implicit-function-declaration]
    const int qspi_flash_config_array_size = ARRAY_SIZE(rdids);
                                             ^~~~~~~~~~
                                             RAM_SIZE
   repos/apache-mynewt-core/hw/bsp/dialog_da1469x-dk-pro/src/hal_bsp.c:50:42: 
error: initializer element is not constant
   ```
   I guess you meant:
   ```c
   const struct qspi_flash_config rdids[] = {};
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@mynewt.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to