Update code to v1.0.14 (10)

This commit is contained in:
Caten
2024-02-29 19:35:00 +08:00
parent c2ee3b694c
commit a956d26f6d
3188 changed files with 2317293 additions and 146 deletions

View File

@@ -0,0 +1,29 @@
<!DOCTYPE Linker_Placement_File>
<Root name="Flash Section Placement">
<MemorySegment name="$(FLASH_NAME:FLASH)">
<ProgramSection alignment="4" load="Yes" name=".vectors" inputsections="KEEP(*(.vectors .vectors.*))" start="$(FLASH_START:)" />
<ProgramSection alignment="4" load="Yes" name=".flashconf" inputsections="KEEP(*(.flashconf .flashconf.*))" start="$(FLASH_START:)+0x400" size="0xF"/>
<ProgramSection alignment="4" load="Yes" name=".init" />
<ProgramSection alignment="4" load="Yes" name=".init_rodata" />
<ProgramSection alignment="4" load="Yes" name=".text" />
<ProgramSection alignment="4" load="Yes" name=".dtors" />
<ProgramSection alignment="4" load="Yes" name=".ctors" />
<ProgramSection alignment="4" load="Yes" name=".rodata" />
<ProgramSection alignment="4" load="Yes" name=".ARM.exidx" address_symbol="__exidx_start" end_symbol="__exidx_end" />
<ProgramSection alignment="4" load="Yes" runin=".fast_run" name=".fast" />
<ProgramSection alignment="4" load="Yes" runin=".data_run" name=".data" />
<ProgramSection alignment="4" load="Yes" runin=".tdata_run" name=".tdata" />
</MemorySegment>
<MemorySegment name="$(RAM_NAME:RAM);SRAM">
<ProgramSection alignment="4" load="No" name=".vectors_ram" start="$(RAM_START:$(SRAM_START:))" />
<ProgramSection alignment="4" load="No" name=".fast_run" />
<ProgramSection alignment="4" load="No" name=".data_run" />
<ProgramSection alignment="4" load="No" name=".tdata_run" />
<ProgramSection alignment="4" load="No" name=".bss" />
<ProgramSection alignment="4" load="No" name=".tbss" />
<ProgramSection alignment="4" load="No" name=".non_init" />
<ProgramSection alignment="4" size="__HEAPSIZE__" load="No" name=".heap" />
<ProgramSection alignment="8" size="__STACKSIZE__" load="No" name=".stack" />
<ProgramSection alignment="8" size="__STACKSIZE_PROCESS__" load="No" name=".stack_process" />
</MemorySegment>
</Root>

View File

