mirror of
https://github.com/espressif/esp-idf.git
synced 2025-12-07 17:08:49 +00:00
lwip: Use custom pbufs for eth and wifi port/netif
This commit is contained in:
32
components/lwip/port/esp32/include/netif/esp_pbuf_ref.h
Normal file
32
components/lwip/port/esp32/include/netif/esp_pbuf_ref.h
Normal file
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
/**
|
||||
* @file esp_pbuf reference interface file
|
||||
*/
|
||||
|
||||
#ifndef __LWIP_ESP_PBUF_REF_H__
|
||||
#define __LWIP_ESP_PBUF_REF_H__
|
||||
|
||||
#include <stddef.h>
|
||||
#include "lwip/pbuf.h"
|
||||
#include "esp_netif.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief Allocate custom pbuf containing pointer to a private l2-free function
|
||||
*
|
||||
* @note pbuf_free() will deallocate this custom pbuf and call the driver assigned free function
|
||||
*/
|
||||
struct pbuf* esp_pbuf_allocate(esp_netif_t *esp_netif, void *buffer, size_t len, void *l2_buff);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif //__LWIP_ESP_PBUF_REF_H__
|
||||
Reference in New Issue
Block a user