Thread (17 messages) 17 messages, 4 authors, 2021-04-19

Re: [PATCH v2 3/3] iommu: dart: Add DART iommu driver

From: Sven Peter <hidden>
Date: 2021-03-28 10:13:26
Also in: lkml, oe-kbuild-all

Hi,


On Sun, Mar 28, 2021, at 11:34, kernel test robot wrote:
All error/warnings (new ones prefixed by >>):

   drivers/iommu/apple-dart-iommu.c: In function 'apple_dart_finalize_domain':
quoted
quoted
drivers/iommu/apple-dart-iommu.c:427:34: error: implicit declaration of function 'DMA_BIT_MASK'; did you mean 'BIT_MASK'? [-Werror=implicit-function-declaration]
     427 |  domain->geometry.aperture_end = DMA_BIT_MASK(32);
         |                                  ^~~~~~~~~~~~
         |                                  BIT_MASK

Fixed by adding the missing <linux/dma-mapping.h> include for DMA_BIT_MASK.
   drivers/iommu/apple-dart-iommu.c: In function 'apple_dart_attach_stream':
quoted
quoted
drivers/iommu/apple-dart-iommu.c:456:11: error: implicit declaration of function 'kzalloc'; did you mean 'kvzalloc'? [-Werror=implicit-function-declaration]
     456 |  stream = kzalloc(sizeof(*stream), GFP_KERNEL);
         |           ^~~~~~~
         |           kvzalloc
quoted
quoted
drivers/iommu/apple-dart-iommu.c:456:9: warning: assignment to 'struct apple_dart_stream *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     456 |  stream = kzalloc(sizeof(*stream), GFP_KERNEL);
         |         ^
   drivers/iommu/apple-dart-iommu.c: In function 'apple_dart_detach_stream':
quoted
quoted
drivers/iommu/apple-dart-iommu.c:523:5: error: implicit declaration of function 'kfree'; did you mean 'kvfree'? [-Werror=implicit-function-declaration]
     523 |     kfree(stream);
         |     ^~~~~
         |     kvfree
   drivers/iommu/apple-dart-iommu.c: In function 'apple_dart_domain_alloc':
quoted
quoted
drivers/iommu/apple-dart-iommu.c:627:14: warning: assignment to 'struct apple_dart_domain *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     627 |  dart_domain = kzalloc(sizeof(*dart_domain), GFP_KERNEL);
         |              ^
   drivers/iommu/apple-dart-iommu.c: In function 'apple_dart_of_xlate':
quoted
quoted
drivers/iommu/apple-dart-iommu.c:659:7: warning: assignment to 'struct apple_dart_master_cfg *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     659 |   cfg = kzalloc(struct_size(cfg, streams, 1), GFP_KERNEL);
         |       ^
quoted
quoted
drivers/iommu/apple-dart-iommu.c:663:13: error: implicit declaration 
of function 'krealloc'; did you mean 'kvcalloc'? 
[-Werror=implicit-function-declaration]
     663 |   cfg_new = krealloc(
         |             ^~~~~~~~
         |             kvcalloc
   drivers/iommu/apple-dart-iommu.c:663:11: warning: assignment to 
'struct apple_dart_master_cfg *' from 'int' makes pointer from integer 
without a cast [-Wint-conversion]
     663 |   cfg_new = krealloc(
         |           ^
   cc1: some warnings being treated as errors
Fixed by adding the missing <linux/slab.h> include for krealloc, kfree and kzalloc.


Thanks,

Sven
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help