@@ -0,0 +1,62 @@
# Rowley CrossWorks ARM Project for wolfSSL and wolfCrypt
This directory contains a CrossWorks solution named wolfssl.hzp.
Inside are three projects:
1. libwolfssl:
This generates a library file named "libwolfssl_ARM_Debug/libwolfssl_v7em_t_le_eabi.a"
2. benchmark:
This is a sample benchmark application. It runs the "benchmark_test" suite repeatedly until a failure occurs.
3. test:
This is a sample test application. It runs "wolfcrypt_test" suite suite repeatedly until a failure occurs.
# Prerequisites
+You will need to install the "Freescale Kinetis CPU Support Package" and "ARM CPU Support Package" in the Rowley Package Manager under Tools -> Package Manager.
# Hardware Support
All hardware functions are defined in `kinetis_hw.c` and are currently setup for a Freescale Kinetis K64 Coretx-M4 microcontroller. This file can be customized to work with other Kinetis microcontrollers by editing the top part of the file. Testing for this project was done with the Freescale Kinetis `MK64FN1M0xxx12` using the `TWR-K64F120M`. To build for the `TWR-K64F120M` or `FRDM-K64F`, define `WOLFSSL_FRDM_K64` in the Preprocessor Definitions section of CrossStudio, or define it in "user_settings.h".
To create support for a new ARM microcontroller the functions in `hw.h` will need to be implemented.
Also you will need to configure the ARM Architecture and ARM Core Type in the "Solution Properties" -> "ARM".
Also the "Target Processor" in each of the projects ("Project Properties" -> "Target Processor")
## Hardware Crypto Acceleration
To enable NXP/Freescale MMCAU:
1. [Download the MMCAU library](http://www.freescale.com/products/arm-processors/kinetis-cortex-m/k-series/k7x-glcd-mcus/crypto-acceleration-unit-cau-and-mmcau-software-library:CAUAP).
2. Copy the `lib_mmcau.a` and `cau_api.h` files into the project.
3. Define `USE_NXP_MMCAU` to enable in `user_settings.h`.
4. Add the `lib_mmcau.a` file to `Source Files` in the application project.
5. Open the wolfssl_ltc.hzp CrossWorks project
6. Build and run
To enable the NXP/Freescale MMCAU and/or LTC:
1. [Download the NXP KSDK 2.0](https://nxp.flexnetoperations.com/control/frse/download?agree=Accept&element=7353807)
2. Copy the following folders into IDE/ROWLEY-CROSSWORKS-ARM: drivers, mmcau_2.0.0 and CMSIS.
3. Copy the following files into IDE/ROWLEY-CROSSWORKS-ARM: clock_config.c, clock_config.h, fsl_debug_console.c, fsl_debug_console.h, fsl_device_registers.h, system_MK82F25615.c, system_MK82F25615.h, MK82F25615.h and MK82F25615_features.h.
4. Define `USE_NXP_LTX` to enable in `user_settings.h`.
5. Open the wolfssl_ltc.hzp CrossWorks project
6. Build and run
# Project Files
* `arm_startup.c`: Handles startup from `reset_handler`. Disabled watchdog, initializes sections, initializes heap, starts hardware and starts main.
* `benchmark_main.c`: The main function entrypoint for benchmark application.
* `hw.h`: The hardware API interface. These hardware interface functions are required for all platforms.
* `kinetis_hw.c`: The most basic hardware implementation required for Kinetis.
* `test_main.c`: The main function entrypoint for test application.
* `user_libc.c`: Defines stubs for functions required by libc. It also wraps hardware functions for UART, RTC and Random Number Generator (RNG).
* `user_settings.h`: This is the custom user configuration file for WolfSSL.
# Functions required by the WolfSSL Library
If you are writing your own application, the following functions need to be implemented to support the WolfSSL library:
* `double current_time(int reset)`: Returns a double as seconds.milliseconds.
* `int custom_rand_generate(void)`: Returns a 32-bit randomly generated number.

View File

@@ -0,0 +1,310 @@
/* arm_startup.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#include "hw.h"
#include <stdio.h>
// Memory initialization
extern uint32_t __data_load_start__[];
extern uint32_t __data_start__[];
extern uint32_t __data_end__[];
extern uint32_t __bss_start__[];
extern uint32_t __bss_end__[];
extern uint32_t __fast_load_start__[];
extern uint32_t __fast_start__[];
extern uint32_t __fast_end__[];
extern uint32_t __stack_process_end__[];
extern uint32_t __heap_start__[];
extern uint32_t __heap_end__[];
// Copy memory: src=Source, dst_beg=Destination Begin, dst_end=Destination End
void memcpy32(uint32_t* src, uint32_t* dst_beg, uint32_t* dst_end)
{
while (dst_beg < dst_end) {
*dst_beg++ = *src++;
}
}
// Zero address in range
void meminit32(uint32_t* start, uint32_t* end)
{
while (start < end) {
*start++ = 0;
}
}
// Entry Point
void reset_handler(void)
{
// Disable Watchdog
hw_watchdog_disable();
// Init sections
memcpy32(__data_load_start__, __data_start__, __data_end__);
meminit32(__bss_start__, __bss_end__);
memcpy32(__fast_load_start__, __fast_start__, __fast_end__);
// Init heap
__heap_start__[0] = 0;
__heap_start__[1] = ((uint32_t)__heap_end__ - (uint32_t)__heap_start__);
// Init hardware
hw_init();
// Start main
extern void main(void);
main();
// Application has ended, so busy wait
while(1);
}
// Vector Exception/Interrupt Handlers
static void Default_Handler(void)
{
/* If we get here then need to implement real IRQ handler */
while(1);
}
void HardFault_HandlerC( uint32_t *hardfault_args )
{
/* These are volatile to try and prevent the compiler/linker optimizing them
away as the variables never actually get used. If the debugger won't show the
values of the variables, make them global my moving their declaration outside
of this function. */
volatile uint32_t stacked_r0;
volatile uint32_t stacked_r1;
volatile uint32_t stacked_r2;
volatile uint32_t stacked_r3;
volatile uint32_t stacked_r12;
volatile uint32_t stacked_lr;
volatile uint32_t stacked_pc;
volatile uint32_t stacked_psr;
volatile uint32_t _CFSR;
volatile uint32_t _HFSR;
volatile uint32_t _DFSR;
volatile uint32_t _AFSR;
volatile uint32_t _BFAR;
volatile uint32_t _MMAR;
stacked_r0 = ((uint32_t)hardfault_args[0]);
stacked_r1 = ((uint32_t)hardfault_args[1]);
stacked_r2 = ((uint32_t)hardfault_args[2]);
stacked_r3 = ((uint32_t)hardfault_args[3]);
stacked_r12 = ((uint32_t)hardfault_args[4]);
stacked_lr = ((uint32_t)hardfault_args[5]);
stacked_pc = ((uint32_t)hardfault_args[6]);
stacked_psr = ((uint32_t)hardfault_args[7]);
// Configurable Fault Status Register
// Consists of MMSR, BFSR and UFSR
_CFSR = (*((volatile uint32_t *)(0xE000ED28)));
// Hard Fault Status Register
_HFSR = (*((volatile uint32_t *)(0xE000ED2C)));
// Debug Fault Status Register
_DFSR = (*((volatile uint32_t *)(0xE000ED30)));
// Auxiliary Fault Status Register
_AFSR = (*((volatile uint32_t *)(0xE000ED3C)));
// Read the Fault Address Registers. These may not contain valid values.
// Check BFARVALID/MMARVALID to see if they are valid values
// MemManage Fault Address Register
_MMAR = (*((volatile uint32_t *)(0xE000ED34)));
// Bus Fault Address Register
_BFAR = (*((volatile uint32_t *)(0xE000ED38)));
printf ("\n\nHard fault handler (all numbers in hex):\n");
printf ("R0 = %x\n", stacked_r0);
printf ("R1 = %x\n", stacked_r1);
printf ("R2 = %x\n", stacked_r2);
printf ("R3 = %x\n", stacked_r3);
printf ("R12 = %x\n", stacked_r12);
printf ("LR [R14] = %x subroutine call return address\n", stacked_lr);
printf ("PC [R15] = %x program counter\n", stacked_pc);
printf ("PSR = %x\n", stacked_psr);
printf ("CFSR = %x\n", _CFSR);
printf ("HFSR = %x\n", _HFSR);
printf ("DFSR = %x\n", _DFSR);
printf ("AFSR = %x\n", _AFSR);
printf ("MMAR = %x\n", _MMAR);
printf ("BFAR = %x\n", _BFAR);
// Break into the debugger
__asm("BKPT #0\n");
}
__attribute__( ( naked ) )
void HardFault_Handler(void)
{
__asm volatile
(
" tst lr, #4 \n"
" ite eq \n"
" mrseq r0, msp \n"
" mrsne r0, psp \n"
" ldr r1, [r0, #24] \n"
" ldr r2, handler2_address_const \n"
" bx r2 \n"
" handler2_address_const: .word HardFault_HandlerC \n"
);
}
// Vectors
typedef void (*vector_entry)(void);
const vector_entry vectors[] __attribute__ ((section(".vectors"),used)) =
{
/* Interrupt Vector Table Function Pointers */
// Address Vector IRQ Source module Source description
(vector_entry)__stack_process_end__, // ARM core Initial Supervisor SP
reset_handler, // 0x0000_0004 1 - ARM core Initial Program Counter
Default_Handler, // 0x0000_0008 2 - ARM core Non-maskable Interrupt (NMI)
HardFault_Handler, // 0x0000_000C 3 - ARM core Hard Fault
Default_Handler, // 0x0000_0010 4 -
HardFault_Handler, // 0x0000_0014 5 - ARM core Bus Fault
HardFault_Handler, // 0x0000_0018 6 - ARM core Usage Fault
Default_Handler, // 0x0000_001C 7 -
Default_Handler, // 0x0000_0020 8 -
Default_Handler, // 0x0000_0024 9 -
Default_Handler, // 0x0000_0028 10 -
Default_Handler, // 0x0000_002C 11 - ARM core Supervisor call (SVCall)
Default_Handler, // 0x0000_0030 12 - ARM core Debug Monitor
Default_Handler, // 0x0000_0034 13 -
Default_Handler, // 0x0000_0038 14 - ARM core Pendable request for system service (PendableSrvReq)
Default_Handler, // 0x0000_003C 15 - ARM core System tick timer (SysTick)
#ifdef CPU_MK82FN256VLL15
// Add specific driver interrupt handlers below
Default_Handler, /* DMA0_DMA16_IRQn = 0, /**< DMA channel 0,16 transfer complete */
Default_Handler, /* DMA1_DMA17_IRQn = 1, /**< DMA channel 1,17 transfer complete */
Default_Handler, /* DMA2_DMA18_IRQn = 2, /**< DMA channel 2,18 transfer complete */
Default_Handler, /* DMA3_DMA19_IRQn = 3, /**< DMA channel 3,19 transfer complete */
Default_Handler, /* DMA4_DMA20_IRQn = 4, /**< DMA channel 4,20 transfer complete */
Default_Handler, /* DMA5_DMA21_IRQn = 5, /**< DMA channel 5,21 transfer complete */
Default_Handler, /* DMA6_DMA22_IRQn = 6, /**< DMA channel 6,22 transfer complete */
Default_Handler, /* DMA7_DMA23_IRQn = 7, /**< DMA channel 7,23 transfer complete */
Default_Handler, /* DMA8_DMA24_IRQn = 8, /**< DMA channel 8,24 transfer complete */
Default_Handler, /* DMA9_DMA25_IRQn = 9, /**< DMA channel 9,25 transfer complete */
Default_Handler, /* DMA10_DMA26_IRQn = 10, /**< DMA channel 10,26 transfer complete */
Default_Handler, /* DMA11_DMA27_IRQn = 11, /**< DMA channel 11,27 transfer complete */
Default_Handler, /* DMA12_DMA28_IRQn = 12, /**< DMA channel 12,28 transfer complete */
Default_Handler, /* DMA13_DMA29_IRQn = 13, /**< DMA channel 13,29 transfer complete */
Default_Handler, /* DMA14_DMA30_IRQn = 14, /**< DMA channel 14,30 transfer complete */
Default_Handler, /* DMA15_DMA31_IRQn = 15, /**< DMA channel 15,31 transfer complete */
Default_Handler, /* DMA_Error_IRQn = 16, /**< DMA channel 0 - 31 error */
Default_Handler, /* MCM_IRQn = 17, /**< MCM normal interrupt */
Default_Handler, /* FTFA_IRQn = 18, /**< FTFA command complete */
Default_Handler, /* Read_Collision_IRQn = 19, /**< FTFA read collision */
Default_Handler, /* LVD_LVW_IRQn = 20, /**< PMC controller low-voltage detect, low-voltage warning */
Default_Handler, /* LLWU_IRQn = 21, /**< Low leakage wakeup unit */
Default_Handler, /* WDOG_EWM_IRQn = 22, /**< Single interrupt vector for WDOG and EWM */
Default_Handler, /* TRNG0_IRQn = 23, /**< True randon number generator */
Default_Handler, /* I2C0_IRQn = 24, /**< Inter-integrated circuit 0 */
Default_Handler, /* I2C1_IRQn = 25, /**< Inter-integrated circuit 1 */
Default_Handler, /* SPI0_IRQn = 26, /**< Serial peripheral Interface 0 */
Default_Handler, /* SPI1_IRQn = 27, /**< Serial peripheral Interface 1 */
Default_Handler, /* I2S0_Tx_IRQn = 28, /**< Integrated interchip sound 0 transmit interrupt */
Default_Handler, /* I2S0_Rx_IRQn = 29, /**< Integrated interchip sound 0 receive interrupt */
Default_Handler, /* LPUART0_IRQn = 30, /**< LPUART0 receive/transmit/error interrupt */
Default_Handler, /* LPUART1_IRQn = 31, /**< LPUART1 receive/transmit/error interrupt */
Default_Handler, /* LPUART2_IRQn = 32, /**< LPUART2 receive/transmit/error interrupt */
Default_Handler, /* LPUART3_IRQn = 33, /**< LPUART3 receive/transmit/error interrupt */
Default_Handler, /* LPUART4_IRQn = 34, /**< LPUART4 receive/transmit/error interrupt */
Default_Handler, /* Reserved51_IRQn = 35, /**< Reserved interrupt */
Default_Handler, /* Reserved52_IRQn = 36, /**< Reserved interrupt */
Default_Handler, /* EMVSIM0_IRQn = 37, /**< EMVSIM0 common interrupt */
Default_Handler, /* EMVSIM1_IRQn = 38, /**< EMVSIM1 common interrupt */
Default_Handler, /* ADC0_IRQn = 39, /**< Analog-to-digital converter 0 */
Default_Handler, /* CMP0_IRQn = 40, /**< Comparator 0 */
Default_Handler, /* CMP1_IRQn = 41, /**< Comparator 1 */
Default_Handler, /* FTM0_IRQn = 42, /**< FlexTimer module 0 fault, overflow and channels interrupt */
Default_Handler, /* FTM1_IRQn = 43, /**< FlexTimer module 1 fault, overflow and channels interrupt */
Default_Handler, /* FTM2_IRQn = 44, /**< FlexTimer module 2 fault, overflow and channels interrupt */
Default_Handler, /* CMT_IRQn = 45, /**< Carrier modulator transmitter */
Default_Handler, /* RTC_IRQn = 46, /**< Real time clock */
Default_Handler, /* RTC_Seconds_IRQn = 47, /**< Real time clock seconds */
Default_Handler, /* PIT0CH0_IRQn = 48, /**< Periodic interrupt timer 0 channel 0 */
Default_Handler, /* PIT0CH1_IRQn = 49, /**< Periodic interrupt timer 0 channel 1 */
Default_Handler, /* PIT0CH2_IRQn = 50, /**< Periodic interrupt timer 0 channel 2 */
Default_Handler, /* PIT0CH3_IRQn = 51, /**< Periodic interrupt timer 0 channel 3 */
Default_Handler, /* PDB0_IRQn = 52, /**< Programmable delay block */
Default_Handler, /* USB0_IRQn = 53, /**< USB OTG interrupt */
Default_Handler, /* USBDCD_IRQn = 54, /**< USB charger detect */
Default_Handler, /* Reserved71_IRQn = 55, /**< Reserved interrupt */
Default_Handler, /* DAC0_IRQn = 56, /**< Digital-to-analog converter 0 */
Default_Handler, /* MCG_IRQn = 57, /**< Multipurpose clock generator */
Default_Handler, /* LPTMR0_LPTMR1_IRQn = 58, /**< Single interrupt vector for Low Power Timer 0 and 1 */
Default_Handler, /* PORTA_IRQn = 59, /**< Port A pin detect interrupt */
Default_Handler, /* PORTB_IRQn = 60, /**< Port B pin detect interrupt */
Default_Handler, /* PORTC_IRQn = 61, /**< Port C pin detect interrupt */
Default_Handler, /* PORTD_IRQn = 62, /**< Port D pin detect interrupt */
Default_Handler, /* PORTE_IRQn = 63, /**< Port E pin detect interrupt */
Default_Handler, /* SWI_IRQn = 64, /**< Software interrupt */
Default_Handler, /* SPI2_IRQn = 65, /**< Serial peripheral Interface 2 */
Default_Handler, /* Reserved82_IRQn = 66, /**< Reserved interrupt */
Default_Handler, /* Reserved83_IRQn = 67, /**< Reserved interrupt */
Default_Handler, /* Reserved84_IRQn = 68, /**< Reserved interrupt */
Default_Handler, /* Reserved85_IRQn = 69, /**< Reserved interrupt */
Default_Handler, /* FLEXIO0_IRQn = 70, /**< FLEXIO0 */
Default_Handler, /* FTM3_IRQn = 71, /**< FlexTimer module 3 fault, overflow and channels interrupt */
Default_Handler, /* Reserved88_IRQn = 72, /**< Reserved interrupt */
Default_Handler, /* Reserved89_IRQn = 73, /**< Reserved interrupt */
Default_Handler, /* I2C2_IRQn = 74, /**< Inter-integrated circuit 2 */
Default_Handler, /* Reserved91_IRQn = 75, /**< Reserved interrupt */
Default_Handler, /* Reserved92_IRQn = 76, /**< Reserved interrupt */
Default_Handler, /* Reserved93_IRQn = 77, /**< Reserved interrupt */
Default_Handler, /* Reserved94_IRQn = 78, /**< Reserved interrupt */
Default_Handler, /* Reserved95_IRQn = 79, /**< Reserved interrupt */
Default_Handler, /* Reserved96_IRQn = 80, /**< Reserved interrupt */
Default_Handler, /* SDHC_IRQn = 81, /**< Secured digital host controller */
Default_Handler, /* Reserved98_IRQn = 82, /**< Reserved interrupt */
Default_Handler, /* Reserved99_IRQn = 83, /**< Reserved interrupt */
Default_Handler, /* Reserved100_IRQn = 84, /**< Reserved interrupt */
Default_Handler, /* Reserved101_IRQn = 85, /**< Reserved interrupt */
Default_Handler, /* Reserved102_IRQn = 86, /**< Reserved interrupt */
Default_Handler, /* TSI0_IRQn = 87, /**< Touch Sensing Input */
Default_Handler, /* TPM1_IRQn = 88, /**< TPM1 single interrupt vector for all sources */
Default_Handler, /* TPM2_IRQn = 89, /**< TPM2 single interrupt vector for all sources */
Default_Handler, /* Reserved106_IRQn = 90, /**< Reserved interrupt */
Default_Handler, /* I2C3_IRQn = 91, /**< Inter-integrated circuit 3 */
Default_Handler, /* Reserved108_IRQn = 92, /**< Reserved interrupt */
Default_Handler, /* Reserved109_IRQn = 93, /**< Reserved interrupt */
Default_Handler, /* Reserved110_IRQn = 94, /**< Reserved interrupt */
Default_Handler, /* Reserved111_IRQn = 95, /**< Reserved interrupt */
Default_Handler, /* Reserved112_IRQn = 96, /**< Reserved interrupt */
Default_Handler, /* Reserved113_IRQn = 97, /**< Reserved interrupt */
Default_Handler, /* Reserved114_IRQn = 98, /**< Reserved interrupt */
Default_Handler, /* Reserved115_IRQn = 99, /**< Reserved interrupt */
Default_Handler, /* QuadSPI0_IRQn = 100, /**< qspi */
Default_Handler, /* Reserved117_IRQn = 101, /**< Reserved interrupt */
Default_Handler, /* Reserved118_IRQn = 102, /**< Reserved interrupt */
Default_Handler, /* Reserved119_IRQn = 103, /**< Reserved interrupt */
Default_Handler, /* LTC0_IRQn = 104, /**< LP Trusted Cryptography */
Default_Handler, /* Reserved121_IRQn = 105, /**< Reserved interrupt */
Default_Handler, /* Reserved122_IRQn = 106 /**< Reserved interrupt */
#endif /* CPU_MK82FN256VLL15 */
};

View File

@@ -0,0 +1,177 @@
/* benchmark_main.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <wolfssl/wolfcrypt/settings.h>
#include <wolfssl/wolfcrypt/wc_port.h>
#include <wolfcrypt/benchmark/benchmark.h>
#include <stdio.h>
#include "hw.h" /* Needed for 'delay_us' prototype */
typedef struct func_args {
int argc;
char** argv;
int return_code;
} func_args;
static func_args args = { 0 } ;
extern double current_time(int reset);
void main(void)
{
int test_num = 0;
wolfCrypt_Init(); /* required for ksdk_port_init */
do
{
/* Used for testing, must have a delay so no data is missed while serial is initializing */
#ifdef WOLFSSL_FRDM_K64_JENKINS
/* run once */
if(test_num == 1){
printf("\n&&&&&&&&&&&&& done &&&&&&&&&&&&&&&");
delay_us(1000000);
break;
}
delay_us(1000000); /* 1 second */
#endif
printf("\nBenchmark Test %d:\n", test_num);
benchmark_test(&args);
printf("Benchmark Test %d: Return code %d\n", test_num, args.return_code);
test_num++;
} while(args.return_code == 0);
/*Print this again for redundancy*/
#ifdef WOLFSSL_FRDM_K64_JENKINS
printf("\n&&&&&&&&&&&&&& done &&&&&&&&&&&&&\n");
delay_us(1000000);
#endif
wolfCrypt_Cleanup();
}
/*
SAMPLE OUTPUT: Freescale K64 running at 96MHz with no MMCAU:
Benchmark Test 0:
AES 25 kB took 0.073 seconds, 0.334 MB/s
ARC4 25 kB took 0.033 seconds, 0.740 MB/s
RABBIT 25 kB took 0.027 seconds, 0.904 MB/s
3DES 25 kB took 0.375 seconds, 0.065 MB/s
MD5 25 kB took 0.016 seconds, 1.526 MB/s
SHA 25 kB took 0.044 seconds, 0.555 MB/s
SHA-256 25 kB took 0.119 seconds, 0.205 MB/s
RSA 1024 encryption took 91.000 milliseconds, avg over 1 iterations
RSA 1024 decryption took 573.000 milliseconds, avg over 1 iterations
DH 1024 key generation 253.000 milliseconds, avg over 1 iterations
DH 1024 key agreement 311.000 milliseconds, avg over 1 iterations
Benchmark Test 0: Return code 0
SAMPLE OUTPUT: Freescale K64 running at 96MHz with MMCAU enabled:
Benchmark Test 0:
AES 25 kB took 0.019 seconds, 1.285 MB/s
ARC4 25 kB took 0.033 seconds, 0.740 MB/s
RABBIT 25 kB took 0.028 seconds, 0.872 MB/s
3DES 25 kB took 0.026 seconds, 0.939 MB/s
MD5 25 kB took 0.005 seconds, 4.883 MB/s
SHA 25 kB took 0.008 seconds, 3.052 MB/s
SHA-256 25 kB took 0.013 seconds, 1.878 MB/s
RSA 1024 encryption took 89.000 milliseconds, avg over 1 iterations
RSA 1024 decryption took 573.000 milliseconds, avg over 1 iterations
DH 1024 key generation 250.000 milliseconds, avg over 1 iterations
DH 1024 key agreement 308.000 milliseconds, avg over 1 iterations
Benchmark Test 0: Return code 0
SAMPLE OUTPUT: NXP K82 running at 150Mhz w/MMCAU and LTC
Benchmark Test 0:
RNG 25 kB took 0.026 seconds, 0.939 MB/s
AES enc 25 kB took 0.002 seconds, 12.207 MB/s
AES dec 25 kB took 0.002 seconds, 12.207 MB/s
AES-GCM 25 kB took 0.002 seconds, 12.207 MB/s
AES-CTR 25 kB took 0.003 seconds, 8.138 MB/s
AES-CCM 25 kB took 0.004 seconds, 6.104 MB/s
CHACHA 25 kB took 0.008 seconds, 3.052 MB/s
CHA-POLY 25 kB took 0.013 seconds, 1.878 MB/s
POLY1305 25 kB took 0.003 seconds, 8.138 MB/s
SHA 25 kB took 0.006 seconds, 4.069 MB/s
SHA-256 25 kB took 0.009 seconds, 2.713 MB/s
SHA-384 25 kB took 0.032 seconds, 0.763 MB/s
SHA-512 25 kB took 0.035 seconds, 0.698 MB/s
RSA 2048 public 12.000 milliseconds, avg over 1 iterations
RSA 2048 private 135.000 milliseconds, avg over 1 iterations
ECC 256 key generation 17.400 milliseconds, avg over 5 iterations
EC-DHE key agreement 15.200 milliseconds, avg over 5 iterations
EC-DSA sign time 20.200 milliseconds, avg over 5 iterations
EC-DSA verify time 33.000 milliseconds, avg over 5 iterations
CURVE25519 256 key generation 14.400 milliseconds, avg over 5 iterations
CURVE25519 key agreement 14.400 milliseconds, avg over 5 iterations
ED25519 key generation 14.800 milliseconds, avg over 5 iterations
ED25519 sign time 16.800 milliseconds, avg over 5 iterations
ED25519 verify time 30.400 milliseconds, avg over 5 iterations
Benchmark Test 0: Return code 0
SAMPLE OUTPUT: NXP K82 running at 150Mhz software only
Benchmark Test 0:
RNG 25 kB took 0.035 seconds, 0.698 MB/s
AES enc 25 kB took 0.038 seconds, 0.642 MB/s
AES dec 25 kB took 0.036 seconds, 0.678 MB/s
AES-GCM 25 kB took 0.485 seconds, 0.050 MB/s
AES-CTR 25 kB took 0.038 seconds, 0.642 MB/s
AES-CCM 25 kB took 0.077 seconds, 0.317 MB/s
CHACHA 25 kB took 0.009 seconds, 2.713 MB/s
CHA-POLY 25 kB took 0.013 seconds, 1.878 MB/s
POLY1305 25 kB took 0.003 seconds, 8.138 MB/s
SHA 25 kB took 0.006 seconds, 4.069 MB/s
SHA-256 25 kB took 0.014 seconds, 1.744 MB/s
SHA-384 25 kB took 0.032 seconds, 0.763 MB/s
SHA-512 25 kB took 0.034 seconds, 0.718 MB/s
RSA 1024 encryption took 18.000 milliseconds, avg over 1 iterations
RSA 1024 decryption took 123.000 milliseconds, avg over 1 iterations
RSA 2048 encryption took 63.000 milliseconds, avg over 1 iterations
RSA 2048 decryption took 1011.000 milliseconds, avg over 1 iterations
ECC 256 key generation 180.800 milliseconds, avg over 5 iterations
EC-DHE key agreement 178.600 milliseconds, avg over 5 iterations
EC-DSA sign time 184.600 milliseconds, avg over 5 iterations
EC-DSA verify time 130.200 milliseconds, avg over 5 iterations
CURVE25519 256 key generation 41.800 milliseconds, avg over 5 iterations
CURVE25519 key agreement 41.600 milliseconds, avg over 5 iterations
ED25519 key generation 14.800 milliseconds, avg over 5 iterations
ED25519 sign time 16.600 milliseconds, avg over 5 iterations
ED25519 verify time 48.000 milliseconds, avg over 5 iterations
Benchmark Test 0: Return code 0
*/

View File

@@ -0,0 +1,23 @@
#ifndef WOLFSSL_ROWLEY_HW_H
#define WOLFSSL_ROWLEY_HW_H
#include <__cross_studio_io.h>
#include <__libc.h>
#include <stdint.h>
// Generic HW API
void hw_init(void);
uint32_t hw_get_time_sec(void);
uint32_t hw_get_time_msec(void);
void hw_uart_printchar(int c);
void hw_watchdog_disable(void);
uint32_t hw_rand(void);
// Delay functions
void delay_us(uint32_t microseconds);
#endif /* WOLFSSL_ROWLEY_HW_H */

View File

@@ -0,0 +1,15 @@
# vim:ft=automake
# included from Top Level Makefile.am
# All paths should be given relative to the root
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/arm_startup.c
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/benchmark_main.c
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/hw.h
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/kinetis_hw.c
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/Kinetis_FlashPlacement.xml
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/README.md
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/test_main.c
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/retarget.c
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/user_settings.h
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/wolfssl.hzp
EXTRA_DIST+= IDE/ROWLEY-CROSSWORKS-ARM/wolfssl_ltc.hzp

View File

@@ -0,0 +1,345 @@
/* kinetis_hw.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#include "hw.h"
#include "user_settings.h"
#if defined(FREESCALE) && defined(K_SERIES)
/**********************************************
* NOTE: Customize for actual hardware
**********************************************/
// CPU include for Rowley CrossWorks packages
// $(TargetsDir) location:
// On Mac OS/X: Users/USERNAME/Library/Rowley Associates Limited/CrossWorks for ARM/packages/targets/
// On Windows: C:/Users/USERNAME/Application Data/Local/Rowley Associates Limited/CrossWorks for ARM/packages/targets/
// On Linux: home/USERNAME/.rowley_associates_limited/CrossWorks for ARM/v4/packages/targets/
// Located in $(TargetsDir)/Kinetis/CMSIS/
#ifdef FREESCALE_KSDK_BM
#include "fsl_common.h"
#include "fsl_debug_console.h"
#include "fsl_rtc.h"
#include "fsl_trng.h"
#include "fsl_lpuart.h"
#include "fsl_port.h"
#include "clock_config.h"
#else
#include <MK64F12.h> // Located in $(TargetsDir)/Kinetis/CMSIS/
#endif
// System clock
#ifdef FREESCALE_KSDK_BM
#define SYS_CLK_HZ SystemCoreClock
#else
#define SYS_CLK_HZ 96000000ul /* Core system clock in Hz */
#define SYS_CLK_DRS MCG_C4_DRST_DRS(0x03) /* DRS 0=24MHz, 1=48MHz, 2=72MHz, 3=96MHz */
#define SYS_CLK_DMX MCG_C4_DMX32_MASK /* 0=Disable DMX32 (lower actual speed), MCG_C4_DMX32_MASK=Enable DMX32 */
#define SYS_CLK_DIV 1 /* System clock divisor */
#define BUS_CLK_DIV 2 /* Bus clock divisor */
#define BUS_CLK_KHZ (SYS_CLK_HZ/BUS_CLK_DIV) /* Helper to calculate bus speed for UART */
#define FLASH_CLK_DIV 4 /* Flash clock divisor */
#endif
// UART TX Port, Pin, Mux and Baud
#ifdef FREESCALE_KSDK_BM
#define UART_PORT LPUART4 /* UART Port */
#define UART_TX_PORT PORTC /* UART TX Port */
#define UART_TX_PIN 15U /* UART TX Pin */
#define UART_TX_MUX kPORT_MuxAlt3 /* Kinetis UART pin mux */
#elif defined (WOLFSSL_FRDM_K64)
#define UART_PORT UART0 /* UART Port */
#define UART_TX_PORT PORTB /* UART TX Port */
#define UART_TX_PIN 17U /* UART TX Pin */
#define UART_TX_MUX 0x3 /* Kinetis UART pin mux */
#else
#define UART_PORT UART4 /* UART Port */
#define UART_TX_PORT PORTE /* UART TX Port */
#define UART_TX_PIN 24U /* UART TX Pin */
#define UART_TX_MUX 0x3 /* Kinetis UART pin mux */
#endif
#define UART_BAUD_RATE 115200 /* UART Baud Rate */
#ifdef WOLFSSL_FRDM_K64
#define UART_BAUD UART_BAUD_RATE*8
#else
#define UART_BAUD UART_BAUD_RATE
#endif
/* Note: You will also need to update the UART clock gate in hw_uart_init (SIM_SCGC1_UART5_MASK) */
/* Note: TWR-K60 is UART3, PTC17 */
/* Note: FRDM-K64 is UART4, PTE24 or UART0 PTB17 for OpenOCD (SIM_SCGC4_UART0_MASK)*/
/* Note: TWR-K64 is UART5, PTE8 */
/* Note: FRDM-K82F is LPUART4 PTC15 Alt3 (OpenOCD UART) */
/***********************************************/
// Private functions
static uint32_t mDelayCyclesPerUs = 0;
#define NOP_FOR_LOOP_INSTRUCTION_COUNT 6
static void delay_nop(uint32_t count)
{
int i;
for(i=0; i<count; i++) {
__asm volatile("nop");
}
}
static void hw_mcg_init(void)
{
#ifdef FREESCALE_KSDK_BM
BOARD_BootClockHSRUN();
#else
/* Adjust clock dividers (core/system=div/1, bus=div/2, flex bus=div/2, flash=div/4) */
SIM->CLKDIV1 = SIM_CLKDIV1_OUTDIV1(SYS_CLK_DIV-1) | SIM_CLKDIV1_OUTDIV2(BUS_CLK_DIV-1) |
SIM_CLKDIV1_OUTDIV3(BUS_CLK_DIV-1) | SIM_CLKDIV1_OUTDIV4(FLASH_CLK_DIV-1);
/* Configure FEI internal clock speed */
MCG->C4 = (SYS_CLK_DMX | SYS_CLK_DRS);
while((MCG->C4 & (MCG_C4_DRST_DRS_MASK | MCG_C4_DMX32_MASK)) != (SYS_CLK_DMX | SYS_CLK_DRS));
#endif
}
static void hw_gpio_init(void)
{
#ifdef FREESCALE_KSDK_BM
CLOCK_EnableClock(kCLOCK_PortA);
CLOCK_EnableClock(kCLOCK_PortB);
CLOCK_EnableClock(kCLOCK_PortC);
CLOCK_EnableClock(kCLOCK_PortD);
CLOCK_EnableClock(kCLOCK_PortE);
#else
/* Enable clocks to all GPIO ports */
SIM->SCGC5 |= (SIM_SCGC5_PORTA_MASK | SIM_SCGC5_PORTB_MASK
#ifdef SIM_SCGC5_PORTC_MASK
| SIM_SCGC5_PORTC_MASK
#endif
#ifdef SIM_SCGC5_PORTD_MASK
| SIM_SCGC5_PORTD_MASK
#endif
#ifdef SIM_SCGC5_PORTE_MASK
| SIM_SCGC5_PORTE_MASK
#endif
);
#if 0 /* Debug clock */
/* ClockOut on PTC3 */
PORTC->PCR[3] = PORT_PCR_MUX(0x05); /* Alt 5 */
SIM_SOPT2 |= SIM_SOPT2_CLKOUTSEL(0); /* FlexBus CLKOUT */
#endif
#endif
}
static void hw_uart_init(void)
{
#ifdef FREESCALE_KSDK_BM
PORT_SetPinMux(UART_TX_PORT, UART_TX_PIN, UART_TX_MUX);
CLOCK_SetLpuartClock(1); /* MCGPLLCLK */
DbgConsole_Init((uint32_t)UART_PORT, UART_BAUD, DEBUG_CONSOLE_DEVICE_TYPE_LPUART, SYS_CLK_HZ);
#else
register uint16_t sbr, brfa;
uint8_t temp;
#ifdef WOLFSSL_FRDM_K64
/* Enable UART core clock ONLY for FRDM-K64F */
SIM->SCGC4 |= SIM_SCGC4_UART0_MASK;
#else
/* Enable UART core clock */
/* Note: Remember to update me if UART_PORT changes */
SIM->SCGC1 |= SIM_SCGC1_UART4_MASK;
#endif
/* Configure UART TX pin */
UART_TX_PORT->PCR[UART_TX_PIN] = PORT_PCR_MUX(UART_TX_MUX);
/* Disable transmitter and receiver while we change settings. */
UART_PORT->C2 &= ~(UART_C2_TE_MASK | UART_C2_RE_MASK );
/* Configure the UART for 8-bit mode, no parity */
UART_PORT->C1 = 0;
/* Calculate baud settings */
sbr = (uint16_t)((BUS_CLK_KHZ * 1000)/(UART_BAUD * 16));
temp = UART_PORT->BDH & ~(UART_BDH_SBR(0x1F));
UART_PORT->BDH = temp | UART_BDH_SBR(((sbr & 0x1F00) >> 8));
UART_PORT->BDL = (uint8_t)(sbr & UART_BDL_SBR_MASK);
/* Determine if a fractional divider is needed to get closer to the baud rate */
brfa = (((BUS_CLK_KHZ * 32000)/(UART_BAUD * 16)) - (sbr * 32));
temp = UART_PORT->C4 & ~(UART_C4_BRFA(0x1F));
UART_PORT->C4 = temp | UART_C4_BRFA(brfa);
/* Enable receiver and transmitter */
UART_PORT->C2 |= (UART_C2_TE_MASK | UART_C2_RE_MASK);
#endif
}
static void hw_rtc_init(void)
{
/* Init nop delay */
mDelayCyclesPerUs = (SYS_CLK_HZ / 1000000 / NOP_FOR_LOOP_INSTRUCTION_COUNT);
/* Enable RTC clock and oscillator */
SIM->SCGC6 |= SIM_SCGC6_RTC_MASK;
if (RTC->SR & RTC_SR_TIF_MASK) {
/* Resets the RTC registers except for the SWR bit */
RTC->CR |= RTC_CR_SWR_MASK;
RTC->CR &= ~RTC_CR_SWR_MASK;
/* Set TSR register to 0x1 to avoid the TIF bit being set in the SR register */
RTC->TSR = 1;
}
/* Disable RTC Interrupts */
RTC->IER = 0;
/* Enable OSC */
if ((RTC->CR & RTC_CR_OSCE_MASK) == 0) {
/* Turn on */
RTC->CR |= RTC_CR_OSCE_MASK;
/* Wait RTC startup delay 1000 us */
delay_us(1000);
}
/* Enable counter */
RTC->SR |= RTC_SR_TCE_MASK;
}
static void hw_rand_init(void)
{
#ifdef FREESCALE_KSDK_BM
trng_config_t trngConfig;
TRNG_GetDefaultConfig(&trngConfig);
/* Set sample mode of the TRNG ring oscillator to Von Neumann, for better random data.*/
trngConfig.sampleMode = kTRNG_SampleModeVonNeumann;
/* Initialize TRNG */
TRNG_Init(TRNG0, &trngConfig);
#else
/* Enable RNG clocks */
SIM->SCGC6 |= SIM_SCGC6_RNGA_MASK;
SIM->SCGC3 |= SIM_SCGC3_RNGA_MASK;
/* Wake up RNG to normal mode (take out of sleep) */
RNG->CR &= ~RNG_CR_SLP_MASK;
/* Enable High Assurance mode (Enables notification of security violations via SR[SECV]) */
RNG->CR |= RNG_CR_HA_MASK;
/* Enable RNG generation to RANDOUT FIFO */
RNG->CR |= RNG_CR_GO_MASK;
#endif
}
/* Public Functions */
void hw_init(void)
{
hw_mcg_init();
hw_gpio_init();
hw_uart_init();
hw_rtc_init();
hw_rand_init();
}
uint32_t hw_get_time_sec(void)
{
/* Return RTC seconds */
return RTC->TSR;
}
uint32_t hw_get_time_msec(void)
{
/* RTC TPR precision register increments every 32.768 kHz clock cycle */
/* Convert with rounding crystal count (32768 or (1 << 15)) to milliseconds */
return ( ((uint32_t)RTC->TPR * 1000) + ((1 << 15) / 2) ) / (1 << 15);
}
void hw_uart_printchar(int c)
{
#ifdef FREESCALE_KSDK_BM
LPUART_WriteBlocking(UART_PORT, (const uint8_t*)&c, 1); /* Send the character */
#else
while(!(UART_PORT->S1 & UART_S1_TDRE_MASK)); /* Wait until space is available in the FIFO */
UART_PORT->D = (uint8_t)c; /* Send the character */
#endif
}
uint32_t hw_rand(void)
{
uint32_t rng;
#ifdef FREESCALE_KSDK_BM
TRNG_GetRandomData(TRNG0, &rng, sizeof(rng));
#else
while((RNG->SR & RNG_SR_OREG_LVL(0xF)) == 0) {}; /* Wait until FIFO has a value available */
rng = RNG->OR; /* Return next value in FIFO output register */
#endif
return rng;
}
void delay_us(uint32_t microseconds)
{
delay_nop(mDelayCyclesPerUs * microseconds);
}
// Watchdog
void hw_watchdog_disable(void)
{
WDOG->UNLOCK = 0xC520;
WDOG->UNLOCK = 0xD928;
WDOG->STCTRLH = WDOG_STCTRLH_ALLOWUPDATE_MASK;
}
// Flash configuration
#define FSEC_UNSECURE 2
#define FSEC_SECURE 0
#define FSEC_FSLACC_DENIED 2
#define FSEC_FSLACC_GRANTED 3
#define FSEC_KEY_ENABLED 2
#define FSEC_KEY_DISABLED 3
#define FSEC_MASS_ERASE_DISABLE 2
#define FSEC_MASS_ERASE_ENABLE 3
struct flash_conf {
uint8_t backdoor_key[8]; /* Backdoor Comparison Key */
uint8_t fprot[4]; /* Program flash protection bytes */
uint8_t fsec; /* Flash security byte */
uint8_t fopt; /* Flash nonvolatile option byte */
uint8_t feprot; /* FlexNVM: EEPROM protection byte */
uint8_t fdprot; /* FlexNVM: Data flash protection byte */
};
const struct flash_conf flash_conf __attribute__ ((section (".flashconf"),used)) =
{
.backdoor_key = { 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF },
.fprot = { 0xFF, 0xFF, 0xFF, 0xFF },
.fsec = NV_FSEC_SEC(FSEC_UNSECURE) | NV_FSEC_FSLACC(FSEC_FSLACC_GRANTED) |
NV_FSEC_MEEN(FSEC_MASS_ERASE_ENABLE) | NV_FSEC_KEYEN(FSEC_KEY_DISABLED),
.fopt = 0xFF,
.feprot = 0xFF,
.fdprot = 0xFF
};
#endif /* FREESCALE && K_SERIES */

View File

@@ -0,0 +1,134 @@
/* retarget.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#include "hw.h"
#include "user_settings.h"
#include <stdio.h>
void __assert(const char *__expression, const char *__filename, int __line)
{
printf("Assert: %s, File %s (%d)\n", __expression, __filename, __line);
}
unsigned long ksdk_time(unsigned long* timer)
{
(void)timer;
return hw_get_time_sec();
}
unsigned int LowResTimer(void)
{
return hw_get_time_sec();
}
double current_time(int reset)
{
double time;
(void)reset;
time = hw_get_time_sec();
time += (double)hw_get_time_msec() / 1000;
return time;
}
unsigned int custom_rand_generate(void)
{
return hw_rand();
}
int custom_rand_generate_block(unsigned char* output, unsigned int sz)
{
uint32_t i = 0;
while (i < sz)
{
/* If not aligned or there is odd/remainder */
if( (i + sizeof(CUSTOM_RAND_TYPE)) > sz ||
((uint32_t)&output[i] % sizeof(CUSTOM_RAND_TYPE)) != 0
) {
/* Single byte at a time */
output[i++] = (unsigned char)custom_rand_generate();
}
else {
/* Use native 8, 16, 32 or 64 copy instruction */
*((CUSTOM_RAND_TYPE*)&output[i]) = custom_rand_generate();
i += sizeof(CUSTOM_RAND_TYPE);
}
}
return 0;
}
// Debug print handler
int __putchar(int c, __printf_tag_ptr ctx)
{
hw_uart_printchar(c);
}
/* C library support function to write buffer (always to UART) */
int __write(int __fildes, const unsigned char *__buf, unsigned __len)
{
(void)__fildes;
for (unsigned i = 0; i < __len; i++) {
hw_uart_printchar((int)__buf[i]);
}
}
extern unsigned char __stack_process_start__[];
unsigned char * __aeabi_read_tp(void)
{
// thread-local storage addressing refers to the thread pointer
// This is returning start address of stack process
return (__stack_process_start__);
}
/* Stubs */
void __heap_lock(void)
{
}
void __heap_unlock(void)
{
}
void __printf_lock(void)
{
}
void __printf_unlock(void)
{
}
void __scanf_lock(void)
{
}
void __scanf_unlock(void)
{
}
void __debug_io_lock(void)
{
}
void __debug_io_unlock(void)
{
}

