Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Piotr Zalewski
Hi Andy On Wednesday, October 16th, 2024 at 11:23 AM, Piotr Zalewski wrote: > > > static void vop2_crtc_atomic_flush(struct drm_crtc *crtc, > > > @@ -2790,7 +2945,13 @@ static int vop2_create_crtcs(struct vop2 *vop2) > > > } > > > > > > drm_crtc_helper_add(&vp->crtc, &vop2_crtc_helper_funcs);

Re: Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Daniel Stone
Hi Piotr, On Wed, 16 Oct 2024 at 20:19, Piotr Zalewski wrote: > On Wednesday, October 16th, 2024 at 2:27 PM, Daniel Stone > wrote: > > 1 is the only solution that can work. Silently changing the colour > > properties of a separate CRTC is not OK, since this can lead to > > displaying incorrect

Re: Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Piotr Zalewski
Hi Daniel, On Wednesday, October 16th, 2024 at 2:27 PM, Daniel Stone wrote: > Hi all, > > On Wed, 16 Oct 2024 at 02:11, Andy Yan andys...@163.com wrote: > > > At 2024-10-16 04:13:40, "Piotr Zalewski" pz010001011...@proton.me wrote: > > > > > Ok I get it now. Is such rework correct? - when gamma

Re: Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Daniel Stone
Hi all, On Wed, 16 Oct 2024 at 02:11, Andy Yan wrote: > At 2024-10-16 04:13:40, "Piotr Zalewski" wrote: > >Ok I get it now. Is such rework correct? - when gamma LUT for rk356x is > >being set, instead of disabling the LUT before the gamma LUT write for the > >current CRTC's video port, active vi

Re: [PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Piotr Zalewski
Hi Diederik On Wednesday, October 16th, 2024 at 11:20 AM, Diederik de Haas wrote: > On Wed Oct 16, 2024 at 11:16 AM CEST, Piotr Zalewski wrote: > > > I will rework it to[1] and test it. (Have to check if hdmi out on pt2 > > works). > > > Last time I tried it, hdmi out did work. Nice, thank

Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Piotr Zalewski
Hi Andy, > > > > static void vop2_crtc_atomic_flush(struct drm_crtc *crtc, > > @@ -2790,7 +2945,13 @@ static int vop2_create_crtcs(struct vop2 *vop2) > > } > > > > drm_crtc_helper_add(&vp->crtc, &vop2_crtc_helper_funcs); > > + if (vop2->lut_regs && vp->crtc.dev != NULL) { > > > > There is no

Re: [PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Diederik de Haas
On Wed Oct 16, 2024 at 11:16 AM CEST, Piotr Zalewski wrote: > I will rework it to[1] and test it. (Have to check if hdmi out on pt2 works). Last time I tried it, hdmi out did work. signature.asc Description: PGP signature

Re:Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Piotr Zalewski
Hi Andy, On Wednesday, October 16th, 2024 at 3:10 AM, Andy Yan wrote: > Hi Piotr, > > At 2024-10-16 04:13:40, "Piotr Zalewski" pz010001011...@proton.me wrote: > > > Hi Andy > > > > On Tuesday, October 15th, 2024 at 2:22 PM, Andy Yan andys...@163.com wrote: > > > > > > > > + struct vop2_video

Re:Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Piotr Zalewski
Hi Andy, Ignore the message I'm answering to. I accidentally sent it prematurely. On Wednesday, October 16th, 2024 at 9:41 AM, Piotr Zalewski wrote: > Hi Andy, > > On Wednesday, October 16th, 2024 at 3:10 AM, Andy Yan andys...@163.com wrote: > > > Hi Piotr, > > > > At 2024-10-16 04:13:40,

Re:Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-16 Thread Piotr Zalewski
Hi Andy, On Wednesday, October 16th, 2024 at 3:10 AM, Andy Yan wrote: > Hi Piotr, > > At 2024-10-16 04:13:40, "Piotr Zalewski" pz010001011...@proton.me wrote: > > > Hi Andy > > > > On Tuesday, October 15th, 2024 at 2:22 PM, Andy Yan andys...@163.com wrote: > > > > > > > > + struct vop2_video

Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-15 Thread Andy Yan
Hi Piotr, At 2024-10-15 06:30:27, "Piotr Zalewski" wrote: >Add support for gamma LUT in VOP2 driver. The implementation was inspired >by one found in VOP1 driver. Blue and red channels in gamma LUT register >write were swapped with respect to how gamma LUT values are written in >VOP1. Gamma LUT p

Re:Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-15 Thread Andy Yan
Hi Piotr, At 2024-10-16 04:13:40, "Piotr Zalewski" wrote: >Hi Andy > >On Tuesday, October 15th, 2024 at 2:22 PM, Andy Yan wrote: > >> > > > + struct vop2_video_port *vp, >> > > > + struct drm_crtc *crtc, >> > > > + struct drm_crtc_state *crtc_state) >> > > > +{ >> > > > + >> > > > + if (vop2->l

Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-15 Thread Piotr Zalewski
Hi Andy On Tuesday, October 15th, 2024 at 2:22 PM, Andy Yan wrote: > > > > + struct vop2_video_port *vp, > > > > + struct drm_crtc *crtc, > > > > + struct drm_crtc_state *crtc_state) > > > > +{ > > > > + > > > > + if (vop2->lut_regs && crtc_state->color_mgmt_changed) { > > > > + if (!crtc_state-

Re:Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-15 Thread Andy Yan
Hi Piotr, At 2024-10-15 19:55:44, "Piotr Zalewski" wrote: >On Tuesday, October 15th, 2024 at 5:38 AM, Andy Yan wrote: > >> Hi Piotr, >> >> At 2024-10-15 06:30:27, "Piotr Zalewski" pz010001011...@proton.me wrote: >> >> > Add support for gamma LUT in VOP2 driver. The implementation was inspired

Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-15 Thread Piotr Zalewski
On Tuesday, October 15th, 2024 at 5:38 AM, Andy Yan wrote: > Hi Piotr, > > At 2024-10-15 06:30:27, "Piotr Zalewski" pz010001011...@proton.me wrote: > > > Add support for gamma LUT in VOP2 driver. The implementation was inspired > > by one found in VOP1 driver. Blue and red channels in gamma LUT

Re:[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-14 Thread Andy Yan
Hi Piotr, At 2024-10-15 06:30:27, "Piotr Zalewski" wrote: >Add support for gamma LUT in VOP2 driver. The implementation was inspired >by one found in VOP1 driver. Blue and red channels in gamma LUT register >write were swapped with respect to how gamma LUT values are written in >VOP1. Gamma LUT

[PATCH v5] rockchip/drm: vop2: add support for gamma LUT

2024-10-14 Thread Piotr Zalewski
Add support for gamma LUT in VOP2 driver. The implementation was inspired by one found in VOP1 driver. Blue and red channels in gamma LUT register write were swapped with respect to how gamma LUT values are written in VOP1. Gamma LUT port selection was added before the write of new gamma LUT table