lkml.org 
[lkml]   [2020]   [May]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH 3/8] qaic: Create char dev
On Thu, May 14, 2020 at 08:07:41AM -0600, Jeffrey Hugo wrote:
> /* Copyright (c) 2019-2020, The Linux Foundation. All rights reserved. */
>
> +#include <linux/cdev.h>
> +#include <linux/idr.h>
> +#include <linux/list.h>
> +#include <linux/kref.h>
> +#include <linux/mhi.h>
> #include <linux/module.h>
> #include <linux/msi.h>
> +#include <linux/mutex.h>
> #include <linux/pci.h>
> #include <linux/pci_ids.h>
>
> @@ -13,9 +19,242 @@
> #define PCI_DEV_AIC100 0xa100
>
> #define QAIC_NAME "Qualcomm Cloud AI 100"
> +#define QAIC_MAX_MINORS 256

Why have a max?

Why not just use a misc device so you make the logic a lot simple, no
class or chardev logic to mess with at all.

thanks,

greg k-h

\
 
 \ /
  Last update: 2020-05-14 16:12    [W:0.161 / U:0.492 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site