summaryrefslogtreecommitdiff
path: root/lib/rendercopy_gen4.c
AgeCommit message (Collapse)Author
2019-04-29lib/rendercopy: Add fp16 support for gen4+Ville Syrjälä
Allow copying between fp16 surfaces. We'll use the FLOAT surface format since that's all the display supports currently. Hopefully the hardware gives us a 1:1 copy, at least if the input doesn't contain crazy infs/nans etc. We could choose UNORM instead but that won't work for eventually exposing fp16+ccs. Although we do need to replace the simple bpp value with a more specific format type to get 10bpc+ccs working as well. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2019-04-04lib/rendercopy: Assert that buffer dimensions/stride are acceptableVille Syrjälä
Sprinkle some asserts into rendercopy to make sure we don't try to exceed the render engine surface size/stride limitations. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
2018-11-20lib/rendercopy: Implement support for 8/16 bppMaarten Lankhorst
To handle drawing 16 bpp formats correctly with odd x/w, we need to use the correct bpp to rendercopy. Now that everything sets bpp in igt_buf, fix the rendercopy support to use it and set the correct format. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> [mlankhorst: Add assert(src->bpp == dst->bpp)]
2018-07-20lib/rendercopy: Fix lack of const throughout gen4 rendercopyChris Wilson
The gen4 code was pushed without being fixed up for the constification of igt_render_copyfunc_t ../lib/intel_batchbuffer.c: In function ‘igt_get_render_copyfunc’: ../lib/intel_batchbuffer.c:837:8: warning: assignment to ‘igt_render_copyfunc_t’ {aka ‘void (*)(struct intel_batchbuffer *, struct _drm_intel_context *, const struct igt_buf *, unsigned int, unsigned int, unsigned int, unsigned int, const struct igt_buf *, unsigned int, unsigned int)’} from incompatible pointer type ‘void (*)(struct intel_batchbuffer *, drm_intel_context *, struct igt_buf *, unsigned int, unsigned int, unsigned int, unsigned int, struct igt_buf *, unsigned int, unsigned int)’ {aka ‘void (*)(struct intel_batchbuffer *, struct _drm_intel_context *, struct igt_buf *, unsigned int, unsigned int, unsigned int, unsigned int, struct igt_buf *, unsigned int, unsigned int)’} [-Wincompatible-pointer-types] copy = gen4_render_copyfunc; Fixes: 61370b2d43db ("lib/rendercopy: Add gen4/5 rendercopy") Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
2018-07-18lib/rendercopy: Add gen4/5 rendercopyLukasz Kalamarz
Add rendercopy implementation for gen4/5. Basic structure copied from the gen6 implementation, and the gen4/5 specific bits were mostly lifted from sna. v2: Renamed registers definitions, which are GEN4 specific to include that prefix (Lukasz) v3: Rebase and checkpatch Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Lukasz Kalamarz <lukasz.kalamarz@intel.com> Cc: Katarzyna Dec <katarzyna.dec@intel.com> Cc: Antonio Argenziano <antonio.argenziano@intel.com> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Reviewed-by: Katarzyna Dec <katarzyna.dec@intel.com>