lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <mhng-5f994c20-0b96-41b1-bb01-9aa8c71228de@palmerdabbelt-glaptop1>
Date:   Tue, 24 Nov 2020 13:14:02 -0800 (PST)
From:   Palmer Dabbelt <palmerdabbelt@...gle.com>
To:     rdunlap@...radead.org
CC:     lkp@...el.com, kbuild-all@...ts.01.org,
        clang-built-linux@...glegroups.com, linux-kernel@...r.kernel.org
Subject:     Re: drivers/clocksource/timer-riscv.c:28:16: error: implicit declaration of function 'get_cycles64'

On Tue, 24 Nov 2020 13:13:07 PST (-0800), rdunlap@...radead.org wrote:
> On 11/21/20 6:26 AM, kernel test robot wrote:
>> Hi Palmer,
>>
>> FYI, the error/warning still remains.
>>
>> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
>> head:   27bba9c532a8d21050b94224ffd310ad0058c353
>> commit: d5be89a8d118a8e8d09cd74a921a808f17fbdd09 RISC-V: Resurrect the MMIO timer implementation for M-mode systems
>> date:   9 weeks ago
>> config: riscv-randconfig-r034-20201121 (attached as .config)
>> compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project bec968cbb367dd03439c89c1d4ef968ef662d7c0)
>> reproduce (this is a W=1 build):
>>          wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>>          chmod +x ~/bin/make.cross
>>          # install riscv cross compiling tool for clang build
>>          # apt-get install binutils-riscv64-linux-gnu
>>          # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=d5be89a8d118a8e8d09cd74a921a808f17fbdd09
>>          git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
>>          git fetch --no-tags linus master
>>          git checkout d5be89a8d118a8e8d09cd74a921a808f17fbdd09
>>          # save the attached .config to linux build tree
>>          COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=riscv
>>
>> If you fix the issue, kindly add following tag as appropriate
>> Reported-by: kernel test robot <lkp@...el.com>
>>
>> All errors (new ones prefixed by >>):
>
> CONFIG_RISCV_M_MODE=y
>
> and that prevents get_cycles64() in
> arch/riscv/include/asm/timex.h from being visible.
>
> I suppose that was intended?

No, I have a fix for it that I'm about to send out.  There's also a bit more necessary.

>
>
>>>> drivers/clocksource/timer-riscv.c:28:16: error: implicit declaration of function 'get_cycles64' [-Werror,-Wimplicit-function-declaration]
>>             sbi_set_timer(get_cycles64() + delta);
>>                           ^
>>     drivers/clocksource/timer-riscv.c:28:16: note: did you mean 'get_cycles'?
>>     arch/riscv/include/asm/timex.h:18:24: note: 'get_cycles' declared here
>>     static inline cycles_t get_cycles(void)
>>                            ^
>>     drivers/clocksource/timer-riscv.c:47:9: error: implicit declaration of function 'get_cycles64' [-Werror,-Wimplicit-function-declaration]
>>             return get_cycles64();
>>                    ^
>>     drivers/clocksource/timer-riscv.c:52:9: error: implicit declaration of function 'get_cycles64' [-Werror,-Wimplicit-function-declaration]
>>             return get_cycles64();
>>                    ^
>>     7 warnings and 3 errors generated.
>>
>> vim +/get_cycles64 +28 drivers/clocksource/timer-riscv.c
>>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