From: Zack Rusin <zackr@vmware.com>
To: "daniel@ffwll.ch" <daniel@ffwll.ch>,
"maarten.lankhorst@linux.intel.com"
<maarten.lankhorst@linux.intel.com>,
"mripard@kernel.org" <mripard@kernel.org>,
"juntong.deng@outlook.com" <juntong.deng@outlook.com>,
"airlied@gmail.com" <airlied@gmail.com>,
"tzimmermann@suse.de" <tzimmermann@suse.de>,
Linux-graphics-maintainer <Linux-graphics-maintainer@vmware.com>
Cc: "dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>,
"linux-kernel-mentees@lists.linuxfoundation.org"
<linux-kernel-mentees@lists.linuxfoundation.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] drm: Rename drm_ioctl_flags() to eliminate duplicate declaration warning
Date: Wed, 6 Sep 2023 21:13:49 +0000 [thread overview]
Message-ID: <da7e44fac65b2c73c9f1000a2c1d9c75d931a9d7.camel@vmware.com> (raw)
In-Reply-To: <VI1P193MB0752635EE197F2BB14A2D87499EFA@VI1P193MB0752.EURP193.PROD.OUTLOOK.COM>
On Thu, 2023-09-07 at 00:45 +0800, Juntong Deng wrote:
> There are 'enum drm_ioctl_flags' and 'bool drm_ioctl_flags(...)' with the
> same name, which is not a problem in C, but it can lead to
> 'WARNING: Duplicate C declaration' when generating documentation.
>
> According to the purpose of the function, rename 'drm_ioctl_flags(...)' to
> 'drm_check_ioctl_flags(...)' to eliminate the warning.
>
> Signed-off-by: Juntong Deng <juntong.deng@outlook.com>
> ---
> drivers/gpu/drm/drm_ioctl.c | 6 +++---
> drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 2 +-
> include/drm/drm_ioctl.h | 2 +-
> 3 files changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_ioctl.c b/drivers/gpu/drm/drm_ioctl.c
> index f03ffbacfe9b..30699a0a10bc 100644
> --- a/drivers/gpu/drm/drm_ioctl.c
> +++ b/drivers/gpu/drm/drm_ioctl.c
> @@ -911,7 +911,7 @@ long drm_ioctl(struct file *filp,
> EXPORT_SYMBOL(drm_ioctl);
>
> /**
> - * drm_ioctl_flags - Check for core ioctl and return ioctl permission flags
> + * drm_check_ioctl_flags - Check for core ioctl and return ioctl permission flags
> * @nr: ioctl number
> * @flags: where to return the ioctl permission flags
> *
> @@ -922,7 +922,7 @@ EXPORT_SYMBOL(drm_ioctl);
> * Returns:
> * True if the @nr corresponds to a DRM core ioctl number, false otherwise.
> */
> -bool drm_ioctl_flags(unsigned int nr, unsigned int *flags)
> +bool drm_check_ioctl_flags(unsigned int nr, unsigned int *flags)
> {
Can we follow the namespace_action naming convention here? i.e.
drm_ioctl_flags_check instead. I find it a lot easier to look up/memorise the api if
naming is consistent.
z
next prev parent reply other threads:[~2023-09-06 21:14 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-06 16:45 Juntong Deng
2023-09-06 21:13 ` Zack Rusin [this message]
2023-09-06 22:16 ` Juntong Deng
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=da7e44fac65b2c73c9f1000a2c1d9c75d931a9d7.camel@vmware.com \
--to=zackr@vmware.com \
--cc=Linux-graphics-maintainer@vmware.com \
--cc=airlied@gmail.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=juntong.deng@outlook.com \
--cc=linux-kernel-mentees@lists.linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--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®