Skip to content

Commit 0c82690

Browse files
authored
Merge pull request #5160 from cndabai/bsp
修复部分bsp编译报错
2 parents e7f4a11 + 99e9ea6 commit 0c82690

File tree

16 files changed

+23
-21
lines changed

16 files changed

+23
-21
lines changed

bsp/at91sam9g45/platform/system_clock.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ static struct clk plla = {
4444
static struct clk mck = {
4545
"mck",
4646
0,
47-
NULL,
47+
RT_NULL,
4848
{RT_NULL, RT_NULL},
4949
};
5050

bsp/ft2004/drivers/drv_spi.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ typedef struct
3232
{
3333
FSpi_Ctrl_t spi_ctrl;
3434
struct rt_spi_bus spi_bus;
35-
uint16_t spi_cs_pin;
35+
rt_uint16_t spi_cs_pin;
3636
spi_cs_handler_t spi_cs_handler;
3737
} ft2004_spi_class;
3838

@@ -214,7 +214,7 @@ static const struct rt_spi_ops ft2004_spi_ops =
214214
/**
215215
* Attach the spi device to SPI bus, this function must be used after initialization.
216216
*/
217-
rt_err_t rt_hw_spi_device_attach(const char *bus_name, const char *device_name, uint16_t cs_gpio_pin)
217+
rt_err_t rt_hw_spi_device_attach(const char *bus_name, const char *device_name, rt_uint16_t cs_gpio_pin)
218218
{
219219
rt_err_t result;
220220
struct rt_spi_device *spi_device;

bsp/ft2004/drivers/drv_spi.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
#define SPI_BUS_NAME "spi0"
2020
#define SPI_DEV_NAME "S25FS256"
2121

22-
rt_err_t rt_hw_spi_device_attach(const char *bus_name, const char *device_name, uint16_t cs_gpio_pin);
22+
rt_err_t rt_hw_spi_device_attach(const char *bus_name, const char *device_name, rt_uint16_t cs_gpio_pin);
2323

2424
#ifdef __cplusplus
2525
extern "C"

bsp/ft2004/drivers/ft2004.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ rt_uint32_t arm_gic_cpumask_to_affval(rt_uint32_t *cpu_mask, rt_uint32_t *cluste
7575

7676
void send_core_isg(void)
7777
{
78-
for (size_t i = 0; i <= 0xf; i++)
78+
for (rt_size_t i = 0; i <= 0xf; i++)
7979
{
8080
/* code */
8181
rt_kprintf("i %x \r\n", i);

bsp/ft2004/drivers/gtimer.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ static inline rt_uint64_t __get_cntp_cval(void)
8686
* This function assigns the given value to PL1 Physical Timer Control Register (CNTP_CTL).
8787
* param value: CNTP_CTL Register value to set
8888
*/
89-
static inline void __set_cntp_ctl(uint32_t value)
89+
static inline void __set_cntp_ctl(rt_uint32_t value)
9090
{
9191
__set_cp(15, 0, value, 14, 2, 1);
9292
}

bsp/maxim/libraries/HAL_Drivers/drv_gpio.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ static rt_err_t mcu_pin_dettach_irq(struct rt_device *device, rt_int32_t pin)
158158
tmp_gpio_cfg.func = GPIO_FUNC_IN;
159159
GPIO_Config(&tmp_gpio_cfg);
160160
GPIO_IntDisable(&tmp_gpio_cfg);
161-
GPIO_RegisterCallback(&tmp_gpio_cfg, NULL, NULL);
161+
GPIO_RegisterCallback(&tmp_gpio_cfg, RT_NULL, RT_NULL);
162162
return RT_EOK;
163163
}
164164

@@ -189,7 +189,7 @@ const static struct rt_pin_ops _mcu_pin_ops =
189189
mcu_pin_attach_irq,
190190
mcu_pin_dettach_irq,
191191
mcu_pin_irq_enable,
192-
NULL,
192+
RT_NULL,
193193
};
194194

195195
int rt_hw_pin_init(void)

bsp/maxim/libraries/HAL_Drivers/drv_uart.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ int rt_hw_usart_init(void)
241241
RT_DEVICE_FLAG_RDWR
242242
| RT_DEVICE_FLAG_INT_RX
243243
| RT_DEVICE_FLAG_INT_TX
244-
, NULL);
244+
, RT_NULL);
245245
RT_ASSERT(result == RT_EOK);
246246
}
247247

bsp/nuvoton/libraries/nu_packages/Demo/slcd_show_tick.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
#include <rtthread.h>
1818
#include <rtdevice.h>
19+
#include <sys/time.h>
1920

2021
#include "slcd_rhe6616tp01.h"
2122

bsp/raspberry-pi/raspi3-32/applications/test_device.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
#include <rthw.h>
1515
#include <string.h>
1616
#include <drivers/hwtimer.h>
17-
#include "raspi.h"
17+
#include <raspi.h>
18+
#include <sys/time.h>
1819

1920
#ifdef BSP_USING_HDMI
2021
#include "drv_fb.h"
@@ -368,7 +369,7 @@ int test_rtc(void)
368369
{
369370
#ifdef BSP_USING_RTC
370371
rt_kprintf("Hello Test RTC!\n");
371-
uint8_t i;
372+
rt_uint8_t i;
372373
time_t now;
373374

374375
rt_err_t ret = RT_EOK;

bsp/raspberry-pi/raspi3-32/cpu/cp15.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ static inline rt_uint32_t read_cntctrl(void)
142142
return val;
143143
}
144144

145-
static inline uint32_t write_cntctrl(uint32_t val)
145+
static inline rt_uint32_t write_cntctrl(rt_uint32_t val)
146146
{
147147

148148
asm volatile ("mcr p15, 0, %0, c14, c1, 0" : :"r"(val));

0 commit comments

Comments
 (0)