Search Linux Wireless

Re: [PATCH v4 05/12] mt76: mt7915: add firmware support for mt7916

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2022-01-20 at 13:29 -0800, Ben Greear wrote:
> On 12/19/21 6:17 PM, Bo Jiao wrote:
> > From: Bo Jiao <Bo.Jiao@xxxxxxxxxxxx>
> > 
> > Update firmware initialization for mt7916.
> > This is an intermediate patch to add mt7916 support.
> > 
> > Co-developed-by: Sujuan Chen <sujuan.chen@xxxxxxxxxxxx>
> > Signed-off-by: Sujuan Chen <sujuan.chen@xxxxxxxxxxxx>
> > Co-developed-by: Ryder Lee <ryder.lee@xxxxxxxxxxxx>
> > Signed-off-by: Ryder Lee <ryder.lee@xxxxxxxxxxxx>
> > Signed-off-by: Bo Jiao <Bo.Jiao@xxxxxxxxxxxx>
> > ---
> > v3:
> > - modify the function mt7915_wfsys_reset to support mt7916
> > ---
> >   .../net/wireless/mediatek/mt76/mt7915/init.c  | 75 ++++++++----
> > -----
> >   .../net/wireless/mediatek/mt76/mt7915/mcu.c   | 81
> > +++++++++++++++----
> >   .../wireless/mediatek/mt76/mt7915/mt7915.h    |  4 +
> >   .../net/wireless/mediatek/mt76/mt7915/pci.c   |  3 +
> >   .../net/wireless/mediatek/mt76/mt7915/regs.h  |  6 +-
> >   5 files changed, 115 insertions(+), 54 deletions(-)
> > 
> > diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/init.c
> > b/drivers/net/wireless/mediatek/mt76/mt7915/init.c
> > index 2da342d..edf0d7e 100644
> > --- a/drivers/net/wireless/mediatek/mt76/mt7915/init.c
> > +++ b/drivers/net/wireless/mediatek/mt76/mt7915/init.c
> > @@ -511,41 +511,53 @@ static void mt7915_init_work(struct
> > work_struct *work)
> >   
> >   static void mt7915_wfsys_reset(struct mt7915_dev *dev)
> >   {
> > -	u32 val = MT_TOP_PWR_KEY | MT_TOP_PWR_SW_PWR_ON |
> > MT_TOP_PWR_PWR_ON;
> > +	u32 val;
> >   
> >   #define MT_MCU_DUMMY_RANDOM	GENMASK(15, 0)
> >   #define MT_MCU_DUMMY_DEFAULT	GENMASK(31, 16)
> > +	if (is_mt7915(&dev->mt76)) {
> > +		mt76_wr(dev, MT_MCU_WFDMA0_DUMMY_CR,
> > MT_MCU_DUMMY_RANDOM);
> > +
> > +		/* change to software control */
> > +		val |= MT_TOP_PWR_SW_RST;
> > +		mt76_wr(dev, MT_TOP_PWR_CTRL, val);
> 
> val is not properly initialized in this path.  I also notice this is
> not the version of the patch
> that was applied to nbd's tree.  The 'else nic is 7916' clause that
> this patch creates is also different
> in nbd's tree vs this patch.
> 
He sent a follow up to fix this and had been folded into nbd's tree.

Ryder




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux