Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp2180702rwl; Sun, 26 Mar 2023 17:47:55 -0700 (PDT) X-Google-Smtp-Source: AK7set+tl91HVqsAUpcJSEDoJu1GCN815BTv9RIwuIYO1nrmtm0FPRv2huTQ1jN3y/b0IPUhni+K X-Received: by 2002:a05:6a20:2446:b0:d9:e7e5:71d9 with SMTP id t6-20020a056a20244600b000d9e7e571d9mr12869759pzc.29.1679878075727; Sun, 26 Mar 2023 17:47:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679878075; cv=none; d=google.com; s=arc-20160816; b=P+msFc7wFjAH5BTp5Be/yOmvZtpy838qRAvw6bQhdpfm+ztSUGrFW8UnGSh8YnoMw6 /MWTy1Q3gPKmRLXZBtyZoEY3kcRik55MGpQpo0KjSErITOe+os5XABShLXWYxu9bM1Wa kwhIlyDuLQQ01uIwE5dQxxwkNPLx+D7nXZ2BvQ/3dDAHNs6Fi5IdSczT+shaEyaze6FC 5phXcYaf6LMB7oRCnax+hADj1NFWj12+Yl/Ppq/nCanTWDjB5MB5gbg7vvEvjIY6ATtD UK4yfaOgrbl99I5TeWeudqP13ik3FKJ0iqGiNkzshiB3EEGItHIzT8ONQACuA57BqJ/k 7/sw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:authenticated-by; bh=r7qADizZ0HPuXdehFuZyJGQ59cB8U38uDZMVUqIwtYk=; b=lFubUbskOv1WQ5YrO4rnDCdVwZ0hPLN5KbwSqJDaNd/Puv3gzqVkGIWOUIatgB5X59 o0R79eblBLxb0YGtq9WRbDKoZu6+fz2WMmlTkNiP/zoJcV3zgtkmViiH/88jCssPqLiu F4aqyVWaPP1wZmX3qYKZh0iAeFZbLY93RSXiP2csRRUmiTl6fJc1MH5zq8bpzLa+ZSd8 ER/RTjYFL5PdMYq/vEKPXYHSyrglMkq9GEEyxpjvg8bCQkch3mprL6G3TzoCs9ay1PTB CIRyahSkfuGDqHNuRA9BidlwyGIr7pAqZKLgrBAnW+zQeMzm/IocroCd4Z5ThsyV78/r xk4Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g8-20020a056a001a0800b0058d6a27d641si26923129pfv.234.2023.03.26.17.47.48; Sun, 26 Mar 2023 17:47:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229850AbjC0Aqn convert rfc822-to-8bit (ORCPT + 59 others); Sun, 26 Mar 2023 20:46:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59160 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229808AbjC0Aqm (ORCPT ); Sun, 26 Mar 2023 20:46:42 -0400 Received: from rtits2.realtek.com.tw (rtits2.realtek.com [211.75.126.72]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51B7C49FC for ; Sun, 26 Mar 2023 17:46:41 -0700 (PDT) Authenticated-By: X-SpamFilter-By: ArmorX SpamTrap 5.77 with qID 32R0jxWM3016779, This message is accepted by code: ctloc85258 Received: from mail.realtek.com (rtexh36505.realtek.com.tw[172.21.6.25]) by rtits2.realtek.com.tw (8.15.2/2.81/5.90) with ESMTPS id 32R0jxWM3016779 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=OK); Mon, 27 Mar 2023 08:45:59 +0800 Received: from RTEXMBS06.realtek.com.tw (172.21.6.99) by RTEXH36505.realtek.com.tw (172.21.6.25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.32; Mon, 27 Mar 2023 08:46:15 +0800 Received: from RTEXMBS04.realtek.com.tw (172.21.6.97) by RTEXMBS06.realtek.com.tw (172.21.6.99) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Mon, 27 Mar 2023 08:46:15 +0800 Received: from RTEXMBS04.realtek.com.tw ([fe80::b4a2:2bcc:48d1:8b02]) by RTEXMBS04.realtek.com.tw ([fe80::b4a2:2bcc:48d1:8b02%5]) with mapi id 15.01.2375.007; Mon, 27 Mar 2023 08:46:15 +0800 From: Ping-Ke Shih To: Martin Kaistra , "linux-wireless@vger.kernel.org" CC: Jes Sorensen , Kalle Valo , Bitterblue Smith , Sebastian Andrzej Siewior Subject: RE: [RFC PATCH 01/14] wifi: rtl8xxxu: Add start_ap() callback Thread-Topic: [RFC PATCH 01/14] wifi: rtl8xxxu: Add start_ap() callback Thread-Index: AQHZXOKRYT+MvfsxukK4ImPrnPVroK8N0TMA Date: Mon, 27 Mar 2023 00:46:15 +0000 Message-ID: <31c3ee6fe34b418e993fb3d26258e71d@realtek.com> References: <20230322171905.492855-1-martin.kaistra@linutronix.de> <20230322171905.492855-2-martin.kaistra@linutronix.de> In-Reply-To: <20230322171905.492855-2-martin.kaistra@linutronix.de> Accept-Language: en-US, zh-TW Content-Language: zh-TW X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [172.21.69.188] x-kse-serverinfo: RTEXMBS06.realtek.com.tw, 9 x-kse-attachmentfiltering-interceptor-info: no applicable attachment filtering rules found x-kse-antivirus-interceptor-info: scan successful x-kse-antivirus-info: =?us-ascii?Q?Clean,_bases:_2023/3/26_=3F=3F_06:25:00?= x-kse-bulkmessagesfiltering-scan-result: protection disabled Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-KSE-ServerInfo: RTEXH36505.realtek.com.tw, 9 X-KSE-AntiSpam-Interceptor-Info: fallback X-KSE-Antivirus-Interceptor-Info: fallback X-KSE-AntiSpam-Interceptor-Info: fallback X-Spam-Status: No, score=0.0 required=5.0 tests=SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org > -----Original Message----- > From: Martin Kaistra > Sent: Thursday, March 23, 2023 1:19 AM > To: linux-wireless@vger.kernel.org > Cc: Jes Sorensen ; Kalle Valo ; Ping-Ke Shih > ; Bitterblue Smith ; Sebastian Andrzej Siewior > > Subject: [RFC PATCH 01/14] wifi: rtl8xxxu: Add start_ap() callback > > This gets called at the start of AP mode operation. Set bssid, beacon > interval and send a connect report to the HW. > > Signed-off-by: Martin Kaistra Reviewed-by: Ping-Ke Shih > --- > .../net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c | 15 +++++++++++++++ > 1 file changed, 15 insertions(+) > > diff --git a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c > b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c > index c152b228606f1..90b98b9dcbd9d 100644 > --- a/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c > +++ b/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c > @@ -4899,6 +4899,20 @@ rtl8xxxu_bss_info_changed(struct ieee80211_hw *hw, struct ieee80211_vif *vif, > return; > } > > +static int rtl8xxxu_start_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif, > + struct ieee80211_bss_conf *link_conf) > +{ > + struct rtl8xxxu_priv *priv = hw->priv; > + struct device *dev = &priv->udev->dev; > + > + dev_dbg(dev, "Start AP mode\n"); > + rtl8xxxu_set_bssid(priv, vif->bss_conf.bssid); > + rtl8xxxu_write16(priv, REG_BCN_INTERVAL, vif->bss_conf.beacon_int); > + priv->fops->report_connect(priv, 0, true); > + > + return 0; > +} > + > static u32 rtl8xxxu_80211_to_rtl_queue(u32 queue) > { > u32 rtlqueue; > @@ -7026,6 +7040,7 @@ static const struct ieee80211_ops rtl8xxxu_ops = { > .config = rtl8xxxu_config, > .conf_tx = rtl8xxxu_conf_tx, > .bss_info_changed = rtl8xxxu_bss_info_changed, > + .start_ap = rtl8xxxu_start_ap, > .configure_filter = rtl8xxxu_configure_filter, > .set_rts_threshold = rtl8xxxu_set_rts_threshold, > .start = rtl8xxxu_start, > -- > 2.30.2