linux-riscv.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: Atish Patra <atish.patra@wdc.com>
Cc: Albert Ou <aou@eecs.berkeley.edu>,
	kbuild-all@lists.01.org, Anup Patel <anup@brainfault.org>,
	linux-kernel@vger.kernel.org, Mike Rapoport <rppt@linux.ibm.com>,
	Atish Patra <atish.patra@wdc.com>,
	Palmer Dabbelt <palmer@dabbelt.com>,
	Paul Walmsley <paul.walmsley@sifive.com>,
	linux-riscv@lists.infradead.org,
	Thomas Gleixner <tglx@linutronix.de>, Mao Han <han_mao@c-sky.com>
Subject: Re: [PATCH v4 4/4] RISC-V: Implement new SBI v0.2 extensions
Date: Tue, 26 Nov 2019 14:52:32 +0800	[thread overview]
Message-ID: <201911261435.WbPxe8Dn%lkp@intel.com> (raw)
In-Reply-To: <20191126032033.14825-5-atish.patra@wdc.com>

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

Hi Atish,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on next-20191125]
[cannot apply to linus/master v5.4 v5.4-rc8 v5.4-rc7 v5.4]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Atish-Patra/Add-support-for-SBI-v0-2/20191126-122142
base:    c165016bac2719e05794c216f9b6da730d68d1e3
config: riscv-allnoconfig (attached as .config)
compiler: riscv64-linux-gcc (GCC) 7.4.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        GCC_VERSION=7.4.0 make.cross ARCH=riscv 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   arch/riscv/kernel/sbi.c:71:52: note: format string is defined here
     pr_warn("IPI extension is not available in SBI v%lu.%lu\n",
                                                     ~~^
                                                     %u
   In file included from include/linux/printk.h:7:0,
                    from include/linux/kernel.h:15,
                    from include/linux/list.h:9,
                    from include/linux/pm.h:11,
                    from arch/riscv/kernel/sbi.c:4:
   include/linux/kern_levels.h:5:18: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'int' [-Wformat=]
    #define KERN_SOH "\001"  /* ASCII Start Of Header */
                     ^
   include/linux/kern_levels.h:12:22: note: in expansion of macro 'KERN_SOH'
    #define KERN_WARNING KERN_SOH "4" /* warning conditions */
                         ^~~~~~~~
   include/linux/printk.h:306:9: note: in expansion of macro 'KERN_WARNING'
     printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
            ^~~~~~~~~~~~
   include/linux/printk.h:307:17: note: in expansion of macro 'pr_warning'
    #define pr_warn pr_warning
                    ^~~~~~~~~~
   arch/riscv/kernel/sbi.c:71:2: note: in expansion of macro 'pr_warn'
     pr_warn("IPI extension is not available in SBI v%lu.%lu\n",
     ^~~~~~~
   arch/riscv/kernel/sbi.c:71:56: note: format string is defined here
     pr_warn("IPI extension is not available in SBI v%lu.%lu\n",
                                                         ~~^
                                                         %u
   In file included from include/linux/printk.h:7:0,
                    from include/linux/kernel.h:15,
                    from include/linux/list.h:9,
                    from include/linux/pm.h:11,
                    from arch/riscv/kernel/sbi.c:4:
   arch/riscv/kernel/sbi.c: In function '__sbi_rfence_dummy_warn':
   include/linux/kern_levels.h:5:18: warning: format '%lu' expects argument of type 'long unsigned int', but argument 2 has type 'int' [-Wformat=]
    #define KERN_SOH "\001"  /* ASCII Start Of Header */
                     ^
   include/linux/kern_levels.h:12:22: note: in expansion of macro 'KERN_SOH'
    #define KERN_WARNING KERN_SOH "4" /* warning conditions */
                         ^~~~~~~~
   include/linux/printk.h:306:9: note: in expansion of macro 'KERN_WARNING'
     printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
            ^~~~~~~~~~~~
   include/linux/printk.h:307:17: note: in expansion of macro 'pr_warning'
    #define pr_warn pr_warning
                    ^~~~~~~~~~
   arch/riscv/kernel/sbi.c:83:2: note: in expansion of macro 'pr_warn'
     pr_warn("remote fence extension is not available in SBI v%lu.%lu\n",
     ^~~~~~~
   arch/riscv/kernel/sbi.c:83:61: note: format string is defined here
     pr_warn("remote fence extension is not available in SBI v%lu.%lu\n",
                                                              ~~^
                                                              %u
   In file included from include/linux/printk.h:7:0,
                    from include/linux/kernel.h:15,
                    from include/linux/list.h:9,
                    from include/linux/pm.h:11,
                    from arch/riscv/kernel/sbi.c:4:
   include/linux/kern_levels.h:5:18: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'int' [-Wformat=]
    #define KERN_SOH "\001"  /* ASCII Start Of Header */
                     ^
   include/linux/kern_levels.h:12:22: note: in expansion of macro 'KERN_SOH'
    #define KERN_WARNING KERN_SOH "4" /* warning conditions */
                         ^~~~~~~~
   include/linux/printk.h:306:9: note: in expansion of macro 'KERN_WARNING'
     printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
            ^~~~~~~~~~~~
   include/linux/printk.h:307:17: note: in expansion of macro 'pr_warning'
    #define pr_warn pr_warning
                    ^~~~~~~~~~
   arch/riscv/kernel/sbi.c:83:2: note: in expansion of macro 'pr_warn'
     pr_warn("remote fence extension is not available in SBI v%lu.%lu\n",
     ^~~~~~~
   arch/riscv/kernel/sbi.c:83:65: note: format string is defined here
     pr_warn("remote fence extension is not available in SBI v%lu.%lu\n",
                                                                  ~~^
                                                                  %u
   arch/riscv/kernel/sbi.c: In function '__sbi_set_timer_v02':
   arch/riscv/kernel/sbi.c:214:12: error: 'SBI_EXT_TIME' undeclared (first use in this function); did you mean 'STA_PPSTIME'?
     sbi_ecall(SBI_EXT_TIME, SBI_EXT_TIME_SET_TIMER, stime_value, 0,
               ^~~~~~~~~~~~
               STA_PPSTIME
   arch/riscv/kernel/sbi.c:214:26: error: 'SBI_EXT_TIME_SET_TIMER' undeclared (first use in this function); did you mean 'SBI_EXT_TIME'?
     sbi_ecall(SBI_EXT_TIME, SBI_EXT_TIME_SET_TIMER, stime_value, 0,
                             ^~~~~~~~~~~~~~~~~~~~~~
                             SBI_EXT_TIME
   arch/riscv/kernel/sbi.c: In function '__sbi_send_ipi_v02':
   arch/riscv/kernel/sbi.c:222:9: error: variable 'ret' has initializer but incomplete type
     struct sbiret ret = {0};
            ^~~~~~
   arch/riscv/kernel/sbi.c:222:23: warning: excess elements in struct initializer
     struct sbiret ret = {0};
                          ^
   arch/riscv/kernel/sbi.c:222:23: note: (near initialization for 'ret')
   arch/riscv/kernel/sbi.c:222:16: error: storage size of 'ret' isn't known
     struct sbiret ret = {0};
                   ^~~
   arch/riscv/kernel/sbi.c:230:18: error: 'SBI_EXT_IPI' undeclared (first use in this function)
     ret = sbi_ecall(SBI_EXT_IPI, SBI_EXT_IPI_SEND_IPI, hmask_val,
                     ^~~~~~~~~~~
>> arch/riscv/kernel/sbi.c:230:31: error: 'SBI_EXT_IPI_SEND_IPI' undeclared (first use in this function); did you mean 'SBI_EXT_IPI'?
     ret = sbi_ecall(SBI_EXT_IPI, SBI_EXT_IPI_SEND_IPI, hmask_val,
                                  ^~~~~~~~~~~~~~~~~~~~
                                  SBI_EXT_IPI
   arch/riscv/kernel/sbi.c:222:16: warning: unused variable 'ret' [-Wunused-variable]
     struct sbiret ret = {0};
                   ^~~
   arch/riscv/kernel/sbi.c: In function '__sbi_rfence_v02':
   arch/riscv/kernel/sbi.c:249:9: error: variable 'ret' has initializer but incomplete type
     struct sbiret ret = {0};
            ^~~~~~
   arch/riscv/kernel/sbi.c:249:23: warning: excess elements in struct initializer
     struct sbiret ret = {0};
                          ^
   arch/riscv/kernel/sbi.c:249:23: note: (near initialization for 'ret')
   arch/riscv/kernel/sbi.c:249:16: error: storage size of 'ret' isn't known
     struct sbiret ret = {0};
                   ^~~
   arch/riscv/kernel/sbi.c:251:22: error: 'SBI_EXT_RFENCE' undeclared (first use in this function); did you mean 'RISCV_FENCE'?
     unsigned long ext = SBI_EXT_RFENCE;
                         ^~~~~~~~~~~~~~
                         RISCV_FENCE
   arch/riscv/kernel/sbi.c:259:7: error: 'SBI_EXT_RFENCE_REMOTE_FENCE_I' undeclared (first use in this function)
     case SBI_EXT_RFENCE_REMOTE_FENCE_I:
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c:262:7: error: 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA' undeclared (first use in this function); did you mean 'SBI_EXT_RFENCE_REMOTE_FENCE_I'?
     case SBI_EXT_RFENCE_REMOTE_SFENCE_VMA:
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          SBI_EXT_RFENCE_REMOTE_FENCE_I
   arch/riscv/kernel/sbi.c:266:7: error: 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID' undeclared (first use in this function); did you mean 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA'?
     case SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID:
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          SBI_EXT_RFENCE_REMOTE_SFENCE_VMA
>> arch/riscv/kernel/sbi.c:271:7: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA' undeclared (first use in this function); did you mean 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA'?
     case SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA:
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          SBI_EXT_RFENCE_REMOTE_SFENCE_VMA
>> arch/riscv/kernel/sbi.c:275:7: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA_VMID' undeclared (first use in this function); did you mean 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID'?
     case SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA_VMID:
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID
>> arch/riscv/kernel/sbi.c:279:7: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA' undeclared (first use in this function); did you mean 'SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA'?
     case SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA:
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA
>> arch/riscv/kernel/sbi.c:283:7: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA_ASID' undeclared (first use in this function); did you mean 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID'?
     case SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA_ASID:
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID
   arch/riscv/kernel/sbi.c:249:16: warning: unused variable 'ret' [-Wunused-variable]
     struct sbiret ret = {0};
                   ^~~
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_fence_i':
   arch/riscv/kernel/sbi.c:335:15: error: 'SBI_EXT_0_1_REMOTE_FENCE_I' undeclared (first use in this function)
     __sbi_rfence(SBI_EXT_0_1_REMOTE_FENCE_I, SBI_EXT_RFENCE_REMOTE_FENCE_I,
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c:335:43: error: 'SBI_EXT_RFENCE_REMOTE_FENCE_I' undeclared (first use in this function); did you mean 'SBI_EXT_0_1_REMOTE_FENCE_I'?
     __sbi_rfence(SBI_EXT_0_1_REMOTE_FENCE_I, SBI_EXT_RFENCE_REMOTE_FENCE_I,
                                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                              SBI_EXT_0_1_REMOTE_FENCE_I
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_sfence_vma':
   arch/riscv/kernel/sbi.c:353:15: error: 'SBI_EXT_0_1_REMOTE_SFENCE_VMA' undeclared (first use in this function)
     __sbi_rfence(SBI_EXT_0_1_REMOTE_SFENCE_VMA,
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> arch/riscv/kernel/sbi.c:354:8: error: 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA' undeclared (first use in this function); did you mean 'SBI_EXT_0_1_REMOTE_SFENCE_VMA'?
           SBI_EXT_RFENCE_REMOTE_SFENCE_VMA,
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
           SBI_EXT_0_1_REMOTE_SFENCE_VMA
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_sfence_vma_asid':
   arch/riscv/kernel/sbi.c:375:15: error: 'SBI_EXT_0_1_REMOTE_SFENCE_VMA_ASID' undeclared (first use in this function)
     __sbi_rfence(SBI_EXT_0_1_REMOTE_SFENCE_VMA_ASID,
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> arch/riscv/kernel/sbi.c:376:8: error: 'SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID' undeclared (first use in this function); did you mean 'SBI_EXT_0_1_REMOTE_SFENCE_VMA_ASID'?
           SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID,
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
           SBI_EXT_0_1_REMOTE_SFENCE_VMA_ASID
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_gvma':
   arch/riscv/kernel/sbi.c:394:22: error: 'SBI_EXT_RFENCE' undeclared (first use in this function); did you mean 'RISCV_FENCE'?
     return __sbi_rfence(SBI_EXT_RFENCE, SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA,
                         ^~~~~~~~~~~~~~
                         RISCV_FENCE
   arch/riscv/kernel/sbi.c:394:38: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA' undeclared (first use in this function)
     return __sbi_rfence(SBI_EXT_RFENCE, SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA,
                                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_gvma_vmid':
   arch/riscv/kernel/sbi.c:415:22: error: 'SBI_EXT_RFENCE' undeclared (first use in this function); did you mean 'RISCV_FENCE'?
     return __sbi_rfence(SBI_EXT_RFENCE,
                         ^~~~~~~~~~~~~~
                         RISCV_FENCE
   arch/riscv/kernel/sbi.c:416:8: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA_VMID' undeclared (first use in this function)
           SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA_VMID,
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_vvma':
   arch/riscv/kernel/sbi.c:434:22: error: 'SBI_EXT_RFENCE' undeclared (first use in this function); did you mean 'RISCV_FENCE'?
     return __sbi_rfence(SBI_EXT_RFENCE, SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA,
                         ^~~~~~~~~~~~~~
                         RISCV_FENCE
   arch/riscv/kernel/sbi.c:434:38: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA' undeclared (first use in this function)
     return __sbi_rfence(SBI_EXT_RFENCE, SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA,
                                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_vvma_asid':
   arch/riscv/kernel/sbi.c:456:22: error: 'SBI_EXT_RFENCE' undeclared (first use in this function); did you mean 'RISCV_FENCE'?
     return __sbi_rfence(SBI_EXT_RFENCE,
                         ^~~~~~~~~~~~~~
                         RISCV_FENCE
   arch/riscv/kernel/sbi.c:457:8: error: 'SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA_ASID' undeclared (first use in this function)
           SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA_ASID,
           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c: In function 'sbi_probe_extension':
   arch/riscv/kernel/sbi.c:470:16: error: storage size of 'ret' isn't known
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c:472:18: error: 'SBI_EXT_BASE' undeclared (first use in this function); did you mean 'BIT_MASK'?
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_PROBE_EXT, extid, 0, 0, 0, 0, 0);
                     ^~~~~~~~~~~~
                     BIT_MASK
   arch/riscv/kernel/sbi.c:472:32: error: 'SBI_BASE_PROBE_EXT' undeclared (first use in this function)
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_PROBE_EXT, extid, 0, 0, 0, 0, 0);
                                   ^~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c:470:16: warning: unused variable 'ret' [-Wunused-variable]
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c: In function 'sbi_get_spec_version':
   arch/riscv/kernel/sbi.c:484:16: error: storage size of 'ret' isn't known
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c:486:18: error: 'SBI_EXT_BASE' undeclared (first use in this function); did you mean 'BIT_MASK'?
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_GET_SPEC_VERSION,
                     ^~~~~~~~~~~~
                     BIT_MASK
   arch/riscv/kernel/sbi.c:486:32: error: 'SBI_BASE_GET_SPEC_VERSION' undeclared (first use in this function)
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_GET_SPEC_VERSION,
                                   ^~~~~~~~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c:484:16: warning: unused variable 'ret' [-Wunused-variable]
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c: In function 'sbi_get_firmware_id':
   arch/riscv/kernel/sbi.c:496:16: error: storage size of 'ret' isn't known
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c:498:18: error: 'SBI_EXT_BASE' undeclared (first use in this function); did you mean 'BIT_MASK'?
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_GET_IMP_ID,
                     ^~~~~~~~~~~~
                     BIT_MASK
   arch/riscv/kernel/sbi.c:498:32: error: 'SBI_BASE_GET_IMP_ID' undeclared (first use in this function)
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_GET_IMP_ID,
                                   ^~~~~~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c:496:16: warning: unused variable 'ret' [-Wunused-variable]
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c: In function 'sbi_get_firmware_version':
   arch/riscv/kernel/sbi.c:508:16: error: storage size of 'ret' isn't known
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c:510:18: error: 'SBI_EXT_BASE' undeclared (first use in this function); did you mean 'BIT_MASK'?
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_GET_IMP_VERSION,
                     ^~~~~~~~~~~~
                     BIT_MASK
   arch/riscv/kernel/sbi.c:510:32: error: 'SBI_BASE_GET_IMP_VERSION' undeclared (first use in this function); did you mean '__GXX_ABI_VERSION'?
     ret = sbi_ecall(SBI_EXT_BASE, SBI_BASE_GET_IMP_VERSION,
                                   ^~~~~~~~~~~~~~~~~~~~~~~~
                                   __GXX_ABI_VERSION
   arch/riscv/kernel/sbi.c:508:16: warning: unused variable 'ret' [-Wunused-variable]
     struct sbiret ret;
                   ^~~
   arch/riscv/kernel/sbi.c: In function 'sbi_power_off':
   arch/riscv/kernel/sbi.c:520:2: error: implicit declaration of function 'sbi_shutdown' [-Werror=implicit-function-declaration]
     sbi_shutdown();
     ^~~~~~~~~~~~
   In file included from include/linux/printk.h:7:0,
                    from include/linux/kernel.h:15,
                    from include/linux/list.h:9,
                    from include/linux/pm.h:11,
                    from arch/riscv/kernel/sbi.c:4:
   arch/riscv/kernel/sbi.c: In function 'sbi_init':
   include/linux/kern_levels.h:5:18: warning: format '%lu' expects argument of type 'long unsigned int', but argument 2 has type 'int' [-Wformat=]
    #define KERN_SOH "\001"  /* ASCII Start Of Header */
                     ^
   include/linux/kern_levels.h:14:19: note: in expansion of macro 'KERN_SOH'
    #define KERN_INFO KERN_SOH "6" /* informational */
                      ^~~~~~~~
   include/linux/printk.h:311:9: note: in expansion of macro 'KERN_INFO'
     printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
            ^~~~~~~~~
   arch/riscv/kernel/sbi.c:532:2: note: in expansion of macro 'pr_info'
     pr_info("SBI specification v%lu.%lu detected\n",
     ^~~~~~~
   arch/riscv/kernel/sbi.c:532:32: note: format string is defined here
     pr_info("SBI specification v%lu.%lu detected\n",
                                 ~~^
                                 %u
   In file included from include/linux/printk.h:7:0,
                    from include/linux/kernel.h:15,
                    from include/linux/list.h:9,
                    from include/linux/pm.h:11,
                    from arch/riscv/kernel/sbi.c:4:
   include/linux/kern_levels.h:5:18: warning: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'int' [-Wformat=]
    #define KERN_SOH "\001"  /* ASCII Start Of Header */
                     ^
   include/linux/kern_levels.h:14:19: note: in expansion of macro 'KERN_SOH'
    #define KERN_INFO KERN_SOH "6" /* informational */
                      ^~~~~~~~
   include/linux/printk.h:311:9: note: in expansion of macro 'KERN_INFO'
     printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__)
            ^~~~~~~~~
   arch/riscv/kernel/sbi.c:532:2: note: in expansion of macro 'pr_info'
     pr_info("SBI specification v%lu.%lu detected\n",
     ^~~~~~~
   arch/riscv/kernel/sbi.c:532:36: note: format string is defined here
     pr_info("SBI specification v%lu.%lu detected\n",
                                     ~~^
                                     %u
   arch/riscv/kernel/sbi.c:535:6: error: implicit declaration of function 'sbi_spec_is_0_1' [-Werror=implicit-function-declaration]
     if (sbi_spec_is_0_1()) {
         ^~~~~~~~~~~~~~~
   arch/riscv/kernel/sbi.c:542:27: error: 'SBI_EXT_TIME' undeclared (first use in this function); did you mean 'STA_PPSTIME'?
      if (sbi_probe_extension(SBI_EXT_TIME) > 0)
                              ^~~~~~~~~~~~
                              STA_PPSTIME
>> arch/riscv/kernel/sbi.c:546:27: error: 'SBI_EXT_IPI' undeclared (first use in this function); did you mean 'SBI_EXT_TIME'?
      if (sbi_probe_extension(SBI_EXT_IPI) > 0)
                              ^~~~~~~~~~~
                              SBI_EXT_TIME
>> arch/riscv/kernel/sbi.c:550:27: error: 'SBI_EXT_RFENCE' undeclared (first use in this function); did you mean 'SBI_EXT_TIME'?
      if (sbi_probe_extension(SBI_EXT_RFENCE) > 0)
                              ^~~~~~~~~~~~~~
                              SBI_EXT_TIME
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_gvma':
   arch/riscv/kernel/sbi.c:396:1: warning: control reaches end of non-void function [-Wreturn-type]
    }
    ^
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_gvma_vmid':
   arch/riscv/kernel/sbi.c:418:1: warning: control reaches end of non-void function [-Wreturn-type]
    }
    ^
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_vvma':
   arch/riscv/kernel/sbi.c:436:1: warning: control reaches end of non-void function [-Wreturn-type]
    }
    ^
   arch/riscv/kernel/sbi.c: In function 'sbi_remote_hfence_vvma_asid':
   arch/riscv/kernel/sbi.c:459:1: warning: control reaches end of non-void function [-Wreturn-type]
    }
    ^
   arch/riscv/kernel/sbi.c: In function 'sbi_get_spec_version':
   arch/riscv/kernel/sbi.c:492:1: warning: control reaches end of non-void function [-Wreturn-type]
    }
    ^
   arch/riscv/kernel/sbi.c: In function 'sbi_get_firmware_id':
   arch/riscv/kernel/sbi.c:504:1: warning: control reaches end of non-void function [-Wreturn-type]
    }
    ^
   arch/riscv/kernel/sbi.c: In function 'sbi_get_firmware_version':
   arch/riscv/kernel/sbi.c:516:1: warning: control reaches end of non-void function [-Wreturn-type]
    }
    ^
   cc1: some warnings being treated as errors

vim +230 arch/riscv/kernel/sbi.c

   218	
   219	static int __sbi_send_ipi_v02(const unsigned long *hart_mask)
   220	{
   221		unsigned long hmask_val;
 > 222		struct sbiret ret = {0};
   223		int result;
   224	
   225		if (!hart_mask)
   226			hmask_val = *(cpumask_bits(cpu_online_mask));
   227		else
   228			hmask_val = *hart_mask;
   229	
 > 230		ret = sbi_ecall(SBI_EXT_IPI, SBI_EXT_IPI_SEND_IPI, hmask_val,
   231				0, 0, 0, 0, 0);
   232		if (ret.error) {
   233			pr_err("%s: failed with error [%d]\n", __func__,
   234				sbi_err_map_linux_errno(ret.error));
   235			result = ret.error;
   236		} else
   237			result = ret.value;
   238	
   239		return result;
   240	}
   241	
   242	static int __sbi_rfence_v02(unsigned long extid, unsigned long fid,
   243				     const unsigned long *hart_mask,
   244				     unsigned long hbase, unsigned long start,
   245				     unsigned long size, unsigned long arg4,
   246				     unsigned long arg5)
   247	{
   248		unsigned long hmask_val;
   249		struct sbiret ret = {0};
   250		int result;
   251		unsigned long ext = SBI_EXT_RFENCE;
   252	
   253		if (!hart_mask)
   254			hmask_val = *(cpumask_bits(cpu_online_mask));
   255		else
   256			hmask_val = *hart_mask;
   257	
   258		switch (fid) {
   259		case SBI_EXT_RFENCE_REMOTE_FENCE_I:
   260			ret = sbi_ecall(ext, fid, hmask_val, 0, 0, 0, 0, 0);
   261			break;
 > 262		case SBI_EXT_RFENCE_REMOTE_SFENCE_VMA:
   263			ret = sbi_ecall(ext, fid, hmask_val, 0, start,
   264					size, 0, 0);
   265			break;
 > 266		case SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID:
   267			ret = sbi_ecall(ext, fid, hmask_val, 0, start,
   268					size, arg4, 0);
   269			break;
   270		/*TODO: Handle non zero hbase cases */
 > 271		case SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA:
   272			ret = sbi_ecall(ext, fid, hmask_val, 0, start,
   273					size, 0, 0);
   274			break;
 > 275		case SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA_VMID:
   276			ret = sbi_ecall(ext, fid, hmask_val, 0, start,
   277					size, arg4, 0);
   278			break;
 > 279		case SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA:
   280			ret = sbi_ecall(ext, fid, hmask_val, 0, start,
   281					size, 0, 0);
   282			break;
 > 283		case SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA_ASID:
   284			ret = sbi_ecall(ext, fid, hmask_val, 0, start,
   285					size, arg4, 0);
   286			break;
   287		default:
   288			pr_err("unknown function ID [%lu] for SBI extension [%lu]\n",
   289				fid, ext);
   290			result = -EINVAL;
   291		}
   292	
   293		if (ret.error) {
   294			pr_err("%s: failed with error [%d]\n", __func__,
   295				sbi_err_map_linux_errno(ret.error));
   296			result = ret.error;
   297		} else
   298			result = ret.value;
   299	
   300		return result;
   301	}
   302	
   303	/**
   304	 * sbi_set_timer() - Program the timer for next timer event.
   305	 * @stime_value: The value after which next timer event should fire.
   306	 *
   307	 * Return: None
   308	 */
   309	void sbi_set_timer(uint64_t stime_value)
   310	{
   311		__sbi_set_timer(stime_value);
   312	}
   313	
   314	/**
   315	 * sbi_send_ipi() - Send an IPI to any hart.
   316	 * @hart_mask: A cpu mask containing all the target harts.
   317	 *
   318	 * Return: None
   319	 */
   320	void sbi_send_ipi(const unsigned long *hart_mask)
   321	{
   322		__sbi_send_ipi(hart_mask);
   323	}
   324	EXPORT_SYMBOL(sbi_send_ipi);
   325	
   326	
   327	/**
   328	 * sbi_remote_fence_i() - Execute FENCE.I instruction on given remote harts.
   329	 * @hart_mask: A cpu mask containing all the target harts.
   330	 *
   331	 * Return: None
   332	 */
   333	void sbi_remote_fence_i(const unsigned long *hart_mask)
   334	{
 > 335		__sbi_rfence(SBI_EXT_0_1_REMOTE_FENCE_I, SBI_EXT_RFENCE_REMOTE_FENCE_I,
   336			     hart_mask, 0, 0, 0, 0, 0);
   337	}
   338	EXPORT_SYMBOL(sbi_remote_fence_i);
   339	
   340	/**
   341	 * sbi_remote_sfence_vma() - Execute SFENCE.VMA instructions on given remote
   342	 *			     harts for the specified virtual address range.
   343	 * @hart_mask: A cpu mask containing all the target harts.
   344	 * @start: Start of the virtual address
   345	 * @size: Total size of the virtual address range.
   346	 *
   347	 * Return: None
   348	 */
   349	void sbi_remote_sfence_vma(const unsigned long *hart_mask,
   350						 unsigned long start,
   351						 unsigned long size)
   352	{
   353		__sbi_rfence(SBI_EXT_0_1_REMOTE_SFENCE_VMA,
 > 354			     SBI_EXT_RFENCE_REMOTE_SFENCE_VMA,
   355			     hart_mask, 0, start, size, 0, 0);
   356	}
   357	EXPORT_SYMBOL(sbi_remote_sfence_vma);
   358	
   359	/**
   360	 * sbi_remote_sfence_vma_asid() - Execute SFENCE.VMA instructions on given
   361	 * remote harts for a virtual address range belonging to a specific ASID.
   362	 *
   363	 * @hart_mask: A cpu mask containing all the target harts.
   364	 * @start: Start of the virtual address
   365	 * @size: Total size of the virtual address range.
   366	 * @asid: The value of address space identifier (ASID).
   367	 *
   368	 * Return: None
   369	 */
   370	void sbi_remote_sfence_vma_asid(const unsigned long *hart_mask,
   371						      unsigned long start,
   372						      unsigned long size,
   373						      unsigned long asid)
   374	{
   375		__sbi_rfence(SBI_EXT_0_1_REMOTE_SFENCE_VMA_ASID,
 > 376			     SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID,
   377			     hart_mask, 0, start, size, asid, 0);
   378	}
   379	EXPORT_SYMBOL(sbi_remote_sfence_vma_asid);
   380	

---
0-DAY kernel test infrastructure                 Open Source Technology Center
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 5332 bytes --]

[-- Attachment #3: Type: text/plain, Size: 161 bytes --]

_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

      parent reply	other threads:[~2019-11-26  6:53 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-26  3:20 [PATCH v4 0/4] Add support for SBI v0.2 Atish Patra
2019-11-26  3:20 ` [PATCH v4 1/4] RISC-V: Mark existing SBI as 0.1 SBI Atish Patra
2019-11-26  4:10   ` Anup Patel
2019-11-26  3:20 ` [PATCH v4 2/4] RISC-V: Add basic support for SBI v0.2 Atish Patra
2019-11-26  4:11   ` Anup Patel
2019-11-26  3:20 ` [PATCH v4 3/4] RISC-V: Introduce a new config for SBI v0.1 Atish Patra
2019-11-26  4:14   ` Anup Patel
2019-11-26 18:12     ` Atish Patra
2019-11-26  3:20 ` [PATCH v4 4/4] RISC-V: Implement new SBI v0.2 extensions Atish Patra
2019-11-26  4:16   ` Anup Patel
2019-11-26 18:13     ` Atish Patra
2019-11-26  6:52   ` kbuild test robot [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201911261435.WbPxe8Dn%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=anup@brainfault.org \
    --cc=aou@eecs.berkeley.edu \
    --cc=atish.patra@wdc.com \
    --cc=han_mao@c-sky.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    --cc=rppt@linux.ibm.com \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).