@@ -88,9 +88,8 @@ struct vwifi_vif {
8888 struct wireless_dev wdev ;
8989 struct net_device * ndev ;
9090 struct net_device_stats stats ;
91- int manual_mcs ; /* ADDED: Store user-specified MCS */
92- bool manual_mcs_set ; /* ADDED: Flag to indicate manual MCS override */
93-
91+ int manual_mcs ;
92+ bool manual_mcs_set ;
9493 size_t ssid_len ;
9594 /* Currently connected BSS id */
9695 u8 bssid [ETH_ALEN ];
@@ -1406,7 +1405,7 @@ static int vwifi_get_station(struct wiphy *wiphy,
14061405 sinfo -> rx_bytes = vif -> stats .rx_bytes ;
14071406
14081407
1409- /* Log byte counters for debugging */ /* CHANGED */
1408+ /* Log byte counters for debugging */
14101409 pr_info (
14111410 "vwifi: Station %pM tx_bytes %llu, rx_bytes %llu, tx_packets %u, "
14121411 "rx_packets %u, tx_failed %u\n" ,
@@ -1416,7 +1415,7 @@ static int vwifi_get_station(struct wiphy *wiphy,
14161415 /* For CFG80211_SIGNAL_TYPE_MBM, value is expressed in dBm */
14171416 sinfo -> signal = rand_int_smooth (-100 , -30 , jiffies );
14181417 pr_info ("vwifi: Station %pM signal %d dBm (raw)\n" , mac ,
1419- sinfo -> signal ); /* ADDED */
1418+ sinfo -> signal );
14201419 sinfo -> inactive_time = jiffies_to_msecs (jiffies - vif -> active_time );
14211420 /*
14221421 * Using 802.11n (HT) as the PHY, configure as follows:
@@ -1743,9 +1742,14 @@ static int vwifi_start_ap(struct wiphy *wiphy,
17431742
17441743 /* Initialize hrtimer of beacon */
17451744 pr_info ("vwifi: init beacon_timer.\n" );
1745+ #if LINUX_VERSION_CODE >= KERNEL_VERSION (6 , 15 , 0 )
1746+ hrtimer_setup (& vif -> beacon_timer , vwifi_beacon , CLOCK_MONOTONIC ,
1747+ HRTIMER_MODE_ABS_SOFT );
1748+ #else
17461749 hrtimer_init (& vif -> beacon_timer , CLOCK_MONOTONIC , HRTIMER_MODE_ABS_SOFT );
17471750 vif -> beacon_timer .function = vwifi_beacon ;
1748-
1751+ #endif
1752+
17491753 if (!hrtimer_is_queued (& vif -> beacon_timer )) {
17501754 u64 tsf , until_tbtt ;
17511755 tsf = ktime_to_us (ktime_get_real ());
0 commit comments