mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-23 06:50:02 +02:00
udp destination entries configured properly
This commit is contained in:
parent
0c6911e469
commit
2afe7112b2
Binary file not shown.
@ -137,8 +137,10 @@ void basictests() {
|
||||
|
||||
// update default udpdstip and udpdstmac (1g is hardware ip and hardware
|
||||
// mac)
|
||||
udpDetails[0].srcip = ipadd;
|
||||
udpDetails[0].srcmac = macadd;
|
||||
for (int iRxEntry = 0; iRxEntry != numUdpDestinations; ++iRxEntry) {
|
||||
udpDetails[iRxEntry].srcip = ipadd;
|
||||
udpDetails[iRxEntry].srcmac = macadd;
|
||||
}
|
||||
|
||||
#ifdef VIRTUAL
|
||||
return;
|
||||
@ -1524,13 +1526,13 @@ int configureMAC() {
|
||||
LOG(logINFOBLUE, ("Configuring MAC\n"));
|
||||
|
||||
for (int iRxEntry = 0; iRxEntry != numUdpDestinations; ++iRxEntry) {
|
||||
uint32_t srcip = udpDetails[0].srcip;
|
||||
uint32_t dstip = udpDetails[0].dstip;
|
||||
uint64_t srcmac = udpDetails[0].srcmac;
|
||||
uint64_t dstmac = udpDetails[0].dstmac;
|
||||
int srcport = udpDetails[0].srcport;
|
||||
int dstport = udpDetails[0].dstport;
|
||||
int dstport2 = udpDetails[0].dstport2;
|
||||
uint32_t srcip = udpDetails[iRxEntry].srcip;
|
||||
uint32_t dstip = udpDetails[iRxEntry].dstip;
|
||||
uint64_t srcmac = udpDetails[iRxEntry].srcmac;
|
||||
uint64_t dstmac = udpDetails[iRxEntry].dstmac;
|
||||
int srcport = udpDetails[iRxEntry].srcport;
|
||||
int dstport = udpDetails[iRxEntry].dstport;
|
||||
int dstport2 = udpDetails[iRxEntry].dstport2;
|
||||
|
||||
char src_mac[50], src_ip[INET_ADDRSTRLEN], dst_mac[50],
|
||||
dst_ip[INET_ADDRSTRLEN];
|
||||
@ -1539,6 +1541,7 @@ int configureMAC() {
|
||||
getIpAddressinString(src_ip, srcip);
|
||||
getIpAddressinString(dst_ip, dstip);
|
||||
|
||||
LOG(logINFOBLUE, ("\tEntry %d\n", iRxEntry));
|
||||
LOG(logINFO,
|
||||
("\tSource IP : %s\n"
|
||||
"\tSource MAC : %s\n"
|
||||
|
Binary file not shown.
@ -1353,7 +1353,7 @@ int getPrimaryInterface() {
|
||||
void setupHeader(int iRxEntry, enum interfaceType type, uint32_t destip,
|
||||
uint64_t destmac, uint32_t destport, uint64_t sourcemac,
|
||||
uint32_t sourceip, uint32_t sourceport) {
|
||||
|
||||
|
||||
// start addr
|
||||
uint32_t addr = (type == INNER ? RXR_ENDPOINT_INNER_START_REG
|
||||
: RXR_ENDPOINT_OUTER_START_REG);
|
||||
@ -1436,18 +1436,18 @@ int configureMAC() {
|
||||
(selInterface ? "Inner" : "Outer")));
|
||||
|
||||
for (int iRxEntry = 0; iRxEntry != numUdpDestinations; ++iRxEntry) {
|
||||
uint32_t srcip = udpDetails[0].srcip;
|
||||
uint32_t srcip2 = udpDetails[0].srcip2;
|
||||
uint32_t dstip = udpDetails[0].dstip;
|
||||
uint32_t dstip2 = udpDetails[0].dstip2;
|
||||
uint64_t srcmac = udpDetails[0].srcmac;
|
||||
uint64_t srcmac2 = udpDetails[0].srcmac2;
|
||||
uint64_t dstmac = udpDetails[0].dstmac;
|
||||
uint64_t dstmac2 = udpDetails[0].dstmac2;
|
||||
int srcport = udpDetails[0].srcport;
|
||||
int srcport2 = udpDetails[0].srcport2;
|
||||
int dstport = udpDetails[0].dstport;
|
||||
int dstport2 = udpDetails[0].dstport2;
|
||||
uint32_t srcip = udpDetails[iRxEntry].srcip;
|
||||
uint32_t srcip2 = udpDetails[iRxEntry].srcip2;
|
||||
uint32_t dstip = udpDetails[iRxEntry].dstip;
|
||||
uint32_t dstip2 = udpDetails[iRxEntry].dstip2;
|
||||
uint64_t srcmac = udpDetails[iRxEntry].srcmac;
|
||||
uint64_t srcmac2 = udpDetails[iRxEntry].srcmac2;
|
||||
uint64_t dstmac = udpDetails[iRxEntry].dstmac;
|
||||
uint64_t dstmac2 = udpDetails[iRxEntry].dstmac2;
|
||||
int srcport = udpDetails[iRxEntry].srcport;
|
||||
int srcport2 = udpDetails[iRxEntry].srcport2;
|
||||
int dstport = udpDetails[iRxEntry].dstport;
|
||||
int dstport2 = udpDetails[iRxEntry].dstport2;
|
||||
|
||||
char src_mac[50], src_ip[INET_ADDRSTRLEN], dst_mac[50],
|
||||
dst_ip[INET_ADDRSTRLEN];
|
||||
@ -1461,6 +1461,7 @@ int configureMAC() {
|
||||
getMacAddressinString(dst_mac2, 50, dstmac2);
|
||||
getIpAddressinString(src_ip2, srcip2);
|
||||
getIpAddressinString(dst_ip2, dstip2);
|
||||
LOG(logINFOBLUE, ("\tEntry %d\n", iRxEntry));
|
||||
|
||||
LOG(logINFO, ("\tOuter %s\n", (numInterfaces == 2)
|
||||
? "(Bottom)"
|
||||
|
Loading…
x
Reference in New Issue
Block a user