NVIDIA DOCA SDK Data Center on a Chip Framework Documentation
http_txbuf.c File Reference
#include <arpa/inet.h>
#include <rte_ethdev.h>
#include <doca_flow.h>
#include <doca_mmap.h>
#include <doca_gpunetio.h>
#include <doca_buf_array.h>
#include "common.h"
#include "packets.h"
#include "dpdk_tcp/tcp_session_table.h"
Include dependency graph for http_txbuf.c:

Go to the source code of this file.

Functions

 DOCA_LOG_REGISTER (GPU_PACKET_PROCESSING_TXBUF)
 
doca_error_t create_tx_buf (struct tx_buf *buf, struct doca_gpu *gpu_dev, struct doca_dev *ddev, uint32_t num_packets, uint32_t max_pkt_sz)
 
doca_error_t prepare_tx_buf (struct tx_buf *buf, enum http_page_get page_type)
 
doca_error_t destroy_tx_buf (struct tx_buf *buf)
 

Variables

const char * payload_page_index
 
const char * payload_page_contacts
 
const char * payload_page_not_found
 

Function Documentation

◆ create_tx_buf()

doca_error_t create_tx_buf ( struct tx_buf buf,
struct doca_gpu *  gpu_dev,
struct doca_dev *  ddev,
uint32_t  num_packets,
uint32_t  max_pkt_sz 
)

Definition at line 97 of file http_txbuf.c.

◆ destroy_tx_buf()

doca_error_t destroy_tx_buf ( struct tx_buf buf)

Definition at line 287 of file http_txbuf.c.

◆ DOCA_LOG_REGISTER()

DOCA_LOG_REGISTER ( GPU_PACKET_PROCESSING_TXBUF  )

◆ prepare_tx_buf()

doca_error_t prepare_tx_buf ( struct tx_buf buf,
enum http_page_get  page_type 
)

Definition at line 217 of file http_txbuf.c.

Variable Documentation

◆ payload_page_contacts

const char* payload_page_contacts
Initial value:
= "HTTP/1.1 200 OK\r\n"
"Date: Sun, 30 Apr 2023 20:30:40 GMT\r\n"
"Content-Type: text/html; charset=UTF-8\r\n"
"Content-Length: 175\r\n"
"Last-Modified: Sun, 30 Apr 2023 22:38:34 GMT\r\n"
"Server: GPUNetIO\r\n"
"Accept-Ranges: bytes\r\n"
"Connection: keep-alive\r\n"
"Keep-Alive: timeout=5\r\n"
"\r\n"
"<html>\r\n"
" <head>\r\n"
" <title>GPUNetIO Contact page</title>\r\n"
" </head>\r\n"
" <body>\r\n"
" <p>For any GPUNetIO question please contact support@nvidia.com</p>\r\n"
" </body>\r\n"
"</html>\r\n"
"\r\n"

Definition at line 59 of file http_txbuf.c.

◆ payload_page_index

const char* payload_page_index
Initial value:
= "HTTP/1.1 200 OK\r\n"
"Date: Sun, 30 Apr 2023 20:30:40 GMT\r\n"
"Content-Type: text/html; charset=UTF-8\r\n"
"Content-Length: 158\r\n"
"Last-Modified: Sun, 30 Apr 2023 22:38:34 GMT\r\n"
"Server: GPUNetIO\r\n"
"Accept-Ranges: bytes\r\n"
"Connection: keep-alive\r\n"
"Keep-Alive: timeout=5\r\n"
"\r\n"
"<html>\r\n"
" <head>\r\n"
" <title>GPUNetIO index page</title>\r\n"
" </head>\r\n"
" <body>\r\n"
" <p>Hello World, the GPUNetIO server Index page!</p>\r\n"
" </body>\r\n"
"</html>\r\n"
"\r\n"

Definition at line 39 of file http_txbuf.c.

◆ payload_page_not_found

const char* payload_page_not_found
Initial value:
= "HTTP/1.1 404 Not Found\r\n"
"Date: Sun, 30 Apr 2023 20:30:40 GMT\r\n"
"Content-Type: text/html; charset=UTF-8\r\n"
"Content-Length: 152\r\n"
"Last-Modified: Sun, 30 Apr 2023 22:38:34 GMT\r\n"
"Server: GPUNetIO\r\n"
"Connection: close\r\n"
"\r\n"
"<html>\r\n"
" <head>\r\n"
" <title>GPUNetIO 404 page</title>\r\n"
" </head>\r\n"
" <body>\r\n"
" <p>Hello! Page you requested doesn't exist!</p>\r\n"
" </body>\r\n"
"</html>\r\n"
"\r\n"

Definition at line 79 of file http_txbuf.c.