cfg80211.h (d875aa1587ce7d1651cabe395ed991f2384795cd) cfg80211.h (4a07abdeb8ce5271996d85f648832e3d7bc741a7)
1/*-
2 * Copyright (c) 2020-2021 The FreeBSD Foundation
3 * Copyright (c) 2021-2022 Bjoern A. Zeeb
4 *
5 * This software was developed by Björn Zeeb under sponsorship from
6 * the FreeBSD Foundation.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 1152 unchanged lines hidden (view full) ---

1161static __inline void
1162cfg80211_chandef_create(struct cfg80211_chan_def *chandef,
1163 struct linuxkpi_ieee80211_channel *chan, enum nl80211_chan_flags chan_flag)
1164{
1165
1166 KASSERT(chandef != NULL, ("%s: chandef is NULL\n", __func__));
1167 KASSERT(chan != NULL, ("%s: chan is NULL\n", __func__));
1168
1/*-
2 * Copyright (c) 2020-2021 The FreeBSD Foundation
3 * Copyright (c) 2021-2022 Bjoern A. Zeeb
4 *
5 * This software was developed by Björn Zeeb under sponsorship from
6 * the FreeBSD Foundation.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 1152 unchanged lines hidden (view full) ---

1161static __inline void
1162cfg80211_chandef_create(struct cfg80211_chan_def *chandef,
1163 struct linuxkpi_ieee80211_channel *chan, enum nl80211_chan_flags chan_flag)
1164{
1165
1166 KASSERT(chandef != NULL, ("%s: chandef is NULL\n", __func__));
1167 KASSERT(chan != NULL, ("%s: chan is NULL\n", __func__));
1168
1169 memset(chandef, 0, sizeof(*chandef));
1169 chandef->chan = chan;
1170 chandef->center_freq2 = 0; /* Set here and only overwrite if needed. */
1170 chandef->chan = chan;
1171 chandef->center_freq2 = 0; /* Set here and only overwrite if needed. */
1171 chandef->chan = chan;
1172
1173 switch (chan_flag) {
1174 case NL80211_CHAN_NO_HT:
1175 chandef->width = NL80211_CHAN_WIDTH_20_NOHT;
1176 chandef->center_freq1 = chan->center_freq;
1177 break;
1178 default:
1179 printf("%s: unsupported chan_flag %#0x\n", __func__, chan_flag);

--- 451 unchanged lines hidden ---
1172
1173 switch (chan_flag) {
1174 case NL80211_CHAN_NO_HT:
1175 chandef->width = NL80211_CHAN_WIDTH_20_NOHT;
1176 chandef->center_freq1 = chan->center_freq;
1177 break;
1178 default:
1179 printf("%s: unsupported chan_flag %#0x\n", __func__, chan_flag);

--- 451 unchanged lines hidden ---