librem-ec-acpi-dkms FTBS with linux 6.2

Bug #2009511 reported by Andrea Righi
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
librem-ec-acpi (Ubuntu)
Fix Released
Undecided
Unassigned
Lunar
Fix Released
Undecided
Unassigned

Bug Description

[Impact]

librem-ec-acpi-dkms fails to build with linux 6.2:

/var/lib/dkms/librem_ec_acpi/0.9.1/build/librem_ec_acpi.c:276:24: error: initialization of ‘int (*)(struct power_supply *, struct acpi_battery_hook *)’ from incompatible pointer type ‘int (*)(struct power_supply *)’ [-Werror=incompatible-pointer-types]
  276 | .add_battery = librem_ec_battery_add,
      | ^~~~~~~~~~~~~~~~~~~~~
/var/lib/dkms/librem_ec_acpi/0.9.1/build/librem_ec_acpi.c:276:24: note: (near initialization for ‘librem_ec_battery_hook.add_battery’)
/var/lib/dkms/librem_ec_acpi/0.9.1/build/librem_ec_acpi.c:277:27: error: initialization of ‘int (*)(struct power_supply *, struct acpi_battery_hook *)’ from incompatible pointer type ‘int (*)(struct power_supply *)’ [-Werror=incompatible-pointer-types]
  277 | .remove_battery = librem_ec_battery_remove,
      | ^~~~~~~~~~~~~~~~~~~~~~~~
/var/lib/dkms/librem_ec_acpi/0.9.1/build/librem_ec_acpi.c:277:27: note: (near initialization for ‘librem_ec_battery_hook.remove_battery’)
/var/lib/dkms/librem_ec_acpi/0.9.1/build/librem_ec_acpi.c:773:27: error: initialization of ‘void (*)(struct acpi_device *)’ from incompatible pointer type ‘int (*)(struct acpi_device *)’ [-Werror=incompatible-pointer-types]
  773 | .remove = librem_ec_remove,
      | ^~~~~~~~~~~~~~~~

[Test case]

$ sudo apt install librem-ec-acpi-dkms

[Fix]

Patch librem-ec-acpi-dkms to support the new 6.2 kernel ABI.

[Regression potential]

Users of librem-ec-acpi-dkms with linux 6.2 may experience regressions, source code is unchanged with previous kernels.

ProblemType: Bug
DistroRelease: Ubuntu 23.04
Package: librem-ec-acpi-dkms 0.9.1-2ubuntu2
ProcVersionSignature: User Name 6.2.0-1.1-generic 6.2.1
Uname: Linux 6.2.0-1-generic x86_64
ApportVersion: 2.26.0-0ubuntu2
Architecture: amd64
CasperMD5CheckResult: unknown
CloudBuildName: server
CloudSerial: 20230202
Date: Mon Mar 6 16:13:40 2023
PackageArchitecture: all
SourcePackage: librem-ec-acpi
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Andrea Righi (arighi) wrote :
Revision history for this message
Andrea Righi (arighi) wrote :

debdiff in attach, applied on top of the latest Debian sid version librem-ec-acpi (0.9.1-4), allows to build librem-ec-acpi with linux 6.2.

[ resync with Debian is not really needed to support linux 6.2, but it's better to keep this package aligned ]

tags: added: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package librem-ec-acpi - 0.9.1-4ubuntu1

---------------
librem-ec-acpi (0.9.1-4ubuntu1) lunar; urgency=medium

  * Resync with Debian version 0.9.1-4, adding the following Ubuntu specific
    change:
    - Build librem-ec-acpi-dkms modules only on kernels that have
      CONFIG_ACPI_BATTERY turned on.
  * Support linux 6.2 ABI (LP: #2009511):
    - debian/patches/0001-fix-compilation-on-linux-6.2.1.patch

 -- Andrea Righi <email address hidden> Mon, 06 Mar 2023 16:24:04 +0000

Changed in librem-ec-acpi (Ubuntu Lunar):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.