mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Richard Gooch <rgooch@ras.ucalgary.ca>
To: Taral <taral@taral.net>
Cc: linux-kernel@vger.kernel.org
Subject: Re: DEVFS_FL_AUTO_DEVNUM on block devices
Date: Tue, 4 Sep 2001 14:13:34 -0600	[thread overview]
Message-ID: <200109042013.f84KDYD08203@vindaloo.ras.ucalgary.ca> (raw)
In-Reply-To: <20010904144605.A5496@taral.net>
In-Reply-To: <20010904144605.A5496@taral.net>

taral@taral.net writes:
> 
> --HlL+5n6rz5pIUxbD
> Content-Type: text/plain; charset=us-ascii
> Content-Disposition: inline
> Content-Transfer-Encoding: quoted-printable

Please fix your mailer to not send this junk.

> I'm trying to write a device driver that dynamically creates block
> devices (kind of like loop does). I'd like to use DEVFS_FL_AUTO_DEVNUM,
> but it looks like devfs doesn't initialize the block queues in any
> useful way. Does anyone have any code that I can use? If so, Cc: me on
> replies. Thanks!

Devfs isn't supposed to manage your block queues. That's not what it's
designed for. Devfs is just a way of managing your device nodes.

Block queue management can be done by the "generic" block I/O layer
(or you can write your own management code, but that's not
practical). This layer requires that you have a major number for your
driver, so that certain information can be shoved into some static
arrays (yes, it's butt-ugly, and it will change in 2.5).

You can use the devfs_alloc_major() function to grab a major number
that won't conflict with another driver. Then use that major when
calling devfs_register().

				Regards,

					Richard....
Permanent: rgooch@atnf.csiro.au
Current:   rgooch@ras.ucalgary.ca

  reply	other threads:[~2001-09-04 20:13 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-09-04 19:46 Taral
2001-09-04 20:13 ` Richard Gooch [this message]
2001-09-04 20:24   ` Taral
2001-09-04 20:35   ` Richard Gooch

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=200109042013.f84KDYD08203@vindaloo.ras.ucalgary.ca \
    --to=rgooch@ras.ucalgary.ca \
    --cc=linux-kernel@vger.kernel.org \
    --cc=taral@taral.net \
    /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

all inboxes | Powered by JetHome®