Re: [viro-vfs:work.alpha 5/8] arch/alpha/kernel/io.c:655:1: error: redefinition of 'scr_memcpyw'

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

 



On Sun, Jan 28, 2024 at 06:59:08AM +0800, kernel test robot wrote:
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git work.alpha
> head:   267674e3b4fd1ff6cedf9b22cd304daa75297966
> commit: 1fb71c4d2bcacd6510fbe411016475ccc15b1a03 [5/8] alpha: missing includes
> config: alpha-allnoconfig (https://download.01.org/0day-ci/archive/20240128/202401280650.Us2Lrkgl-lkp@xxxxxxxxx/config)
> compiler: alpha-linux-gcc (GCC) 13.2.0
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240128/202401280650.Us2Lrkgl-lkp@xxxxxxxxx/reproduce)
> 
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@xxxxxxxxx>
> | Closes: https://lore.kernel.org/oe-kbuild-all/202401280650.Us2Lrkgl-lkp@xxxxxxxxx/
> 
> All errors (new ones prefixed by >>):
> 
> >> arch/alpha/kernel/io.c:655:1: error: redefinition of 'scr_memcpyw'
>      655 | scr_memcpyw(u16 *d, const u16 *s, unsigned int count)
>          | ^~~~~~~~~~~
>    In file included from arch/alpha/kernel/io.c:10:
>    include/linux/vt_buffer.h:42:20: note: previous definition of 'scr_memcpyw' with type 'void(u16 *, const u16 *, unsigned int)' {aka 'void(short unsigned int *, const short unsigned int *, unsigned int)'}
>       42 | static inline void scr_memcpyw(u16 *d, const u16 *s, unsigned int count)
>          |                    ^~~~~~~~~~~

_Very_ interesting.  First of all, there are 3 users of scr_memcpyw() -
vt.c, vgacon.c and fbcon.c.  All of them are getting that thing via
vt_buffer.h.  There we have
* include of asm/vga.h, conditional upon VGA_CONSOLE | MDA_CONSOLE
* fallback definitions of scr_...() stuff, conditional upon the
corresponding VT_BUF_HAVE_... not being defined.

The thing is, VT_BUF_HAVE_... are defined in asm/vga.h, so if you don't
have VGA_CONSOLE or MDA_CONSOLE you are going to get the default ones.
In case of scr_memcpyw() it's going to end up with memcpy(); on alpha
that does *not* match the native scr_memcpyw() instance.

Since we have vga.h in mandatory-y, with asm-generic fallback being
reasonable enough...  Should that include of asm/vga.h be conditional
in the first place?

I'm really unfamiliar with that thing - the last time I'd looked at
anything related to virtual console had been back in '99 or so...




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux