Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: fixing package version QA issue for linux-firmware updates #298

Closed
pabigot opened this issue Jul 29, 2018 · 7 comments · Fixed by #331
Closed

RFC: fixing package version QA issue for linux-firmware updates #298

pabigot opened this issue Jul 29, 2018 · 7 comments · Fixed by #331

Comments

@pabigot
Copy link
Contributor

pabigot commented Jul 29, 2018

When I reworked linux-firmware to use the OE-Core base augmented by overrides taken from the raspbian distro (#245), I changed the version format so that it identified the git version from all three sources:

SRCREV_FORMAT_rpi = "default+raspbian-nf+raspbian-bluez"

This reflects that what we build uses different firmware from raspbian-nf for:

brcmfmac43430-sdio brcmfmac43455-sdio

and adds firmware from raspbian-bluez for:

BCM43430A1.hcd BCM4345C0.hcd

This was useful as it allowed diagnosis of #260 without lots of back and forth. The longer version number also makes more clear that the rpi packages are not entirely the same as ones built for other architectures (which may be good, or bad, depending).

Now we need to advance the raspbian-bluez commit, because there's an updated firmware. The problem is that doing this causes a QA error:

ERROR:
linux-firmware-1_0.0+gitAUTOINC+d114732723+86e88fbf03+ade2bae1aa-r0 do_packagedata_setscene:
QA Issue: Package version for package linux-firmware went backwards which would break package feeds
from (1:0.0+git0+d114732723+86e88fbf03+e28cd7ee86-r0.0
   to 1:0.0+git0+d114732723+86e88fbf03+ade2bae1aa-r0.0) [version-going-backwards]

There are several approaches I can conceive:

  • Live with the version-going-backwards. Non-starter for production use.

  • Come up with some magic so the AUTOINC part of SRCREVPV doesn't pay attention to the change in the non-default SRCREV contributors (which is the behavior I unconsciously assumed).

  • Remove the SRCREV_FORMAT so we match OE-Core and just silently replace the -sdio firmware package contents along with adding the BCM434X ones if the packages are built for _rpi. Might cause some confusion in multi-machine build areas? Or is that already a problem?

  • Make a second stab at providing a different package that supersedes linux-firmware only for the pieces that are out of date.

  • Convince people (vendors and maintainers) to keep linux-firmware up to date so we don't have to maintain a fork.

I don't like any of those (well, I love the last one, but it's probably impractical).
Something's gotta be done.
Opinions?

@pabigot
Copy link
Contributor Author

pabigot commented Nov 13, 2018

@otavio I notice you've updated meta-raspberrypi linux-firmware. The problem discussed in this issue wasn't encountered because raspbian-nf went to lexically greater SHA1. Nonetheless, if you have insight as to a preferred fix I'd appreciate it.

At this time I'm tending towards option four (separate package for raspberry-pi override firmware). Attempts to get upstream to fix this elicited no response.

@otavio
Copy link
Contributor

otavio commented Nov 13, 2018

A separated recipe makes most since as it is what it really is. Appending it to linux-firmware is wrong conceptually.

@pabigot
Copy link
Contributor Author

pabigot commented Nov 13, 2018

@otavio That's what I figured (deep sigh). OK, I'll work towards that. It'll be two recipes, though, since there are two external sources: probably bluez-firmware and firmware-nonfree-rpi-distro to make provenance more clear. @agherzan @hhromic FYI, please comment if concerned and bring in anybody else who should provide design input.

@otavio
Copy link
Contributor

otavio commented Nov 13, 2018

To provide a good upgrade path in future, it would be good to also create a packagegroup-rpi-base which rdepends on the firmware and other "base" packages, thus providing an upgrade path.

pabigot added a commit to pabigot/meta-raspberrypi that referenced this issue Nov 13, 2018
Raspberry Pi hardware requires firmware that supersedes or is not
present in the standard linux-firmware distribution.  These files are
maintained in the RPi-Distro project on github.

Several attempts have been made to reconcile conflicts between what's in
linux-firmware and what the hardware needs.  The existing approach is
functional but not maintainable since it combines material from three
repositories into a single package that claims to be linux-firmware.

Remove the appends that change the content of linux-firmware for rpi
hardware.  Add two new recipes that follow the RPi-Distro repositories:

* firmware-nonfree which forked from linux-firmware and replaces
  content;
* bluez-firmware which forked from bluez and adds content;

The packages are named to make clear that these come from RPi-Distro,
rather than generic sources.  Licensing attempts to record the state of
licensing as documented in RPi-Distro.

