Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Bernard Xiong 2015-09-02 12:18:31 +08:00
commit 9e3c42273d
13 changed files with 147 additions and 38 deletions

View File

@ -1,11 +1,21 @@
/* /*
* File : application.c * File : application.c
* This file is part of RT-Thread RTOS * This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2006, RT-Thread Development Team * COPYRIGHT (C) 2015, RT-Thread Development Team
* *
* The license and distribution terms for this file may be * This program is free software; you can redistribute it and/or modify
* found in the file LICENSE in this distribution or at * it under the terms of the GNU General Public License as published by
* http://www.rt-thread.org/license/LICENSE * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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-1301 USA.
* *
* Change Logs: * Change Logs:
* Date Author Notes * Date Author Notes

View File

@ -1,13 +1,23 @@
/* /*
* File : sram.c * File : sram.c
* This file is part of RT-Thread RTOS * This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2015 RT-Thread Develop Team * COPYRIGHT (C) 2015, RT-Thread Development Team
* *
* The license and distribution terms for this file may be * This program is free software; you can redistribute it and/or modify
* found in the file LICENSE in this distribution or at * it under the terms of the GNU General Public License as published by
* http://www.rt-thread.org/license/LICENSE * the Free Software Foundation; either version 2 of the License, or
* * (at your option) any later version.
* Change Logs: *
* This program 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-1301 USA.
*
* Change Logs:
* Date Author Notes * Date Author Notes
* 2015-08-03 xiaonong The first version for STM32F7 * 2015-08-03 xiaonong The first version for STM32F7
*/ */

View File

@ -1,11 +1,21 @@
/* /*
* File : startup.c * File : startup.c
* This file is part of RT-Thread RTOS * This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2015, RT-Thread Develop Team * COPYRIGHT (C) 2015, RT-Thread Development Team
* *
* The license and distribution terms for this file may be * This program is free software; you can redistribute it and/or modify
* found in the file LICENSE in this distribution or at * it under the terms of the GNU General Public License as published by
* http://openlab.rt-thread.com/license/LICENSE * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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-1301 USA.
* *
* Change Logs: * Change Logs:
* Date Author Notes * Date Author Notes

View File

@ -1,11 +1,21 @@
/* /*
* File : board.c * File : board.c
* This file is part of RT-Thread RTOS * This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2015 RT-Thread Develop Team * COPYRIGHT (C) 2015, RT-Thread Development Team
* *
* The license and distribution terms for this file may be * This program is free software; you can redistribute it and/or modify
* found in the file LICENSE in this distribution or at * it under the terms of the GNU General Public License as published by
* http://www.rt-thread.org/license/LICENSE * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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-1301 USA.
* *
* Change Logs: * Change Logs:
* Date Author Notes * Date Author Notes

View File

@ -3,9 +3,19 @@
* This file is part of RT-Thread RTOS * This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2015, RT-Thread Development Team * COPYRIGHT (C) 2015, RT-Thread Development Team
* *
* The license and distribution terms for this file may be * This program is free software; you can redistribute it and/or modify
* found in the file LICENSE in this distribution or at * it under the terms of the GNU General Public License as published by
* http://www.rt-thread.org/license/LICENSE * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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-1301 USA.
* *
* Change Logs: * Change Logs:
* Date Author Notes * Date Author Notes

View File

@ -1,3 +1,27 @@
/*
* File : drv_mpu.c
* This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2015, RT-Thread Development Team
*
* This program 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.
*
* This program 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-1301 USA.
*
* Change Logs:
* Date Author Notes
* 2015-08-01 xiaonong the first version for stm32f7xx
*/
#include "drv_mpu.h" #include "drv_mpu.h"

View File

