fix(fg_spi): slave rx packet size (including header) to be checked against max transp...
authorYogesh Mantri <yogesh.mantri@espressif.com>
Fri, 26 Apr 2024 07:55:08 +0000 (15:55 +0800)
committerYogesh Mantri <yogesh.mantri@espressif.com>
Fri, 26 Apr 2024 07:55:08 +0000 (15:55 +0800)
fix(ng): remove inlining for raw throughput

esp_hosted_fg/esp/esp_driver/network_adapter/main/spi_slave_api.c
esp_hosted_ng/host/esp_stats.c
esp_hosted_ng/host/include/esp_stats.h

index fc03cec69fbdd1ebcd87d9db358276f8dc795308..745a675f4a92c020810cdad89a8ff88b9d83e7f1 100644 (file)
@@ -432,9 +432,8 @@ static int process_spi_rx(interface_buffer_handle_t *buf_handle)
        if (!len)
                return -1;
 
-       if (len > SPI_BUFFER_SIZE) {
-               ESP_LOGE(TAG, "rx_pkt len[%u]>max[%u], dropping it", len, SPI_BUFFER_SIZE);
-
+       if (len+offset > SPI_BUFFER_SIZE) {
+               ESP_LOGE(TAG, "rx_pkt len+offset[%u]>max[%u], dropping it", len+offset, SPI_BUFFER_SIZE);
                return -1;
        }
 
index 231a913ff0ed751aa10970522e61c5679e9b259b..5817da00966259eb15ac7699d56788c4f94e658f 100644 (file)
@@ -135,7 +135,7 @@ static void stop_test_raw_tp(void)
        test_raw_tp__host_to_esp = 0;
 }
 
-inline void esp_raw_tp_queue_resume(void)
+void esp_raw_tp_queue_resume(void)
 {
        if (traffic_open_init_done)
                if (!completion_done(&traffic_open))
index a508d2c6c7de2ee7f62f5dce814f63b5449651ed..55a1222660b04b573bbe092a0d90236ef7aae371 100644 (file)
@@ -19,7 +19,7 @@
 #define ESP_TEST_RAW_TP__RX      0
 #define ESP_TEST_RAW_TP__TX      1
 
-inline void esp_raw_tp_queue_resume(void);
+void esp_raw_tp_queue_resume(void);
 #endif
 
 void test_raw_tp_cleanup(void);
This page took 0.032094 seconds and 4 git commands to generate.