[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#388296: nobootloader: Pegasos firmware older than 1.2.99 need to substract 1 from partitions.

Package: nobootloader
Version: 1.10
Severity: important
Tags: d-i, patch

Hi Colin, ...

Can you please check the attached patch and commit it in both ubuntu and
debian if it seems ok to you.

I did some hand-testing only, not a full install with it, but it seems mostly

In any case, there is an error in the code using /sys over the old devfs code
compared to the older devfs code. The devfs code always substract 1 from the
partitions, while the /sys code never does it.

The right behaviour is to check for the
/proc/device-tree/openprom/firmware-version property, and discriminate
depending on the version there.

Only newer firmware versions have this property, and only those firmware more
recent or equal to 1.2.99 have partitions starting at 1. older firmwares and
those not having the property all start at 0.

The attached patch implements this check, and brings both /sys and devfs
partition numbering in sync again.

-- System Information:
Debian Release: testing/unstable
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: powerpc (ppc)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.15-1-powerpc
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)

Reply to: