This is an automated email from Gerrit.

Richard Watts ([email protected]) just uploaded a new patch set to Gerrit, 
which you can find at http://openocd.zylin.com/3934

-- gerrit

commit 249aed6a72a7d923258957cd8fac9c8875e3f73e
Author: Richard Watts <[email protected]>
Date:   Mon Jan 2 11:56:36 2017 +0000

    flash/nor/efm32: Support EZR32HG devices.
    
    Recognise the family number for Silicon Labs EZR32HG devices and
    select the correct flash page size.
    
    Change-Id: I876e930f3a9f679557fa0d0acac33e9bbfb28c46
    Signed-off-by: Richard Watts <[email protected]>

diff --git a/src/flash/nor/efm32.c b/src/flash/nor/efm32.c
index 81c1a37..7b19ab2 100644
--- a/src/flash/nor/efm32.c
+++ b/src/flash/nor/efm32.c
@@ -48,6 +48,7 @@
 #define EFM_FAMILY_ID_HAPPY_GECKO      77
 #define EZR_FAMILY_ID_WONDER_GECKO             120
 #define EZR_FAMILY_ID_LEOPARD_GECKO            121
+#define EZR_FAMILY_ID_EZR32HG           122
 
 #define EFM32_FLASH_ERASE_TMO           100
 #define EFM32_FLASH_WDATAREADY_TMO      100
@@ -178,7 +179,8 @@ static int efm32x_read_info(struct flash_bank *bank,
                        EFM_FAMILY_ID_TINY_GECKO == efm32_info->part_family)
                efm32_info->page_size = 512;
        else if (EFM_FAMILY_ID_ZERO_GECKO == efm32_info->part_family ||
-                       EFM_FAMILY_ID_HAPPY_GECKO == efm32_info->part_family)
+                       EFM_FAMILY_ID_HAPPY_GECKO == efm32_info->part_family ||
+                       EZR_FAMILY_ID_EZR32HG == efm32_info->part_family)
                efm32_info->page_size = 1024;
        else if (EFM_FAMILY_ID_GIANT_GECKO == efm32_info->part_family ||
                        EFM_FAMILY_ID_LEOPARD_GECKO == efm32_info->part_family) 
{
@@ -236,6 +238,7 @@ static int efm32x_decode_info(struct efm32_info *info, char 
*buf, int buf_size)
        switch (info->part_family) {
                case EZR_FAMILY_ID_WONDER_GECKO:
                case EZR_FAMILY_ID_LEOPARD_GECKO:
+               case EZR_FAMILY_ID_EZR32HG:
                        printed = snprintf(buf, buf_size, "EZR32 ");
                        break;
                default:
@@ -272,6 +275,9 @@ static int efm32x_decode_info(struct efm32_info *info, char 
*buf, int buf_size)
                case EFM_FAMILY_ID_HAPPY_GECKO:
                        printed = snprintf(buf, buf_size, "Happy Gecko");
                        break;
+               case EZR_FAMILY_ID_EZR32HG:
+                       printed = snprintf(buf, buf_size, "EZR32HG");
+                       break;
        }
 
        buf += printed;

-- 

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to