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:	Wed, 24 Aug 2011 18:23:20 +0200
From:	Arnd Bergmann <arnd@...db.de>
To:	dedekind1@...il.com
Cc:	david.wagner@...e-electrons.com,
	"linux-mtd" <linux-mtd@...ts.infradead.org>,
	"linux-embedded" <linux-embedded@...r.kernel.org>,
	lkml <linux-kernel@...r.kernel.org>,
	Tim Bird <tim.bird@...sony.com>,
	David Woodhouse <dwmw2@...radead.org>
Subject: Re: [PATCHv3] UBI: new module ubiblk: block layer on top of UBI

On Monday 22 August 2011, Artem Bityutskiy wrote:
> 
> On Wed, 2011-08-17 at 15:17 +0200, david.wagner@...e-electrons.com
> wrote:
> > Questions:
> > ==========
> > I wasn't sure what magic ioctl number to use, so I settled to use the same one
> > as a part of UBI: 'O', which was so far only used by UBI but on a higher range
> > and leaving some room for UBI to add ioctls (for nw, it uses 'O'/0x00-0x06 and
> > ubiblk uses 'O'/0x10-0x11).  Is it ok or should ubiblk use a different
> > number/range ?
> 
> I think this is OK to share them between UBI and ubiblk, as long as this
> is documented.

That should  be fine, yes. I would probably put them into the same
header file though if they are in the same number space even
when you use them on distinct devices.

It does feel a little clumsy to have yet another character device
to manage the block devices though. What do you think about one
of these alternative approaches:

* When the ubi block device driver gets loaded, create one block
  device per volume and let the user deal with permissions for
  the devices instead of having to first create them as well.
* Use the existing UBI control device for the block devices as
  well and just add two more ioctls to create the devices.
  You can add a logical bus_type for this so that the ubi block
  driver gets automatically loaded matched with the device when
  one is created using the control device.

	Arnd
--
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