@ -1,11 +1,21 @@
/* /*
* File : drv_sdram.c * File : drv_sdram.c
* This file is part of RT-Thread RTOS * This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2015 RT-Thread Develop Team * COPYRIGHT (C) 2015, RT-Thread Development Team
* *
* The license and distribution terms for this file may be * This program is free software; you can redistribute it and/or modify
* found in the file LICENSE in this distribution or at * it under the terms of the GNU General Public License as published by
* http://www.rt-thread.org/license/LICENSE * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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-1301 USA.
* *
* Change Logs: * Change Logs:
* Date Author Notes * Date Author Notes

View File

@ -1,11 +1,21 @@
/* /*
* File : usart.c * File : drv_usart.c
* This file is part of RT-Thread RTOS * This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2009, RT-Thread Development Team * COPYRIGHT (C) 2015, RT-Thread Development Team
* *
* The license and distribution terms for this file may be * This program is free software; you can redistribute it and/or modify
* found in the file LICENSE in this distribution or at * it under the terms of the GNU General Public License as published by
* http://www.rt-thread.org/license/LICENSE * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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-1301 USA.
* *
* Change Logs: * Change Logs:
* Date Author Notes * Date Author Notes

View File

@ -114,7 +114,7 @@
// <section name="LIBC" description="C Runtime library setting" default="always" > // <section name="LIBC" description="C Runtime library setting" default="always" >
// <bool name="RT_USING_LIBC" description="Using libc library" default="true" /> // <bool name="RT_USING_LIBC" description="Using libc library" default="true" />
#define RT_USING_NEWLIB #define RT_USING_LIBC
// <bool name="RT_USING_PTHREADS" description="Using POSIX threads library" default="true" /> // <bool name="RT_USING_PTHREADS" description="Using POSIX threads library" default="true" />
//#define RT_USING_PTHREADS //#define RT_USING_PTHREADS
// </section> // </section>

View File

@ -229,8 +229,8 @@ struct finsh_sysvar* finsh_sysvar_lookup(const char* name);
#else #else
#define FINSH_FUNCTION_EXPORT_CMD(name, cmd, desc) \ #define FINSH_FUNCTION_EXPORT_CMD(name, cmd, desc) \
const char __fsym_##cmd##_name[] = #cmd; \ const char __fsym_##cmd##_name[] SECTION(".name") = #cmd; \
const char __fsym_##cmd##_desc[] = #desc; \ const char __fsym_##cmd##_desc[] SECTION(".name") = #desc; \
const struct finsh_syscall __fsym_##cmd SECTION("FSymTab")= \ const struct finsh_syscall __fsym_##cmd SECTION("FSymTab")= \
{ \ { \
__fsym_##cmd##_name, \ __fsym_##cmd##_name, \
@ -239,8 +239,8 @@ struct finsh_sysvar* finsh_sysvar_lookup(const char* name);
}; };
#define FINSH_VAR_EXPORT(name, type, desc) \ #define FINSH_VAR_EXPORT(name, type, desc) \
const char __vsym_##name##_name[] = #name; \ const char __vsym_##name##_name[] SECTION(".name") = #name; \
const char __vsym_##name##_desc[] = #desc; \ const char __vsym_##name##_desc[] SECTION(".name") = #desc; \
const struct finsh_sysvar __vsym_##name SECTION("VSymTab")= \ const struct finsh_sysvar __vsym_##name SECTION("VSymTab")= \
{ \ { \
__vsym_##name##_name, \ __vsym_##name##_name, \

View File

@ -253,6 +253,7 @@ int system(const char *command)
{ {
return msh_exec_module(command, rt_strlen(command)); return msh_exec_module(command, rt_strlen(command));
} }
RTM_EXPORT(system);
#endif #endif
static int _msh_exec_cmd(char* cmd, rt_size_t length, int *retp) static int _msh_exec_cmd(char* cmd, rt_size_t length, int *retp)

View File

@ -695,3 +695,17 @@ RTM_EXPORT(dhcp_stop);
#include <lwip/netifapi.h> #include <lwip/netifapi.h>
RTM_EXPORT(netifapi_netif_set_addr); RTM_EXPORT(netifapi_netif_set_addr);
#endif #endif
#if LWIP_NETIF_LINK_CALLBACK
RTM_EXPORT(netif_set_link_callback);
#endif
#if LWIP_NETIF_STATUS_CALLBACK
RTM_EXPORT(netif_set_status_callback);
#endif
RTM_EXPORT(netif_find);
RTM_EXPORT(netif_set_addr);
RTM_EXPORT(netif_set_ipaddr);
RTM_EXPORT(netif_set_gw);
RTM_EXPORT(netif_set_netmask);

View File

@ -42,7 +42,7 @@ __declspec(allocate("RTMSymTab$f"))const char __rtmsym_##symbol##_name[] = "__vs
#else #else
#define RTM_EXPORT(symbol) \ #define RTM_EXPORT(symbol) \
const char __rtmsym_##symbol##_name[] = #symbol; \ const char __rtmsym_##symbol##_name[] SECTION(".name") = #symbol; \
const struct rt_module_symtab __rtmsym_##symbol SECTION("RTMSymTab")= \ const struct rt_module_symtab __rtmsym_##symbol SECTION("RTMSymTab")= \
{ \ { \
(void *)&symbol, \ (void *)&symbol, \