lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Yk8M5C/7YO7F9sk2@unreal>
Date:   Thu, 7 Apr 2022 19:10:12 +0300
From:   Leon Romanovsky <leon@...nel.org>
To:     Jason Gunthorpe <jgg@...dia.com>
Cc:     Bart Van Assche <bvanassche@....org>,
        Ariel Elior <aelior@...vell.com>,
        Anna Schumaker <anna@...nel.org>, Jens Axboe <axboe@...com>,
        Christian Benvenuti <benve@...co.com>,
        Potnuri Bharat Teja <bharat@...lsio.com>,
        Bernard Metzler <bmt@...ich.ibm.com>,
        Chuck Lever <chuck.lever@...cle.com>,
        "David S. Miller" <davem@...emloft.net>,
        Dennis Dalessandro <dennis.dalessandro@...nelisnetworks.com>,
        Christoph Hellwig <hch@....de>,
        Keith Busch <kbusch@...nel.org>,
        Chaitanya Kulkarni <kch@...dia.com>,
        Jakub Kicinski <kuba@...nel.org>, linux-cifs@...r.kernel.org,
        linux-nfs@...r.kernel.org, linux-nvme@...ts.infradead.org,
        linux-rdma@...r.kernel.org, Max Gurtovoy <mgurtovoy@...dia.com>,
        Mike Marciniszyn <mike.marciniszyn@...nelisnetworks.com>,
        Michal Kalderon <mkalderon@...vell.com>,
        Mustafa Ismail <mustafa.ismail@...el.com>,
        Nelson Escobar <neescoba@...co.com>, netdev@...r.kernel.org,
        Paolo Abeni <pabeni@...hat.com>, rds-devel@....oracle.com,
        Sagi Grimberg <sagi@...mberg.me>,
        samba-technical@...ts.samba.org,
        Santosh Shilimkar <santosh.shilimkar@...cle.com>,
        Selvin Xavier <selvin.xavier@...adcom.com>,
        Steve French <sfrench@...ba.org>,
        Shiraz Saleem <shiraz.saleem@...el.com>,
        target-devel@...r.kernel.org,
        Trond Myklebust <trond.myklebust@...merspace.com>,
        Yishai Hadas <yishaih@...dia.com>,
        Zhu Yanjun <zyjzyj2000@...il.com>
Subject: Re: [PATCH v2] RDMA: Split kernel-only global device caps from
 uverbs device caps

On Thu, Apr 07, 2022 at 12:52:44PM -0300, Jason Gunthorpe wrote:
> On Wed, Apr 06, 2022 at 12:57:31PM -0700, Bart Van Assche wrote:
> > On 4/6/22 12:27, Jason Gunthorpe wrote:
> > > +enum ib_kernel_cap_flags {
> > > +	/*
> > > +	 * This device supports a per-device lkey or stag that can be
> > > +	 * used without performing a memory registration for the local
> > > +	 * memory.  Note that ULPs should never check this flag, but
> > > +	 * instead of use the local_dma_lkey flag in the ib_pd structure,
> > > +	 * which will always contain a usable lkey.
> > > +	 */
> > > +	IBK_LOCAL_DMA_LKEY = 1 << 0,
> > > +	/* IB_QP_CREATE_INTEGRITY_EN is supported to implement T10-PI */
> > > +	IBK_INTEGRITY_HANDOVER = 1 << 1,
> > > +	/* IB_ACCESS_ON_DEMAND is supported during reg_user_mr() */
> > > +	IBK_ON_DEMAND_PAGING = 1 << 2,
> > > +	/* IB_MR_TYPE_SG_GAPS is supported */
> > > +	IBK_SG_GAPS_REG = 1 << 3,
> > > +	/* Driver supports RDMA_NLDEV_CMD_DELLINK */
> > > +	IBK_ALLOW_USER_UNREG = 1 << 4,
> > > +
> > > +	/* ipoib will use IB_QP_CREATE_BLOCK_MULTICAST_LOOPBACK */
> > > +	IBK_BLOCK_MULTICAST_LOOPBACK = 1 << 5,
> > > +	/* iopib will use IB_QP_CREATE_IPOIB_UD_LSO for its QPs */
> > > +	IBK_UD_TSO = 1 << 6,
> > > +	/* iopib will use the device ops:
> > > +	 *   get_vf_config
> > > +	 *   get_vf_guid
> > > +	 *   get_vf_stats
> > > +	 *   set_vf_guid
> > > +	 *   set_vf_link_state
> > > +	 */
> > > +	IBK_VIRTUAL_FUNCTION = 1 << 7,
> > > +	/* ipoib will use IB_QP_CREATE_NETDEV_USE for its QPs */
> > > +	IBK_RDMA_NETDEV_OPA = 1 << 8,
> > > +};
> > 
> > Has it been considered to use the kernel-doc syntax? This means moving all
> > comments above "enum ib_kernel_cap_flags {".
> 
> TBH I'm not a huge fan of kdoc for how wordy it is:
> 
>  /** @IBK_RDMA_NETDEV_OPA: ipoib will use IB_QP_CREATE_NETDEV_USE for its QPs */
>  IBK_RDMA_NETDEV_OPA = 1 << 8,
> 
> Is the shortest format and still a bit awkward.
> 
> Given that we don't have a proper kdoc for rdma I haven't been putting
> much energy there.
> 
> If someone came with patches to make a kdoc chapter and start to
> organize it nicely I could see enforcing kdoc format..

Do you see any value in kdoc?

I personally didn't find it useful for kernel at all.

> 
> Jason

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