platform/surface: clean up a variable in surface_dtx_read()
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 26 Mar 2021 12:28:48 +0000 (15:28 +0300)
committerHans de Goede <hdegoede@redhat.com>
Wed, 7 Apr 2021 17:47:22 +0000 (19:47 +0200)
The "&client->ddev->lock" and "&ddev->lock" are the same thing.  Let's
use "&ddev->lock" consistently.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Maximilian Luz <luzmaximilian@gmail.com>
Link: https://lore.kernel.org/r/YF3TgCcpcCYl3a//@mwanda
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/surface/surface_dtx.c

index 1fedacf7405002cda186f6ff405a6f901820c2b9..63ce587e79e3ba2470778b2dfc5386dfcb0d8ea4 100644 (file)
@@ -487,7 +487,7 @@ static ssize_t surface_dtx_read(struct file *file, char __user *buf, size_t coun
                        if (status < 0)
                                return status;
 
-                       if (down_read_killable(&client->ddev->lock))
+                       if (down_read_killable(&ddev->lock))
                                return -ERESTARTSYS;
 
                        /* Need to check that we're not shut down again. */