View File

@@ -0,0 +1,101 @@
/* test_main.c
*
* Copyright (C) 2006-2022 wolfSSL Inc.
*
* This file is part of wolfSSL.
*
* wolfSSL is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* wolfSSL is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
*/
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
#include <wolfssl/wolfcrypt/settings.h>
#include <wolfssl/wolfcrypt/wc_port.h>
#include <wolfcrypt/test/test.h>
#include <stdio.h>
#include "hw.h"
typedef struct func_args {
int argc;
char** argv;
int return_code;
} func_args;
static func_args args = { 0 } ;
void main(void)
{
int test_num = 0;
wolfCrypt_Init(); /* required for ksdk_port_init */
do
{
/* Used for testing, must have a delay so no data is missed while serial is initializing */
#ifdef WOLFSSL_FRDM_K64_JENKINS
/* run twice */
if(test_num == 2){
printf("\n&&&&&&&&&&&&& done &&&&&&&&&&&&&&&");
delay_us(1000000);
break;
}
delay_us(1000000); /* 1 second */
#endif
printf("\nCrypt Test %d:\n", test_num);
wolfcrypt_test(&args);
printf("Crypt Test %d: Return code %d\n", test_num, args.return_code);
test_num++;
} while(args.return_code == 0);
/* Print this again for redundancy */
#ifdef WOLFSSL_FRDM_K64_JENKINS
printf("\n&&&&&&&&&&&&&& done &&&&&&&&&&&&&\n");
delay_us(1000000);
#endif
wolfCrypt_Cleanup();
}
/* SAMPLE OUTPUT:
Crypt Test 0:
SHA test passed!
SHA-256 test passed!
SHA-384 test passed!
SHA-512 test passed!
HMAC-SHA test passed!
HMAC-SHA256 test passed!
HMAC-SHA384 test passed!
HMAC-SHA512 test passed!
GMAC test passed!
Chacha test passed!
POLY1305 test passed!
ChaCha20-Poly1305 AEAD test passed!
AES test passed!
AES-GCM test passed!
AES-CCM test passed!
RANDOM test passed!
RSA test passed!
ECC test passed!
CURVE25519 test passed!
ED25519 test passed!
Crypt Test 0: Return code 0
*/

