Hej,

I just tried to migrate an 8.1 custom kernel to -current, but failed to compile 
that with build.sh.
It seems this is because of fall-through code ist treated as an error and mfi.c 
does contain that if MFI_DEBUG is activated, at least the compiler thinks so.

MFI_DEBUG is not used in GENERIC or ALL, but nevertheless it is „in the 
source“, so i do think it should work.

This is for mfi.c with __KERNEL_RCSID(0, "$NetBSD: mfi.c,v 1.60 2018/11/24 
18:10:29 bouyer Exp $");
# cvs status mfi.c
===================================================================
File: mfi.c             Status: Up-to-date

   Working revision:    1.60
   Repository revision: 1.60    /cvsroot/src/sys/dev/ic/mfi.c,v
   Commit Identifier:   UN6z1XUdO6jDYd1B
   Sticky Tag:          (none)
   Sticky Date:         (none)
   Sticky Options:      (none)


Output from the compilation attempt (also not the type in the code „fyll“ 
should be „full“):
—
--- mfi.o ---
/usr/src/sys/dev/ic/mfi.c: In function 'mfi_get_bbu':
/usr/src/sys/dev/ic/mfi.c:868:3: error: this statement may fall through 
[-Werror=implicit-fallthrough=]
   printf("\trem capacity %d fyll capacity %d SOH %d\n",
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       stat->detail.bbu.remaining_capacity ,
       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       stat->detail.bbu.full_charge_capacity ,
       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       stat->detail.bbu.is_SOH_good);
       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/src/sys/dev/ic/mfi.c:872:2: note: here
  default:
  ^~~~~~~
—

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to