Re: [PATCH] Generic WorkQueue Engine (GenWQE) device driver (v4)

Greg KH
2013-10-30T17:39:08Z

On Wed, Oct 30, 2013 at 10:32:58AM +0100, Frank Haverkamp wrote:
> +/*
> + * GenWQE Driver: Need SLC timeout set to 250ms (temporary setting for
> + * testing of 1000ms due to decompressor testcase failing)
> + *
> + * There is a requirement by the card users that the timeout must not
> + * exceed the 250ms.
> + *
> + * In this case the settings must be done before any interaction to
> + * the device can be done, since we cannot change the settings without
> + * stopping the queues.

Then stop the queue, change the value, and start them up again.

Why would anyone ever want to change these values? Don't make anything
"tunable", just get it right and don't rely on someone making tweaks
later with module options, especially as, again, these are driver wide,
not specific to a device.

If you _really_ need them for a device, make them a sysfs file and fix
the code to handle stopping and starting. You have to handle that
anyway with dynamic bind/unbind of the driver to specific devices
anyway, so this shouldn't be a big deal.

greg k-h