Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp460266rwr; Wed, 26 Apr 2023 01:35:04 -0700 (PDT) X-Google-Smtp-Source: AKy350YeBo492lQtaRWavb87toiWQl0OC2iJNLRqLMNzdQm5eqzL5ta4NsgHBtuXhZWjq4ywuyC0 X-Received: by 2002:a05:6a20:258b:b0:f4:ac2d:8e95 with SMTP id k11-20020a056a20258b00b000f4ac2d8e95mr13969096pzd.9.1682498103970; Wed, 26 Apr 2023 01:35:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682498103; cv=none; d=google.com; s=arc-20160816; b=XdOJ4gmvReTML4yUl2aQivfaAbUUb8PWkPpZW3MY/HLdlZGkrr0CnjaSmXoTuSJZHp SUoSmAHvPMYBZAJu4TbMGMu/GPFyU0DFzAHZMQ9YbH71Qccsc1HNdqk3AYkWWsZrgiw6 XBaxg+UxQKG/5GluA+O8AHygwFDDxtvparGcKl2czMtmWAq38KRIXsnGw18TdkSyhvT2 tJHfHR4/y7ewPqr+0/jeKwQ/fft33gdbkVtjsHfgFZsaSI/1fT6pSq5pPmLTWOmiZAa9 aIB7zAYNmiAveetZaBXs+MRdN5sH8u0RFfueGiSca+JufRFWSm70a8wcmLbPqadEqlIM QiIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent :content-transfer-encoding:references:in-reply-to:date:cc:to:from :subject:message-id:dkim-signature; bh=fr6SUQxoC/8u9dg+rT54woScWFBPHqDXPsE53mCRKdU=; b=dYcbwct1XwLXTgXvaW9ZW/0XTq1L7cC+MN/htVYiWwz4q5q10Mofy22EjL09ramItQ ibVSvZo55+2DThaY2IRGnwlZZBzFK6hP5AKeQvRH9vxF1EmOb5kmAMjs2xBcGLygS11T dLx4kIIr+YzP1XmRTCWbBHwoqvjTOklQXioDQO4rEesOheH+fgGxr4WGnAtfCljTa23W xC/Csv0HGI+XIi4hQg1eFb1Q6LPZdSCokg+oB5YqzLS29cOO3JDZVQCzlqUTH3Khm2I0 RBfQq0RDdUF34kee4aUd/kB1k/5ys9hWvVhsTVPmc3VZGT9VUAEumMKTrriOk9tnL5us 0lOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sipsolutions.net header.s=mail header.b=jtbminiP; 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; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q197-20020a632ace000000b0050be02c590asi15416305pgq.666.2023.04.26.01.34.52; Wed, 26 Apr 2023 01:35:03 -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; dkim=pass header.i=@sipsolutions.net header.s=mail header.b=jtbminiP; 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; dmarc=pass (p=NONE sp=REJECT dis=NONE) header.from=sipsolutions.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240279AbjDZIZi (ORCPT + 63 others); Wed, 26 Apr 2023 04:25:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46778 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239789AbjDZIZG (ORCPT ); Wed, 26 Apr 2023 04:25:06 -0400 Received: from sipsolutions.net (s3.sipsolutions.net [IPv6:2a01:4f8:191:4433::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C13973C0F; Wed, 26 Apr 2023 01:25:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sipsolutions.net; s=mail; h=MIME-Version:Content-Transfer-Encoding: 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=fr6SUQxoC/8u9dg+rT54woScWFBPHqDXPsE53mCRKdU=; t=1682497502; x=1683707102; b=jtbminiPTEN89EeeSsDfwDaIQ2racyiMr3D8P0XzJF3x4GB o+T76/LTeFHO6ufof3fZaeODZzLo1HO7ETtArem1srObDTMxc842hKvQUhbXI5laP2HtddJ1IBTlb F8P0QUFEO9IzQyWE+QBSZFVH7AaR/ZZeCctYH6AJm6RuFCY2hDzaGllyio6FCIesnjNAtf3rL9lEr 3CfZy6OuoabzrwLe/N+m/i+uwBMa7Ux2a4PBvcp58pBcIFLbXSCV8ZMvnCCGsWxrZvxXLU+qm+O1/ o07MESlP+JSOAD9UWMhEU7KW0QheRDCWDTg1YHXJE9x3oUFz2iuFMwOiopbpJ7QQ==; Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.96) (envelope-from ) id 1praSM-0092u4-1v; Wed, 26 Apr 2023 10:24:54 +0200 Message-ID: <7214a6a800e4af80b9319c30b13cc52286bba50a.camel@sipsolutions.net> Subject: Re: pull-request: wireless-next-2023-04-21 From: Johannes Berg To: Ping-Ke Shih , Jakub Kicinski , Kalle Valo Cc: "netdev@vger.kernel.org" , "linux-wireless@vger.kernel.org" Date: Wed, 26 Apr 2023 10:24:53 +0200 In-Reply-To: <1a38a4289ef34672a2bc9a880e8608a8@realtek.com> References: <20230421104726.800BCC433D2@smtp.kernel.org> <20230421075404.63c04bca@kernel.org> <87leigr06u.fsf@kernel.org> <20230425071848.6156c0a0@kernel.org> <77cf7fa9de20be55d50f03ccbdd52e3c8682b2b3.camel@sipsolutions.net> <1a38a4289ef34672a2bc9a880e8608a8@realtek.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.4 (3.46.4-1.fc37) MIME-Version: 1.0 X-malware-bazaar: not-scanned X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham 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 Wed, 2023-04-26 at 03:30 +0000, Ping-Ke Shih wrote: > > >=20 > >=20 > > I think the extra work Kalle meant is what I mentioned previously -- > > need functions to convert old tables v1, v2, ... to current. Like, > >=20 >=20 > struct table_v1 { // from file > __le32 channel_tx_power[10]; > }; >=20 > struct table_v2 { // from file > __le32 channel_tx_power[20]; > }; >=20 > struct table { // from file, the latest version of current use > __le32 channel_tx_power[30]; > }; >=20 > struct table_cpu { // current table in cpu order > u32 channel_tx_power[30]; > }; >=20 > To make example clearer, I change the name of fields, because the thing I > want to mention is not register table that wouldn't need conversion. Right, the file format would have to be __le32 (or __be32), but that's pretty easy to handle while writing it to the device? Not sure I understand the other thing about conversion. > > If loading a table_v1 table, for example, we need to convert to table_c= pu by > > some rules. Also, maybe we need to disable some features relay on the v= alues > > introduced by table_cpu. I think it will work, but just add some flags = and > > rules to handle them. But wouldn't this basically be tied to a driver? I mean you could have a file called "rtlwifi/rtlxyz.v1.tables" that the driver in kernel 6.4 loads, and ...v2... that the driver in 6.5 loads, and requires for operation? Then again - it'd be better if the driver in 6.5 can deal with it if a user didn't install the v2 file yet, is that what you meant? > > Another question is about number of files for single device. Since firm= ware and > > tables (e.g. TX power, registers) are released by different people, and= they > > maintain their own version, if I append tables to firmware, it's a litt= le hard > > to have a clear version code. So, I would like to know the rule if I ca= n just > > add additional one file for these tables? Oh, I certainly wasn't trying to say that it should be done by combining the file, just that it might be _easier_ to distribute this stuff then. If not, then not! johannes