On Tue, Jan 16, 2024 at 11:23:00AM +0100, Nirmoy Das wrote: > > On 1/16/2024 8:56 AM, Ville Syrjala wrote: > > From: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx> > > > > mem->region is a struct resource, but mem->io_start and > > mem->io_size are not for whatever reason. Let's unify this > > and convert the io stuff into a struct resource as well. > > Should make life a little less annoying when you don't have > > juggle between two different approaches all the time. > > > > Mostly done using cocci (with manual tweaks at all the > > places where we mutate io_size by hand): > > @@ > > struct intel_memory_region *M; > > expression START, SIZE; > > @@ > > - M->io_start = START; > > - M->io_size = SIZE; > > + M->io = DEFINE_RES_MEM(START, SIZE); > > > > @@ > > struct intel_memory_region *M; > > @@ > > - M->io_start > > + M->io.start > > > > @@ > > struct intel_memory_region M; > > @@ > > - M.io_start > > + M.io.start > > > > @@ > > expression M; > > @@ > > - M->io_size > > + resource_size(&M->io) > > > > @@ > > expression M; > > @@ > > - M.io_size > > + resource_size(&M.io) > > > > Cc: Paz Zcharya <pazz@xxxxxxxxxxxx> > > Reviewed-by: Andrzej Hajda <andrzej.hajda@xxxxxxxxx> > > Signed-off-by: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx> > Acked-by: Nirmoy Das <nirmoy.das@xxxxxxxxx> Hi Ville, Thank you so much for this incredible series. It solves the issue regarding MTL initial plane readout that Andrzej Hajda and I worked on in https://patchwork.freedesktop.org/patch/570811/?series=127130&rev=2 In addition, it solved the issue with the new GOP. I tested it on two different devices with Meteor Lake and it worked perfectly: no i915 errors, no flickers or observable issues. Tested-by: Paz Zcharya <pazz@xxxxxxxxxxxx>