[pm:acpica-osl 6/6] drivers/acpi/acpica/evgpeinit.c:39:3: warning: cast from pointer to integer of different size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git acpica-osl
head:   c32c3c4079f8a62616413abbead45b6622fb7602
commit: c32c3c4079f8a62616413abbead45b6622fb7602 [6/6] ACPI: OSL: Make ACPICA use logical addresses of GPE blocks
config: i386-randconfig-r006-20200904 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce (this is a W=1 build):
        git checkout c32c3c4079f8a62616413abbead45b6622fb7602
        # save the attached .config to linux build tree
        make W=1 ARCH=i386 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All warnings (new ones prefixed by >>):

   drivers/acpi/acpica/evgpeinit.c: In function 'acpi_ev_gpe_initialize':
>> drivers/acpi/acpica/evgpeinit.c:39:3: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
      39 |   (u64)acpi_gbl_xgpe##N##_block_logical_address : \
         |   ^
   drivers/acpi/acpica/evgpeinit.c:99:12: note: in expansion of macro 'ACPI_FADT_GPE_BLOCK_ADDRESS'
      99 |  address = ACPI_FADT_GPE_BLOCK_ADDRESS(0);
         |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/acpi/acpica/evgpeinit.c:39:3: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
      39 |   (u64)acpi_gbl_xgpe##N##_block_logical_address : \
         |   ^
   drivers/acpi/acpica/evgpeinit.c:124:12: note: in expansion of macro 'ACPI_FADT_GPE_BLOCK_ADDRESS'
     124 |  address = ACPI_FADT_GPE_BLOCK_ADDRESS(1);
         |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~
--
   In file included from include/acpi/acpi.h:24,
                    from drivers/acpi/acpica/hwgpe.c:10:
   drivers/acpi/acpica/hwgpe.c: In function 'acpi_hw_gpe_read':
>> include/acpi/actypes.h:501:48: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
     501 | #define ACPI_CAST_PTR(t, p)             ((t *) (acpi_uintptr_t) (p))
         |                                                ^
   drivers/acpi/acpica/acmacros.h:18:41: note: in expansion of macro 'ACPI_CAST_PTR'
      18 | #define ACPI_CAST8(ptr)                 ACPI_CAST_PTR (u8, (ptr))
         |                                         ^~~~~~~~~~~~~
   drivers/acpi/acpica/acmacros.h:22:43: note: in expansion of macro 'ACPI_CAST8'
      22 | #define ACPI_GET8(ptr)                  (*ACPI_CAST8 (ptr))
         |                                           ^~~~~~~~~~
   drivers/acpi/acpica/hwgpe.c:50:17: note: in expansion of macro 'ACPI_GET8'
      50 |   *value = (u64)ACPI_GET8(reg->address);
         |                 ^~~~~~~~~
   drivers/acpi/acpica/hwgpe.c: In function 'acpi_hw_gpe_write':
>> include/acpi/actypes.h:501:48: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
     501 | #define ACPI_CAST_PTR(t, p)             ((t *) (acpi_uintptr_t) (p))
         |                                                ^
   drivers/acpi/acpica/acmacros.h:18:41: note: in expansion of macro 'ACPI_CAST_PTR'
      18 | #define ACPI_CAST8(ptr)                 ACPI_CAST_PTR (u8, (ptr))
         |                                         ^~~~~~~~~~~~~
   drivers/acpi/acpica/acmacros.h:26:43: note: in expansion of macro 'ACPI_CAST8'
      26 | #define ACPI_SET8(ptr, val)             (*ACPI_CAST8 (ptr) = (u8) (val))
         |                                           ^~~~~~~~~~
   drivers/acpi/acpica/hwgpe.c:85:3: note: in expansion of macro 'ACPI_SET8'
      85 |   ACPI_SET8(reg->address, value);
         |   ^~~~~~~~~

# https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git/commit/?id=c32c3c4079f8a62616413abbead45b6622fb7602
git remote add pm https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
git fetch --no-tags pm acpica-osl
git checkout c32c3c4079f8a62616413abbead45b6622fb7602
vim +39 drivers/acpi/acpica/evgpeinit.c