View File

@@ -0,0 +1,427 @@
/* Example custom user settings for wolfSSL */
#ifndef WOLFSSL_USER_SETTINGS_H
#define WOLFSSL_USER_SETTINGS_H
#ifdef __cplusplus
extern "C" {
#endif
#include <stddef.h> /* for size_t */
/* ------------------------------------------------------------------------- */
/* Platform */
/* ------------------------------------------------------------------------- */
#undef WOLFSSL_GENERAL_ALIGNMENT
#define WOLFSSL_GENERAL_ALIGNMENT 4
#undef SINGLE_THREADED
#define SINGLE_THREADED
#undef WOLFSSL_SMALL_STACK
//#define WOLFSSL_SMALL_STACK
#undef WOLFSSL_SMALL_STACK_CACHE
//#define WOLFSSL_SMALL_STACK_CACHE
#define WOLFSSL_IGNORE_FILE_WARN
/* ------------------------------------------------------------------------- */
/* Math Configuration */
/* ------------------------------------------------------------------------- */
#undef USE_FAST_MATH
#define USE_FAST_MATH
#ifdef USE_FAST_MATH
#undef TFM_TIMING_RESISTANT
#define TFM_TIMING_RESISTANT
/* Optimizations (TFM_ARM, TFM_ASM or none) */
#define TFM_ARM
//#define TFM_ASM
#endif
/* Math debugging (adds support for mp_dump) */
#undef WOLFSSL_DEBUG_MATH
//#define WOLFSSL_DEBUG_MATH
/* Wolf Single Precision Math */
#undef WOLFSSL_SP
#if 0
#define WOLFSSL_SP
#define WOLFSSL_SP_SMALL /* use smaller version of code */
#define WOLFSSL_HAVE_SP_RSA
#define WOLFSSL_HAVE_SP_DH
#define WOLFSSL_HAVE_SP_ECC
//#define WOLFSSL_SP_CACHE_RESISTANT
#define WOLFSSL_SP_MATH /* only SP math - eliminates fast math code */
/* SP Assembly Speedups */
#define WOLFSSL_SP_ASM /* required if using the ASM versions */
//#define WOLFSSL_SP_ARM32_ASM
//#define WOLFSSL_SP_ARM64_ASM
//#define WOLFSSL_SP_ARM_THUMB_ASM
#define WOLFSSL_SP_ARM_CORTEX_M_ASM
#endif
/* ------------------------------------------------------------------------- */
/* Crypto */
/* ------------------------------------------------------------------------- */
/* ECC */
#if 1
#undef HAVE_ECC
#define HAVE_ECC
/* Manually define enabled curves */
#undef ECC_USER_CURVES
#define ECC_USER_CURVES
#define HAVE_ECC192
#define HAVE_ECC224
#undef NO_ECC256
#define HAVE_ECC384
#ifndef USE_NXP_LTC /* NXP LTC HW supports up to 384 */
#define HAVE_ECC521
#endif
/* Fixed point cache (speeds repeated operations against same private key) */
#undef FP_ECC
//#define FP_ECC
#ifdef FP_ECC
/* Bits / Entries */
#undef FP_ENTRIES
#define FP_ENTRIES 2
#undef FP_LUT
#define FP_LUT 4
#endif
/* Optional ECC calculation method */
/* Note: doubles heap usage, but slightly faster */
#undef ECC_SHAMIR
#ifndef USE_NXP_LTC /* Don't enable Shamir code for HW ECC */
#define ECC_SHAMIR
#endif
/* Reduces heap usage, but slower */
#undef ECC_TIMING_RESISTANT
#define ECC_TIMING_RESISTANT
#ifdef USE_FAST_MATH
/* use reduced size math buffers for ecc points */
#undef ALT_ECC_SIZE
#define ALT_ECC_SIZE
/* Enable TFM optimizations for ECC */
#if defined(HAVE_ECC192) || defined(HAVE_ALL_CURVES)
#define TFM_ECC192
#endif
#if defined(HAVE_ECC224) || defined(HAVE_ALL_CURVES)
#define TFM_ECC224
#endif
#if !defined(NO_ECC256) || defined(HAVE_ALL_CURVES)
#define TFM_ECC256
#endif
#if defined(HAVE_ECC384) || defined(HAVE_ALL_CURVES)
#define TFM_ECC384
#endif
#if defined(HAVE_ECC521) || defined(HAVE_ALL_CURVES)
#define TFM_ECC521
#endif
#endif
#endif
/* RSA */
#undef NO_RSA
#if 1
#ifdef USE_FAST_MATH
/* Maximum math bits (Max RSA key bits * 2) */
#undef FP_MAX_BITS
#define FP_MAX_BITS 4096
#endif
/* half as much memory but twice as slow */
#undef RSA_LOW_MEM
//#define RSA_LOW_MEM
/* Enables blinding mode, to prevent timing attacks */
#undef WC_RSA_BLINDING
#define WC_RSA_BLINDING
#else
#define NO_RSA
#endif
/* AES */
#undef NO_AES
#if 1
#undef HAVE_AESGCM
#define HAVE_AESGCM
/* GCM Method: GCM_SMALL, GCM_WORD32 or GCM_TABLE */
#undef GCM_SMALL
#define GCM_SMALL
#else
#define NO_AES
#endif
/* ChaCha20 / Poly1305 */
#undef HAVE_CHACHA
#undef HAVE_POLY1305
#if 1
#define HAVE_CHACHA
#define HAVE_POLY1305
/* Needed for Poly1305 */
#undef HAVE_ONE_TIME_AUTH
#define HAVE_ONE_TIME_AUTH
#endif
/* Ed25519 / Curve25519 */
#undef HAVE_CURVE25519
#undef HAVE_ED25519
#if 1
#define HAVE_CURVE25519
#define HAVE_ED25519
/* Optionally use small math (less flash usage, but much slower) */
#if 0
#define CURVED25519_SMALL
#endif
#endif
/* ------------------------------------------------------------------------- */
/* Hashing */
/* ------------------------------------------------------------------------- */
/* Sha */
#undef NO_SHA
#if 1
/* 1k smaller, but 25% slower */
//#define USE_SLOW_SHA
#else
#define NO_SHA
#endif
/* Sha256 */
#undef NO_SHA256
#if 1
#else
#define NO_SHA256
#endif
/* Sha512 */
#undef WOLFSSL_SHA512
#if 1
#define WOLFSSL_SHA512
/* Sha384 */
#undef WOLFSSL_SHA384
#if 1
#define WOLFSSL_SHA384
#endif
/* over twice as small, but 50% slower */
//#define USE_SLOW_SHA2
#endif
/* MD5 */
#undef NO_MD5
#if 1
#else
#define NO_MD5
#endif
/* ------------------------------------------------------------------------- */
/* HW Crypto Acceleration */
/* ------------------------------------------------------------------------- */
#define FSL_HW_CRYPTO_MANUAL_SELECTION
#if 1
/* NXP MMCAU / LTC Support (See README.md for instructions) */
#if defined(USE_NXP_MMCAU) || defined(USE_NXP_LTC)
#ifdef USE_NXP_MMCAU
#define FREESCALE_USE_MMCAU
#endif
#ifdef USE_NXP_LTC
#define FREESCALE_USE_LTC
#define LTC_MAX_ECC_BITS (384)
#define LTC_MAX_INT_BYTES (256)
//#define FREESCALE_LTC_TFM_RSA_4096_ENABLE
#endif
#endif
#endif
/* ------------------------------------------------------------------------- */
/* Benchmark / Test */
/* ------------------------------------------------------------------------- */
/* Use reduced benchmark / test sizes */
#undef BENCH_EMBEDDED
#define BENCH_EMBEDDED
#undef USE_CERT_BUFFERS_2048
#define USE_CERT_BUFFERS_2048
#undef USE_CERT_BUFFERS_256
#define USE_CERT_BUFFERS_256
/* ------------------------------------------------------------------------- */
/* Debugging */
/* ------------------------------------------------------------------------- */
#undef DEBUG_WOLFSSL
//#define DEBUG_WOLFSSL
#ifdef DEBUG_WOLFSSL
#define fprintf(file, format, ...) printf(format, ##__VA_ARGS__)
/* Use this to measure / print heap usage */
#if 0
#undef USE_WOLFSSL_MEMORY
#define USE_WOLFSSL_MEMORY
#undef WOLFSSL_TRACK_MEMORY
#define WOLFSSL_TRACK_MEMORY
#endif
#else
#undef NO_WOLFSSL_MEMORY
#define NO_WOLFSSL_MEMORY
#undef NO_ERROR_STRINGS
//#define NO_ERROR_STRINGS
#endif
/* ------------------------------------------------------------------------- */
/* Port */
/* ------------------------------------------------------------------------- */
/* Override Current Time */
/* Allows custom "custom_time()" function to be used for benchmark */
#define WOLFSSL_USER_CURRTIME
#define USER_TICKS
extern unsigned long ksdk_time(unsigned long* timer);
#define XTIME ksdk_time
/* ------------------------------------------------------------------------- */
/* RNG */
/* ------------------------------------------------------------------------- */
/* Size of returned HW RNG value */
#define CUSTOM_RAND_TYPE unsigned int
/* Seed source */
extern unsigned int custom_rand_generate(void);
#undef CUSTOM_RAND_GENERATE
#define CUSTOM_RAND_GENERATE custom_rand_generate
/* Choose RNG method */
#if 1
/* Use built-in P-RNG (SHA256 based) with HW RNG */
/* P-RNG + HW RNG (P-RNG is ~8K) */
#undef HAVE_HASHDRBG
#define HAVE_HASHDRBG
#else
#undef WC_NO_HASHDRBG
#define WC_NO_HASHDRBG
/* Bypass P-RNG and use only HW RNG */
extern int custom_rand_generate_block(unsigned char* output, unsigned int sz);
#undef CUSTOM_RAND_GENERATE_BLOCK
#define CUSTOM_RAND_GENERATE_BLOCK custom_rand_generate_block
#endif
/* ------------------------------------------------------------------------- */
/* Enable Features */
/* ------------------------------------------------------------------------- */
#undef KEEP_PEER_CERT
//#define KEEP_PEER_CERT
#undef HAVE_COMP_KEY
//#define HAVE_COMP_KEY
#undef HAVE_TLS_EXTENSIONS
//#define HAVE_TLS_EXTENSIONS
#undef HAVE_SUPPORTED_CURVES
//#define HAVE_SUPPORTED_CURVES
#undef WOLFSSL_BASE64_ENCODE
//#define WOLFSSL_BASE64_ENCODE
/* TLS Session Cache */
#if 0
#define SMALL_SESSION_CACHE
#else
#define NO_SESSION_CACHE
#endif
/* ------------------------------------------------------------------------- */
/* Disable Features */
/* ------------------------------------------------------------------------- */
#undef NO_WOLFSSL_SERVER
//#define NO_WOLFSSL_SERVER
#undef NO_WOLFSSL_CLIENT
//#define NO_WOLFSSL_CLIENT
#undef NO_CRYPT_TEST
//#define NO_CRYPT_TEST
#undef NO_CRYPT_BENCHMARK
//#define NO_CRYPT_BENCHMARK
/* In-lining of misc.c functions */
/* If defined, must include wolfcrypt/src/misc.c in build */
/* Slower, but about 1k smaller */
#undef NO_INLINE
//#define NO_INLINE
#undef NO_FILESYSTEM
#define NO_FILESYSTEM
#undef NO_WRITEV
#define NO_WRITEV
#undef NO_MAIN_DRIVER
#define NO_MAIN_DRIVER
#undef NO_DEV_RANDOM
#define NO_DEV_RANDOM
#undef NO_DSA
#define NO_DSA
#undef NO_DH
#define NO_DH
#undef NO_DES3
#define NO_DES3
#undef NO_RC4
#define NO_RC4
#undef NO_OLD_TLS
#define NO_OLD_TLS
#undef NO_PSK
#define NO_PSK
#undef NO_MD4
#define NO_MD4
#undef NO_PWDBASED
#define NO_PWDBASED
#undef NO_CODING
#define NO_CODING
#ifdef __cplusplus
}
#endif
#endif /* WOLFSSL_USER_SETTINGS_H */

