diff --git a/src/intel/isl/isl.c b/src/intel/isl/isl.c index dcc48b74ff3..79d64a9f7de 100644 --- a/src/intel/isl/isl.c +++ b/src/intel/isl/isl.c @@ -2065,20 +2065,7 @@ isl_surf_get_mcs_surf(const struct isl_device *dev, assert(surf->dim == ISL_SURF_DIM_2D); assert(surf->levels == 1); assert(surf->logical_level0_px.depth == 1); - - /* From the Ivy Bridge PRM, Vol4 Part1 p77 ("MCS Enable"): - * - * This field must be set to 0 for all SINT MSRTs when all RT channels - * are not written - * - * In practice this means that we have to disable MCS for all signed - * integer MSAA buffers. The alternative, to disable MCS only when one - * of the render target channels is disabled, is impractical because it - * would require converting between CMS and UMS MSAA layouts on the fly, - * which is expensive. - */ - if (ISL_GFX_VER(dev) == 7 && isl_format_has_sint_channel(surf->format)) - return false; + assert(isl_format_supports_multisampling(dev->info, surf->format)); enum isl_format mcs_format; switch (surf->samples) { diff --git a/src/intel/isl/isl_format.c b/src/intel/isl/isl_format.c index 9dd5e4c1290..f634a3e75c0 100644 --- a/src/intel/isl/isl_format.c +++ b/src/intel/isl/isl_format.c @@ -900,6 +900,21 @@ isl_format_supports_multisampling(const struct intel_device_info *devinfo, * is multisampled. See also isl_surf_get_hiz_surf(). */ return devinfo->ver <= 8; + } else if (devinfo->ver == 7 && isl_format_has_sint_channel(format)) { + /* From the Ivy Bridge PRM, Vol4 Part1 p73 ("Number of Multisamples"): + * + * This field must be set to MULTISAMPLECOUNT_1 for SINT MSRTs when + * all RT channels are not written + * + * From the Ivy Bridge PRM, Vol4 Part1 p77 ("MCS Enable"): + * + * This field must be set to 0 for all SINT MSRTs when all RT channels + * are not written + * + * Disable multisampling support now as we don't handle the case when + * one of the render target channels is disabled. + */ + return false; } else if (devinfo->ver < 7 && isl_format_get_layout(format)->bpb > 64) { return false; } else if (isl_format_is_compressed(format)) {