From patchwork Wed May 17 09:58:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 1782598 X-Patchwork-Delegate: zajec5@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=lZ2+++o8; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20221208 header.b=QqcJZAoi; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4QLpXq51Rxz20dg for ; Wed, 17 May 2023 20:01:29 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=t8G2ic5QbvCi5GkzKtLi7pyjtWtM6b/uJliA69elL1g=; b=lZ2+++o8zeYANa qhP0fKgDNeMjJRacRcJXQ5dB+ippq2ikFTrFBK8woZ1pvsJTwLztkg4/g5/BGd4JZXBxm6atN1OQD p2Tx58u0XS6g62nEbb3sG30yZZQpimxFKzXH0yYCvCAlF/phDOKfVTYtPsiLk9q29j515RvOZH3aa y5g3Iiv5AUo0FN0HliqljBuk72ZTvhl4iSmsxOrb2mV8lwp6lnaZ+EeXHs7vxSY0OHg29Cr3q/5OX fAvk7KlYw+kCuGjtAexsycApqKokioB/5naju8Api5amJYLpfdhnu9gvMnwrC5EiAf5kXIYqTkTj1 sRIH0fYth8KaFpkMhGGA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pzDvR-009BoO-2o; Wed, 17 May 2023 09:58:29 +0000 Received: from mail-lf1-x12b.google.com ([2a00:1450:4864:20::12b]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pzDvP-009Bn5-02 for openwrt-devel@lists.openwrt.org; Wed, 17 May 2023 09:58:28 +0000 Received: by mail-lf1-x12b.google.com with SMTP id 2adb3069b0e04-4eed764a10cso777065e87.0 for ; Wed, 17 May 2023 02:58:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684317504; x=1686909504; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=LFCLQ9ppgaWXDKLZ6tStdJ7mo/3i3AQVmOheoOU1dAs=; b=QqcJZAoiwawg17LyF8/RwwIVkqUf6/ocICJDZFwHpJXg3nRY41GPyyHtVjNTmwN5Pb 0l1nj2bnNXBiaIV2/T7vnsNXb67lyz9bc/Wp3vkhEkwdRbak1U7iCBarEc7VBFqSGW55 5GY+bh2O6b3D+8WGw3kYJe4vQsGXL27XdnyBMlC79ooAdlLQXeqiua+riMzOK6+MweKg Pw1liIPwaq5PGE2hKM1oiE0wSJtFelwyU8BCCdKFEYEq8x6VV8zcniLwZxLVma5PbSPa OIlHqbnNsMoGI1cKYMGhs6Fmfz8+P1WEvpxc4Shz09MWpnR0cUnK07RhUXoim9G9+8Gz Cs7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684317504; x=1686909504; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=LFCLQ9ppgaWXDKLZ6tStdJ7mo/3i3AQVmOheoOU1dAs=; b=LdGVKX+C/oX6WFvESc24zy3igv6/cgqQBsFH/mGzPcRWmAyQuJh1MCVQcTqlZjM59Y FgULS/dlnlM5KuwNfj2yTtcnohtv6HGcXrDf1j1Yr93aeGfohoDhZPtnFvebQ6PTCliI OxrfTewmzVpXXPVWbhJ82XOXNWJxwG65UziqrCeEDESgQJM8PfPkp2+nhz9Gr5U49972 NmATCGfhM/AOAI4qyM+el7svZbr7CDOeTCE0M5jKLS3rU4eXIv1GBvSoJTuiULInkpgp eoSm7yazRiIju/8jsHuyhAzkYxP6AaoLmy2vSfNUDJZUiNM25dIItZ1jX7Sh4VVee9mZ FrOw== X-Gm-Message-State: AC+VfDzM3wocKOeg+GEk3qRvqCrK9XyzmI/jvLdIenC+aV0+Il8RGkQ4 /nAWbscaAxbBpogdjd2NtJczgBEN1eo= X-Google-Smtp-Source: ACHHUZ7tjXE+uBjbfAxio4Q/FqhRJNzIyRuOhEigzh9ViPyF8Z/6bHQZ27ax//xtyD0gjg6sLhgBNg== X-Received: by 2002:ac2:4283:0:b0:4f1:4051:d77b with SMTP id m3-20020ac24283000000b004f14051d77bmr17679lfh.60.1684317503619; Wed, 17 May 2023 02:58:23 -0700 (PDT) Received: from localhost.lan (031011218106.poznan.vectranet.pl. [31.11.218.106]) by smtp.gmail.com with ESMTPSA id f17-20020a056512093100b004edd4d1e55dsm3302544lft.284.2023.05.17.02.58.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 May 2023 02:58:22 -0700 (PDT) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: openwrt-devel@lists.openwrt.org Cc: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH] mac80211: brcm: drop brcmfmac patch waiting for register_wiphy() Date: Wed, 17 May 2023 11:58:16 +0200 Message-Id: <20230517095816.28533-1-zajec5@gmail.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230517_025827_067073_DE25BB96 X-CRM114-Status: GOOD ( 13.97 ) X-Spam-Score: 0.1 (/) X-Spam-Report: =?unknown-8bit?q?Spam_detection_software=2C_running_on_the_sy?= =?unknown-8bit?q?stem_=22bombadil=2Einfradead=2Eorg=22=2C?= =?unknown-8bit?q?_has_NOT_identified_this_incoming_email_as_spam=2E__The_ori?= =?unknown-8bit?q?ginal?= =?unknown-8bit?q?_message_has_been_attached_to_this_so_you_can_view_it_or_la?= =?unknown-8bit?q?bel?= =?unknown-8bit?q?_similar_future_email=2E__If_you_have_any_questions=2C_see?= =?unknown-8bit?q?_the_administrator_of_that_system_for_details=2E?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_preview=3A__From=3A_Rafa=C5=82_Mi=C5=82ecki_That_w?= =?unknown-8bit?q?as_a_workaround_for_OpenWrt_generation?= =?unknown-8bit?q?_of_config_files=2E_This_patch_was_used_to_postpone_returni?= =?unknown-8bit?q?ng_from_probe_function?= =?unknown-8bit?q?_until_loading_firmware_and_calling_register=5Fwiphy=28=29?= =?unknown-8bit?q?=2E_?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_analysis_details=3A___=280=2E1_points=2C_5=2E0_req?= =?unknown-8bit?q?uired=29?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_pts_rule_name______________description?= =?unknown-8bit?q?_----_----------------------_------------------------------?= =?unknown-8bit?q?--------------------?= =?unknown-8bit?q?_-0=2E0_RCVD=5FIN=5FDNSWL=5FNONE_____RBL=3A_Sender_listed_a?= =?unknown-8bit?q?t_https=3A//www=2Ednswl=2Eorg/=2C?= =?unknown-8bit?q?_no_trust?= =?unknown-8bit?b?IFsyYTAwOjE0NTA6NDg2NDoyMDowOjA6MDoxMmIgbGlzdGVkIGluXQ==?= =?unknown-8bit?b?IFtsaXN0LmRuc3dsLm9yZ10=?= =?unknown-8bit?q?_-0=2E0_SPF=5FPASS_______________SPF=3A_sender_matches_SPF_?= =?unknown-8bit?q?record?= =?unknown-8bit?q?_0=2E0_SPF=5FHELO=5FNONE__________SPF=3A_HELO_does_not_publ?= =?unknown-8bit?q?ish_an_SPF_Record?= =?unknown-8bit?q?_0=2E0_FREEMAIL=5FFROM__________Sender_email_is_commonly_ab?= =?unknown-8bit?q?used_enduser_mail?= =?unknown-8bit?q?_provider?= =?unknown-8bit?q?_=5Bzajec5=5Bat=5Dgmail=2Ecom=5D?= =?unknown-8bit?q?_0=2E2_FREEMAIL=5FENVFROM=5FEND=5FDIGIT_Envelope-from_freem?= =?unknown-8bit?q?ail_username_ends?= =?unknown-8bit?q?_in_digit?= =?unknown-8bit?q?_=5Bzajec5=5Bat=5Dgmail=2Ecom=5D?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FAU__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from?= =?unknown-8bit?q?_author=27s_domain?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID_____________Message_has_at_least_one_v?= =?unknown-8bit?q?alid_DKIM_or_DK_signature?= =?unknown-8bit?q?_0=2E1_DKIM=5FSIGNED____________Message_has_a_DKIM_or_DK_si?= =?unknown-8bit?q?gnature=2C_not_necessarily?= =?unknown-8bit?q?_valid?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FEF__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from?= =?unknown-8bit?q?_envelope-from_domain?= X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org From: Rafał Miłecki That was a workaround for OpenWrt generation of config files. This patch was used to postpone returning from probe function until loading firmware and calling register_wiphy(). All of that is not needed anymore thanks to the ieee80211 hotplug.d script introduced in the commit 5f8f8a366136 ("base-files, mac80211, broadcom-wl: wifi detection and configuration"). That takes care of generating /etc/config/wireless entries even if wireless device appears late in the booting process. Signed-off-by: Rafał Miłecki --- package/kernel/mac80211/Makefile | 2 +- ...-register-wiphy-s-during-module_init.patch | 64 ------------------- 2 files changed, 1 insertion(+), 65 deletions(-) delete mode 100644 package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile index 02cf715d8e..077bc0cba6 100644 --- a/package/kernel/mac80211/Makefile +++ b/package/kernel/mac80211/Makefile @@ -11,7 +11,7 @@ include $(INCLUDE_DIR)/kernel.mk PKG_NAME:=mac80211 PKG_VERSION:=6.1.24 -PKG_RELEASE:=1 +PKG_RELEASE:=2 # PKG_SOURCE_URL:=@KERNEL/linux/kernel/projects/backports/stable/v5.15.58/ PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources/ PKG_HASH:=5d39aca7e34c33cb9b3e366117b2e86841b7bdd37933679d6b1e61be6b150648 diff --git a/package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch b/package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch deleted file mode 100644 index 9d0f3e20b1..0000000000 --- a/package/kernel/mac80211/patches/brcm/860-brcmfmac-register-wiphy-s-during-module_init.patch +++ /dev/null @@ -1,64 +0,0 @@ -From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= -Date: Mon, 8 Jun 2015 16:11:40 +0200 -Subject: [PATCH] brcmfmac: register wiphy(s) during module_init -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -This is needed by OpenWrt which expects all PHYs to be created after -module loads successfully. - -Signed-off-by: Rafał Miłecki ---- - ---- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c -+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/firmware.c -@@ -459,6 +459,7 @@ struct brcmf_fw { - u32 curpos; - unsigned int board_index; - void (*done)(struct device *dev, int err, struct brcmf_fw_request *req); -+ struct completion *completion; - }; - - #ifdef CONFIG_EFI -@@ -686,6 +687,8 @@ static void brcmf_fw_request_done(const - fwctx->req = NULL; - } - fwctx->done(fwctx->dev, ret, fwctx->req); -+ if (fwctx->completion) -+ complete(fwctx->completion); - kfree(fwctx); - } - -@@ -751,6 +754,8 @@ int brcmf_fw_get_firmwares(struct device - { - struct brcmf_fw_item *first = &req->items[0]; - struct brcmf_fw *fwctx; -+ struct completion completion; -+ unsigned long time_left; - char *alt_path = NULL; - int ret; - -@@ -768,6 +773,9 @@ int brcmf_fw_get_firmwares(struct device - fwctx->dev = dev; - fwctx->req = req; - fwctx->done = fw_cb; -+ -+ init_completion(&completion); -+ fwctx->completion = &completion; - - /* First try alternative board-specific path if any */ - if (fwctx->req->board_types[0]) -@@ -787,6 +795,12 @@ int brcmf_fw_get_firmwares(struct device - if (ret < 0) - brcmf_fw_request_done(NULL, fwctx); - -+ -+ time_left = wait_for_completion_timeout(&completion, -+ msecs_to_jiffies(5000)); -+ if (!time_left && fwctx) -+ fwctx->completion = NULL; -+ - return 0; - } -