Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp999469pxp; Wed, 9 Mar 2022 18:09:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJw8rVNuh4DP4c+kJWqW62aDJ/NqJcgyodaftUOm3KS6FUbhfoaCs19JBaPFxbTHmvWxkvZK X-Received: by 2002:a17:906:1e13:b0:6ce:e50c:2a9c with SMTP id g19-20020a1709061e1300b006cee50c2a9cmr2314197ejj.546.1646878195788; Wed, 09 Mar 2022 18:09:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646878195; cv=none; d=google.com; s=arc-20160816; b=ba5FFEZBACsY+y3PP2uz6Fyk49cvqKS6S4Japp0TYvruKzQU9mPEe5/zBzc7XLKV79 3A8NUIyFfavgeLNJ62o6pkLg5InIlEKkNbwoXAc6++nc8PQWPRO83L3HcassRw+k6oM7 VkNB8I28graX5d1fOQF4J7r+gvHD8zTtMIsqzHoPdrnMguTn+TnHbJb7mEwDCfHXFWAy nlhRyby/eCl0AGi7Cvo9XAV9hN5rJHivfzbxRnDdv2hC82tPFC52kn63yXDJeDXyMxJT g/oHfGyTdWEtcU7HYLPi04DxnfpUdB20bFaRq7VmjQV08M23g98L4l6wOQd9ioAvCJlc JH9A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:dkim-signature; bh=x7ymHsgqFEN86o8611pDZsoSVDfvMkyfUVRqrMffFAo=; b=AIikGBQeqbcExxqqLFJq7cTz1LJ237W6KWTY+1f6E5OSVMv0J5wAYVwmvnxygaQ0oQ GNzrCNw/Ac5MiifA9WfelYtAlzmCbwUQT1InfyDoCsDVSv2fbg2Jd7jYZJ12eVpB1LjI n9bXtNtdRqhPK5RRIu2ENKArhXlPKhODeLucCq7dnAcr0b5LBVRofzegNYGAeYEwbV92 7podQwgVpOcyvY8xWkRIrE0E/5tiYbBEB5TioJb48dV6hbM4uptKT6rJ4/SflsLzCxNn AxLoevDQU/oXwzynJlqFPCpYlGHXw3Qwi6zCWqrySxRmK2IcHK1Tzk1yLwctwT6GjD4C IDAQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=fOf6Gt30; 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=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id nd20-20020a170907629400b006da8a7caf42si2487112ejc.945.2022.03.09.18.09.08; Wed, 09 Mar 2022 18:09:55 -0800 (PST) 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=@redhat.com header.s=mimecast20190719 header.b=fOf6Gt30; 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=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237605AbiCIXZN (ORCPT + 70 others); Wed, 9 Mar 2022 18:25:13 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34208 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229618AbiCIXZN (ORCPT ); Wed, 9 Mar 2022 18:25:13 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id ED361527D1 for ; Wed, 9 Mar 2022 15:24:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1646868252; h=from:from:reply-to:subject:subject: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=x7ymHsgqFEN86o8611pDZsoSVDfvMkyfUVRqrMffFAo=; b=fOf6Gt301jLcm+cwF+fH94VjW1sSWkBe2qmd15FkLrMSK1HOHUHhHwecKQ8QQSzTTdIuYu r+y8XcKhXOq8438w8L7dLyyYT1FOg+OSiuNg5xNig5YxYDn5mzuprUq6S+1lz9VFlWglxT xbT8PswHvu2QMl4peVOhhPWrp4Nfo+M= Received: from mail-ej1-f71.google.com (mail-ej1-f71.google.com [209.85.218.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-155-FDW6LY1kMVWxpgBuw2GU_Q-1; Wed, 09 Mar 2022 18:24:11 -0500 X-MC-Unique: FDW6LY1kMVWxpgBuw2GU_Q-1 Received: by mail-ej1-f71.google.com with SMTP id r18-20020a17090609d200b006a6e943d09eso2088734eje.20 for ; Wed, 09 Mar 2022 15:24:11 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version; bh=x7ymHsgqFEN86o8611pDZsoSVDfvMkyfUVRqrMffFAo=; b=O89SXbJXteTp0Shzisdc+YenSWlC2WjKlrNMGwyCh6RDYKt1jRm71AHzxnQRSmSVGx yo+xIRFXzxCJf+hMObYA+ygEPd37NnDL4MrchVo5V1jevryH2EWx7Ap5Bh1hqsV9BzTK 15neVfV8jpdEcI3kUJCiFe+Ao9faIxxLfS9SdANaartgGhhKJtEiU3AoCY2H0DPyod2x sGwoSX7F00XNWbltp/qEVO2Lua1yKwIBFx5N2cVRqWnAQ0xzbGEOPmqpajm4FCbzmd5m n6V1tKd5AVbhUMY7CxszU/J9RICoy4p50B6t/4y7k3NeThwnxym/9EQ6onQtZhW0MxnF 3oEA== X-Gm-Message-State: AOAM53171RX50fIZohVbAVfwqmubIS+g6jISn5m16q4+y6hw83NzdBwT CKn3XS9PAGonOz0zZ+8SgAWtfrEWGs57AXYQzis9e2zQW3WuLXIMT8rcIdMl0LMHw5/c3Vcd8JA DwBOPvnN1Ze/1wM14qrqhjYQEl6g= X-Received: by 2002:a17:906:c151:b0:6db:2b7f:302f with SMTP id dp17-20020a170906c15100b006db2b7f302fmr1957020ejc.4.1646868250009; Wed, 09 Mar 2022 15:24:10 -0800 (PST) X-Received: by 2002:a17:906:c151:b0:6db:2b7f:302f with SMTP id dp17-20020a170906c15100b006db2b7f302fmr1957005ejc.4.1646868249579; Wed, 09 Mar 2022 15:24:09 -0800 (PST) Received: from alrua-x1.borgediget.toke.dk ([45.145.92.2]) by smtp.gmail.com with ESMTPSA id y6-20020a056402358600b004166413d27bsm1339194edc.97.2022.03.09.15.24.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Mar 2022 15:24:08 -0800 (PST) Received: by alrua-x1.borgediget.toke.dk (Postfix, from userid 1000) id 22F5D192B84; Thu, 10 Mar 2022 00:24:08 +0100 (CET) From: Toke =?utf-8?Q?H=C3=B8iland-J=C3=B8rgensen?= To: Wenli Looi , Kalle Valo Cc: ath9k-devel@qca.qualcomm.com, Miaoqing Pan , linux-wireless@vger.kernel.org Subject: Re: QCN5502 support in ath9k In-Reply-To: References: <87r18d1upk.fsf@kernel.org> X-Clacks-Overhead: GNU Terry Pratchett Date: Thu, 10 Mar 2022 00:24:08 +0100 Message-ID: <87mthyvhev.fsf@toke.dk> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE 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 Wenli Looi writes: > I've managed to get QCN5502 working in ath9k in a very hacky way, by > mainly treating it as QCA956x, including the initvals: > > https://github.com/openwrt/openwrt/pull/9389 > > It would be great if anyone could provide comments on the code, as > well as the ideas for incorporating this cleanly into ath9k (and > whether there would be interest in doing so). I certainly wouldn't mind merging this support if it can be implemented in a clean way; we'd have to be sure it doesn't break anything on existing devices, of course. You'll have to split out the code to co-exist with the ar9003. My immediate thought would be that it would be a mistake to employ too clever tricks to maximise code reuse. By all means, try to reuse as much code as possible, but I'd rather take a bit of code duplication than end up with something that works in non-obvious ways :) Hope that helps! -Toke