Re: [PATCH V3 3/5] ublk_drv: add SET_PARAM/GET_PARAM control command

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jul 29, 2022 at 04:22:26PM +0200, Christoph Hellwig wrote:
> On Fri, Jul 29, 2022 at 03:29:52PM +0800, Ming Lei wrote:
> > The parameter passed from userspace is added to one array, and the type is
> > used as index of the array. The following patch will add two parameter
> > types: basic(covers basic queue setting and misc settings which can't be grouped
> 
> A bunch of overly long lines here.
> 
> But I still think this is the wrong design.  The number of potential
> parameter is very limited, so splitting them over multiple ioctls

So far, at least the following 6 parameters are to be added:

- basic
- discard
- segment
- zoned
- user space crash recovery parameter
- userspace backing buffer parameter

And each one is basically not related with others.

And ublk is really one generic userspace driver framework, it is very
likely to have more parameters added in future.

> and data structure for no good reason is really a de-optimization
> that makes the code more complex and slower.

Fine, I don't have time to argue which one is better.

For the timing's reason, I switch to the single parameter way. If turns
outs single parameter can't work well enough in future, I will restart
to add set/get parameter command.


Thanks,
Ming




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux