Linux RDMA and InfiniBand development
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Yanze Zhang" <zhang.yanze@zte.com.cn>
Cc: linux-rdma@vger.kernel.org
Subject: Re: [PATCH rdma v10 1/7] RDMA/zrdma: Add build infrastructure and module skeleton
Date: Thu, 03 Dec 2026 13:19:02 +0000	[thread overview]
Message-ID: <sashiko-outbox-247842@kernel.org> (raw)
In-Reply-To: <20261203124928.48716-2-zhang.yanze@zte.com.cn>

Thank you for your contribution! Sashiko AI review found 4 potential
issues to consider:
- [High] RDMA/zrdma: auxiliary driver binds to nonexistent
  dinghai10e.rdma_aux device
- [High] RDMA/zrdma: non-functional verbs ops and unused resources fail
  v2 review
- [Low] RDMA/zrdma: commit message omits RDMA_DRIVER_ZRDMA UAPI addition
- [Low] RDMA/zrdma: UAPI ABI header zrdma_abi.h diverges from *-abi.h
  convention
--

commit 3691a422452232635cbbadb8369d21180b5db92d
Author: Yanze Zhang <zhang.yanze@zte.com.cn>

RDMA/zrdma: Add build infrastructure and module skeleton

This commit adds the MAINTAINERS entry, Kconfig, Makefile, RDMA driver
ID, and a minimal auxiliary driver skeleton for the ZTE DingHai RDMA
driver.

> diff --git a/MAINTAINERS b/MAINTAINERS
> index 222b7fc2c3aab..de75c93ca3a86 100644
> --- a/MAINTAINERS
> +++ b/MAINTAINERS
> @@ -31025,6 +31025,13 @@ L:	netdev@vger.kernel.org
>  S:	Maintained
>  F:	drivers/net/ethernet/zte/
>  
> +ZTE DINGHAI ZRDMA DRIVER
> +M:	Yanze Zhang <zhang.yanze@zte.com.cn>
> +L:	linux-rdma@vger.kernel.org
> +S:	Supported
> +F:	drivers/infiniband/hw/zrdma/
> +F:	include/uapi/rdma/zrdma_abi.h

[Severity: Low]
Should this UAPI header be named include/uapi/rdma/zrdma-abi.h to match
the rest of the RDMA subsystem?

Every existing provider ABI header under include/uapi/rdma/ uses a
hyphenated -abi.h suffix (including bnxt_re-abi.h and
vmw_pvrdma-abi.h).  Because this header is exported to userspace (added
in commit "RDMA/zrdma: Add core data structures and ABI definitions"),
its filename becomes permanent once merged.

[ ... ]

> diff --git a/drivers/infiniband/hw/zrdma/zrdma_main.c b/drivers/infiniband/hw/zrdma/zrdma_main.c
> new file mode 100644
> index 0000000000000..da42494a43c69
> --- /dev/null
> +++ b/drivers/infiniband/hw/zrdma/zrdma_main.c

[ ... ]

> +/* The name has to match the auxiliary device that the DingHai PF
> + * driver creates.
> + */
> +static const struct auxiliary_device_id zxdh_auxiliary_id_table[] = {
> +	{
> +		.name = "dinghai10e.rdma_aux",
> +	},
> +	{},
> +};

[Severity: High]
Does anything in the tree actually create the "dinghai10e.rdma_aux"
auxiliary device?

In drivers/net/ethernet/zte/dinghai/en_pf.c, zxdh_pf_probe() returns
immediately after devlink_register(devlink) without registering any
auxiliary device, and the DingHai PF driver does not use AUXILIARY_BUS
at all.

None of the later patches in this series add auxiliary device creation
to dinghai10e either, leaving zxdh_probe() and zxdh_remove()
unreachable and the driver unable to bind on DingHai hardware.

[ ... ]

> diff --git a/include/uapi/rdma/ib_user_ioctl_verbs.h b/include/uapi/rdma/ib_user_ioctl_verbs.h
> index ca8b8b8d28f24..676e784fe5418 100644
> --- a/include/uapi/rdma/ib_user_ioctl_verbs.h
> +++ b/include/uapi/rdma/ib_user_ioctl_verbs.h
> @@ -258,6 +258,7 @@ enum rdma_driver_id {
>  	RDMA_DRIVER_ERDMA,
>  	RDMA_DRIVER_MANA,
>  	RDMA_DRIVER_IONIC,
> +	RDMA_DRIVER_ZRDMA,
>  };

[Severity: High]
As reported by Leon Romanovsky on v2 [1], should this series be
committing a permanent RDMA_DRIVER_ZRDMA UAPI driver ID when the driver
is still not functional and still carries unused definitions and
resources?

Even at the end of the series, zxdh_dev_ops in zrdma_verbs.c omits all
CQ, QP, MR, AH, SRQ, and post/poll verbs.  12 of the 17 ops checked by
ib_device_check_mandatory() are NULL, so ib_register_device() sets
kverbs_provider false and neither kernel nor userspace can run RDMA.

In addition, unused code remains at the end of the series:
zxdh_set_hw_rsrc() and zxdh_initialize_hw_rsrc() allocate qp_cnt_8k_idxs
and eight resource bitmaps that are never used (only allocated_pds is
used), and enum zxdh_mmap_flag defines unused ZXDH_MMAP_PFN and
ZXDH_MMAP_HMC values.

[Severity: Low]
The commit message does not mention adding RDMA_DRIVER_ZRDMA to the
public UAPI header include/uapi/rdma/ib_user_ioctl_verbs.h.  Should
this UAPI addition be documented in the changelog, or moved to the
verbs patch that consumes it?

[1] https://lore.kernel.org/r/20260705112915.GB15188@unreal

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261203124928.48716-1-zhang.yanze@zte.com.cn?part=1

  reply	other threads:[~2026-12-03 13:19 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-03 12:49 [PATCH rdma v10 0/7] Add ZTE DingHai Ethernet Protocol Driver for RDMA Yanze Zhang
2026-12-03 12:49 ` [PATCH rdma v10 1/7] RDMA/zrdma: Add build infrastructure and module skeleton Yanze Zhang
2026-12-03 13:19   ` sashiko-bot [this message]
2026-12-03 12:49 ` [PATCH rdma v10 2/7] RDMA/zrdma: Add core data structures and ABI definitions Yanze Zhang
2026-12-03 13:21   ` sashiko-bot
2026-12-03 12:49 ` [PATCH rdma v10 3/7] RDMA/zrdma: Add internal headers and hardware register definitions Yanze Zhang
2026-12-03 13:17   ` sashiko-bot
2026-12-03 12:49 ` [PATCH rdma v10 4/7] RDMA/zrdma: Add hardware resource initialization and verbs skeleton Yanze Zhang
2026-12-03 13:20   ` sashiko-bot
2026-12-03 12:49 ` [PATCH rdma v10 5/7] RDMA/zrdma: Implement device and port query operations Yanze Zhang
2026-12-03 13:32   ` sashiko-bot
2026-12-03 12:49 ` [PATCH rdma v10 6/7] RDMA/zrdma: Add device probe and remove logic Yanze Zhang
2026-12-03 13:28   ` sashiko-bot
2026-12-03 12:49 ` [PATCH rdma v10 7/7] RDMA/zrdma: Implement context, PD, and mmap operations Yanze Zhang

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=sashiko-outbox-247842@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    --cc=zhang.yanze@zte.com.cn \
    /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