linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dmaengine: ptdma: remove PT_OFFSET to avoid redefnition
@ 2021-08-28 19:28 Sanjay R Mehta
  2021-08-29 13:42 ` Vinod Koul
  0 siblings, 1 reply; 2+ messages in thread
From: Sanjay R Mehta @ 2021-08-28 19:28 UTC (permalink / raw)
  To: vkoul; +Cc: kbuild-all, linux-mm, Sanjay R Mehta

From: Sanjay R Mehta <sanju.mehta@amd.com>

Building on ARCH=um causes a "redefined" warning, so remove this
PT_OFFSET macro to avoid the warning.

drivers/dma/ptdma/ptdma.h:34: warning: "PT_OFFSET" redefined
34 | #define PT_OFFSET   0x0
|
In file included from ./arch/um/include/asm/thread_info.h:17,
from ./include/linux/thread_info.h:60,
from ./include/asm-generic/preempt.h:5,
from ./arch/um/include/generated/asm/preempt.h:1,
from ./include/linux/preempt.h:78,
from ./include/linux/spinlock.h:55,
from ./include/linux/wait.h:9,
from ./include/linux/wait_bit.h:8,
from ./include/linux/fs.h:6,
from ./include/linux/debugfs.h:15,
from drivers/dma/ptdma/ptdma-debugfs.c:12:
./arch/x86/um/shared/sysdep/ptrace_user.h:4: note: this is the location of the previous definition
4 | #define PT_OFFSET(r) ((r) * sizeof(long))

Reported-by: kernel test robot <lkp@intel.com>
Fixes: 2a99524459ce ("dmaengine: ptdma: Initial driver for the AMD PTDMA")
Signed-off-by: Sanjay R Mehta <sanju.mehta@amd.com>
---
 drivers/dma/ptdma/ptdma.h | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/dma/ptdma/ptdma.h b/drivers/dma/ptdma/ptdma.h
index 860e302..afbf192 100644
--- a/drivers/dma/ptdma/ptdma.h
+++ b/drivers/dma/ptdma/ptdma.h
@@ -31,7 +31,6 @@
 #define MAX_CMD_QLEN			100
 
 #define PT_ENGINE_PASSTHRU		5
-#define PT_OFFSET			0x0
 
 /* Register Mappings */
 #define IRQ_MASK_REG			0x040
-- 
2.7.4



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

* Re: [PATCH] dmaengine: ptdma: remove PT_OFFSET to avoid redefnition
  2021-08-28 19:28 [PATCH] dmaengine: ptdma: remove PT_OFFSET to avoid redefnition Sanjay R Mehta
@ 2021-08-29 13:42 ` Vinod Koul
  0 siblings, 0 replies; 2+ messages in thread
From: Vinod Koul @ 2021-08-29 13:42 UTC (permalink / raw)
  To: Sanjay R Mehta; +Cc: kbuild-all, linux-mm

On 28-08-21, 14:28, Sanjay R Mehta wrote:
> From: Sanjay R Mehta <sanju.mehta@amd.com>
> 
> Building on ARCH=um causes a "redefined" warning, so remove this
> PT_OFFSET macro to avoid the warning.
> 
> drivers/dma/ptdma/ptdma.h:34: warning: "PT_OFFSET" redefined
> 34 | #define PT_OFFSET   0x0
> |
> In file included from ./arch/um/include/asm/thread_info.h:17,
> from ./include/linux/thread_info.h:60,
> from ./include/asm-generic/preempt.h:5,
> from ./arch/um/include/generated/asm/preempt.h:1,
> from ./include/linux/preempt.h:78,
> from ./include/linux/spinlock.h:55,
> from ./include/linux/wait.h:9,
> from ./include/linux/wait_bit.h:8,
> from ./include/linux/fs.h:6,
> from ./include/linux/debugfs.h:15,
> from drivers/dma/ptdma/ptdma-debugfs.c:12:
> ./arch/x86/um/shared/sysdep/ptrace_user.h:4: note: this is the location of the previous definition
> 4 | #define PT_OFFSET(r) ((r) * sizeof(long))

Applied, thanks

-- 
~Vinod


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

end of thread, other threads:[~2021-08-29 13:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-28 19:28 [PATCH] dmaengine: ptdma: remove PT_OFFSET to avoid redefnition Sanjay R Mehta
2021-08-29 13:42 ` Vinod Koul

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).