From: Thomas Zimmermann <tzimmermann@suse.de>
To: Sui Jingfeng <suijingfeng@loongson.cn>,
Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
Maxime Ripard <mripard@kernel.org>,
David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>
Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm/fbdev-generic: Remove a redundant assignment clause
Date: Wed, 14 Jun 2023 07:29:20 +0200 [thread overview]
Message-ID: <b99747c5-8810-d2b6-80c7-dbc85fcefb8b@suse.de> (raw)
In-Reply-To: <20230614013011.750598-1-suijingfeng@loongson.cn>
[-- Attachment #1.1: Type: text/plain, Size: 1700 bytes --]
Hi
Am 14.06.23 um 03:30 schrieb Sui Jingfeng:
> The assignment "dst = map;" in the drm_fbdev_generic_damage_blit() function
> is redundant because it has already been copied when the call to
> drm_client_buffer_vmap() is finished. Therefore, this patch saves a useless
> copy. No functional change.
Isn't that what we discussed here?
https://lore.kernel.org/dri-devel/20230325074636.136833-1-15330273260@189.cn/
Best regards
Thomas
>
> Signed-off-by: Sui Jingfeng <suijingfeng@loongson.cn>
> ---
> drivers/gpu/drm/drm_fbdev_generic.c | 5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_fbdev_generic.c b/drivers/gpu/drm/drm_fbdev_generic.c
> index 98ae703848a0..aa6924e3a58c 100644
> --- a/drivers/gpu/drm/drm_fbdev_generic.c
> +++ b/drivers/gpu/drm/drm_fbdev_generic.c
> @@ -182,7 +182,7 @@ static int drm_fbdev_generic_damage_blit(struct drm_fb_helper *fb_helper,
> struct drm_clip_rect *clip)
> {
> struct drm_client_buffer *buffer = fb_helper->buffer;
> - struct iosys_map map, dst;
> + struct iosys_map map;
> int ret;
>
> /*
> @@ -202,8 +202,7 @@ static int drm_fbdev_generic_damage_blit(struct drm_fb_helper *fb_helper,
> if (ret)
> goto out;
>
> - dst = map;
> - drm_fbdev_generic_damage_blit_real(fb_helper, clip, &dst);
> + drm_fbdev_generic_damage_blit_real(fb_helper, clip, &map);
>
> drm_client_buffer_vunmap(buffer);
>
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstrasse 146, 90461 Nuernberg, Germany
GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman
HRB 36809 (AG Nuernberg)
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 840 bytes --]
next prev parent reply other threads:[~2023-06-14 5:29 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-14 1:30 Sui Jingfeng
2023-06-14 5:29 ` Thomas Zimmermann [this message]
2023-06-14 8:17 ` Sui Jingfeng
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=b99747c5-8810-d2b6-80c7-dbc85fcefb8b@suse.de \
--to=tzimmermann@suse.de \
--cc=airlied@gmail.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=suijingfeng@loongson.cn \
/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®