Commit d5a96b2c authored by aikaterini.trilyraki's avatar aikaterini.trilyraki

comment address restore

parent 6975efd6
...@@ -328,8 +328,6 @@ int eth_set_dev_conf_udp(openair0_device *device) { ...@@ -328,8 +328,6 @@ int eth_set_dev_conf_udp(openair0_device *device) {
exit(0); exit(0);
} }
/* printf("[RRHbbb] mod_%d socket %d connected to BBU %s:%d\n", Mod_id, eth->sockfd[Mod_id], inet_ntoa(dest_addr[Mod_id].sin_addr), */
/* ntohs(dest_addr[Mod_id].sin_port)); */
return 0; return 0;
} }
...@@ -347,10 +345,6 @@ int eth_get_dev_conf_udp(openair0_device *device) { ...@@ -347,10 +345,6 @@ int eth_get_dev_conf_udp(openair0_device *device) {
inet_ntop(AF_INET, &(local_addr[Mod_id].sin_addr), str, INET_ADDRSTRLEN); inet_ntop(AF_INET, &(local_addr[Mod_id].sin_addr), str, INET_ADDRSTRLEN);
inet_ntop(AF_INET, &(dest_addr[Mod_id].sin_addr), str1, INET_ADDRSTRLEN); inet_ntop(AF_INET, &(dest_addr[Mod_id].sin_addr), str1, INET_ADDRSTRLEN);
/* printf("[RRH] mod_%d socket %d connected to BBU %s:%d %s:%d\n", Mod_id, eth->sockfd[Mod_id], str1, */
/* ntohs(dest_addr[Mod_id].sin_port),str, */
/* ntohs(local_addr[Mod_id].sin_port)); */
/* RRH receives from BBU openair0_config_t */ /* RRH receives from BBU openair0_config_t */
if (recvfrom(eth->sockfd[Mod_id], if (recvfrom(eth->sockfd[Mod_id],
msg, msg,
...@@ -361,19 +355,18 @@ int eth_get_dev_conf_udp(openair0_device *device) { ...@@ -361,19 +355,18 @@ int eth_get_dev_conf_udp(openair0_device *device) {
perror("ETHERNET: "); perror("ETHERNET: ");
exit(0); exit(0);
} }
memcpy((void*)&device->openair0_cfg,msg,msg_len); memcpy((void*)&device->openair0_cfg,msg,msg_len);
/* get remote ip address and port */ /* get remote ip address and port */
inet_ntop(AF_INET, &(dest_addr[Mod_id].sin_addr), str1, INET_ADDRSTRLEN); /* inet_ntop(AF_INET, &(dest_addr[Mod_id].sin_addr), str1, INET_ADDRSTRLEN); */
device->openair0_cfg.remote_port =ntohs(dest_addr[Mod_id].sin_port); /* device->openair0_cfg.remote_port =ntohs(dest_addr[Mod_id].sin_port); */
device->openair0_cfg.remote_addr =str1; /* device->openair0_cfg.remote_addr =str1; */
/* restore local ip address and port */ /* /\* restore local ip address and port *\/ */
inet_ntop(AF_INET, &(local_addr[Mod_id].sin_addr), str, INET_ADDRSTRLEN); /* inet_ntop(AF_INET, &(local_addr[Mod_id].sin_addr), str, INET_ADDRSTRLEN); */
device->openair0_cfg.my_port =ntohs(local_addr[Mod_id].sin_port); /* device->openair0_cfg.my_port =ntohs(local_addr[Mod_id].sin_port); */
device->openair0_cfg.my_addr =str; /* device->openair0_cfg.my_addr =str; */
/* printf("[RRH2] mod_%d socket %d connected to BBU %s:%d %s:%d\n", Mod_id, eth->sockfd[Mod_id],str1, device->openair0_cfg.remote_port, str, device->openair0_cfg.my_port); */ /* printf("[RRH] mod_%d socket %d connected to BBU %s:%d %s:%d\n", Mod_id, eth->sockfd[Mod_id],str1, device->openair0_cfg.remote_port, str, device->openair0_cfg.my_port); */
return 0; return 0;
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment