lkml.org 
[lkml]   [2019]   [Feb]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] mei: expand minor range when registering chrdev region
On Tue, Feb 12, 2019 at 02:02:52PM +0800, Chengguang Xu wrote:
> Actually, total amount of available minor number
> for a single major is MINORMARK + 1. So expand
> minor range when registering chrdev region.
>
> Signed-off-by: Chengguang Xu <cgxu519@gmx.com>
> ---
> drivers/misc/mei/main.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/misc/mei/main.c b/drivers/misc/mei/main.c
> index 87281b3695e6..3df54f1e1a8b 100644
> --- a/drivers/misc/mei/main.c
> +++ b/drivers/misc/mei/main.c
> @@ -869,7 +869,7 @@ static const struct file_operations mei_fops = {
>
> static struct class *mei_class;
> static dev_t mei_devt;
> -#define MEI_MAX_DEVS MINORMASK
> +#define MEI_MAX_DEVS (MINORMASK + 1)

Why is this needed? Have you really run out of that many minor nodes
for this driver?

thanks,

greg k-h

\
 
 \ /
  Last update: 2019-02-12 10:29    [W:0.040 / U:1.256 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site