Skip to content

Commit

Permalink
lib: added ifdef to compile on freeBSD
Browse files Browse the repository at this point in the history
  • Loading branch information
aleksinx committed Dec 17, 2020
1 parent 8b7eb7b commit 9cf0261
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/cap.c
Original file line number Diff line number Diff line change
Expand Up @@ -999,6 +999,7 @@ _pqos_cap_mba_change(const enum pqos_mba_config cfg)
if (mba_cap == NULL)
return;

#ifdef __linux__
/* refresh number of classes */
if (m_interface == PQOS_INTER_OS ||
m_interface == PQOS_INTER_OS_RESCTRL_MON) {
Expand All @@ -1009,6 +1010,7 @@ _pqos_cap_mba_change(const enum pqos_mba_config cfg)
if (ret == PQOS_RETVAL_OK)
mba_cap->num_classes = num_classes;
}
#endif

if (cfg == PQOS_MBA_DEFAULT)
mba_cap->ctrl_on = 0;
Expand Down

0 comments on commit 9cf0261

Please sign in to comment.