A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
Loading...
Searching...
No Matches
dpdk-net-device-helper.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2020 NITK Surathkal
3
*
4
* SPDX-License-Identifier: GPL-2.0-only
5
*
6
* Authors: Harsh Patel <thadodaharsh10@gmail.com>
7
* Hrishikesh Hiraskar <hrishihiraskar@gmail.com>
8
*/
9
10
#ifndef DPDK_NET_DEVICE_HELPER_H
11
#define DPDK_NET_DEVICE_HELPER_H
12
13
#include "
emu-fd-net-device-helper.h
"
14
15
namespace
ns3
16
{
17
18
/**
19
* \ingroup fd-net-device
20
* \brief build a DpdkNetDevice object attached to a physical network
21
* interface
22
*/
23
class
DpdkNetDeviceHelper
:
public
EmuFdNetDeviceHelper
24
{
25
public
:
26
/**
27
* Construct a DpdkNetDeviceHelper and initialize DPDK EAL
28
*/
29
DpdkNetDeviceHelper
();
30
31
~DpdkNetDeviceHelper
()
override
32
{
33
}
34
35
/**
36
* \brief Sets list of logical cores to use
37
*
38
* \param lCoreList Comma separated logical core list (e.g., "0,1")
39
*/
40
void
SetLCoreList
(std::string lCoreList);
41
42
/**
43
* \brief Sets PMD Library to be used for the NIC
44
*
45
* \param pmdLibrary The PMD Library
46
*/
47
void
SetPmdLibrary
(std::string pmdLibrary);
48
49
/**
50
* \brief Sets DPDK Driver to bind NIC to
51
*
52
* \param dpdkDriver The DPDK Driver
53
*/
54
void
SetDpdkDriver
(std::string dpdkDriver);
55
56
protected
:
57
/**
58
* \brief This method creates an ns3::FdNetDevice attached to a physical network
59
* interface
60
*
61
* \param node The node to install the device in
62
* \returns A container holding the added net device.
63
*/
64
Ptr<NetDevice>
InstallPriv
(
Ptr<Node>
node)
const override
;
65
66
/**
67
* Logical cores to use
68
*/
69
std::string
m_lCoreList
;
70
71
/**
72
* PMD Library to be used for NIC
73
*/
74
std::string
m_pmdLibrary
;
75
76
/**
77
* DPDK Driver to bind NIC to
78
*/
79
std::string
m_dpdkDriver
;
80
};
81
82
}
// namespace ns3
83
84
#endif
/* DPDK_NET_DEVICE_HELPER_H */
ns3::DpdkNetDeviceHelper
build a DpdkNetDevice object attached to a physical network interface
Definition
dpdk-net-device-helper.h:24
ns3::DpdkNetDeviceHelper::SetPmdLibrary
void SetPmdLibrary(std::string pmdLibrary)
Sets PMD Library to be used for the NIC.
Definition
dpdk-net-device-helper.cc:35
ns3::DpdkNetDeviceHelper::~DpdkNetDeviceHelper
~DpdkNetDeviceHelper() override
Definition
dpdk-net-device-helper.h:31
ns3::DpdkNetDeviceHelper::m_lCoreList
std::string m_lCoreList
Logical cores to use.
Definition
dpdk-net-device-helper.h:69
ns3::DpdkNetDeviceHelper::SetDpdkDriver
void SetDpdkDriver(std::string dpdkDriver)
Sets DPDK Driver to bind NIC to.
Definition
dpdk-net-device-helper.cc:41
ns3::DpdkNetDeviceHelper::m_dpdkDriver
std::string m_dpdkDriver
DPDK Driver to bind NIC to.
Definition
dpdk-net-device-helper.h:79
ns3::DpdkNetDeviceHelper::m_pmdLibrary
std::string m_pmdLibrary
PMD Library to be used for NIC.
Definition
dpdk-net-device-helper.h:74
ns3::DpdkNetDeviceHelper::SetLCoreList
void SetLCoreList(std::string lCoreList)
Sets list of logical cores to use.
Definition
dpdk-net-device-helper.cc:29
ns3::DpdkNetDeviceHelper::InstallPriv
Ptr< NetDevice > InstallPriv(Ptr< Node > node) const override
This method creates an ns3::FdNetDevice attached to a physical network interface.
Definition
dpdk-net-device-helper.cc:47
ns3::DpdkNetDeviceHelper::DpdkNetDeviceHelper
DpdkNetDeviceHelper()
Construct a DpdkNetDeviceHelper and initialize DPDK EAL.
Definition
dpdk-net-device-helper.cc:19
ns3::EmuFdNetDeviceHelper
build a set of FdNetDevice objects attached to a physical network interface
Definition
emu-fd-net-device-helper.h:31
ns3::Ptr
Smart pointer class similar to boost::intrusive_ptr.
Definition
mpi-test-fixtures.h:37
emu-fd-net-device-helper.h
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
src
fd-net-device
helper
dpdk-net-device-helper.h
Generated on Fri Nov 8 2024 13:59:00 for ns-3 by
1.11.0