linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* linux-next: build warning after merge of the swiotlb tree
@ 2020-12-11  2:02 Stephen Rothwell
  2020-12-11  2:47 ` Ashish Kalra
  0 siblings, 1 reply; 4+ messages in thread
From: Stephen Rothwell @ 2020-12-11  2:02 UTC (permalink / raw)
  To: Konrad Rzeszutek Wilk
  Cc: Ashish Kalra, Borislav Petkov, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 3386 bytes --]

Hi all,

After merging the swiotlb tree, today's linux-next build (arm
multi_v7_defconfig) produced this warning:

In file included from arch/arm/mm/init.c:24:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/dma-direct.h:13,
                 from arch/arm/mm/dma-mapping.c:17:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/dma-direct.h:13,
                 from kernel/dma/direct.h:10,
                 from kernel/dma/mapping.c:17:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/dma-direct.h:13,
                 from kernel/dma/coherent.c:10:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/dma-direct.h:13,
                 from kernel/dma/direct.h:10,
                 from kernel/dma/direct.c:16:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/dma-direct.h:13,
                 from drivers/of/device.c:8:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/dma-direct.h:13,
                 from drivers/remoteproc/remoteproc_core.c:27:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/dma-direct.h:13,
                 from drivers/of/address.c:16:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from drivers/mmc/host/sdhci.c:23:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~
In file included from drivers/gpu/drm/nouveau/nouveau_bo.c:31:
include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
  108 | static void swiotlb_adjust_size(unsigned long new_size)
      |             ^~~~~~~~~~~~~~~~~~~

Introduced by commit

  79f748d1bdb6 ("x86,swiotlb: Adjust SWIOTLB bounce buffer size for SEV guests")

Forgot the "inline" :-(
-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

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

* Re: linux-next: build warning after merge of the swiotlb tree
  2020-12-11  2:02 linux-next: build warning after merge of the swiotlb tree Stephen Rothwell
@ 2020-12-11  2:47 ` Ashish Kalra
  0 siblings, 0 replies; 4+ messages in thread
From: Ashish Kalra @ 2020-12-11  2:47 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Konrad Rzeszutek Wilk, Borislav Petkov,
	Linux Kernel Mailing List, Linux Next Mailing List

Posted a fix for this.

Thanks,
Ashish

