If imx-drm is combined with a bridge or panel that requests an
unsupported format, warn and use a default mapping instead of
hanging the machine. The worst that can happen here are wrong
colors.
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
 static int ipu_bus_format_to_map(u32 fmt)
 {
        switch (fmt) {
+       default:
+               WARN_ON(1);
+               /* fall-through */
        case MEDIA_BUS_FMT_RGB888_1X24:
                return IPU_DC_MAP_RGB24;
        case MEDIA_BUS_FMT_RGB565_1X16:
                return IPU_DC_MAP_LVDS666;
        case MEDIA_BUS_FMT_BGR888_1X24:
                return IPU_DC_MAP_BGR24;
-       default:
-               return -EINVAL;
        }
 }
 
        dc->di = ipu_di_get_num(di);
 
        map = ipu_bus_format_to_map(bus_format);
-       BUG_ON(map < 0);
 
        /*
         * In interlaced mode we need more counters to create the asymmetric