3fe50208b29b24 Bob Moore         2010-04-27  14  
3fe50208b29b24 Bob Moore         2010-04-27  15  #define _COMPONENT          ACPI_EVENTS
3fe50208b29b24 Bob Moore         2010-04-27  16  ACPI_MODULE_NAME("evgpeinit")
33620c5419e8a1 Bob Moore         2012-02-14  17  #if (!ACPI_REDUCED_HARDWARE)	/* Entire module */
da50337373c90c Lin Ming          2010-12-13  18  /*
da50337373c90c Lin Ming          2010-12-13  19   * Note: History of _PRW support in ACPICA
da50337373c90c Lin Ming          2010-12-13  20   *
da50337373c90c Lin Ming          2010-12-13  21   * Originally (2000 - 2010), the GPE initialization code performed a walk of
da50337373c90c Lin Ming          2010-12-13  22   * the entire namespace to execute the _PRW methods and detect all GPEs
da50337373c90c Lin Ming          2010-12-13  23   * capable of waking the system.
da50337373c90c Lin Ming          2010-12-13  24   *
da50337373c90c Lin Ming          2010-12-13  25   * As of 10/2010, the _PRW method execution has been removed since it is
da50337373c90c Lin Ming          2010-12-13  26   * actually unnecessary. The host OS must in fact execute all _PRW methods
da50337373c90c Lin Ming          2010-12-13  27   * in order to identify the device/power-resource dependencies. We now put
da50337373c90c Lin Ming          2010-12-13  28   * the onus on the host OS to identify the wake GPEs as part of this process
da50337373c90c Lin Ming          2010-12-13  29   * and to inform ACPICA of these GPEs via the acpi_setup_gpe_for_wake interface. This
da50337373c90c Lin Ming          2010-12-13  30   * not only reduces the complexity of the ACPICA initialization code, but in
da50337373c90c Lin Ming          2010-12-13  31   * some cases (on systems with very large namespaces) it should reduce the
da50337373c90c Lin Ming          2010-12-13  32   * kernel boot time as well.
da50337373c90c Lin Ming          2010-12-13  33   */
da50337373c90c Lin Ming          2010-12-13  34  
a1705780821d0f Rafael J. Wysocki 2020-09-04  35  #ifdef ACPI_GPE_USE_LOGICAL_ADDRESSES
a1705780821d0f Rafael J. Wysocki 2020-09-04  36  #define ACPI_FADT_GPE_BLOCK_ADDRESS(N)	\
a1705780821d0f Rafael J. Wysocki 2020-09-04  37  	acpi_gbl_FADT.xgpe##N##_block.space_id == \
a1705780821d0f Rafael J. Wysocki 2020-09-04  38  					ACPI_ADR_SPACE_SYSTEM_MEMORY ? \
a1705780821d0f Rafael J. Wysocki 2020-09-04 @39  		(u64)acpi_gbl_xgpe##N##_block_logical_address : \
a1705780821d0f Rafael J. Wysocki 2020-09-04  40  		acpi_gbl_FADT.xgpe##N##_block.address
a1705780821d0f Rafael J. Wysocki 2020-09-04  41  #else
a1705780821d0f Rafael J. Wysocki 2020-09-04  42  #define ACPI_FADT_GPE_BLOCK_ADDRESS(N)	acpi_gbl_FADT.xgpe##N##_block.address
a1705780821d0f Rafael J. Wysocki 2020-09-04  43  #endif		/* ACPI_GPE_USE_LOGICAL_ADDRESSES */
a1705780821d0f Rafael J. Wysocki 2020-09-04  44  

:::::: The code at line 39 was first introduced by commit
:::::: a1705780821d0f36a542bacc21b8c353080a3204 ACPICA: Add support for using logical addresses of GPE blocks

:::::: TO: Rafael J. Wysocki <rafael.j.wysocki@xxxxxxxxx>
:::::: CC: Rafael J. Wysocki <rafael.j.wysocki@xxxxxxxxx>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux