From: Javier Martinez Canillas <javierm@redhat.com>
To: John Keeping <jkeeping@inmusicbrands.com>
Cc: John Keeping <jkeeping@inmusicbrands.com>,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
Thomas Zimmermann <tzimmermann@suse.de>,
David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/3] drm/ssd130x: fix ssd132x encoding
Date: Wed, 15 Jan 2025 00:16:41 +0100 [thread overview]
Message-ID: <87v7uhvvdy.fsf@minerva.mail-host-address-is-not-set> (raw)
In-Reply-To: <20250113152752.3369731-3-jkeeping@inmusicbrands.com>
John Keeping <jkeeping@inmusicbrands.com> writes:
> The ssd132x buffer is encoded one pixel per nibble, with two pixels in
> each byte. When encoding and 8-bit greyscale input, take the top 4-bits
I think the correct phrase is "encoding an 8-bit" ?
> as the value and ensure the two pixels are distinct and do not overwrite
> each other.
>
Fixes: fdd591e00a9c ("drm/ssd130x: Add support for the SSD132x OLED controller family")
> Signed-off-by: John Keeping <jkeeping@inmusicbrands.com>
> ---
> drivers/gpu/drm/solomon/ssd130x.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/solomon/ssd130x.c b/drivers/gpu/drm/solomon/ssd130x.c
> index 2622172228361..64f1123080996 100644
> --- a/drivers/gpu/drm/solomon/ssd130x.c
> +++ b/drivers/gpu/drm/solomon/ssd130x.c
> @@ -880,7 +880,7 @@ static int ssd132x_update_rect(struct ssd130x_device *ssd130x,
> u8 n1 = buf[i * width + j];
> u8 n2 = buf[i * width + j + 1];
>
> - data_array[array_idx++] = (n2 << 4) | n1;
> + data_array[array_idx++] = (n2 & 0xf0) | (n1 >> 4);
> }
> }
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
--
Best regards,
Javier Martinez Canillas
Core Platforms
Red Hat
next prev parent reply other threads:[~2025-01-14 23:16 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-13 15:27 [PATCH 0/3] drm/ssd130x: some small ssd132x fixes John Keeping
2025-01-13 15:27 ` [PATCH 1/3] drm/ssd130x: Fix reset timing for ssd132x John Keeping
2025-01-14 22:21 ` Javier Martinez Canillas
2025-01-15 10:40 ` John Keeping
2025-01-15 11:01 ` Javier Martinez Canillas
2025-01-13 15:27 ` [PATCH 2/3] drm/ssd130x: fix ssd132x encoding John Keeping
2025-01-14 23:16 ` Javier Martinez Canillas [this message]
2025-01-13 15:27 ` [PATCH 3/3] drm/ssd130x: ensure ssd132x pitch is correct John Keeping
2025-01-14 23:19 ` Javier Martinez Canillas
2025-01-15 8:48 ` Javier Martinez Canillas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87v7uhvvdy.fsf@minerva.mail-host-address-is-not-set \
--to=javierm@redhat.com \
--cc=airlied@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=jkeeping@inmusicbrands.com \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=simona@ffwll.ch \
--cc=tzimmermann@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®