md_type is an enum.  On my tests, GCC treats it as unsigned but
according to the C standard it's an implementation dependant thing so we
should check for negatives.
Fixes: a49d25364dfb ("staging/atomisp: Add support for the Intel IPU v2")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
                return 0;
 
        md_type = md->type;
-       if (md_type >= ATOMISP_METADATA_TYPE_NUM)
+       if (md_type < 0 || md_type >= ATOMISP_METADATA_TYPE_NUM)
                return -EINVAL;
 
        /* This is done in the atomisp_buf_done() */