diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2018-05-07 21:32:27 -0400 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2018-05-25 11:52:13 -0400 |
commit | 970831ee0d3b91897196e92270d98b2a3067427f (patch) | |
tree | 441c2b329ea669ff5e996a617d7b6bc2c315fa0d /lib/lpc176x/lpc176x.patch | |
parent | 5ae22a5e51872fd3e6130a3acce68f598bee9ff0 (diff) | |
download | kutter-970831ee0d3b91897196e92270d98b2a3067427f.tar.gz kutter-970831ee0d3b91897196e92270d98b2a3067427f.tar.xz kutter-970831ee0d3b91897196e92270d98b2a3067427f.zip |
lpc176x: Add initial support for LPC176x processors
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'lib/lpc176x/lpc176x.patch')
-rw-r--r-- | lib/lpc176x/lpc176x.patch | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/lib/lpc176x/lpc176x.patch b/lib/lpc176x/lpc176x.patch new file mode 100644 index 00000000..f8995d3f --- /dev/null +++ b/lib/lpc176x/lpc176x.patch @@ -0,0 +1,39 @@ +--- device/system_LPC17xx.c 2018-05-02 12:23:57.292132454 -0400 ++++ device/system_LPC17xx.c 2018-05-23 20:09:29.681308483 -0400 +@@ -297,19 +297,16 @@ + #define CLKSRCSEL_Val 0x00000001 + #define PLL0_SETUP 1 + +-#ifdef MCB1700 +-# define PLL0CFG_Val 0x00050063 +-# define PLL1_SETUP 1 +-# define PLL1CFG_Val 0x00000023 +-# define CCLKCFG_Val 0x00000003 +-# define USBCLKCFG_Val 0x00000000 ++#include "autoconf.h" // CONFIG_MACH_LPC1769 ++#if CONFIG_MACH_LPC1769 ++# define PLL0CFG_Val 0x0000000E + #else +-# define PLL0CFG_Val 0x0000000B +-# define PLL1_SETUP 0 +-# define PLL1CFG_Val 0x00000000 +-# define CCLKCFG_Val 0x00000002 +-# define USBCLKCFG_Val 0x00000005 ++# define PLL0CFG_Val 0x00010018 + #endif ++#define PLL1_SETUP 1 ++#define PLL1CFG_Val 0x00000023 ++#define CCLKCFG_Val 0x00000002 ++#define USBCLKCFG_Val 0x00000000 + + #define PCLKSEL0_Val 0x00000000 + #define PCLKSEL1_Val 0x00000000 +@@ -514,7 +511,7 @@ + * @brief Setup the microcontroller system. + * Initialize the System. + */ +-void SystemInit (void) ++void __attribute__((externally_visible)) SystemInit (void) + { + #if (CLOCK_SETUP) /* Clock Setup */ + LPC_SC->SCS = SCS_Val; |