diff mbox series

[v7,3/6] mei: clean pending read with vtag on bus

Message ID 20230125082637.118970-4-alan.previn.teres.alexis@intel.com (mailing list archive)
State New, archived
Headers show
Series drm/i915/pxp: Add missing cleanup steps for PXP global-teardown | expand

Commit Message

Teres Alexis, Alan Previn Jan. 25, 2023, 8:26 a.m. UTC
From: Alexander Usyskin <alexander.usyskin@intel.com>

Client on bus have only one vtag map slot and should disregard the vtag
value when cleaning pending read flag.
Fixes read flow control message unexpectedly generated when
clent on bus send messages with different vtags.

Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com>
Reviewed-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
---
 drivers/misc/mei/client.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Rodrigo Vivi Jan. 25, 2023, 5:28 p.m. UTC | #1
Greg, ack on getting these 3 mei patches merged through intel-gfx?

On Wed, Jan 25, 2023 at 12:26:34AM -0800, Alan Previn wrote:
> From: Alexander Usyskin <alexander.usyskin@intel.com>
> 
> Client on bus have only one vtag map slot and should disregard the vtag
> value when cleaning pending read flag.
> Fixes read flow control message unexpectedly generated when
> clent on bus send messages with different vtags.
> 
> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com>
> Reviewed-by: Tomas Winkler <tomas.winkler@intel.com>
> Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
> ---
>  drivers/misc/mei/client.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/misc/mei/client.c b/drivers/misc/mei/client.c
> index 9ddb854b8155..5c19097266fe 100644
> --- a/drivers/misc/mei/client.c
> +++ b/drivers/misc/mei/client.c
> @@ -1343,7 +1343,9 @@ static void mei_cl_reset_read_by_vtag(const struct mei_cl *cl, u8 vtag)
>  	struct mei_cl_vtag *vtag_l;
>  
>  	list_for_each_entry(vtag_l, &cl->vtag_map, list) {
> -		if (vtag_l->vtag == vtag) {
> +		/* The client on bus has one fixed vtag map */
> +		if ((cl->cldev && mei_cldev_enabled(cl->cldev)) ||
> +		    vtag_l->vtag == vtag) {
>  			vtag_l->pending_read = false;
>  			break;
>  		}
> -- 
> 2.39.0
>
Greg Kroah-Hartman Jan. 25, 2023, 6:01 p.m. UTC | #2
Why are you top posting?

On Wed, Jan 25, 2023 at 12:28:29PM -0500, Rodrigo Vivi wrote:
> 
> Greg, ack on getting these 3 mei patches merged through intel-gfx?

$ mdfrm -c ~/mail/todo/
756 messages in /home/gregkh/mail/todo/

Give me a chance, what is the sudden rush?

greg k-h
Greg Kroah-Hartman Jan. 27, 2023, 9:08 a.m. UTC | #3
On Wed, Jan 25, 2023 at 12:26:34AM -0800, Alan Previn wrote:
> From: Alexander Usyskin <alexander.usyskin@intel.com>
> 
> Client on bus have only one vtag map slot and should disregard the vtag
> value when cleaning pending read flag.
> Fixes read flow control message unexpectedly generated when
> clent on bus send messages with different vtags.
> 
> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com>
> Reviewed-by: Tomas Winkler <tomas.winkler@intel.com>
> Signed-off-by: Alan Previn <alan.previn.teres.alexis@intel.com>
> ---
>  drivers/misc/mei/client.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/misc/mei/client.c b/drivers/misc/mei/client.c
> index 9ddb854b8155..5c19097266fe 100644
> --- a/drivers/misc/mei/client.c
> +++ b/drivers/misc/mei/client.c
> @@ -1343,7 +1343,9 @@ static void mei_cl_reset_read_by_vtag(const struct mei_cl *cl, u8 vtag)
>  	struct mei_cl_vtag *vtag_l;
>  
>  	list_for_each_entry(vtag_l, &cl->vtag_map, list) {
> -		if (vtag_l->vtag == vtag) {
> +		/* The client on bus has one fixed vtag map */
> +		if ((cl->cldev && mei_cldev_enabled(cl->cldev)) ||
> +		    vtag_l->vtag == vtag) {
>  			vtag_l->pending_read = false;
>  			break;
>  		}
> -- 
> 2.39.0
> 

Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Greg Kroah-Hartman Jan. 27, 2023, 9:09 a.m. UTC | #4
On Wed, Jan 25, 2023 at 12:28:29PM -0500, Rodrigo Vivi wrote:
> 
> Greg, ack on getting these 3 mei patches merged through intel-gfx?

I only see 2 mei patches in this series, what am I missing?

thanks,

greg k-h
Teres Alexis, Alan Previn Jan. 27, 2023, 7:07 p.m. UTC | #5
Hi Greg, appreciate your time on this, 

Patch #2 adds a device link between i915 and mei
(at bind time) specifically for the PXP interface
that is subject to the issue being fixed.

Change is on i915 but implication is mei suspend-resume
aligfnent with i915. Rodrigo has already reviewed it
but Alex and himself felt you might wanna take a look.

...alan


On Fri, 2023-01-27 at 10:09 +0100, Greg Kroah-Hartman wrote:
> On Wed, Jan 25, 2023 at 12:28:29PM -0500, Rodrigo Vivi wrote:
> > 
> > Greg, ack on getting these 3 mei patches merged through intel-gfx?
> 
> I only see 2 mei patches in this series, what am I missing?
> 
> thanks,
> 
> greg k-h
Rodrigo Vivi Jan. 27, 2023, 8:26 p.m. UTC | #6
On Fri, Jan 27, 2023 at 10:09:31AM +0100, Greg Kroah-Hartman wrote:
> On Wed, Jan 25, 2023 at 12:28:29PM -0500, Rodrigo Vivi wrote:
> > 
> > Greg, ack on getting these 3 mei patches merged through intel-gfx?
> 
> I only see 2 mei patches in this series, what am I missing?

right... 2 mei patches only... sorry for the noise and for the top posting.

thanks for the ack.

series pushed to drm-intel-next

> 
> thanks,
> 
> greg k-h
diff mbox series

Patch

diff --git a/drivers/misc/mei/client.c b/drivers/misc/mei/client.c
index 9ddb854b8155..5c19097266fe 100644
--- a/drivers/misc/mei/client.c
+++ b/drivers/misc/mei/client.c
@@ -1343,7 +1343,9 @@  static void mei_cl_reset_read_by_vtag(const struct mei_cl *cl, u8 vtag)
 	struct mei_cl_vtag *vtag_l;
 
 	list_for_each_entry(vtag_l, &cl->vtag_map, list) {
-		if (vtag_l->vtag == vtag) {
+		/* The client on bus has one fixed vtag map */
+		if ((cl->cldev && mei_cldev_enabled(cl->cldev)) ||
+		    vtag_l->vtag == vtag) {
 			vtag_l->pending_read = false;
 			break;
 		}