Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp5285705iob; Mon, 9 May 2022 12:48:29 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx71c8VJ+VWZr+KL8gw8e+ZmoOtlN1sTKroUzZSDDJHqNQHqLO7UB9LpuacOjLl/i+pLawo X-Received: by 2002:a17:90b:3a86:b0:1dc:2343:2429 with SMTP id om6-20020a17090b3a8600b001dc23432429mr19458548pjb.206.1652125709115; Mon, 09 May 2022 12:48:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652125709; cv=none; d=google.com; s=arc-20160816; b=affw3lsQ/PpoxR0XTT4VDxuTofOfxv3xMHnQ5+CIM/7et8OR77C6z6EnTwfe6DkHz1 k9W1xz8YlZGONoFpiduie1V/U1zZFHXSjiVYNs/oZFO6+LNVrNSVIUrhahU/G4zXFnTZ XY3KFw6Ohozm9golo7pAoOlH9cmLcHIVQA5dkszScFqdlf+HsOgX4uek5m47PDPNCvSG /y3fUqZl601JNiYi9XUswL0+CnbkeVq7maxqab2DVgHahDZgRnSTbsxJOKA6tt93LQYO J1BpPxO0eFJN7juMbqx2JWUTD9XxZzTgUa4GE88EymGRT5nraGT8YOrcB85EkXywLIHo qd0g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id:dkim-signature; bh=7m/9oUwqcQ+mHWUWgpbbBTTQFzglaV3pywa+M/m7L1U=; b=Zh+0vlgRR8xnUP08SzzlYZGjtwh4S1ufOl75XNUyH2vfKkJ3weuVA+Rm4DMB/lBCM0 vU/8Y0kFW5FNUm7pVNC2TSQ/81C/Q0kP29G+iqQB3jZdR7Dx1ncx3o8kc26mpTmimbvI yaaTAtQGm2rRQhLKvCNOCWsofa3TYRHPRU355XndDyyyz3jnKfCLxn7BjPoFefp2LnDI falr2fq6Rkc1UQOhfy+Ta+shiNCEFsvcDstaPNI1sEF28P6Tlp95UyDY5pCnL+O6Vxj4 EzTMbww/wlGOjLAkqIYThHVK+MLkn/oV4meAI7nI3c8LXrdoZ1LcNTKoTkuCg2bsD6/f sUmg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b="DVkgzn/4"; spf=softfail (google.com: domain of transitioning linux-wireless-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id t10-20020a63f34a000000b003816043f063si15178256pgj.600.2022.05.09.12.48.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 May 2022 12:48:29 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-wireless-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b="DVkgzn/4"; spf=softfail (google.com: domain of transitioning linux-wireless-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id ED5002D9EF3; Mon, 9 May 2022 12:44:46 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240650AbiEITsj (ORCPT + 69 others); Mon, 9 May 2022 15:48:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35634 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240639AbiEITsj (ORCPT ); Mon, 9 May 2022 15:48:39 -0400 Received: from sipsolutions.net (s3.sipsolutions.net [IPv6:2a01:4f8:191:4433::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D49032D9ED9 for ; Mon, 9 May 2022 12:44:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sipsolutions.net; s=mail; h=Content-Transfer-Encoding:MIME-Version: Content-Type:References:In-Reply-To:Date:Cc:To:From:Subject:Message-ID:Sender :Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-To: Resent-Cc:Resent-Message-ID; bh=7m/9oUwqcQ+mHWUWgpbbBTTQFzglaV3pywa+M/m7L1U=; t=1652125484; x=1653335084; b=DVkgzn/4dP3f+05guCrOpoyx7VJ28Wyhvj5Boc6bku3evlu m/fo6wGhHbsrUMfGWtdpDN3uGFVc7OMT+pgdF97veZuj9ReCMU+o+tnxlqJUUOX4BZk17iVhi6647 IUWDu8RSvDKgg64Ogl/Xc5qB+ISHv/2k0ymiDvBzcsISrBvNZ8HSgac4ozuhzfEG/x/uSF009ldvo n56MQH7VWtDgBEtqaRhQOPZGPXmb2+J3r7VqsRA1oiULIPcFBYQDWo1PRXSM6f6atsoZpjzuiYkuG bivibLS+PjfXKzkSGxyDvyC8j0vBnk9as7Q7mKj2Ba255BZnxLQ/WZyCi4KEGuXw==; Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.95) (envelope-from ) id 1no9JA-006vHR-Vc; Mon, 09 May 2022 21:44:41 +0200 Message-ID: <57cb3e2f1ba75aec472ca5cfdcd8fc3c7ffffeb0.camel@sipsolutions.net> Subject: Re: [PATCH 3/5] wilc1000: fix crash observed in AP mode with cfg80211_register_netdevice() From: Johannes Berg To: Ajay.Kathat@microchip.com, kvalo@kernel.org Cc: linux-wireless@vger.kernel.org, Claudiu.Beznea@microchip.com, Sripad.Balwadgi@microchip.com Date: Mon, 09 May 2022 21:44:40 +0200 In-Reply-To: References: <20220504161924.2146601-1-ajay.kathat@microchip.com> <20220504161924.2146601-3-ajay.kathat@microchip.com> <87pmkmylex.fsf@kernel.org> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.42.4 (3.42.4-2.fc35) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-malware-bazaar: not-scanned X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 On Mon, 2022-05-09 at 13:49 +0000, Ajay.Kathat@microchip.com wrote: > > As I understand, in WILC "ieee80211_ptr" is used for the station/AP > interface but not to configure the monitor interface which gets > additionally added in AP mode. In AP mode, for an interface( wlan0 ), an > additional monitor interface( mon.wlan0 ) gets created. A netdevice is > register for monitor interface(mon.wlan0) to transmit/receive frames > from/to hostapd. That interface doesn't explicitly set up > 'ieee80211_ptr' because the original interface(wlan0) uses it, so using > "cfg80211_register/unregister" API's for mon.wlan0 interfaces fails. Btw, this probably should just be removed in favour of using the nl80211 based APIs for hostapd ... But I think as a quick bugfix goes this is fine, but it'd be better to remove this and either allow hostapd to create the interface with the proper ieee80211_ptr, or to just use the nl80211-based TX/RX. johannes