1 /****************************************************************************** 2 * 3 * Copyright(c) 2020 Realtek Corporation. 4 * 5 * This program is free software; you can redistribute it and/or modify it 6 * under the terms of version 2 of the GNU General Public License as 7 * published by the Free Software Foundation. 8 * 9 * This program is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 12 * more details. 13 * 14 *****************************************************************************/ 15 #ifndef _PHL_SCAN_INSTANCE_H_ 16 #define _PHL_SCAN_INSTANCE_H_ 17 18 #define MAX_SCAN_INSTANCE 160 19 20 enum order_strategy { 21 ORDER_5GHZ_PRIOR = BIT(0), 22 ORDER_ACTIVE_PRIOR = BIT(1) 23 }; 24 25 enum skip_strategy { 26 SKIP_2GHZ = BIT(0), 27 SKIP_5GHZ = BIT(1), 28 SKIP_PASSIVE = BIT(2), 29 SKIP_DFS = BIT(3), 30 SKIP_6GHZ = BIT(4), 31 }; 32 33 enum period_strategy { 34 PERIOD_ALL_MAX = BIT(0), 35 PERIOD_ALL_MIN = BIT(1), 36 PERIOD_MIN_DFS = BIT(2) 37 }; 38 39 struct instance_strategy { 40 u8 order; 41 u8 skip; 42 u8 period; 43 }; 44 45 struct instance_channel { 46 enum band_type band; 47 u8 channel; 48 u8 property; 49 u8 active; 50 u8 period; 51 u8 mode; 52 u8 bw; 53 u8 offset; 54 }; 55 56 struct instance { 57 u32 cnt; /* channel cnt */ 58 struct instance_channel ch[MAX_SCAN_INSTANCE]; 59 }; 60 61 62 #endif /* _PHL_SCAN_INSTANCE_H_ */ 63