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] [thread-next>] [day] [month] [year] [list]
Message-ID: <59ba6905-baef-02af-a424-41969f3ad0b3@infradead.org>
Date:   Tue, 24 Nov 2020 13:13:07 -0800
From:   Randy Dunlap <rdunlap@...radead.org>
To:     kernel test robot <lkp@...el.com>,
        Palmer Dabbelt <palmerdabbelt@...gle.com>
Cc:     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 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?


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