Information such as samplerate, time limit or sample limit is context specific.
Information about samplerate, time limit, sample limit, and pattern is currently
kept in static global variables, while a count of the number of samples sent is
kept in the device context.

These variables belong in a device context, since they are device-specific.

Store these variables in dev_context, following the model that most other
drivers use: keep devc in sdi->priv.