From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id EE52AC76196 for ; Fri, 31 Mar 2023 13:58:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232564AbjCaN6V (ORCPT ); Fri, 31 Mar 2023 09:58:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58170 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229629AbjCaN6U (ORCPT ); Fri, 31 Mar 2023 09:58:20 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2001:67c:2178:6::1d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1499111665; Fri, 31 Mar 2023 06:58:19 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id B6DB71F38D; Fri, 31 Mar 2023 13:58:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1680271097; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=B/+tyY+4YpwTOvMQ+ZR0O6laVYkxzmAUjSzVvakVAIE=; b=OBXbH6pyTiyJ5e9/dr6LwXShmAblyQ/ZxioBwAjPouXsCkO7ixnmAazRgT+s9gDKukKOYJ HiTI0gC7kmiM80MKLGTpw7+NgmFHk19L9kmN+MHea44KJd7Z5cVg8v21t02vHsA2/OsaEj wfJgGazaJ6uMvBUtnZ+jUzrukJdFQgA= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1680271097; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=B/+tyY+4YpwTOvMQ+ZR0O6laVYkxzmAUjSzVvakVAIE=; b=KEr4kxObXcosEhAT0gdkag7OXo4TMquLztGct6qr0jSX+d9NhwQPzMkaAl+ej8SI11t/zP 6VI3yhHRii3lEkCA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 906C7133B6; Fri, 31 Mar 2023 13:58:17 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id XKJxIvnmJmQwWQAAMHmgww (envelope-from ); Fri, 31 Mar 2023 13:58:17 +0000 Date: Fri, 31 Mar 2023 15:58:17 +0200 Message-ID: <87a5ztja4m.wl-tiwai@suse.de> From: Takashi Iwai To: Simon Horman Cc: Takashi Iwai , Kalle Valo , ath11k@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org Subject: Re: [PATCH] ath11k: pci: Add more MODULE_FIRMWARE() entries In-Reply-To: References: <20230330143718.19511-1-tiwai@suse.de> User-Agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/27.2 Mule/6.0 MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Fri, 31 Mar 2023 15:45:27 +0200, Simon Horman wrote: > > On Thu, Mar 30, 2023 at 04:37:18PM +0200, Takashi Iwai wrote: > > As there are a few more models supported by the driver, let's add the > > missing MODULE_FIRMWARE() entries for them. The lack of them resulted > > in the missing device enablement on some systems, such as the > > installation image of openSUSE. > > > > While we are at it, use the wildcard instead of listing each firmware > > files individually for each. > > > > Signed-off-by: Takashi Iwai > > --- > > > > I can rewrite without wildcards if it's preferred, too. > > But IMO this makes easier to maintain. > > > > drivers/net/wireless/ath/ath11k/pci.c | 9 +++++---- > > 1 file changed, 5 insertions(+), 4 deletions(-) > > > > diff --git a/drivers/net/wireless/ath/ath11k/pci.c b/drivers/net/wireless/ath/ath11k/pci.c > > index 0aeef2948ff5..379f7946a29e 100644 > > --- a/drivers/net/wireless/ath/ath11k/pci.c > > +++ b/drivers/net/wireless/ath/ath11k/pci.c > > @@ -1039,7 +1039,8 @@ module_exit(ath11k_pci_exit); > > MODULE_DESCRIPTION("Driver support for Qualcomm Technologies 802.11ax WLAN PCIe devices"); > > MODULE_LICENSE("Dual BSD/GPL"); > > > > -/* QCA639x 2.0 firmware files */ > > -MODULE_FIRMWARE(ATH11K_FW_DIR "/QCA6390/hw2.0/" ATH11K_BOARD_API2_FILE); > > -MODULE_FIRMWARE(ATH11K_FW_DIR "/QCA6390/hw2.0/" ATH11K_AMSS_FILE); > > -MODULE_FIRMWARE(ATH11K_FW_DIR "/QCA6390/hw2.0/" ATH11K_M3_FILE); > > +/* firmware files */ > > +MODULE_FIRMWARE(ATH11K_FW_DIR "/QCA6390/hw2.0/*"); > > +MODULE_FIRMWARE(ATH11K_FW_DIR "/QCN9074/hw1.0/*"); > > +MODULE_FIRMWARE(ATH11K_FW_DIR "/WCN6855/hw2.0/*"); > > +MODULE_FIRMWARE(ATH11K_FW_DIR "/WCN6855/hw2.1/*"); > > I don't feel strongly about this. > > But unless I'm mistaken the above does seem to pick up a number of files > totalling around 25Mbytes. Perhaps that isn't ideal. MODULE_FIRMWARE() itself is nothing but a hint for the required firmware files. The driver supports those models, hence it should list up the mandatory firmware files that *can* be used with it; without the firmware, the driver itself is just useless, as you know. The rest -- how to reduce the actual sizes -- is above the kernel modinfo covers, and it depends on the system implementation, IMO. It can be somehow more selective, it can compress data, or it can load the stuff on demands. thanks, Takashi