[PATCH] nvme-pci: add module parameter for io queue depth
weiping zhang
zhangweiping at didichuxing.com
Fri Jul 7 09:53:59 PDT 2017
On Fri, Jul 07, 2017 at 11:29:48AM -0400, Keith Busch wrote:
> On Fri, Jul 07, 2017 at 05:05:47PM +0800, weiping zhang wrote:
> > Adjust io queue depth more easily.
> > cap = lo_hi_readq(dev->bar + NVME_REG_CAP);
> >
> > - dev->q_depth = min_t(int, NVME_CAP_MQES(cap) + 1, NVME_Q_DEPTH);
> > + dev->q_depth = min_t(int, NVME_CAP_MQES(cap) + 1, io_queue_depth);
>
> We need to be a little more careful about this field if users can write
> whatever they want. It's gotta be >= 2 or else trouble will occur.
ok, I will send patch v2, thanks all.
More information about the Linux-nvme
mailing list