Due to recent change to do_insnlist_ioctl() and do_insn_ioctl(), the
'data' pointer will be NULL when insn->n == 0. Do not access *data in
this case.
Signed-off-by: Ian Abbott <abbotti@mev.co.uk>
unioxx5_subd_priv *usp = subdev->private;
int channel, type;
+ if (insn->n == 0)
+ return 0;
+
channel = CR_CHAN(insn->chanspec);
type = usp->usp_module_type[channel / 2]; /* defining module type(analog or digital) */
unioxx5_subd_priv *usp = subdev->private;
int channel, type;
+ if (insn->n == 0)
+ return 0;
+
channel = CR_CHAN(insn->chanspec);
type = usp->usp_module_type[channel / 2]; /* defining module type(analog or digital) */