Skip to content

Commit 1468a73

Browse files
committed
Fix the CI build issue
1 parent da3e53e commit 1468a73

File tree

7 files changed

+19
-19
lines changed

7 files changed

+19
-19
lines changed

features/netsocket/emac-drivers/TARGET_ARM_SSG/COMPONENT_SMSC9220/smsc9220_emac.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ bool SMSC9220_EMAC::power_up()
210210
this));
211211
212212
/* Initialize the hardware */
213-
enum smsc9220_error_t init_successful = smsc9220_init(dev, &wait_ms);
213+
enum smsc9220_error_t init_successful = smsc9220_init(dev, &thread_sleep_for);
214214
if (init_successful != SMSC9220_ERROR_NONE) {
215215
return false;
216216
}
@@ -236,7 +236,7 @@ bool SMSC9220_EMAC::power_up()
236236
&SMSC9220_EMAC::link_status_task));
237237
238238
/* Allow the Link Status task to detect the initial link state */
239-
wait_ms(10);
239+
thread_sleep_for(10);
240240
_link_status_task_handle = mbed::mbed_event_queue()->call_every(
241241
LINK_STATUS_TASK_PERIOD_MS,
242242
mbed::callback(this,

platform/mbed_wait_api.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,18 +40,18 @@ extern "C" {
4040
* Example:
4141
* @code
4242
* #include "mbed.h"
43-
*
43+
*
4444
* // Blinking rate in milliseconds
4545
* #define BLINKING_RATE_MS 500
4646
* DigitalOut led(LED2);
4747
* InterruptIn button(SW2);
48-
*
48+
*
4949
* void blink_led() {
5050
* led = 1;
5151
* wait_us(BLINKING_RATE_MS * 1000);
5252
* led = 0;
5353
* }
54-
*
54+
*
5555
* int main() {
5656
* button.fall(&blink_led);
5757
* while(1) {

targets/TARGET_ARM_SSG/TARGET_MPS2/SDK/ETH_MPS2.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ unsigned int smsc9220_mac_regread(unsigned char regoffset, unsigned int *data)
5757
timedout = 50;
5858
do {
5959
val = SMSC9220->BYTE_TEST; // A no-op read.
60-
wait_ms(1);
60+
thread_sleep_for(1);
6161
timedout--;
6262
} while(timedout && (SMSC9220->MAC_CSR_CMD & ((unsigned int)1 << 31)));
6363

@@ -91,7 +91,7 @@ unsigned int smsc9220_mac_regwrite(unsigned char regoffset, unsigned int data)
9191
timedout = 50;
9292
do {
9393
read = SMSC9220->BYTE_TEST; // A no-op read.
94-
wait_ms(1);
94+
thread_sleep_for(1);
9595
timedout--;
9696
} while(timedout && (SMSC9220->MAC_CSR_CMD & ((unsigned int)1 << 31)));
9797

@@ -125,7 +125,7 @@ unsigned int smsc9220_phy_regread(unsigned char regoffset, unsigned short *data)
125125
val = 0;
126126
timedout = 50;
127127
do {
128-
wait_ms(1);
128+
thread_sleep_for(1);
129129
timedout--;
130130
smsc9220_mac_regread(SMSC9220_MAC_MII_ACC,&val);
131131
} while(timedout && (val & ((unsigned int)1 << 0)));
@@ -165,7 +165,7 @@ unsigned int smsc9220_phy_regwrite(unsigned char regoffset, unsigned short data)
165165

166166
do {
167167

168-
wait_ms(1);
168+
thread_sleep_for(1);
169169
timedout--;
170170
smsc9220_mac_regread(SMSC9220_MAC_MII_ACC, &phycmd);
171171
} while(timedout && (phycmd & (1 << 0)));
@@ -196,7 +196,7 @@ unsigned int smsc9220_soft_reset(void)
196196
SMSC9220->HW_CFG |= 1;
197197

198198
do {
199-
wait_ms(1);
199+
thread_sleep_for(1);
200200
timedout--;
201201
} while(timedout && (SMSC9220->HW_CFG & 1));
202202

@@ -223,7 +223,7 @@ unsigned int smsc9220_wait_eeprom(void)
223223
timedout = 50;
224224

225225
do {
226-
wait_ms(1);
226+
thread_sleep_for(1);
227227
timedout--;
228228

229229
} while(timedout && (SMSC9220->E2P_CMD & ((unsigned int) 1 << 31)));

targets/TARGET_ARM_SSG/TARGET_MPS2/ethernet_api.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ int ethernet_init()
7575
return error;
7676
}
7777

78-
wait_ms(100);
78+
thread_sleep_for(100);
7979
// Checking whether phy reset completed successfully.
8080
{
8181
unsigned short phyreset;
@@ -110,7 +110,7 @@ int ethernet_init()
110110
SMSC9220->FIFO_INT &= ~(0xFF); // Clear 2 bottom nibbles
111111

112112
// This sleep is compulsory otherwise txmit/receive will fail.
113-
wait_ms(2000);
113+
thread_sleep_for(2000);
114114
return error;
115115

116116
}

targets/TARGET_NXP/USBHAL_LPC17.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ void USBPhyHw::init(USBPhyEvents *events)
411411
LPC_PINCON->PINSEL4 |= 0x00040000;
412412

413413
// Connect must be low for at least 2.5uS
414-
wait(0.3);
414+
thread_sleep_for(300);
415415

416416
// Disable control endpoints
417417
SIEsetEndpointStatus(EP0IN, SIE_SES_DA);

targets/TARGET_RENESAS/TARGET_RZ_A1XX/TARGET_GR_LYCHEE/trng_api_esp32.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ extern "C" void trng_init_esp32(void)
4747
GPIOPM3 &= ~0x4000; /* Output mode */
4848

4949
GPIOP3 |= 0x4000; /* Outputs hi level */
50-
wait_ms(5);
50+
thread_sleep_for(5);
5151
GPIOP5 |= 0x0008; /* Outputs hi level */
5252
}
5353
}
@@ -84,7 +84,7 @@ extern "C" int trng_get_bytes_esp32(uint8_t *output, size_t length, size_t *outp
8484
}
8585
if (ret != 0) {
8686
retry_cnt++;
87-
wait_ms(100);
87+
thread_sleep_for(100);
8888
}
8989
}
9090
if (retry_cnt >= RETRY_CNT_MAX) {

targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F413xH/TARGET_MTS_DRAGONFLY_F413RH/ONBOARD_TELIT_HE910.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ nsapi_error_t ONBOARD_TELIT_HE910::soft_power_on()
4949
/* keep the power line low for 200 milisecond */
5050
press_power_button(200);
5151
/* give modem a little time to respond */
52-
wait_ms(100);
52+
thread_sleep_for(100);
5353
// From Telit_xE910 Global form factor App note: It is mandatory to avoid sending data to the serial ports during the first 200ms of the module start-up.
5454
rtos::ThisThread::sleep_for(200);
5555
return NSAPI_ERROR_OK;
@@ -64,7 +64,7 @@ nsapi_error_t ONBOARD_TELIT_HE910::soft_power_off()
6464
* If 3G_ON_OFF pin is kept low for more than a second, a controlled disconnect and shutdown takes
6565
* place, Due to the network disconnect, shut-off can take up to 30 seconds. However, we wait for 10
6666
* seconds only */
67-
wait_ms(10 * 1000);
67+
thread_sleep_for(10 * 1000);
6868
return NSAPI_ERROR_OK;
6969
}
7070

@@ -74,7 +74,7 @@ void ONBOARD_TELIT_HE910::press_power_button(int time_ms)
7474

7575
gpio_init_out_ex(&gpio, MDMPWRON, 1);
7676
gpio_write(&gpio, 0);
77-
wait_ms(time_ms);
77+
thread_sleep_for(time_ms);
7878
gpio_write(&gpio, 1);
7979
}
8080

0 commit comments

Comments
 (0)