]> git.baikalelectronics.ru Git - kernel.git/commit
net: i825xx: Use absolute_pointer for memcpy from fixed memory location
authorGuenter Roeck <linux@roeck-us.net>
Wed, 15 Sep 2021 03:52:25 +0000 (20:52 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 15 Sep 2021 19:04:28 +0000 (12:04 -0700)
commitb906e5589b50ff60402a740d8449d537bc0bb549
treeb6d356dabf212ebd062da23da8a98e5f079ecebe
parentdfbcd091b8a50779310f9d6b2ccb4affbf1a984f
net: i825xx: Use absolute_pointer for memcpy from fixed memory location

gcc 11.x reports the following compiler warning/error.

  drivers/net/ethernet/i825xx/82596.c: In function 'i82596_probe':
  arch/m68k/include/asm/string.h:72:25: error:
'__builtin_memcpy' reading 6 bytes from a region of size 0 [-Werror=stringop-overread]

Use absolute_pointer() to work around the problem.

Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/net/ethernet/i825xx/82596.c