[Mesa-dev] [PATCH 2/3] intel: Add a force_y_tiling parameter to intel_miptree_create().

Chad Versace chad.versace at linux.intel.com
Wed Jan 9 10:44:32 PST 2013


On 01/08/2013 02:27 PM, Paul Berry wrote:
> This allows intel_miptree_alloc_mcs() to force Y tiling for the MCS
> buffer.  Previously we accomplished this by the hack of passing
> INTEL_MSAA_LAYOUT_CMS as the msaa_layout parameter, but that parameter
> is going to be going away soon.
> ---
>  src/mesa/drivers/dri/intel/intel_fbo.c          |  3 +-
>  src/mesa/drivers/dri/intel/intel_mipmap_tree.c  | 48 +++++++++++++------------
>  src/mesa/drivers/dri/intel/intel_mipmap_tree.h  |  3 +-
>  src/mesa/drivers/dri/intel/intel_tex_image.c    |  3 +-
>  src/mesa/drivers/dri/intel/intel_tex_validate.c |  3 +-
>  5 files changed, 34 insertions(+), 26 deletions(-)


> @@ -823,10 +829,6 @@ intel_miptree_alloc_mcs(struct intel_context *intel,
>     /* From the Ivy Bridge PRM, Vol4 Part1 p76, "MCS Base Address":
>      *
>      *     "The MCS surface must be stored as Tile Y."
> -    *
> -    * We set msaa_format to INTEL_MSAA_LAYOUT_CMS to force
> -    * intel_miptree_create() to use Y tiling.  msaa_format is otherwise
> -    * ignored for the MCS miptree.
>      */
>     mt->mcs_mt = intel_miptree_create(intel,
>                                       mt->target,
> @@ -838,7 +840,8 @@ intel_miptree_alloc_mcs(struct intel_context *intel,
>                                       mt->depth0,
>                                       true,
>                                       0 /* num_samples */,
> -                                     INTEL_MSAA_LAYOUT_CMS);
> +                                     INTEL_MSAA_LAYOUT_NONE,
> +                                     true /* force_y_tiling */);

It's good to see this little lie go away.


More information about the mesa-dev mailing list