← Back to team overview

group.of.nepali.translators team mailing list archive

[Bug 1842110] Re: rt-tests backfire dkms module fails to build on ppc64el

 

** Changed in: rt-tests (Ubuntu)
       Status: New => Fix Released

-- 
You received this bug notification because you are a member of नेपाली
भाषा समायोजकहरुको समूह, which is subscribed to Xenial.
Matching subscriptions: Ubuntu 16.04 Bugs
https://bugs.launchpad.net/bugs/1842110

Title:
  rt-tests backfire dkms module fails to build on ppc64el

Status in ubuntu-kernel-tests:
  New
Status in rt-tests package in Ubuntu:
  Fix Released
Status in rt-tests source package in Xenial:
  Confirmed

Bug description:
  An update to the powerpc arch in xenial/linux-hwe exposed a bug in the backfire dkms module in rt-tests. The backfire dkms module fails to build with the following error:
  ---
  make: Entering directory '/usr/src/linux-headers-4.15.0-60-generic'
    CC [M]  /var/lib/dkms/backfire/0.84-2/build/backfire.o
  In file included from ./include/linux/kernel.h:10:0,
                   from ./include/linux/list.h:9,
                   from ./include/linux/module.h:9,
                   from /var/lib/dkms/backfire/0.84-2/build/backfire.c:22:
  ./arch/powerpc/include/asm/uaccess.h: In function ‘clear_user’:
  ./arch/powerpc/include/asm/uaccess.h:368:23: error: ‘VERIFY_WRITE’ undeclared (first use in this function)
    if (likely(access_ok(VERIFY_WRITE, addr, size)))
                         ^
  ./include/linux/compiler.h:76:40: note: in definition of macro ‘likely’
   # define likely(x) __builtin_expect(!!(x), 1)
                                          ^
  ./arch/powerpc/include/asm/uaccess.h:368:13: note: in expansion of macro ‘access_ok’
    if (likely(access_ok(VERIFY_WRITE, addr, size)))
               ^
  ./arch/powerpc/include/asm/uaccess.h:368:23: note: each undeclared identifier is reported only once for each function it appears in
    if (likely(access_ok(VERIFY_WRITE, addr, size)))
                         ^
  ./include/linux/compiler.h:76:40: note: in definition of macro ‘likely’
   # define likely(x) __builtin_expect(!!(x), 1)
                                          ^
  ./arch/powerpc/include/asm/uaccess.h:368:13: note: in expansion of macro ‘access_ok’
    if (likely(access_ok(VERIFY_WRITE, addr, size)))
               ^
  ./arch/powerpc/include/asm/uaccess.h:57:37: warning: left-hand operand of comma expression has no effect [-Wunused-value]
    (__chk_user_ptr(addr), (void)(type),  \
                                       ^
  ./include/linux/compiler.h:76:40: note: in definition of macro ‘likely’
   # define likely(x) __builtin_expect(!!(x), 1)
                                          ^
  ./arch/powerpc/include/asm/uaccess.h:368:13: note: in expansion of macro ‘access_ok’
    if (likely(access_ok(VERIFY_WRITE, addr, size)))
               ^
  scripts/Makefile.build:337: recipe for target '/var/lib/dkms/backfire/0.84-2/build/backfire.o' failed
  make[1]: *** [/var/lib/dkms/backfire/0.84-2/build/backfire.o] Error 1
  Makefile:1571: recipe for target '_module_/var/lib/dkms/backfire/0.84-2/build' failed
  make: *** [_module_/var/lib/dkms/backfire/0.84-2/build] Error 2
  make: Leaving directory '/usr/src/linux-headers-4.15.0-60-generic'
  ---

  This occurs because backfire.c includes arch-specific uaccess.h
  headers directly (via "#include <asm/uaccess.h>"), which is incorrect
  because arch-specific uaccess.h can have dependencies on the
  linux/uaccess.h header. The linux/uaccess.h header includes
  asm/uaccess.h, so the fix is to replace "#include <asm/uaccess.h>"
  with "#include <linux/uaccess.h>" in the backfire.c file.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/1842110/+subscriptions