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

From: Greg KH
Date: Thu Apr 11 2024 - 09:02:32 EST


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.

> +/* 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.)

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