Skip to content

Commit e766a4a

Browse files
committed
esp8266/etshal.h: Make function prototypes compatible with ESP SDK 2.1.0+.
In the vendor SDK 2.1.0, some of the functions which previously didn't have prototypes, finally acquired them. Change prototypes on our side to match those in vendor headers, to avoid warnings-as-errors.
1 parent ad5a6f5 commit e766a4a

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

ports/esp8266/etshal.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,14 @@
66
// see http://esp8266-re.foogod.com/wiki/Random_Number_Generator
77
#define WDEV_HWRNG ((volatile uint32_t*)0x3ff20e44)
88

9-
void ets_delay_us();
9+
void ets_delay_us(uint16_t us);
1010
void ets_intr_lock(void);
1111
void ets_intr_unlock(void);
1212
void ets_isr_mask(uint32_t mask);
1313
void ets_isr_unmask(uint32_t mask);
1414
void ets_isr_attach(int irq_no, void (*handler)(void *), void *arg);
1515
void ets_install_putc1();
16-
void uart_div_modify();
16+
void uart_div_modify(uint8_t uart, uint32_t divisor);
1717
void ets_set_idle_cb(void (*handler)(void *), void *arg);
1818

1919
void ets_timer_arm_new(os_timer_t *tim, uint32_t millis, bool repeat, bool is_milli_timer);
@@ -33,10 +33,10 @@ void MD5Update(MD5_CTX *context, const void *data, unsigned int len);
3333
void MD5Final(unsigned char digest[16], MD5_CTX *context);
3434

3535
// These prototypes are for recent SDKs with "malloc tracking"
36-
void *pvPortMalloc(unsigned sz, const char *fname, int line);
37-
void *pvPortZalloc(unsigned sz, const char *fname, int line);
38-
void *pvPortRealloc(void *p, unsigned sz, const char *fname, int line);
39-
void vPortFree(void *p, const char *fname, int line);
36+
void *pvPortMalloc(size_t sz, const char *fname, unsigned line);
37+
void *pvPortZalloc(size_t sz, const char *fname, unsigned line);
38+
void *pvPortRealloc(void *p, unsigned sz, const char *fname, unsigned line);
39+
void vPortFree(void *p, const char *fname, unsigned line);
4040

4141
uint32_t SPIRead(uint32_t offset, void *buf, uint32_t len);
4242
uint32_t SPIWrite(uint32_t offset, const void *buf, uint32_t len);

0 commit comments

Comments
 (0)