RE: [EXTERNAL] Re: [PATCH v4 1/1] misc: mrvl-cn10k-dpi: add Octeon CN10K DPI administrative driver

From: Vamsi Krishna Attunuru
Date: Fri Apr 12 2024 - 02:34:30 EST




> -----Original Message-----
> From: Greg KH <gregkh@xxxxxxxxxxxxxxxxxxx>
> Sent: Thursday, April 11, 2024 6:32 PM
> To: Vamsi Krishna Attunuru <vattunuru@xxxxxxxxxxx>
> Cc: arnd@xxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx
> Subject: [EXTERNAL] Re: [PATCH v4 1/1] misc: mrvl-cn10k-dpi: add Octeon
> CN10K DPI administrative driver
>
> Prioritize security for external emails: Confirm sender and content safety
> before clicking links or opening attachments
>
> ----------------------------------------------------------------------
> On Tue, Mar 12, 2024 at 03:56:57AM -0700, Vamsi Attunuru wrote:
> > --- /dev/null
> > +++ b/include/uapi/misc/mrvl_cn10k_dpi.h
> > @@ -0,0 +1,35 @@
> > +// SPDX-License-Identifier: GPL-2.0
>
> Wrong license for a uapi file, right? Please work with your lawyers to figure
> out the correct one if you have any questions.
>

No concerns in using general licensing for uapi file, will fix in next version.

> > +/* Marvell Octeon CN10K DPI driver
> > + *
> > + * Copyright (C) 2024 Marvell.
> > + *
> > + */
> > +
> > +#ifndef __MRVL_CN10K_DPI_H__
> > +#define __MRVL_CN10K_DPI_H__
> > +
> > +#include <linux/types.h>
> > +
> > +#define DPI_MAX_ENGINES 6
> > +
> > +struct dpi_mps_mrrs_cfg {
> > + u64 mrrs; /* Max read request size */
> > + u64 mps; /* Max packet size */
> > + u64 port; /* Ebus port */
> > +};
> > +
> > +struct dpi_engine_cfg {
> > + u64 fifo_mask; /* FIFO size mask in KBytes */
> > + u64 molr[DPI_MAX_ENGINES];
> > + u64 update_molr; /* '1' to update engine MOLR */
>
> This is not how you create an ioctl, please read the kernel documentation for
> how to do it properly please. (hint, wrong data
> types.)
Sure, will send next version with the fixes( u64 --> __u64). Thanks.

>
> Also, a pointer to the userspace code that is going to use this new api you are
> creating would be apprecaited.
>
> thanks,
>
> greg k-h