linux-rdma.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH rdma-next 00/14] Refactor ib_uverbs_write path
@ 2018-02-14 12:38 Leon Romanovsky
       [not found] ` <20180214123844.30321-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
  0 siblings, 1 reply; 32+ messages in thread
From: Leon Romanovsky @ 2018-02-14 12:38 UTC (permalink / raw)
  To: Doug Ledford, Jason Gunthorpe
  Cc: Leon Romanovsky, RDMA mailing list, Matan Barak, Noa Osherovich

Hi,

This series comes as an outcome of [1] which was sent to rdma-rc
and it should be applied on top of that patch.

During review process of that patch, we realized that the
ib_uverbs_write() has number of flaws and this series
tries to fix them:
1. Localize all processing and verification code in specific functions.
2. Fix the command mask insufficient checks.
3. Simplify code to allow drop uverbs_ex_mask and in the future we
   will drop uverbs_mask too.
4. Fix differences in error codes.

Thanks

[1] https://marc.info/?l=linux-rdma&m=151851719021404&w=2

Leon Romanovsky (14):
  RDMA/uverbs: Convert command mask validity check function to be bool
  RDMA/uverbs: Update sizeof users
  RDMA/uverbs: Refactor flags checks and update return value
  RDMA/uverbs: Fail as early as possible if not enough header data was
    provided
  RDMA/uverbs: Return not supported error code for unsupported commands
  RDMA/uverbs: Unify return values of not supported command
  RDMA/uverbs: Refactor command header processing
  RDMA/uverbs: Properly check command supported mask
  RDMA/uverbs: Move uncontext check before SRCU read lock
  RDMa/uverbs: Copy ex_hdr outside of SRCU read lock
  RDMA/uverbs: Refactor the header validation logic
  RDMA/verbs: Return proper error code for not supported system call
  RDMA/verbs: Check existence of function prior to accessing it
  RDMA/verbs: Drop uverbs_ex_mask

 drivers/infiniband/core/core_priv.h   |   3 +
 drivers/infiniband/core/uverbs_cmd.c  |  21 ++++
 drivers/infiniband/core/uverbs_main.c | 219 ++++++++++++++++------------------
 drivers/infiniband/core/verbs.c       |  46 +++----
 drivers/infiniband/hw/mlx4/main.c     |  18 ---
 drivers/infiniband/hw/mlx5/main.c     |  15 ---
 include/rdma/ib_verbs.h               |   1 -
 7 files changed, 150 insertions(+), 173 deletions(-)

--
2.16.1

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 32+ messages in thread

end of thread, other threads:[~2018-02-16 17:09 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-14 12:38 [PATCH rdma-next 00/14] Refactor ib_uverbs_write path Leon Romanovsky
     [not found] ` <20180214123844.30321-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-14 12:38   ` [PATCH rdma-next 01/14] RDMA/uverbs: Convert command mask validity check function to be bool Leon Romanovsky
     [not found]     ` <20180214123844.30321-2-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-14 16:26       ` Dennis Dalessandro
2018-02-14 23:41       ` Jason Gunthorpe
     [not found]         ` <20180214234141.GC1718-uk2M96/98Pc@public.gmane.org>
2018-02-15 14:27           ` Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 02/14] RDMA/uverbs: Update sizeof users Leon Romanovsky
     [not found]     ` <20180214123844.30321-3-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-14 16:27       ` Dennis Dalessandro
2018-02-14 12:38   ` [PATCH rdma-next 03/14] RDMA/uverbs: Refactor flags checks and update return value Leon Romanovsky
     [not found]     ` <20180214123844.30321-4-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-14 23:40       ` Jason Gunthorpe
2018-02-14 12:38   ` [PATCH rdma-next 04/14] RDMA/uverbs: Fail as early as possible if not enough header data was provided Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 05/14] RDMA/uverbs: Return not supported error code for unsupported commands Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 06/14] RDMA/uverbs: Unify return values of not supported command Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 07/14] RDMA/uverbs: Refactor command header processing Leon Romanovsky
     [not found]     ` <20180214123844.30321-8-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-14 23:49       ` Jason Gunthorpe
     [not found]         ` <20180214234951.GF1718-uk2M96/98Pc@public.gmane.org>
2018-02-15 13:51           ` Leon Romanovsky
     [not found]             ` <20180215135120.GG2197-U/DQcQFIOTAAJjI8aNfphQ@public.gmane.org>
2018-02-15 16:23               ` Jason Gunthorpe
2018-02-14 12:38   ` [PATCH rdma-next 08/14] RDMA/uverbs: Properly check command supported mask Leon Romanovsky
     [not found]     ` <20180214123844.30321-9-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-14 23:47       ` Jason Gunthorpe
     [not found]         ` <20180214234714.GE1718-uk2M96/98Pc@public.gmane.org>
2018-02-15 13:56           ` Leon Romanovsky
     [not found]             ` <20180215135628.GH2197-U/DQcQFIOTAAJjI8aNfphQ@public.gmane.org>
2018-02-15 16:26               ` Jason Gunthorpe
     [not found]                 ` <20180215162603.GB18416-uk2M96/98Pc@public.gmane.org>
2018-02-16  7:31                   ` Leon Romanovsky
     [not found]                     ` <20180216073147.GL2197-U/DQcQFIOTAAJjI8aNfphQ@public.gmane.org>
2018-02-16 15:50                       ` Jason Gunthorpe
2018-02-14 12:38   ` [PATCH rdma-next 09/14] RDMA/uverbs: Move uncontext check before SRCU read lock Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 10/14] RDMa/uverbs: Copy ex_hdr outside of " Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 11/14] RDMA/uverbs: Refactor the header validation logic Leon Romanovsky
     [not found]     ` <20180214123844.30321-12-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-14 23:46       ` Jason Gunthorpe
     [not found]         ` <20180214234635.GD1718-uk2M96/98Pc@public.gmane.org>
2018-02-15 14:26           ` Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 12/14] RDMA/verbs: Return proper error code for not supported system call Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 13/14] RDMA/verbs: Check existence of function prior to accessing it Leon Romanovsky
     [not found]     ` <20180214123844.30321-14-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-02-16 16:19       ` Jason Gunthorpe
     [not found]         ` <20180216161956.GA29023-uk2M96/98Pc@public.gmane.org>
2018-02-16 17:09           ` Leon Romanovsky
2018-02-14 12:38   ` [PATCH rdma-next 14/14] RDMA/verbs: Drop uverbs_ex_mask Leon Romanovsky

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).