On Fri, Dec 11, 2020 at 01:02:08PM +1100, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the swiotlb tree, today's linux-next build (arm
> multi_v7_defconfig) produced this warning:
> 
> In file included from arch/arm/mm/init.c:24:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from include/linux/dma-direct.h:13,
>                  from arch/arm/mm/dma-mapping.c:17:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from include/linux/dma-direct.h:13,
>                  from kernel/dma/direct.h:10,
>                  from kernel/dma/mapping.c:17:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from include/linux/dma-direct.h:13,
>                  from kernel/dma/coherent.c:10:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from include/linux/dma-direct.h:13,
>                  from kernel/dma/direct.h:10,
>                  from kernel/dma/direct.c:16:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from include/linux/dma-direct.h:13,
>                  from drivers/of/device.c:8:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from include/linux/dma-direct.h:13,
>                  from drivers/remoteproc/remoteproc_core.c:27:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from include/linux/dma-direct.h:13,
>                  from drivers/of/address.c:16:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from drivers/mmc/host/sdhci.c:23:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> In file included from drivers/gpu/drm/nouveau/nouveau_bo.c:31:
> include/linux/swiotlb.h:108:13: warning: 'swiotlb_adjust_size' defined but not used [-Wunused-function]
>   108 | static void swiotlb_adjust_size(unsigned long new_size)
>       |             ^~~~~~~~~~~~~~~~~~~
> 
> Introduced by commit
> 
>   79f748d1bdb6 ("x86,swiotlb: Adjust SWIOTLB bounce buffer size for SEV guests")
> 
> Forgot the "inline" :-(
> -- 
> Cheers,
> Stephen Rothwell



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

* Re: linux-next: build warning after merge of the swiotlb tree
  2021-06-16  1:38 Stephen Rothwell
@ 2021-06-16  2:43 ` Konrad Rzeszutek Wilk
  0 siblings, 0 replies; 4+ messages in thread
From: Konrad Rzeszutek Wilk @ 2021-06-16  2:43 UTC (permalink / raw)
  To: Stephen Rothwell
  Cc: Bumyong Lee, Chanho Park, Linux Kernel Mailing List,
	Linux Next Mailing List

On Wed, Jun 16, 2021 at 11:38:35AM +1000, Stephen Rothwell wrote:
> Hi all,
> 
> After merging the swiotlb tree, today's linux-next build (powerpc
> ppc64_defconfig and x86_64 allmodconfig) produced this warning:
> 
> In file included from arch/powerpc/include/asm/bug.h:109,
>                  from include/linux/bug.h:5,
>                  from arch/powerpc/include/asm/mmu.h:147,
>                  from arch/powerpc/include/asm/lppaca.h:46,
>                  from arch/powerpc/include/asm/paca.h:17,
>                  from arch/powerpc/include/asm/current.h:13,
>                  from include/linux/sched.h:12,
>                  from include/linux/ratelimit.h:6,
>                  from include/linux/dev_printk.h:16,
>                  from include/linux/device.h:15,
>                  from include/linux/dma-mapping.h:7,
>                  from include/linux/dma-direct.h:9,
>                  from kernel/dma/swiotlb.c:24:
> kernel/dma/swiotlb.c: In function 'swiotlb_bounce':
> include/linux/dev_printk.h:242:23: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=]
>   242 |  WARN_ONCE(condition, "%s %s: " format, \
>       |                       ^~~~~~~~~
> include/asm-generic/bug.h:97:17: note: in definition of macro '__WARN_printf'
>    97 |   __warn_printk(arg);     \
>       |                 ^~~
> include/asm-generic/bug.h:161:3: note: in expansion of macro 'WARN'
>   161 |   WARN(1, format);    \
>       |   ^~~~
> include/linux/dev_printk.h:242:2: note: in expansion of macro 'WARN_ONCE'
>   242 |  WARN_ONCE(condition, "%s %s: " format, \
>       |  ^~~~~~~~~
> kernel/dma/swiotlb.c:355:3: note: in expansion of macro 'dev_WARN_ONCE'
>   355 |   dev_WARN_ONCE(dev, 1,
>       |   ^~~~~~~~~~~~~
> 
> Introduced by commit
> 
>   17eb5dcf1f15 ("swiotlb: manipulate orig_addr when tlb_addr has offset")

Fixed it up and should be OK in the next run. Thanks!
> 
> -- 
> Cheers,
> Stephen Rothwell



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

* linux-next: build warning after merge of the swiotlb tree
@ 2021-06-16  1:38 Stephen Rothwell
  2021-06-16  2:43 ` Konrad Rzeszutek Wilk
  0 siblings, 1 reply; 4+ messages in thread
From: Stephen Rothwell @ 2021-06-16  1:38 UTC (permalink / raw)
  To: Konrad Rzeszutek Wilk
  Cc: Bumyong Lee, Chanho Park, Linux Kernel Mailing List,
	Linux Next Mailing List

[-- Attachment #1: Type: text/plain, Size: 1826 bytes --]

Hi all,

After merging the swiotlb tree, today's linux-next build (powerpc
ppc64_defconfig and x86_64 allmodconfig) produced this warning:

In file included from arch/powerpc/include/asm/bug.h:109,
                 from include/linux/bug.h:5,
                 from arch/powerpc/include/asm/mmu.h:147,
                 from arch/powerpc/include/asm/lppaca.h:46,
                 from arch/powerpc/include/asm/paca.h:17,
                 from arch/powerpc/include/asm/current.h:13,
                 from include/linux/sched.h:12,
                 from include/linux/ratelimit.h:6,
                 from include/linux/dev_printk.h:16,
                 from include/linux/device.h:15,
                 from include/linux/dma-mapping.h:7,
                 from include/linux/dma-direct.h:9,
                 from kernel/dma/swiotlb.c:24:
kernel/dma/swiotlb.c: In function 'swiotlb_bounce':
include/linux/dev_printk.h:242:23: warning: format '%lu' expects argument of type 'long unsigned int', but argument 4 has type 'unsigned int' [-Wformat=]
  242 |  WARN_ONCE(condition, "%s %s: " format, \
      |                       ^~~~~~~~~
include/asm-generic/bug.h:97:17: note: in definition of macro '__WARN_printf'
   97 |   __warn_printk(arg);     \
      |                 ^~~
include/asm-generic/bug.h:161:3: note: in expansion of macro 'WARN'
  161 |   WARN(1, format);    \
      |   ^~~~
include/linux/dev_printk.h:242:2: note: in expansion of macro 'WARN_ONCE'
  242 |  WARN_ONCE(condition, "%s %s: " format, \
      |  ^~~~~~~~~
kernel/dma/swiotlb.c:355:3: note: in expansion of macro 'dev_WARN_ONCE'
  355 |   dev_WARN_ONCE(dev, 1,
      |   ^~~~~~~~~~~~~

Introduced by commit

  17eb5dcf1f15 ("swiotlb: manipulate orig_addr when tlb_addr has offset")

-- 
Cheers,
Stephen Rothwell

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

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

end of thread, other threads:[~2021-06-16  2:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-11  2:02 linux-next: build warning after merge of the swiotlb tree Stephen Rothwell
2020-12-11  2:47 ` Ashish Kalra
2021-06-16  1:38 Stephen Rothwell
2021-06-16  2:43 ` Konrad Rzeszutek Wilk

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