Resolves: agherzan#298
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
pabigot added a commit to pabigot/meta-raspberrypi that referenced this issue Nov 14, 2018
Raspberry Pi hardware requires firmware that supersedes or is not
present in the standard linux-firmware distribution.  These files are
maintained in the RPi-Distro project on github.

Several attempts have been made to reconcile conflicts between what's in
linux-firmware and what the hardware needs.  The existing approach is
functional but not maintainable since it combines material from three
repositories into a single package that claims to be linux-firmware.

Remove the appends that change the content of linux-firmware for rpi
hardware.  Add two new recipes that follow the RPi-Distro repositories:

* firmware-nonfree which forked from linux-firmware and replaces
  content;
* bluez-firmware which forked from bluez and adds content;

The packages are named to make clear that these come from RPi-Distro,
rather than generic sources.  Licensing attempts to record the state of
licensing as documented in RPi-Distro.

Resolves: agherzan#298
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
pabigot added a commit to pabigot/meta-raspberrypi that referenced this issue Nov 14, 2018
Raspberry Pi hardware requires firmware that supersedes or is not
present in the standard linux-firmware distribution.  These files are
maintained in the RPi-Distro project on github.

Several attempts have been made to reconcile conflicts between what's in
linux-firmware and what the hardware needs.  The existing approach is
functional but not maintainable since it combines material from three
repositories into a single package that claims to be linux-firmware.

Remove the appends that change the content of linux-firmware for rpi
hardware.  Add two new recipes that follow the RPi-Distro repositories:

* firmware-nonfree which forked from linux-firmware and replaces
  content;
* bluez-firmware which forked from bluez and adds content;

The packages are named to make clear that these come from RPi-Distro,
rather than generic sources.  Licensing attempts to record the state of
licensing as documented in RPi-Distro.

Resolves: agherzan#298
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
@hhromic
Copy link
Contributor

hhromic commented Nov 15, 2018

hi @pabigot , I'm not an expert in the matter, but my humble opinion is aligned with @otavio 's , a separate recipe for each firmware makes more sense and seems easier to maintain

@agherzan
Copy link
Owner

The PR looks like a good way forward to me too.

pabigot added a commit to pabigot/meta-raspberrypi that referenced this issue Nov 19, 2018
Raspberry Pi hardware requires firmware that supersedes or is not
present in the standard linux-firmware distribution.  These files are
maintained in the RPi-Distro project on github.

Several attempts have been made to reconcile conflicts between what's in
linux-firmware and what the hardware needs.  The existing approach is
functional but not maintainable since it combines material from three
repositories into a single package that claims to be linux-firmware.

Remove the appends that change the content of linux-firmware for rpi
hardware.  Add two new recipes that follow the RPi-Distro repositories:

* firmware-nonfree which forked from linux-firmware and replaces
  content is provided as linux-firmware-rpidistro;
* bluez-firmware which forked from (very old) bluez and adds content is
  provided as bluez-firmware-rpidistro.

The packages are named to make clear that these come from RPi-Distro,
rather than generic sources.  Licensing attempts to record the state of
licensing as documented in RPi-Distro.

Resolves: agherzan#298
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
agherzan pushed a commit that referenced this issue Nov 23, 2018
Raspberry Pi hardware requires firmware that supersedes or is not
present in the standard linux-firmware distribution.  These files are
maintained in the RPi-Distro project on github.

Several attempts have been made to reconcile conflicts between what's in
linux-firmware and what the hardware needs.  The existing approach is
functional but not maintainable since it combines material from three
repositories into a single package that claims to be linux-firmware.

Remove the appends that change the content of linux-firmware for rpi
hardware.  Add two new recipes that follow the RPi-Distro repositories:

* firmware-nonfree which forked from linux-firmware and replaces
  content is provided as linux-firmware-rpidistro;
* bluez-firmware which forked from (very old) bluez and adds content is
  provided as bluez-firmware-rpidistro.

The packages are named to make clear that these come from RPi-Distro,
rather than generic sources.  Licensing attempts to record the state of
licensing as documented in RPi-Distro.

Resolves: #298
Signed-off-by: Peter A. Bigot <pab@pabigot.com>
@kraj
Copy link
Collaborator

kraj commented Nov 24, 2018

To provide a good upgrade path in future, it would be good to also create a packagegroup-rpi-base which rdepends on the firmware and other "base" packages, thus providing an upgrade path.

this will have to be machine specific, since not all rpi variants have same chipsets for which these firmwares are targetted. Secondly, some of them not even have that hardware or peripheral.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants