_channel_ is being dereferenced before it is null checked, hence there is a
potential null pointer dereference. Fix this by moving the pointer dereference
after _channel_ has been null checked.
This issue was detected with the help of Coccinelle.
Fixes: c5f5d0f99794 ("[media] c8sectpfe: STiH407/10 Linux DVB demux support")
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Acked-by: Patrice Chotard <patrice.chotard@st.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
 static void channel_swdemux_tsklet(unsigned long data)
 {
        struct channel_info *channel = (struct channel_info *)data;
-       struct c8sectpfei *fei = channel->fei;
+       struct c8sectpfei *fei;
        unsigned long wp, rp;
        int pos, num_packets, n, size;
        u8 *buf;
        if (unlikely(!channel || !channel->irec))
                return;
 
+       fei = channel->fei;
+
        wp = readl(channel->irec + DMA_PRDS_BUSWP_TP(0));
        rp = readl(channel->irec + DMA_PRDS_BUSRP_TP(0));