Re: [Nbd] [PATCH] nbd: Support FUA, FLUSH and ROTATIONAL
- To: Paul Clements <paul.clements@...856...>
- Cc: nbd-general@lists.sourceforge.net
- Subject: Re: [Nbd] [PATCH] nbd: Support FUA, FLUSH and ROTATIONAL
- From: Wouter Verhelst <w@...112...>
- Date: Wed, 3 Aug 2011 14:32:14 +0200
- Message-id: <20110803123214.GA4077@...3...>
- In-reply-to: <CAECXXi5FTpoa4x3ePKyzz933=vqNHLUVCh=sDVuz654TFAd5+g@...18...>
- References: <1306088301-6173-1-git-send-email-alex@...872...> <CAECXXi4quJhSwtM4LAEQGJ_5bVCh=bp13j8-qmbOTqTvVPMyEA@...18...> <20110802212049.GD31470@...3...> <CAECXXi5FTpoa4x3ePKyzz933=vqNHLUVCh=sDVuz654TFAd5+g@...18...>
On Tue, Aug 02, 2011 at 10:36:26PM -0400, Paul Clements wrote:
> On Tue, Aug 2, 2011 at 5:20 PM, Wouter Verhelst <w@...112...> wrote:
> > On Tue, Aug 02, 2011 at 11:58:11AM -0400, Paul Clements wrote:
> >> One question to the general audience: do we need an ioctl for the flag
> >> setting or would a sysfs entry be sufficient? I really would like to
> >> move away from having so many ioctls in nbd. I've started converting
> >> some debug and ioctl stuff to sysfs already...
> >
> > Me, I don't really care either way.
> >
> > I suppose the NBD_DO_IT ioctl will need to remain, since handing an fd
> > through a write in a totally unrelated file is going to be *very* ugly.
>
> Yeah, I have to say, the passing of the socket fd through the ioctl
> was a pretty clever hack by Pavel.
Yeah.
> > Other than that, I guess moving communication between client and server
> > to sysfs entries makes more sense.
>
> And if we could eventually get rid of all ioctls other than NBD_DO_IT,
> then the unusual nature of NBD_DO_IT being a long-lived ioctl would
> not be a problem. Normally, ioctls are locked against each other, but
> you obviously can't do that when one of the ioctls lasts for the life
> of the device. :)
Quite.
> At any rate, check the patches when they come through and let me know
> if they're providing what we need userland-wise.
Will do.
> I think I'll take the approach of trying to provide everything via
> sysfs that is now available via ioctl, and then deprecate the ioctls
> (at some [probably very] future date down the road)...
Sounds like a plan.
--
The volume of a pizza of thickness a and radius z can be described by
the following formula:
pi zz a
Reply to: