drm/ssd130x: Silence a `dubious: x & !y` warning
authorJavier Martinez Canillas <javierm@redhat.com>
Sat, 21 Jan 2023 19:09:30 +0000 (20:09 +0100)
committerJavier Martinez Canillas <javierm@redhat.com>
Tue, 24 Jan 2023 10:02:33 +0000 (11:02 +0100)
commit51affef35bb39f186aef7eeeb4a7f9ceccd3e65e
treec660a0135ddede55cd2bdbef28376996203da3d5
parent998101f2a78cf506022f2094461105cb3d00e19f
drm/ssd130x: Silence a `dubious: x & !y` warning

The sparse tool complains with the following warning:

$ make M=drivers/gpu/drm/solomon/ C=2
  CC [M]  drivers/gpu/drm/solomon/ssd130x.o
  CHECK   drivers/gpu/drm/solomon/ssd130x.c
drivers/gpu/drm/solomon/ssd130x.c:363:21: warning: dubious: x & !y

This seems to be a false positive in my opinion but still we can silence
the tool while making the code easier to read. Let's also add a comment,
to explain why the "com_seq" logical not is used rather than its value.

Reported-by: Thomas Zimmermann <tzimmermann@suse.de>
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/20230121190930.2804224-1-javierm@redhat.com
drivers/gpu/drm/solomon/ssd130x.c