fal_cfg.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. /*
  2. * Copyright (C) 2012-2019 UCloud. All Rights Reserved.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License").
  5. * You may not use this file except in compliance with the License.
  6. * A copy of the License is located at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * or in the "license" file accompanying this file. This file is distributed
  11. * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
  12. * express or implied. See the License for the specific language governing
  13. * permissions and limitations under the License.
  14. */
  15. #ifndef _FAL_CFG_H_
  16. #define _FAL_CFG_H_
  17. #include <rtconfig.h>
  18. #include <board.h>
  19. /* ===================== Flash device Configuration ========================= */
  20. extern const struct fal_flash_dev stm32_onchip_flash;
  21. /* flash device table */
  22. #define FAL_FLASH_DEV_TABLE \
  23. { \
  24. &stm32_onchip_flash, \
  25. }
  26. /* ====================== Partition Configuration ========================== */
  27. #ifdef FAL_PART_HAS_TABLE_CFG
  28. /* partition table */
  29. #define FAL_PART_TABLE \
  30. { \
  31. {FAL_PART_MAGIC_WORD, "app", "onchip_flash", 512*1024, 512*1024, 0}, \
  32. {FAL_PART_MAGIC_WORD, "download", "onchip_flash", 1024*1024, 512*1024, 0}, \
  33. {FAL_PART_MAGIC_WORD, "factory", "onchip_flash", 1536*1024, 512*1024, 0}, \
  34. }
  35. #endif /* FAL_PART_HAS_TABLE_CFG */
  36. #endif /* _FAL_CFG_H_ */