On Wed, Jul 08, 2020 at 02:05:54PM +0300, Leon Romanovsky wrote: > From: Leon Romanovsky <leonro@xxxxxxxxxxxx> > > The automatic object lifetime model allows us to change write() interface > to have same logic as ioctl() path. Update the create/alloc functions to be > in the following format, so code flow will be the same: > * Allocate objects > * Initialize them > * Call to the drivers, this is last step that is allowed to fail > * Finalize object > * Return response and allow to core code to handle abort/commit > respectively. > > Signed-off-by: Leon Romanovsky <leonro@xxxxxxxxxxxx> > --- > drivers/infiniband/core/uverbs_cmd.c | 299 ++++++++------------------- > 1 file changed, 90 insertions(+), 209 deletions(-) Please drop this patch, I came to realization that create_cq() can be simplfied much more, I'll send v1 after will get results from the verification. Thanks