Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp330160pxb; Fri, 14 Jan 2022 06:39:02 -0800 (PST) X-Google-Smtp-Source: ABdhPJxQz5i2cEWjIWF5Z/CbRAOyXxypfbqHjpETXuMTwMTJ44+TiTZd4isvRoImQqpeTBPysOMw X-Received: by 2002:a17:907:7f1d:: with SMTP id qf29mr7483002ejc.388.1642171142511; Fri, 14 Jan 2022 06:39:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1642171142; cv=none; d=google.com; s=arc-20160816; b=T0bf54BOAbcD1d7Wyls0wJHj1o6fQQhL1YdX90ec/RM+LVEF3mlKskO+PWwvJVxdv8 E4vQyUl/AyUY+ImHK/QHkCHlEJqk35qvC5r4yqwXc8b41w0/zJB2DPCKF01/aXYkozeW awdRkPd0fEZ6O+Bdnl9v4THVteXt2zGvMG8ZYoduyozTZv7nK5AUlu55+rPdZyOZwD9+ mrIiS8ipLkOeOoKVbQHysRouvLHRiqgl4mal9eCIqmez81gmMO1iHOwIfW+vAECdmpGc xKmngS2EyW3pHXq2sHnxAZj8vfAxp/LX2qjnIh0fRWcQhbPVXicfclEmo+2LayA1y+rj JwFA== 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 :references:in-reply-to:date:cc:to:from:subject:message-id; bh=rrMJQmLIXKY3Xcx6EXY0oAX/B5EQsz57ckKeM3aLGLI=; b=ncIQ1CA3yyUsBDucxBXSgUh4EYi8VCWKwb45HWgtyNvlAXmzfl7zVtVA3eQvwawkpt rod0LI4q4r8JPyg957j93V3R2nNG03RCr8SGVr37v0dyrYEHBmtyj7WOBgijZHtHK6mo BTjnN0Sr0jG862UWCyF1brHYfuSblErcgHQ00kyQgvDMqm/ufv3/8t1MuDJXCbnk1W67 USG67gaefjomwe3Cn60lHrKkkZv/JVVhFccUxhDmiXPoiW9tfmzcRl+D0csDeZU3IPZq k/na8rpHBEGztN+dVaoC8v4xT2fQ4S9bHmE9ca/2EgNCqJfF/Xb+RjrETyngRWP4DdLv SI6Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e4si3997339ejs.772.2022.01.14.06.38.43; Fri, 14 Jan 2022 06:39:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238784AbiANCWC (ORCPT + 71 others); Thu, 13 Jan 2022 21:22:02 -0500 Received: from mailgw02.mediatek.com ([210.61.82.184]:48258 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S229863AbiANCWC (ORCPT ); Thu, 13 Jan 2022 21:22:02 -0500 X-UUID: 3b1fa1f097764781a3dae860d2592365-20220114 X-UUID: 3b1fa1f097764781a3dae860d2592365-20220114 Received: from mtkmbs10n2.mediatek.inc [(172.21.101.183)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 1390555901; Fri, 14 Jan 2022 10:21:59 +0800 Received: from mtkcas10.mediatek.inc (172.21.101.39) by mtkmbs07n2.mediatek.inc (172.21.101.141) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 14 Jan 2022 10:21:57 +0800 Received: from mtksdccf07 (172.21.84.99) by mtkcas10.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Fri, 14 Jan 2022 10:21:58 +0800 Message-ID: <57feb4a99c835e6a70496e8e935501bb12a393b3.camel@mediatek.com> Subject: Re: [PATCH v2 3/5] mt76: mt7915: add support for MT7986 From: Peter Chiu To: Lorenzo Bianconi CC: Felix Fietkau , linux-wireless , Ryder Lee , "Xing Song" , Sujuan Chen , Shayne Chen , Evelyn Tsai , linux-mediatek , Bo Jiao Date: Fri, 14 Jan 2022 10:21:58 +0800 In-Reply-To: References: <8b2098132192c0381e41ac78a47b7318d5c28b04.1641901681.git.Bo.Jiao@mediatek.com> <2ab2731dc44494dbfe89363638cdcaf49351afbe.camel@mediatek.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-MTK: N Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org On Thu, 2022-01-13 at 14:55 +0100, Lorenzo Bianconi wrote: > > > On Wed, 2022-01-12 at 14:35 +0100, Lorenzo Bianconi wrote: > > > > > > > > > > @@ -302,6 +316,15 @@ struct mt7915_dev { > > > > > u8 table_mask; > > > > > u8 n_agrt; > > > > > } twt; > > > > > + > > > > > + struct reset_control *rstc; > > > > > + void __iomem *dcm; > > > > > + void __iomem *sku; > > > > > + > > > > > + struct { > > > > > + bool is_7975; > > > > > + bool is_7976; > > > > > + } adie[MT7986_MAX_ADIE_NUM]; > > > > > > > > do we really need it? Can we just read data from chip when > > > > necessary? > > > > it is not > > > > access in the hot-path, right? > > > > I think it is easier and more readable. > > > > > > Adie registers are inaccessible after wfsys power on so we need > > > some > > > places to store chip configuration. > > > We will modify it to make it more readable. > > > + u32 adie; > > > > what I mean is just continue reading these values after the first > > time (that is > > in common for both approaches). > > ok, sorry I misread your reply. Anyway it seems to me we need these > values just > in mt7986_wmac_enable() (or in routines called by > mt7986_wmac_enable). Right? > If so maybe we can just store them in a local struct in > mt7986_wmac_enable(). > What do you think? > OK, I will fix it in the next patch. thanks, Peter > Regards, > Lorenzo > > > > > Regards, > > Lorenzo > > > > > > > > thanks, > > > Peter > > > > >