Skip to content

Commit

Permalink
drm/ssd130x: remove redundant initialization of pointer mode
Browse files Browse the repository at this point in the history
Pointer mode is being assigned a value that is never read, it is
being re-assigned later with a new value. The initialization is
redundant and can be removed.

Cleans up clang scan build warning:
drivers/gpu/drm/solomon/ssd130x.c:582:27: warning: Value stored
to 'mode' during its initialization is never read [deadcode.DeadStores]

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Acked-by: Javier Martinez Canillas <javierm@redhat.com>
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220302175309.1098827-1-colin.i.king@gmail.com
  • Loading branch information
Colin Ian King authored and Javier Martinez Canillas committed Mar 3, 2022
1 parent e41d27e commit 701920c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/solomon/ssd130x.c
Original file line number Diff line number Diff line change
Expand Up @@ -579,7 +579,7 @@ static const struct drm_simple_display_pipe_funcs ssd130x_pipe_funcs = {
static int ssd130x_connector_get_modes(struct drm_connector *connector)
{
struct ssd130x_device *ssd130x = drm_to_ssd130x(connector->dev);
struct drm_display_mode *mode = &ssd130x->mode;
struct drm_display_mode *mode;
struct device *dev = ssd130x->dev;

mode = drm_mode_duplicate(connector->dev, &ssd130x->mode);
Expand Down

0 comments on commit 701920c

Please sign in to comment.