lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 06 Aug 2009 02:01:56 +0900
From:	Tejun Heo <tj@...nel.org>
To:	Greg KH <greg@...ah.com>
CC:	Al Viro <viro@....linux.org.uk>, Takashi Iwai <tiwai@...e.de>,
	Linux Kernel <linux-kernel@...r.kernel.org>,
	cguthrie@...driva.org
Subject: Re: [PATCH 1/2] chrdev: implement __[un]register_chrdev()

Greg KH wrote:
> On Thu, Aug 06, 2009 at 01:30:30AM +0900, Tejun Heo wrote:
>> Greg KH wrote:
>>> On Wed, Aug 05, 2009 at 03:35:42PM +0900, Tejun Heo wrote:
>>>> [un]register_chrdev() assume minor range 0-255.  This patch adds __
>>>> prefixed versions which take @minorbase and @count explicitly.
>>> What's the difference between this and the existing
>>> register_chrdev_region() function?  Why doesn't that work for you?
>>>
>>> What am I missing here?
>> The function names in char_dev.c are quite confusing.
> 
> That's an understatement :)

Yeah, it sure is.  It should have used a different verb at the very
least.

>> register_chrdev_region() only registers chrdev region.
>> register_chrdev() registers chrdev region and creates a cdev for the
>> region.  :-)
> 
> Yes, but you can use register_chrdev_region() and then call cdev_alloc()
> for the specific cdevs you need, right?  It's not the prettiest, but it
> should work.

Yeap, I can.  That's basically what register_chrdev() is.  If it had a
better name, adding a new variant would have been much nicer.  Having
the helper makes sense tho.  Names too confusing?

Thanks.

-- 
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