View File

@@ -0,0 +1,440 @@
<!DOCTYPE CrossStudio_Project_File>
<solution Name="wolfssl" target="8" version="2">
<project Name="libwolfssl">
<configuration
Name="Common"
build_output_file_name="$(OutDir)/$(ProjectName)$(LibExt)$(LIB)"
c_preprocessor_definitions="WOLFSSL_ROWLEY_ARM;WOLFSSL_USER_SETTINGS"
c_user_include_directories=".;../;../../"
project_directory=""
project_type="Library" />
<folder Name="Source Files">
<configuration Name="Common" filter="c;cpp;cxx;cc;h;s;inc" />
<folder Name="wolfcrypt">
<folder Name="benchmark">
<file file_name="../../wolfcrypt/benchmark/benchmark.c" />
<file file_name="../../wolfcrypt/benchmark/benchmark.h" />
<file file_name="../../wolfcrypt/benchmark/include.am" />
</folder>
<folder Name="src">
<file file_name="../../wolfcrypt/src/aes.c" />
<file file_name="../../wolfcrypt/src/arc4.c" />
<file file_name="../../wolfcrypt/src/asm.c" />
<file file_name="../../wolfcrypt/src/asn.c" />
<file file_name="../../wolfcrypt/src/blake2b.c" />
<file file_name="../../wolfcrypt/src/camellia.c" />
<file file_name="../../wolfcrypt/src/chacha.c" />
<file file_name="../../wolfcrypt/src/chacha20_poly1305.c" />
<file file_name="../../wolfcrypt/src/coding.c" />
<file file_name="../../wolfcrypt/src/compress.c" />
<file file_name="../../wolfcrypt/src/curve25519.c" />
<file file_name="../../wolfcrypt/src/des3.c" />
<file file_name="../../wolfcrypt/src/dh.c" />
<file file_name="../../wolfcrypt/src/dsa.c" />
<file file_name="../../wolfcrypt/src/ecc.c" />
<file file_name="../../wolfcrypt/src/ecc_fp.c" />
<file file_name="../../wolfcrypt/src/ed25519.c" />
<file file_name="../../wolfcrypt/src/error.c" />
<file file_name="../../wolfcrypt/src/fe_low_mem.c" />
<file file_name="../../wolfcrypt/src/fe_operations.c" />
<file file_name="../../wolfcrypt/src/fp_mont_small.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_12.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_17.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_20.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_24.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_28.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_3.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_32.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_4.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_48.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_6.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_64.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_7.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_8.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_9.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_small_set.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_12.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_17.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_20.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_24.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_28.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_3.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_32.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_4.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_48.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_6.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_64.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_7.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_8.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_9.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_small_set.i" />
<file file_name="../../wolfcrypt/src/ge_low_mem.c" />
<file file_name="../../wolfcrypt/src/ge_operations.c" />
<file file_name="../../wolfcrypt/src/hash.c" />
<file file_name="../../wolfcrypt/src/kdf.c" />
<file file_name="../../wolfcrypt/src/hmac.c" />
<file file_name="../../wolfcrypt/src/include.am" />
<file file_name="../../wolfcrypt/src/integer.c" />
<file file_name="../../wolfcrypt/src/logging.c" />
<file file_name="../../wolfcrypt/src/md2.c" />
<file file_name="../../wolfcrypt/src/md4.c" />
<file file_name="../../wolfcrypt/src/md5.c" />
<file file_name="../../wolfcrypt/src/memory.c" />
<file file_name="../../wolfcrypt/src/misc.c">
<configuration Name="ARM_Debug" build_exclude_from_build="Yes" />
<configuration
Name="ARM_Release"
build_exclude_from_build="Yes" />
</file>
<file file_name="../../wolfcrypt/src/pkcs7.c" />
<file file_name="../../wolfcrypt/src/poly1305.c" />
<file file_name="../../wolfcrypt/src/pwdbased.c" />
<file file_name="../../wolfcrypt/src/random.c" />
<file file_name="../../wolfcrypt/src/ripemd.c" />
<file file_name="../../wolfcrypt/src/rsa.c" />
<file file_name="../../wolfcrypt/src/sha.c" />
<file file_name="../../wolfcrypt/src/sha256.c" />
<file file_name="../../wolfcrypt/src/sha512.c" />
<file file_name="../../wolfcrypt/src/signature.c" />
<file file_name="../../wolfcrypt/src/srp.c" />
<file file_name="../../wolfcrypt/src/tfm.c" />
<file file_name="../../wolfcrypt/src/wc_encrypt.c" />
<file file_name="../../wolfcrypt/src/wc_port.c" />
<file file_name="../../wolfcrypt/src/wolfmath.c" />
<file file_name="../../wolfcrypt/src/wolfevent.c" />
<file file_name="../../wolfcrypt/src/sp_c32.c" />
<file file_name="../../wolfcrypt/src/sp_cortexm.c" />
<file file_name="../../wolfcrypt/src/sp_int.c" />
</folder>
<folder Name="test">
<file file_name="../../wolfcrypt/test/include.am" />
<file file_name="../../wolfcrypt/test/test.c" />
<file file_name="../../wolfcrypt/test/test.h" />
</folder>
<folder Name="user-crypto" path="../../wolfcrypt/user-crypto">
<configuration Name="Common" build_exclude_from_build="Yes" />
</folder>
</folder>
<folder
Name="wolfssl"
exclude="*.asm;*.s"
filter=""
path="../../wolfssl"
recurse="Yes" />
<file file_name="user_settings.h" />
<file file_name="README.md" />
<folder Name="source">
<file file_name="../../src/bio.c">
<configuration Name="ARM_Debug" build_exclude_from_build="Yes" />
</file>
<file file_name="../../src/crl.c" />
<file file_name="../../src/include.am" />
<file file_name="../../src/internal.c" />
<file file_name="../../src/wolfio.c" />
<file file_name="../../src/keys.c" />
<file file_name="../../src/libwolfssl.la" />
<file file_name="../../src/ocsp.c" />
<file file_name="../../src/sniffer.c" />
<file file_name="../../src/src_libwolfssl_la-internal.lo" />
<file file_name="../../src/src_libwolfssl_la-io.lo" />
<file file_name="../../src/src_libwolfssl_la-keys.lo" />
<file file_name="../../src/src_libwolfssl_la-ssl.lo" />
<file file_name="../../src/src_libwolfssl_la-tls.lo" />
<file file_name="../../src/ssl.c" />
<file file_name="../../src/tls.c" />
</folder>
</folder>
</project>
<project Name="test">
<configuration
Name="Common"
Placement="Flash"
Target="MK64FN1M0xxx12"
arm_linker_fiq_stack_size="0"
arm_linker_heap_size="91136"
arm_linker_irq_stack_size="0"
arm_linker_stack_size="30720"
arm_simulator_memory_simulation_filename="$(TargetsDir)/Kinetis/KinetisSimulatorMemory.dll"
arm_simulator_memory_simulation_parameter="MK64FN1M0xxx12;0x100000;0x0;0x0;0x40000"
arm_target_loader_applicable_loaders="Flash"
arm_target_loader_default_loader="Flash"
c_preprocessor_definitions="WOLFSSL_ROWLEY_ARM;WOLFSSL_USER_SETTINGS"
c_user_include_directories=".;../;../../;$(TargetsDir);$(TargetsDir)/Kinetis;$(TargetsDir)/Kinetis/CMSIS;$(TargetsDir)/Kinetis/CMSIS/include;$(TargetsDir)/CMSIS_4/CMSIS/include;$(TargetsDir)/../CMSIS_4/CMSIS;$(TargetsDir)/../CMSIS_4/CMSIS/Include"
debug_register_definition_file="$(TargetsDir)/Kinetis/MK64F12_Peripherals.xml"
linker_memory_map_file="$(TargetsDir)/Kinetis/MK64FN1M0xxx12_MemoryMap.xml"
linker_memory_map_macros="FLASHSIZE=0x80000;SRAMSIZE=0x20000"
linker_output_format="bin"
project_dependencies="libwolfssl"
project_type="Executable"
property_groups_file_path="$(TargetsDir)/Kinetis/propertyGroups.xml"
target_get_partname_script="GetPartName()"
target_match_partname_script="MatchPartName(&quot;$(Target)&quot;)"
target_reset_script="FLASHReset()"
target_script_file="$(TargetsDir)/Kinetis/Kinetis_Target.js" />
<folder Name="Source Files">
<configuration Name="Common" filter="c;cpp;cxx;cc;h;s;asm;inc" />
<file file_name="retarget.c" />
<file file_name="kinetis_hw.c" />
<file file_name="hw.h" />
<file file_name="test_main.c" />
<file file_name="arm_startup.c" />
<file file_name="user_settings.h" />
<file file_name="README.md" />
</folder>
<folder Name="System Files">
<file file_name="Kinetis_FlashPlacement.xml" />
</folder>
</project>
<project Name="benchmark">
<configuration
Name="Common"
Placement="Flash"
Target="MK64FN1M0xxx12"
arm_architecture="v7EM"
arm_core_type="Cortex-M4"
arm_fpu_type="FPv4-SP-D16"
arm_linker_fiq_stack_size="0"
arm_linker_heap_size="91136"
arm_linker_irq_stack_size="0"
arm_linker_stack_size="30720"
arm_simulator_memory_simulation_filename="$(TargetsDir)/Kinetis/KinetisSimulatorMemory.dll"
arm_simulator_memory_simulation_parameter="MK64FN1M0xxx12;0x100000;0x0;0x0;0x40000;4"
arm_target_loader_applicable_loaders="Flash"
arm_target_loader_default_loader="Flash"
c_preprocessor_definitions="WOLFSSL_ROWLEY_ARM;WOLFSSL_USER_SETTINGS"
c_user_include_directories=".;../;../../;$(TargetsDir);$(TargetsDir)/Kinetis;$(TargetsDir)/Kinetis/CMSIS;$(TargetsDir)/Kinetis/CMSIS/include;$(TargetsDir)/CMSIS_4/CMSIS/include;$(TargetsDir)/../CMSIS_4/CMSIS;$(TargetsDir)/../CMSIS_4/CMSIS/Include"
debug_register_definition_file="$(TargetsDir)/Kinetis/MK64F12_Peripherals.xml"
linker_memory_map_file="$(TargetsDir)/Kinetis/MK64FN1M0xxx12_MemoryMap.xml"
linker_memory_map_macros="FLASHSIZE=0x80000;SRAMSIZE=0x20000"
linker_output_format="bin"
project_dependencies="libwolfssl"
project_type="Executable"
property_groups_file_path="$(TargetsDir)/Kinetis/propertyGroups.xml"
target_get_partname_script="GetPartName()"
target_match_partname_script="MatchPartName(&quot;$(Target)&quot;)"
target_reset_script="FLASHReset()"
target_script_file="$(TargetsDir)/Kinetis/Kinetis_Target.js" />
<folder Name="Source Files">
<configuration Name="Common" filter="c;cpp;cxx;cc;h;s;asm;inc" />
<file file_name="retarget.c" />
<file file_name="kinetis_hw.c" />
<file file_name="hw.h" />
<file file_name="benchmark_main.c" />
<file file_name="arm_startup.c" />
<file file_name="user_settings.h" />
<file file_name="README.md" />
</folder>
<folder Name="System Files">
<file file_name="Kinetis_FlashPlacement.xml" />
</folder>
<configuration
Name="Flash"
arm_target_flash_loader_file_path="$(TargetsDir)/Kinetis/Release/Loader.elf"
arm_target_loader_parameter="4" />
</project>
<configuration
Name="ARM"
Platform="ARM"
arm_architecture="v7EM"
arm_core_type="Cortex-M4"
arm_instruction_set="ARM"
arm_library_instruction_set="ARM"
c_preprocessor_definitions="__ARM"
hidden="Yes" />
<configuration
Name="LE"
arm_endian="Little"
c_preprocessor_definitions="__LITTLE_ENDIAN"
hidden="Yes" />
<configuration
Name="BE"
arm_endian="Big"
c_preprocessor_definitions="__BIG_ENDIAN"
hidden="Yes" />
<configuration
Name="Soft"
arm_fp_abi="Soft"
c_preprocessor_definitions="__FP_ABI_SOFT__"
hidden="Yes" />
<configuration
Name="Small"
arm_library_optimization="Small"
c_preprocessor_definitions="__OPTIMIZATION_SMALL"
gcc_optimization_level="Optimize For Size"
hidden="Yes" />
<configuration Name="WCHAR16" gcc_wchar_size="16-Bit" hidden="Yes" />
<configuration
Name="Debug"
c_preprocessor_definitions="DEBUG"
gcc_debugging_level="Level 3"
gcc_optimization_level="None"
hidden="Yes" />
<configuration
Name="Float"
c_preprocessor_definitions="SHORT_FLOAT"
double_is_float="Yes"
hidden="Yes" />
<configuration
Name="Release"
c_preprocessor_definitions="NDEBUG"
gcc_debugging_level="Level 1"
gcc_optimization_level="Level 1"
hidden="Yes" />
<configuration
Name="Fast"
arm_library_optimization="Fast"
c_preprocessor_definitions="__OPTIMIZATION_FAST"
gcc_optimization_level="Level 1"
hidden="Yes" />
<configuration
Name="THUMB"
Platform="ARM"
arm_instruction_set="Thumb"
arm_library_instruction_set="Thumb"
c_preprocessor_definitions="__THUMB"
hidden="Yes" />
<configuration
Name="Hard"
arm_fp_abi="Hard"
c_preprocessor_definitions="__FP_ABI_HARD__"
hidden="Yes" />
<configuration
Name="Flash"
c_preprocessor_definitions="__FLASH_BUILD"
hidden="Yes" />
<configuration
Name="RAM"
c_preprocessor_definitions="__RAM_BUILD"
hidden="Yes" />
<configuration
Name="Kinetis"
arm_target_debug_interface_type="ADIv5"
c_preprocessor_definitions="FREESCALE;K_SERIES"
hidden="Yes"
linker_section_placement_file="$(ProjectDir)/Kinetis_FlashPlacement.xml" />
<configuration
Name="V4"
arm_architecture="v4T"
arm_interwork="No"
c_preprocessor_definitions="__ARCH_V4"
hidden="Yes" />
<configuration
Name="V4T"
arm_architecture="v4T"
c_preprocessor_definitions="__ARCH_V4T"
hidden="Yes" />
<configuration
Name="V5TE"
arm_architecture="v5TE"
c_preprocessor_definitions="__ARCH_V5TE"
hidden="Yes" />
<configuration
Name="V6"
arm_architecture="v6"
c_preprocessor_definitions="__ARCH_V6"
hidden="Yes" />
<configuration
Name="V7A"
arm_architecture="v7A"
c_preprocessor_definitions="__ARCH_V7A"
hidden="Yes" />
<configuration
Name="V7R"
arm_architecture="v7R"
c_preprocessor_definitions="__ARCH_V7R"
hidden="Yes" />
<configuration
Name="V6M"
arm_architecture="v6M"
c_preprocessor_definitions="__ARCH_V6M"
hidden="Yes" />
<configuration
Name="V7M"
arm_architecture="v7M"
c_preprocessor_definitions="__ARCH_V7M"
hidden="Yes" />
<configuration
Name="V7EM"
arm_architecture="v7EM"
c_preprocessor_definitions="__ARCH_V7EM"
hidden="Yes" />
<configuration
Name="V5TE VFP"
arm_architecture="v5TE"
arm_fpu_type="VFP"
c_preprocessor_definitions="__ARCH_V5TE;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="SoftFP"
arm_fp_abi="SoftFP"
c_preprocessor_definitions="__FP_ABI_SOFT_FP__"
hidden="Yes" />
<configuration
Name="V6 VFP"
arm_architecture="v6"
arm_fpu_type="VFP"
c_preprocessor_definitions="__ARCH_V6;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7A VFPv3-D32"
arm_architecture="v7A"
arm_fpu_type="VFPv3-D32"
c_preprocessor_definitions="__ARCH_V7A;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7A VFPv4-D16"
arm_architecture="v7A"
arm_fpu_type="VFPv4-D16"
c_preprocessor_definitions="__ARCH_V7A;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7A_IDIV VFPv4-D16"
arm_architecture="v7A"
arm_fpu_type="VFPv4-D16"
arm_v7_has_divide_instructions="Yes"
c_preprocessor_definitions="__ARCH_V7A;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7R VFPv3-D16"
arm_architecture="v7R"
arm_fpu_type="VFPv3-D16"
c_preprocessor_definitions="__ARCH_V7R;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7R_IDIV VFPv3-D16"
arm_architecture="v7R"
arm_fpu_type="VFPv3-D16"
arm_v7_has_divide_instructions="Yes"
c_preprocessor_definitions="__ARCH_V7R;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7EM FPv4-SP-D16"
arm_architecture="v7EM"
arm_fpu_type="FPv4-SP-D16"
c_preprocessor_definitions="__ARCH_V7EM;__FPV4_SP_D16__"
hidden="Yes" />
<configuration
Name="V7EM FPv5-SP-D16"
arm_architecture="v7EM"
arm_fpu_type="FPv5-SP-D16"
c_preprocessor_definitions="__ARCH_V7EM;__FPV5_SP_D16__"
hidden="Yes" />
<configuration
Name="V7EM FPv5-D16"
arm_architecture="v7EM"
arm_fpu_type="FPv5-D16"
c_preprocessor_definitions="__ARCH_V7EM;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="ARM_Debug"
batch_build_configurations="V7EM THUMB * Debug"
inherited_configurations="ARM;V7EM;Debug;Kinetis;THUMB;Flash" />
<configuration
Name="ARM_Release"
batch_build_configurations="V7EM THUMB * Release"
inherited_configurations="ARM;V7EM;Release;Kinetis;Flash;THUMB" />
<configuration
Name="Common"
build_intermediate_directory="$(ProjectName)_$(Configuration)"
build_output_directory="$(ProjectName)_$(Configuration)" />
</solution>

View File

@@ -0,0 +1,637 @@
<!DOCTYPE CrossStudio_Project_File>
<solution Name="wolfssl_ltc" target="8" version="2">
<project Name="libwolfssl_ltc">
<configuration
Name="Common"
build_output_file_name="$(OutDir)/$(ProjectName)$(LibExt)$(LIB)"
c_preprocessor_definitions="WOLFSSL_ROWLEY_ARM;WOLFSSL_USER_SETTINGS;USE_NXP_MMCAU;USE_NXP_LTC"
c_user_include_directories=".;../;../../;./drivers;./mmcau_2.0.0;./CMSIS/Include"
project_directory=""
project_type="Library" />
<folder Name="Source Files">
<configuration Name="Common" filter="c;cpp;cxx;cc;h;s;inc" />
<folder Name="wolfcrypt">
<folder Name="benchmark">
<file file_name="../../wolfcrypt/benchmark/benchmark.c" />
<file file_name="../../wolfcrypt/benchmark/benchmark.h" />
<file file_name="../../wolfcrypt/benchmark/include.am" />
</folder>
<folder Name="src">
<file file_name="../../wolfcrypt/src/aes.c" />
<file file_name="../../wolfcrypt/src/arc4.c" />
<file file_name="../../wolfcrypt/src/asm.c">
<configuration Name="ARM_Debug" build_exclude_from_build="Yes" />
</file>
<file file_name="../../wolfcrypt/src/asn.c" />
<file file_name="../../wolfcrypt/src/blake2b.c" />
<file file_name="../../wolfcrypt/src/camellia.c" />
<file file_name="../../wolfcrypt/src/chacha.c" />
<file file_name="../../wolfcrypt/src/chacha20_poly1305.c" />
<file file_name="../../wolfcrypt/src/coding.c" />
<file file_name="../../wolfcrypt/src/compress.c" />
<file file_name="../../wolfcrypt/src/curve25519.c" />
<file file_name="../../wolfcrypt/src/des3.c" />
<file file_name="../../wolfcrypt/src/dh.c" />
<file file_name="../../wolfcrypt/src/dsa.c" />
<file file_name="../../wolfcrypt/src/ecc.c" />
<file file_name="../../wolfcrypt/src/ecc_fp.c" />
<file file_name="../../wolfcrypt/src/ed25519.c" />
<file file_name="../../wolfcrypt/src/error.c" />
<file file_name="../../wolfcrypt/src/fe_low_mem.c" />
<file file_name="../../wolfcrypt/src/fe_operations.c" />
<file file_name="../../wolfcrypt/src/fp_mont_small.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_12.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_17.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_20.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_24.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_28.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_3.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_32.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_4.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_48.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_6.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_64.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_7.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_8.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_9.i" />
<file file_name="../../wolfcrypt/src/fp_mul_comba_small_set.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_12.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_17.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_20.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_24.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_28.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_3.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_32.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_4.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_48.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_6.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_64.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_7.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_8.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_9.i" />
<file file_name="../../wolfcrypt/src/fp_sqr_comba_small_set.i" />
<file file_name="../../wolfcrypt/src/ge_low_mem.c" />
<file file_name="../../wolfcrypt/src/ge_operations.c" />
<file file_name="../../wolfcrypt/src/hash.c" />
<file file_name="../../wolfcrypt/src/kdf.c" />
<file file_name="../../wolfcrypt/src/hmac.c" />
<file file_name="../../wolfcrypt/src/include.am" />
<file file_name="../../wolfcrypt/src/integer.c" />
<file file_name="../../wolfcrypt/src/logging.c" />
<file file_name="../../wolfcrypt/src/md2.c" />
<file file_name="../../wolfcrypt/src/md4.c" />
<file file_name="../../wolfcrypt/src/md5.c" />
<file file_name="../../wolfcrypt/src/memory.c" />
<file file_name="../../wolfcrypt/src/misc.c">
<configuration Name="ARM_Debug" build_exclude_from_build="Yes" />
<configuration
Name="ARM_Release"
build_exclude_from_build="Yes" />
</file>
<file file_name="../../wolfcrypt/src/pkcs7.c" />
<file file_name="../../wolfcrypt/src/poly1305.c" />
<file file_name="../../wolfcrypt/src/pwdbased.c" />
<file file_name="../../wolfcrypt/src/random.c" />
<file file_name="../../wolfcrypt/src/ripemd.c" />
<file file_name="../../wolfcrypt/src/rsa.c" />
<file file_name="../../wolfcrypt/src/sha.c" />
<file file_name="../../wolfcrypt/src/sha256.c" />
<file file_name="../../wolfcrypt/src/sha512.c" />
<file file_name="../../wolfcrypt/src/signature.c" />
<file file_name="../../wolfcrypt/src/srp.c" />
<file file_name="../../wolfcrypt/src/tfm.c" />
<file file_name="../../wolfcrypt/src/wc_encrypt.c" />
<file file_name="../../wolfcrypt/src/wc_port.c" />
<file file_name="../../wolfcrypt/src/wolfmath.c" />
<file file_name="../../wolfcrypt/src/wolfevent.c" />
<folder Name="port">
<folder Name="nxp">
<file file_name="../../wolfcrypt/src/port/nxp/ksdk_port.c" />
<file file_name="fsl_debug_console.c" />
<file file_name="MK82F25615.h" />
<file file_name="MK82F25615_features.h" />
<file file_name="arm_common_tables.h" />
<file file_name="arm_const_structs.h" />
<file file_name="arm_math.h" />
<file file_name="cmsis_gcc.h" />
<file file_name="core_cm4.h" />
<file file_name="core_cmFunc.h" />
<file file_name="core_cmInstr.h" />
<file file_name="core_cmSimd.h" />
<file file_name="fsl_debug_console.h" />
<file file_name="fsl_device_registers.h" />
<file file_name="system_MK82F25615.h" />
<file file_name="clock_config.c" />
<file file_name="clock_config.h" />
<folder Name="drivers">
<file file_name="drivers/fsl_adc16.c" />
<file file_name="drivers/fsl_adc16.h" />
<file file_name="drivers/fsl_clock.c" />
<file file_name="drivers/fsl_clock.h" />
<file file_name="drivers/fsl_cmp.c" />
<file file_name="drivers/fsl_cmp.h" />
<file file_name="drivers/fsl_cmt.c" />
<file file_name="drivers/fsl_cmt.h" />
<file file_name="drivers/fsl_common.c" />
<file file_name="drivers/fsl_common.h" />
<file file_name="drivers/fsl_crc.c" />
<file file_name="drivers/fsl_crc.h" />
<file file_name="drivers/fsl_dac.c" />
<file file_name="drivers/fsl_dac.h" />
<file file_name="drivers/fsl_dmamux.c" />
<file file_name="drivers/fsl_dmamux.h" />
<file file_name="drivers/fsl_dspi.c" />
<file file_name="drivers/fsl_dspi.h" />
<file file_name="drivers/fsl_dspi_edma.c" />
<file file_name="drivers/fsl_dspi_edma.h" />
<file file_name="drivers/fsl_dspi_freertos.c">
<configuration
Name="ARM_Debug"
build_exclude_from_build="Yes" />
<configuration
Name="ARM_Release"
build_exclude_from_build="Yes" />
</file>
<file file_name="drivers/fsl_dspi_freertos.h" />
<file file_name="drivers/fsl_edma.c" />
<file file_name="drivers/fsl_edma.h" />
<file file_name="drivers/fsl_ewm.c" />
<file file_name="drivers/fsl_ewm.h" />
<file file_name="drivers/fsl_flash.h" />
<file file_name="drivers/fsl_flexbus.c" />
<file file_name="drivers/fsl_flexbus.h" />
<file file_name="drivers/fsl_flexio.c" />
<file file_name="drivers/fsl_flexio.h" />
<file file_name="drivers/fsl_flexio_camera.c" />
<file file_name="drivers/fsl_flexio_camera.h" />
<file file_name="drivers/fsl_flexio_camera_edma.c" />
<file file_name="drivers/fsl_flexio_camera_edma.h" />
<file file_name="drivers/fsl_flexio_i2c_master.c" />
<file file_name="drivers/fsl_flexio_i2c_master.h" />
<file file_name="drivers/fsl_flexio_i2s.c" />
<file file_name="drivers/fsl_flexio_i2s.h" />
<file file_name="drivers/fsl_flexio_i2s_edma.c" />
<file file_name="drivers/fsl_flexio_i2s_edma.h" />
<file file_name="drivers/fsl_flexio_spi.c" />
<file file_name="drivers/fsl_flexio_spi.h" />
<file file_name="drivers/fsl_flexio_spi_edma.c" />
<file file_name="drivers/fsl_flexio_spi_edma.h" />
<file file_name="drivers/fsl_flexio_uart.c" />
<file file_name="drivers/fsl_flexio_uart.h" />
<file file_name="drivers/fsl_flexio_uart_edma.c" />
<file file_name="drivers/fsl_flexio_uart_edma.h" />
<file file_name="drivers/fsl_ftm.c" />
<file file_name="drivers/fsl_ftm.h" />
<file file_name="drivers/fsl_gpio.c" />
<file file_name="drivers/fsl_gpio.h" />
<file file_name="drivers/fsl_i2c.c" />
<file file_name="drivers/fsl_i2c.h" />
<file file_name="drivers/fsl_i2c_edma.c" />
<file file_name="drivers/fsl_i2c_edma.h" />
<file file_name="drivers/fsl_i2c_freertos.c">
<configuration
Name="ARM_Debug"
build_exclude_from_build="Yes" />
<configuration
Name="ARM_Release"
build_exclude_from_build="Yes" />
</file>
<file file_name="drivers/fsl_i2c_freertos.h" />
<file file_name="drivers/fsl_llwu.c" />
<file file_name="drivers/fsl_llwu.h" />
<file file_name="drivers/fsl_lmem_cache.c" />
<file file_name="drivers/fsl_lmem_cache.h" />
<file file_name="drivers/fsl_lptmr.c" />
<file file_name="drivers/fsl_lptmr.h" />
<file file_name="drivers/fsl_lpuart.c" />
<file file_name="drivers/fsl_lpuart.h" />
<file file_name="drivers/fsl_lpuart_edma.c" />
<file file_name="drivers/fsl_lpuart_edma.h" />
<file file_name="fsl_lpuart_freertos.c">
<configuration
Name="ARM_Debug"
build_exclude_from_build="Yes" />
<configuration
Name="ARM_Release"
build_exclude_from_build="Yes" />
</file>
<file file_name="drivers/fsl_lpuart_freertos.h" />
<file file_name="drivers/fsl_ltc.c" />
<file file_name="drivers/fsl_ltc.h" />
<file file_name="drivers/fsl_ltc_edma.c" />
<file file_name="drivers/fsl_ltc_edma.h" />
<file file_name="drivers/fsl_pdb.c" />
<file file_name="drivers/fsl_pdb.h" />
<file file_name="drivers/fsl_pit.c" />
<file file_name="drivers/fsl_pit.h" />
<file file_name="drivers/fsl_pmc.c" />
<file file_name="drivers/fsl_pmc.h" />
<file file_name="drivers/fsl_port.h" />
<file file_name="drivers/fsl_qspi.c" />
<file file_name="drivers/fsl_qspi.h" />
<file file_name="drivers/fsl_qspi_edma.c" />
<file file_name="drivers/fsl_qspi_edma.h" />
<file file_name="drivers/fsl_rcm.c" />
<file file_name="drivers/fsl_rcm.h" />
<file file_name="drivers/fsl_rtc.c" />
<file file_name="drivers/fsl_rtc.h" />
<file file_name="drivers/fsl_sai.c" />
<file file_name="drivers/fsl_sai.h" />
<file file_name="drivers/fsl_sai_edma.c" />
<file file_name="drivers/fsl_sai_edma.h" />
<file file_name="drivers/fsl_sdhc.c" />
<file file_name="drivers/fsl_sdhc.h" />
<file file_name="drivers/fsl_sdramc.c" />
<file file_name="drivers/fsl_sdramc.h" />
<file file_name="drivers/fsl_sim.c" />
<file file_name="drivers/fsl_sim.h" />
<file file_name="drivers/fsl_smartcard.h" />
<file file_name="drivers/fsl_smartcard_emvsim.c" />
<file file_name="drivers/fsl_smartcard_emvsim.h" />
<file file_name="drivers/fsl_smartcard_freertos.c">
<configuration
Name="ARM_Debug"
build_exclude_from_build="Yes" />
<configuration
Name="ARM_Release"
build_exclude_from_build="Yes" />
</file>
<file file_name="drivers/fsl_smartcard_freertos.h" />
<file file_name="drivers/fsl_smartcard_phy_emvsim.c" />
<file file_name="drivers/fsl_smartcard_phy_emvsim.h" />
<file file_name="drivers/fsl_smartcard_phy_ncn8025.c" />
<file file_name="drivers/fsl_smartcard_phy_ncn8025.h" />
<file file_name="drivers/fsl_smc.c" />
<file file_name="drivers/fsl_smc.h" />
<file file_name="drivers/fsl_tpm.c" />
<file file_name="drivers/fsl_tpm.h" />
<file file_name="drivers/fsl_trng.c" />
<file file_name="drivers/fsl_trng.h" />
<file file_name="drivers/fsl_tsi_v4.c" />
<file file_name="drivers/fsl_tsi_v4.h" />
<file file_name="drivers/fsl_vref.c" />
<file file_name="drivers/fsl_vref.h" />
<file file_name="drivers/fsl_wdog.c" />
<file file_name="drivers/fsl_wdog.h" />
</folder>
<file file_name="system_MK82F25615.c" />
</folder>
</folder>
</folder>
<folder Name="test">
<file file_name="../../wolfcrypt/test/include.am" />
<file file_name="../../wolfcrypt/test/test.c" />
<file file_name="../../wolfcrypt/test/test.h" />
</folder>
<folder Name="user-crypto" path="../../wolfcrypt/user-crypto">
<configuration Name="Common" build_exclude_from_build="Yes" />
</folder>
</folder>
<folder
Name="wolfssl"
exclude="*.asm;*.s"
filter=""
path="../../wolfssl"
recurse="Yes" />
<file file_name="user_settings.h" />
<file file_name="README.md" />
<folder Name="source">
<file file_name="../../src/bio.c">
<configuration Name="ARM_Debug" build_exclude_from_build="Yes" />
</file>
<file file_name="../../src/crl.c" />
<file file_name="../../src/include.am" />
<file file_name="../../src/internal.c" />
<file file_name="../../src/wolfio.c" />
<file file_name="../../src/keys.c" />
<file file_name="../../src/libwolfssl.la" />
<file file_name="../../src/ocsp.c" />
<file file_name="../../src/sniffer.c" />
<file file_name="../../src/src_libwolfssl_la-internal.lo" />
<file file_name="../../src/src_libwolfssl_la-io.lo" />
<file file_name="../../src/src_libwolfssl_la-keys.lo" />
<file file_name="../../src/src_libwolfssl_la-ssl.lo" />
<file file_name="../../src/src_libwolfssl_la-tls.lo" />
<file file_name="../../src/ssl.c" />
<file file_name="../../src/tls.c" />
</folder>
</folder>
</project>
<project Name="test_ltc">
<configuration
Name="Common"
Placement="Flash"
Target="MK82FN256xxx15"
arm_architecture="v7EM"
arm_core_type="Cortex-M4"
arm_fpu_type="FPv4-SP-D16"
arm_linker_fiq_stack_size="0"
arm_linker_heap_size="91136"
arm_linker_irq_stack_size="0"
arm_linker_stack_size="30720"
arm_simulator_memory_simulation_filename="$(TargetsDir)/Kinetis/KinetisSimulatorMemory.dll"
arm_simulator_memory_simulation_parameter="MK82FN256xxx15;0x40000;0x0;0x0;0x40000;4"
arm_target_loader_applicable_loaders="Flash"
arm_target_loader_default_loader="Flash"
c_preprocessor_definitions="WOLFSSL_ROWLEY_ARM;WOLFSSL_USER_SETTINGS;USE_NXP_MMCAU;USE_NXP_LTC"
c_user_include_directories=".;./drivers;./mmcau_2.0.0;./CMSIS/Include;../;../../;$(TargetsDir);$(TargetsDir)/Kinetis;$(TargetsDir)/Kinetis/CMSIS;$(TargetsDir)/Kinetis/CMSIS/include;$(TargetsDir)/CMSIS_3/CMSIS/include"
debug_register_definition_file="$(TargetsDir)/Kinetis/MK82F25615_Peripherals.xml"
linker_memory_map_file="$(TargetsDir)/Kinetis/MK82FN256xxx15_MemoryMap.xml"
linker_memory_map_macros="FLASHSIZE=0x40000;SRAMSIZE=0x40000"
linker_output_format="bin"
project_dependencies="libwolfssl_ltc"
project_type="Executable"
property_groups_file_path="$(TargetsDir)/Kinetis/propertyGroups.xml"
target_get_partname_script="GetPartName()"
target_match_partname_script="MatchPartName(&quot;$(Target)&quot;)"
target_reset_script="FLASHReset()"
target_script_file="$(TargetsDir)/Kinetis/Kinetis_Target.js" />
<folder Name="Source Files">
<configuration Name="Common" filter="c;cpp;cxx;cc;h;s;asm;inc" />
<file file_name="retarget.c" />
<file file_name="kinetis_hw.c" />
<file file_name="hw.h" />
<file file_name="test_main.c" />
<file file_name="arm_startup.c" />
<file file_name="user_settings.h" />
<file file_name="README.md" />
<folder Name="mmcau">
<file file_name="mmcau_2.0.0/cau_api.h" />
<file file_name="mmcau_2.0.0/fsl_mmcau.c" />
<file file_name="mmcau_2.0.0/fsl_mmcau.h" />
<file file_name="mmcau_2.0.0/README.txt" />
<folder Name="asm-cm4-cm7">
<file file_name="mmcau_2.0.0/asm-cm4-cm7/lib_mmcau.a" />
</folder>
</folder>
</folder>
<folder Name="System Files">
<file file_name="Kinetis_FlashPlacement.xml" />
</folder>
<configuration
Name="Flash"
arm_target_flash_loader_file_path="$(TargetsDir)/Kinetis/Release/Loader3.elf" />
</project>
<project Name="benchmark_ltc">
<configuration
Name="Common"
Placement="Flash"
Target="MK82FN256xxx15"
arm_architecture="v7EM"
arm_core_type="Cortex-M4"
arm_fpu_type="FPv4-SP-D16"
arm_linker_fiq_stack_size="0"
arm_linker_heap_size="91136"
arm_linker_irq_stack_size="0"
arm_linker_stack_size="30720"
arm_simulator_memory_simulation_filename="$(TargetsDir)/Kinetis/KinetisSimulatorMemory.dll"
arm_simulator_memory_simulation_parameter="MK82FN256xxx15;0x40000;0x0;0x0;0x40000;4"
arm_target_loader_applicable_loaders="Flash"
arm_target_loader_default_loader="Flash"
c_preprocessor_definitions="WOLFSSL_ROWLEY_ARM;WOLFSSL_USER_SETTINGS"
c_user_include_directories=".;./drivers;./mmcau_2.0.0;./CMSIS/Include;../;../../;$(TargetsDir);$(TargetsDir)/Kinetis;$(TargetsDir)/Kinetis/CMSIS;$(TargetsDir)/Kinetis/CMSIS/include;$(TargetsDir)/CMSIS_3/CMSIS/include"
debug_register_definition_file="$(TargetsDir)/Kinetis/MK82F25615_Peripherals.xml"
linker_memory_map_file="$(TargetsDir)/Kinetis/MK82FN256xxx15_MemoryMap.xml"
linker_memory_map_macros="FLASHSIZE=0x40000;SRAMSIZE=0x40000"
linker_output_format="bin"
project_dependencies="libwolfssl_ltc"
project_type="Executable"
property_groups_file_path="$(TargetsDir)/Kinetis/propertyGroups.xml"
target_get_partname_script="GetPartName()"
target_match_partname_script="MatchPartName(&quot;$(Target)&quot;)"
target_reset_script="FLASHReset()"
target_script_file="$(TargetsDir)/Kinetis/Kinetis_Target.js" />
<folder Name="Source Files">
<configuration Name="Common" filter="c;cpp;cxx;cc;h;s;asm;inc" />
<file file_name="retarget.c" />
<file file_name="kinetis_hw.c" />
<file file_name="hw.h" />
<file file_name="benchmark_main.c" />
<file file_name="arm_startup.c" />
<file file_name="user_settings.h" />
<file file_name="README.md" />
<folder Name="mmcau">
<file file_name="mmcau_2.0.0/cau_api.h" />
<file file_name="mmcau_2.0.0/fsl_mmcau.c" />
<file file_name="mmcau_2.0.0/fsl_mmcau.h" />
<file file_name="mmcau_2.0.0/README.txt" />
<folder Name="asm-cm4-cm7">
<file file_name="mmcau_2.0.0/asm-cm4-cm7/lib_mmcau.a">
<configuration Name="ARM_Debug" build_exclude_from_build="No" />
</file>
</folder>
</folder>
</folder>
<folder Name="System Files">
<file file_name="Kinetis_FlashPlacement.xml" />
</folder>
<configuration
Name="Flash"
arm_target_flash_loader_file_path="$(TargetsDir)/Kinetis/Release/Loader3.elf" />
</project>
<configuration
Name="ARM"
Platform="ARM"
arm_architecture="v7EM"
arm_core_type="Cortex-M4"
arm_instruction_set="ARM"
arm_library_instruction_set="ARM"
c_preprocessor_definitions="__ARM"
hidden="Yes" />
<configuration
Name="LE"
arm_endian="Little"
c_preprocessor_definitions="__LITTLE_ENDIAN"
hidden="Yes" />
<configuration
Name="BE"
arm_endian="Big"
c_preprocessor_definitions="__BIG_ENDIAN"
hidden="Yes" />
<configuration
Name="Soft"
arm_fp_abi="Soft"
c_preprocessor_definitions="__FP_ABI_SOFT__"
hidden="Yes" />
<configuration
Name="Small"
arm_library_optimization="Small"
c_preprocessor_definitions="__OPTIMIZATION_SMALL"
gcc_optimization_level="Optimize For Size"
hidden="Yes" />
<configuration Name="WCHAR16" gcc_wchar_size="16-Bit" hidden="Yes" />
<configuration
Name="Debug"
c_preprocessor_definitions="DEBUG"
gcc_debugging_level="Level 3"
gcc_optimization_level="None"
hidden="Yes" />
<configuration
Name="Float"
c_preprocessor_definitions="SHORT_FLOAT"
double_is_float="Yes"
hidden="Yes" />
<configuration
Name="Release"
c_preprocessor_definitions="NDEBUG"
gcc_debugging_level="Level 1"
gcc_optimization_level="Level 1"
hidden="Yes" />
<configuration
Name="Fast"
arm_library_optimization="Fast"
c_preprocessor_definitions="__OPTIMIZATION_FAST"
gcc_optimization_level="Level 1"
hidden="Yes" />
<configuration
Name="THUMB"
Platform="ARM"
arm_instruction_set="Thumb"
arm_library_instruction_set="Thumb"
c_preprocessor_definitions="__THUMB"
hidden="Yes" />
<configuration
Name="Hard"
arm_fp_abi="Hard"
c_preprocessor_definitions="__FP_ABI_HARD__"
hidden="Yes" />
<configuration
Name="Flash"
c_preprocessor_definitions="__FLASH_BUILD"
hidden="Yes" />
<configuration
Name="RAM"
c_preprocessor_definitions="__RAM_BUILD"
hidden="Yes" />
<configuration
Name="Kinetis"
arm_target_debug_interface_type="ADIv5"
c_preprocessor_definitions="FREESCALE;K_SERIES;CPU_MK82FN256VLL15;FREESCALE_KSDK_BM;USE_NXP_MMCAU;USE_NXP_LTC"
hidden="Yes"
linker_section_placement_file="$(ProjectDir)/Kinetis_FlashPlacement.xml" />
<configuration
Name="V4"
arm_architecture="v4T"
arm_interwork="No"
c_preprocessor_definitions="__ARCH_V4"
hidden="Yes" />
<configuration
Name="V4T"
arm_architecture="v4T"
c_preprocessor_definitions="__ARCH_V4T"
hidden="Yes" />
<configuration
Name="V5TE"
arm_architecture="v5TE"
c_preprocessor_definitions="__ARCH_V5TE"
hidden="Yes" />
<configuration
Name="V6"
arm_architecture="v6"
c_preprocessor_definitions="__ARCH_V6"
hidden="Yes" />
<configuration
Name="V7A"
arm_architecture="v7A"
c_preprocessor_definitions="__ARCH_V7A"
hidden="Yes" />
<configuration
Name="V7R"
arm_architecture="v7R"
c_preprocessor_definitions="__ARCH_V7R"
hidden="Yes" />
<configuration
Name="V6M"
arm_architecture="v6M"
c_preprocessor_definitions="__ARCH_V6M"
hidden="Yes" />
<configuration
Name="V7M"
arm_architecture="v7M"
c_preprocessor_definitions="__ARCH_V7M"
hidden="Yes" />
<configuration
Name="V7EM"
arm_architecture="v7EM"
c_preprocessor_definitions="__ARCH_V7EM"
hidden="Yes" />
<configuration
Name="V5TE VFP"
arm_architecture="v5TE"
arm_fpu_type="VFP"
c_preprocessor_definitions="__ARCH_V5TE;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="SoftFP"
arm_fp_abi="SoftFP"
c_preprocessor_definitions="__FP_ABI_SOFT_FP__"
hidden="Yes" />
<configuration
Name="V6 VFP"
arm_architecture="v6"
arm_fpu_type="VFP"
c_preprocessor_definitions="__ARCH_V6;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7A VFPv3-D32"
arm_architecture="v7A"
arm_fpu_type="VFPv3-D32"
c_preprocessor_definitions="__ARCH_V7A;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7A VFPv4-D16"
arm_architecture="v7A"
arm_fpu_type="VFPv4-D16"
c_preprocessor_definitions="__ARCH_V7A;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7A_IDIV VFPv4-D16"
arm_architecture="v7A"
arm_fpu_type="VFPv4-D16"
arm_v7_has_divide_instructions="Yes"
c_preprocessor_definitions="__ARCH_V7A;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7R VFPv3-D16"
arm_architecture="v7R"
arm_fpu_type="VFPv3-D16"
c_preprocessor_definitions="__ARCH_V7R;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7R_IDIV VFPv3-D16"
arm_architecture="v7R"
arm_fpu_type="VFPv3-D16"
arm_v7_has_divide_instructions="Yes"
c_preprocessor_definitions="__ARCH_V7R;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="V7EM FPv4-SP-D16"
arm_architecture="v7EM"
arm_fpu_type="FPv4-SP-D16"
c_preprocessor_definitions="__ARCH_V7EM;__FPV4_SP_D16__"
hidden="Yes" />
<configuration
Name="V7EM FPv5-SP-D16"
arm_architecture="v7EM"
arm_fpu_type="FPv5-SP-D16"
c_preprocessor_definitions="__ARCH_V7EM;__FPV5_SP_D16__"
hidden="Yes" />
<configuration
Name="V7EM FPv5-D16"
arm_architecture="v7EM"
arm_fpu_type="FPv5-D16"
c_preprocessor_definitions="__ARCH_V7EM;__FPU_VFP__"
hidden="Yes" />
<configuration
Name="ARM_Debug"
batch_build_configurations="V7EM THUMB * Debug"
inherited_configurations="ARM;V7EM;Debug;Kinetis;THUMB;Flash" />
<configuration
Name="ARM_Release"
batch_build_configurations="V7EM THUMB * Release"
inherited_configurations="ARM;V7EM;Release;Kinetis;Flash;THUMB" />
<configuration
Name="Common"
build_intermediate_directory="$(ProjectName)_$(Configuration)"
build_output_directory="$(ProjectName)_$(Configuration)" />
</solution>