llvm.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [PATCH] ALSA: hdspm: remove unused copy_u32_le function
@ 2023-03-23 20:27 Tom Rix
  2023-03-24  6:51 ` Takashi Iwai
  0 siblings, 1 reply; 2+ messages in thread
From: Tom Rix @ 2023-03-23 20:27 UTC (permalink / raw)
  To: perex, tiwai, nathan, ndesaulniers
  Cc: alsa-devel, linux-kernel, llvm, Tom Rix

clang with W=1 reports
sound/pci/rme9652/hdspm.c:6149:19: error: unused function
  'copy_u32_le' [-Werror,-Wunused-function]
static inline int copy_u32_le(void __user *dest, void __iomem *src)
                  ^
This function is not used so remove it.

Signed-off-by: Tom Rix <trix@redhat.com>
---
 sound/pci/rme9652/hdspm.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c
index fa1812e7a49d..267c7848974a 100644
--- a/sound/pci/rme9652/hdspm.c
+++ b/sound/pci/rme9652/hdspm.c
@@ -6146,12 +6146,6 @@ static int snd_hdspm_hwdep_dummy_op(struct snd_hwdep *hw, struct file *file)
 	return 0;
 }
 
-static inline int copy_u32_le(void __user *dest, void __iomem *src)
-{
-	u32 val = readl(src);
-	return copy_to_user(dest, &val, 4);
-}
-
 static int snd_hdspm_hwdep_ioctl(struct snd_hwdep *hw, struct file *file,
 		unsigned int cmd, unsigned long arg)
 {
-- 
2.27.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] ALSA: hdspm: remove unused copy_u32_le function
  2023-03-23 20:27 [PATCH] ALSA: hdspm: remove unused copy_u32_le function Tom Rix
@ 2023-03-24  6:51 ` Takashi Iwai
  0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2023-03-24  6:51 UTC (permalink / raw)
  To: Tom Rix
  Cc: perex, tiwai, nathan, ndesaulniers, alsa-devel, linux-kernel, llvm

On Thu, 23 Mar 2023 21:27:13 +0100,
Tom Rix wrote:
> 
> clang with W=1 reports
> sound/pci/rme9652/hdspm.c:6149:19: error: unused function
>   'copy_u32_le' [-Werror,-Wunused-function]
> static inline int copy_u32_le(void __user *dest, void __iomem *src)
>                   ^
> This function is not used so remove it.
> 
> Signed-off-by: Tom Rix <trix@redhat.com>

Applied to for-next branch.  Thanks.


Takashi

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-03-24  7:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-23 20:27 [PATCH] ALSA: hdspm: remove unused copy_u32_le function Tom Rix
2023-03-24  6:51 ` Takashi Iwai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).