Commit 285ab7d8 authored by Luis R. Rodriguez's avatar Luis R. Rodriguez

crda: rename min() to reglib_min()

Signed-off-by: 's avatarLuis R. Rodriguez <mcgrof@do-not-panic.com>
parent 2cb7e59c
......@@ -440,18 +440,18 @@ static int reg_rules_intersect(const struct ieee80211_reg_rule *rule1,
freq_range->start_freq_khz = reglib_max(freq_range1->start_freq_khz,
freq_range2->start_freq_khz);
freq_range->end_freq_khz = min(freq_range1->end_freq_khz,
freq_range->end_freq_khz = reglib_min(freq_range1->end_freq_khz,
freq_range2->end_freq_khz);
freq_range->max_bandwidth_khz = min(freq_range1->max_bandwidth_khz,
freq_range->max_bandwidth_khz = reglib_min(freq_range1->max_bandwidth_khz,
freq_range2->max_bandwidth_khz);
freq_diff = freq_range->end_freq_khz - freq_range->start_freq_khz;
if (freq_range->max_bandwidth_khz > freq_diff)
freq_range->max_bandwidth_khz = freq_diff;
power_rule->max_eirp = min(power_rule1->max_eirp,
power_rule->max_eirp = reglib_min(power_rule1->max_eirp,
power_rule2->max_eirp);
power_rule->max_antenna_gain = min(power_rule1->max_antenna_gain,
power_rule->max_antenna_gain = reglib_min(power_rule1->max_antenna_gain,
power_rule2->max_antenna_gain);
intersected_rule->flags = rule1->flags | rule2->flags;
......
......@@ -65,7 +65,7 @@ static inline uint32_t reglib_max(uint32_t a, uint32_t b)
return (a > b) ? a : b;
}
static inline uint32_t min(uint32_t a, uint32_t b)
static inline uint32_t reglib_min(uint32_t a, uint32_t b)
{
return (a > b) ? b : a;
}
......
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