From: Andrew Lunn <andrew@lunn.ch>
To: Dexuan Cui <decui@microsoft.com>
Cc: davem@davemloft.net, kuba@kernel.org, kys@microsoft.com,
haiyangz@microsoft.com, sthemmin@microsoft.com,
wei.liu@kernel.org, liuwe@microsoft.com, netdev@vger.kernel.org,
leon@kernel.org, bernd@petrovitsch.priv.at,
rdunlap@infradead.org, shacharr@microsoft.com,
linux-kernel@vger.kernel.org, linux-hyperv@vger.kernel.org
Subject: Re: [PATCH v4 net-next] net: mana: Add a driver for Microsoft Azure Network Adapter (MANA)
Date: Mon, 12 Apr 2021 14:15:57 +0200 [thread overview]
Message-ID: <YHQ5/fJyvkTHzBqA@lunn.ch> (raw)
In-Reply-To: <20210412023455.45594-1-decui@microsoft.com>
> +static inline bool is_gdma_msg(const void *req)
> +{
> + struct gdma_req_hdr *hdr = (struct gdma_req_hdr *)req;
> +
> + if (hdr->req.hdr_type == GDMA_STANDARD_HEADER_TYPE &&
> + hdr->resp.hdr_type == GDMA_STANDARD_HEADER_TYPE &&
> + hdr->req.msg_size >= sizeof(struct gdma_req_hdr) &&
> + hdr->resp.msg_size >= sizeof(struct gdma_resp_hdr) &&
> + hdr->req.msg_type != 0 && hdr->resp.msg_type != 0)
> + return true;
> +
> + return false;
> +}
> +
> +static inline bool is_gdma_msg_len(const u32 req_len, const u32 resp_len,
> + const void *req)
> +{
> + struct gdma_req_hdr *hdr = (struct gdma_req_hdr *)req;
> +
> + if (req_len >= sizeof(struct gdma_req_hdr) &&
> + resp_len >= sizeof(struct gdma_resp_hdr) &&
> + req_len >= hdr->req.msg_size && resp_len >= hdr->resp.msg_size &&
> + is_gdma_msg(req)) {
> + return true;
> + }
> +
> + return false;
> +}
You missed adding the mana_ prefix here. There might be others.
> +#define CQE_POLLING_BUFFER 512
> +struct ana_eq {
> + struct gdma_queue *eq;
> + struct gdma_comp cqe_poll[CQE_POLLING_BUFFER];
> +};
> +static int ana_poll(struct napi_struct *napi, int budget)
> +{
You also have a few cases of ana_, not mana_. There might be others.
Andrew
next prev parent reply other threads:[~2021-04-12 12:16 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20210412023455.45594-1-decui@microsoft.com>
2021-04-12 7:45 ` [PATCH v4 net-next] net: mana: Add a driver for Microsoft Azure Network Adapter (MANA) Leon Romanovsky
2021-04-12 8:35 ` Dexuan Cui
2021-04-12 8:52 ` Leon Romanovsky
2021-04-12 12:10 ` Andrew Lunn
2021-04-12 12:15 ` Andrew Lunn [this message]
2021-04-12 14:29 ` Haiyang Zhang
2021-04-12 12:32 ` Andrew Lunn
2021-04-12 14:39 ` Haiyang Zhang
2021-04-12 20:30 ` Dexuan Cui
2021-04-12 18:21 ` Jakub Kicinski
2021-04-12 20:43 ` Dexuan Cui
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=YHQ5/fJyvkTHzBqA@lunn.ch \
--to=andrew@lunn.ch \
--cc=bernd@petrovitsch.priv.at \
--cc=davem@davemloft.net \
--cc=decui@microsoft.com \
--cc=haiyangz@microsoft.com \
--cc=kuba@kernel.org \
--cc=kys@microsoft.com \
--cc=leon@kernel.org \
--cc=linux-hyperv@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=liuwe@microsoft.com \
--cc=netdev@vger.kernel.org \
--cc=rdunlap@infradead.org \
--cc=shacharr@microsoft.com \
--cc=sthemmin@microsoft.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).