public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Avi Kivity <avi@qumranet.com>
To: Jan Engelhardt <jengelh@linux01.gwdg.de>
Cc: "Mathiasen, Torben" <Torben.Mathiasen@hp.com>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	kvm-devel <kvm-devel@lists.sourceforge.net>
Subject: Re: minor device number request for /dev/kvm (kernel-based virtual machine)
Date: Thu, 01 Mar 2007 15:05:06 +0200	[thread overview]
Message-ID: <45E6CF82.9090001@qumranet.com> (raw)
In-Reply-To: <Pine.LNX.4.61.0703011401370.23355@yvahk01.tjqt.qr>

Jan Engelhardt wrote:
> On Mar 1 2007 13:58, Avi Kivity wrote:
>   
>> fs/char_dev.c:
>>     
>>> int register_chrdev(unsigned int major, const char *name,
>>>            const struct file_operations *fops)
>>> {
>>> struct char_device_struct *cd;
>>> struct cdev *cdev;
>>> char *s;
>>> int err = -ENOMEM;
>>>
>>> cd = __register_chrdev_region(major, 0, 256, name);
>>>       
>> So misc minor numbers under 256 are not supported.
>>
>> What's the way out?  Increase the region size?  I don't know if that's safe.
>>     
>
> If it does not increase memory usage, then possibly:
>
>   __register_chrdev_region(major, 0, (~0U) & MINORMASK, name);
>                                   or (1<<MINORMASK)-1 if that's more clear
>
>   

I'm more worried about something in the chardev bowels not supporting 
 >8bit minors well.


-- 
error compiling committee.c: too many arguments to function

  reply	other threads:[~2007-03-01 13:05 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <45975F61.4070506@qumranet.com>
     [not found] ` <93C4769E3BED6B42B7203BD6F065654C08C5D6D3@dmoexc01.emea.cpqcorp.net>
2007-03-01 11:58   ` minor device number request for /dev/kvm (kernel-based virtual machine) Avi Kivity
     [not found]     ` <45E6BFD0.1060003-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-03-01 13:03       ` Jan Engelhardt
2007-03-01 13:05         ` Avi Kivity [this message]
2007-03-01 14:09           ` Mathiasen, Torben

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=45E6CF82.9090001@qumranet.com \
    --to=avi@qumranet.com \
    --cc=Torben.Mathiasen@hp.com \
    --cc=jengelh@linux01.gwdg.de \
    --cc=kvm-devel@lists.sourceforge.net \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox