lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: 
 <BY3PR18MB470736FBC23588BE63656D50A0272@BY3PR18MB4707.namprd18.prod.outlook.com>
Date: Fri, 8 Mar 2024 06:09:36 +0000
From: Sai Krishna Gajula <saikrishnag@...vell.com>
To: Jakub Kicinski <kuba@...nel.org>
CC: "davem@...emloft.net" <davem@...emloft.net>,
        "edumazet@...gle.com"
	<edumazet@...gle.com>,
        "pabeni@...hat.com" <pabeni@...hat.com>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        Sunil Kovvuri
 Goutham <sgoutham@...vell.com>,
        Geethasowjanya Akula <gakula@...vell.com>,
        Hariprasad Kelam <hkelam@...vell.com>,
        Subbaraya Sundeep Bhatta
	<sbhatta@...vell.com>
Subject: Re: [net-next PATCH v2] octeontx2-pf: Reset MAC stats during probe


> -----Original Message-----
> From: Jakub Kicinski <kuba@...nel.org>
> Sent: Friday, March 8, 2024 10:17 AM
> To: Sai Krishna Gajula <saikrishnag@...vell.com>
> Cc: davem@...emloft.net; edumazet@...gle.com; pabeni@...hat.com;
> netdev@...r.kernel.org; linux-kernel@...r.kernel.org; Sunil Kovvuri Goutham
> <sgoutham@...vell.com>; Geethasowjanya Akula <gakula@...vell.com>;
> Hariprasad Kelam <hkelam@...vell.com>; Subbaraya Sundeep Bhatta
> <sbhatta@...vell.com>
> Subject: Re: [net-next PATCH v2] octeontx2-pf: Reset MAC stats
> during probe
> 
> On Tue, 5 Mar 2024 13:57:07 +0530 Sai Krishna wrote:
> > +int otx2_reset_mac_stats(struct otx2_nic *pfvf);
> >
> >  /* RVU block related APIs */
> >  int otx2_attach_npa_nix(struct otx2_nic *pfvf); diff --git
> > a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
> > b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
> > index e5fe67e73865..a91f5b7e84c6 100644
> > --- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
> > +++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c
> > @@ -1124,6 +1124,24 @@ static int otx2_cgx_config_linkevents(struct
> otx2_nic *pf, bool enable)
> >  	return err;
> >  }
> >
> > +int otx2_reset_mac_stats(struct otx2_nic *pfvf) {
> > +	struct msg_req *req;
> > +	int err;
> > +
> > +	mutex_lock(&pfvf->mbox.lock);
> > +	req = otx2_mbox_alloc_msg_cgx_stats_rst(&pfvf->mbox);
> > +	if (!req) {
> > +		mutex_unlock(&pfvf->mbox.lock);
> > +		return -ENOMEM;
> > +	}
> > +
> > +	err = otx2_sync_mbox_msg(&pfvf->mbox);
> > +	mutex_unlock(&pfvf->mbox.lock);
> > +	return err;
> > +}
> > +EXPORT_SYMBOL(otx2_reset_mac_stats);
> 
> Why the export? I see only one call to this function and it's right below.

Ack, Will remove this export and submit patch V3

> 
> >  static int otx2_cgx_config_loopback(struct otx2_nic *pf, bool enable)
> > {
> >  	struct msg_req *msg;
> > @@ -3048,6 +3066,9 @@ static int otx2_probe(struct pci_dev *pdev,
> > const struct pci_device_id *id)
> >
> >  	otx2_qos_init(pf, qos_txqs);
> >
> > +	/* reset CGX/RPM MAC stats */
> > +	otx2_reset_mac_stats(pf);
> > +


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