linux-hyperv.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dexuan Cui <decui@microsoft.com>
To: Haiyang Zhang <haiyangz@microsoft.com>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"kuba@kernel.org" <kuba@kernel.org>,
	"gustavoars@kernel.org" <gustavoars@kernel.org>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Cc: KY Srinivasan <kys@microsoft.com>,
	"stephen@networkplumber.org" <stephen@networkplumber.org>,
	"wei.liu@kernel.org" <wei.liu@kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"linux-hyperv@vger.kernel.org" <linux-hyperv@vger.kernel.org>,
	Shachar Raindel <shacharr@microsoft.com>,
	Paul Rosswurm <paulros@microsoft.com>,
	"olaf@aepfle.de" <olaf@aepfle.de>, vkuznets <vkuznets@redhat.com>
Subject: RE: [PATCH net-next 2/4] net: mana: Report OS info to the PF driver
Date: Mon, 1 Nov 2021 06:07:22 +0000	[thread overview]
Message-ID: <BYAPR21MB127031948D2C6E22F8EC805ABF8A9@BYAPR21MB1270.namprd21.prod.outlook.com> (raw)
In-Reply-To: <BN8PR21MB128404C264B2E9081C97CF19CA889@BN8PR21MB1284.namprd21.prod.outlook.com>

> From: Haiyang Zhang <haiyangz@microsoft.com>
> Sent: Saturday, October 30, 2021 8:36 AM
> > @@ -848,6 +850,15 @@ int mana_gd_verify_vf_version(struct pci_dev
> *pdev)
> >  	req.gd_drv_cap_flags3 = GDMA_DRV_CAP_FLAGS3;
> >  	req.gd_drv_cap_flags4 = GDMA_DRV_CAP_FLAGS4;
> >
> > +	req.drv_ver = 0;	/* Unused*/
> > +	req.os_type = 0x10;	/* Linux */
> 
> Instead of a magic number, could you define it as a macro?
> 
> Other parts look fine.
> 
> Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>

Ok, I'll apply the below change in v2.

@@ -497,6 +497,7 @@ enum {

 #define GDMA_DRV_CAP_FLAGS4 0

+#define GDMA_OS_TYPE_LINUX      0x10
 struct gdma_verify_ver_req {
        struct gdma_req_hdr hdr;

diff --git a/drivers/net/ethernet/microsoft/mana/gdma_main.c b/drivers/net/ethernet/microsoft/mana/gdma_main.c
index c96ac81212f7..bea218c5c043 100644
--- a/drivers/net/ethernet/microsoft/mana/gdma_main.c
+++ b/drivers/net/ethernet/microsoft/mana/gdma_main.c
@@ -851,7 +851,7 @@ int mana_gd_verify_vf_version(struct pci_dev *pdev)
        req.gd_drv_cap_flags4 = GDMA_DRV_CAP_FLAGS4;

        req.drv_ver = 0;        /* Unused*/
-       req.os_type = 0x10;     /* Linux */
+       req.os_type = GDMA_OS_TYPE_LINUX;
        req.os_ver_major = LINUX_VERSION_MAJOR;
        req.os_ver_minor = LINUX_VERSION_PATCHLEVEL;
        req.os_ver_build = LINUX_VERSION_SUBLEVEL;

  reply	other threads:[~2021-11-01  6:07 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-30  0:54 [PATCH net-next 0/4] net: mana: some misc patches Dexuan Cui
2021-10-30  0:54 ` [PATCH net-next 1/4] net: mana: Fix the netdev_err()'s vPort argument in mana_init_port() Dexuan Cui
2021-10-30 15:30   ` Haiyang Zhang
2021-10-30 20:07   ` Stephen Hemminger
2021-11-01  5:59     ` Dexuan Cui
2021-10-30  0:54 ` [PATCH net-next 2/4] net: mana: Report OS info to the PF driver Dexuan Cui
2021-10-30 15:35   ` Haiyang Zhang
2021-11-01  6:07     ` Dexuan Cui [this message]
2021-10-30  0:54 ` [PATCH net-next 3/4] net: mana: Improve the HWC error handling Dexuan Cui
2021-10-30 15:36   ` Haiyang Zhang
2021-10-30  0:54 ` [PATCH net-next 4/4] net: mana: Support hibernation and kexec Dexuan Cui
2021-10-30 15:54   ` Haiyang Zhang
2021-11-01  7:03     ` Dexuan Cui
2021-11-01 15:12       ` Haiyang Zhang
2021-11-01 16:41         ` Dexuan Cui
2021-11-01 13:30 ` [PATCH net-next 0/4] net: mana: some misc patches patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BYAPR21MB127031948D2C6E22F8EC805ABF8A9@BYAPR21MB1270.namprd21.prod.outlook.com \
    --to=decui@microsoft.com \
    --cc=davem@davemloft.net \
    --cc=gustavoars@kernel.org \
    --cc=haiyangz@microsoft.com \
    --cc=kuba@kernel.org \
    --cc=kys@microsoft.com \
    --cc=linux-hyperv@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olaf@aepfle.de \
    --cc=paulros@microsoft.com \
    --cc=shacharr@microsoft.com \
    --cc=stephen@networkplumber.org \
    --cc=vkuznets@redhat.com \
    --cc=wei.liu@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).