All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
To: ajit.khaparde@broadcom.com
Cc: andrew.gospodarek@broadcom.com, davem@davemloft.net,
	edumazet@google.com, jgg@ziepe.ca, kuba@kernel.org,
	leon@kernel.org, linux-kernel@vger.kernel.org,
	linux-rdma@vger.kernel.org, michael.chan@broadcom.com,
	netdev@vger.kernel.org, pabeni@redhat.com,
	selvin.xavier@broadcom.com, gregkh@linuxfoundation.org
Subject: [PATCH net-next v10 0/8] Add Auxiliary driver support
Date: Wed,  1 Feb 2023 12:44:52 -0800	[thread overview]
Message-ID: <20230201204500.19420-1-ajit.khaparde@broadcom.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 3968 bytes --]

Add auxiliary device driver for Broadcom devices.
The bnxt_en driver will register and initialize an aux device
if RDMA is enabled in the underlying device.
The bnxt_re driver will then probe and initialize the
RoCE interfaces with the infiniband stack.

We got rid of the bnxt_en_ops which the bnxt_re driver used to
communicate with bnxt_en.
Similarly  We have tried to clean up most of the bnxt_ulp_ops.
In most of the cases we used the functions and entry points provided
by the auxiliary bus driver framework.
And now these are the minimal functions needed to support the functionality.

We will try to work on getting rid of the remaining if we find any
other viable option in future.

v1->v2:
- Incorporated review comments including usage of ulp_id &
  complex function indirections.
- Used function calls provided by the auxiliary bus interface
  instead of proprietary calls.
- Refactor code to remove ROCE driver's access to bnxt structure.

v2->v3:
- Addressed review comments including cleanup of some unnecessary wrappers
- Fixed warnings seen during cross compilation

v3->v4:
- Cleaned up bnxt_ulp.c and bnxt_ulp.h further
- Removed some more dead code
- Sending the patchset as a standalone series

v4->v5:
- Removed the SRIOV config callback which bnxt_en driver was calling into
  bnxt_re driver.
- Removed excessive checks for rdev and other pointers.

v5->v6:
- Removed excessive checks for dev and other pointers
- Remove runtime interrupt vector allocation. bnxt_en preallocates
interrupt vectors for bnxt_re to use.

v6->v7:
- Removed incorrect usage of inline
- Updated Kconfig to select AUXILIARY BUS support
- Addressed various comments including removal of unnecessary forward
  declaration, using static functions where possible, unnecessary jump,
  cleanup logic, etc..
- Added Leon's Reviewed-by, to the commit log in the patches, from
  previous version.

v7->v8:
- Addressed various comments to remove unnecessary check for id, removed
  setting pointer to NULL after free, renamed private pointers to avoid
  confusing them with the auxiliary device names and refactored some
  code accordingly.
- Auxiliary device will be released through auxiliary_device_uninit();

v8->v9:
- Fixed the cleanup code to use the auxiliary driver release function to
  free allocated memory. This allows the cleanup to be performed once
  the device reference count drops to 0.
- Refactored the code to address the above.

v9->v10:
- Fixed residual comments like useless NULL assignments and variable
  initializations.

Commit message uses Leon's Reviewed-by from earlier version.

Please apply. Thanks.

The following are changes since commit c0b67534c95c537f7a506a06b98e5e85d72e2b7d:
  Merge tag 'cgroup-for-6.2-fixes' in Linus's tree
and are available in the git repository at:
  https://github.com/ajitkhaparde1/linux aux-bus-v10
for you to fetch changes upto 2daf6059f4cf2cd3f5f09e6beb4bba3e3a89b977:
   bnxt_en: Remove runtime interrupt vector allocation

----

Ajit Khaparde (7):
  bnxt_en: Add auxiliary driver support
  RDMA/bnxt_re: Use auxiliary driver interface
  bnxt_en: Remove usage of ulp_id
  bnxt_en: Use direct API instead of indirection
  bnxt_en: Use auxiliary bus calls over proprietary calls
  RDMA/bnxt_re: Remove the sriov config callback
  bnxt_en: Remove runtime interrupt vector allocation

Hongguang Gao (1):
  bnxt_en: Remove struct bnxt access from RoCE driver

 drivers/infiniband/hw/bnxt_re/bnxt_re.h       |  10 +-
 drivers/infiniband/hw/bnxt_re/main.c          | 635 +++++++-----------
 drivers/net/ethernet/broadcom/Kconfig         |   1 +
 drivers/net/ethernet/broadcom/bnxt/bnxt.c     |  10 +-
 drivers/net/ethernet/broadcom/bnxt/bnxt.h     |   8 +
 .../net/ethernet/broadcom/bnxt/bnxt_sriov.c   |   7 +-
 drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c | 475 ++++++-------
 drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.h |  51 +-
 8 files changed, 462 insertions(+), 735 deletions(-)

-- 
2.37.1 (Apple Git-137.1)


[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4218 bytes --]

             reply	other threads:[~2023-02-01 20:45 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-01 20:44 Ajit Khaparde [this message]
2023-02-01 20:44 ` [PATCH net-next v10 1/8] bnxt_en: Add auxiliary driver support Ajit Khaparde
2023-02-02  1:34   ` kernel test robot
2023-02-01 20:44 ` [PATCH net-next v10 2/8] RDMA/bnxt_re: Use auxiliary driver interface Ajit Khaparde
2023-02-01 20:44 ` [PATCH net-next v10 3/8] bnxt_en: Remove usage of ulp_id Ajit Khaparde
2023-02-01 20:44 ` [PATCH net-next v10 4/8] bnxt_en: Use direct API instead of indirection Ajit Khaparde
2023-02-01 20:44 ` [PATCH net-next v10 5/8] bnxt_en: Use auxiliary bus calls over proprietary calls Ajit Khaparde
2023-02-01 20:44 ` [PATCH net-next v10 6/8] bnxt_en: Remove struct bnxt access from RoCE driver Ajit Khaparde
2023-02-01 20:44 ` [PATCH net-next v10 7/8] RDMA/bnxt_re: Remove the sriov config callback Ajit Khaparde
2023-02-01 20:45 ` [PATCH net-next v10 8/8] bnxt_en: Remove runtime interrupt vector allocation Ajit Khaparde

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=20230201204500.19420-1-ajit.khaparde@broadcom.com \
    --to=ajit.khaparde@broadcom.com \
    --cc=andrew.gospodarek@broadcom.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jgg@ziepe.ca \
    --cc=kuba@kernel.org \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=michael.chan@broadcom.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=selvin.xavier@broadcom.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.