Hello community,

here is the log from the commit of package lilo for openSUSE:Factory checked in 
at 2012-08-13 19:54:00
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/lilo (Old)
 and      /work/SRC/openSUSE:Factory/.lilo.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "lilo", Maintainer is "[email protected]"

Changes:
--------
--- /work/SRC/openSUSE:Factory/lilo/lilo.changes        2012-03-16 
13:19:00.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.lilo.new/lilo.changes   2012-08-13 
19:54:10.000000000 +0200
@@ -1,0 +2,9 @@
+Fri Aug 10 22:06:31 UTC 2012 - [email protected]
+
+- drop lilo.ppc.nvram-fix.patch. Use nvsetenv wrapper from 
+  powerpc-utils instead
+- get OF path for virtio. Don't run nvsetenv if /dev/nvram is not
+  available
+- find SLOF disks, they are disk@id,lun
+
+-------------------------------------------------------------------

Old:
----
  lilo.ppc.nvram-fix.patch

New:
----
  lilo.ppc-kvm.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ lilo.spec ++++++
--- /var/tmp/diff_new_pack.LSAX2j/_old  2012-08-13 19:54:31.000000000 +0200
+++ /var/tmp/diff_new_pack.LSAX2j/_new  2012-08-13 19:54:31.000000000 +0200
@@ -78,12 +78,12 @@
 Patch8602:      lilo.x86.array-bounds.patch
 Patch8604:      lilo.x86.checkit.patch
 Patch8605:      lilo-no-build-date.patch
-Patch8606:      lilo.ppc.nvram-fix.patch       
 Patch8607:      yaboot-libgcc.patch
 Patch8608:      lilo-libgcc.patch
 Patch8609:      lilo.ppc.ps3.patch
 Patch8610:      lilo.src.Makefile.patch
 Patch8611:      lilo.ppc-22.8.opal.patch
+Patch8612:      lilo.ppc-kvm.patch
 # $Id: lilo.spec 1188 2008-12-09 14:29:53Z olh $
 
 %description
@@ -107,7 +107,6 @@
 %patch8605 -p1
 %patch8610 -p1
 popd
-%patch8606
 pushd yaboot
 %patch8607 -p1
 popd
@@ -115,6 +114,7 @@
 %patch8608 -p1
 %patch8609 -p1
 %patch8611 
+%patch8612 -p1
 popd
 
 %build

++++++ lilo.ppc-kvm.patch ++++++
>From aa67a149d73af0cb4677694a010562a798b5e529 Mon Sep 17 00:00:00 2001
From: Dinar Valeev <[email protected]>
Date: Mon, 13 Aug 2012 13:03:08 +0200
Subject: [PATCH] get OF path for virtio. Don't run nvsetenv where
  /dev/nvram is not available (under KVM). Extend search
  of vscsi disks to disk@id,lun

---
 lilo-chrp.lib   |   29 ++++++++++++++++-------------
 lilo.new        |    8 +++++++-
 show_of_path.sh |   12 +++++++++++-
 3 files changed, 34 insertions(+), 15 deletions(-)

diff --git a/lilo-chrp.lib b/lilo-chrp.lib
index 92cb2ad..a65c0fd 100644
--- a/lilo-chrp.lib
+++ b/lilo-chrp.lib
@@ -649,8 +649,10 @@ function running_on_chrp () {
                fi
 
                if (( fat_boot == 1 )); then
-                       nvsetenv bootinfo-linux 
"${boot_path},\\ppc\\bootinfo.txt"
-                       boot_path=${boot_path},yaboot
+                       if [ is_nvram ];then
+                               nvsetenv bootinfo-linux 
"${boot_path},\\ppc\\bootinfo.txt"
+                       fi
+                               boot_path=${boot_path},yaboot
                elif [[ "${p_flags[*]}" != *type=41*type=41* ]]; then
                        # open firmware is confused about more than one PReP 
partition, in that
                        # case keep full OF path
@@ -658,17 +660,18 @@ function running_on_chrp () {
                fi
 
                if [ "$OPTION_ACTIVATE" = "yes" ] ; then
-                       echo "Prepending  '$boot_path'" to open firmware 
variable boot-device
-
-                       local -a bootdevice=( $(nvsetenv boot-device) )
-                       bootdevice[0]=${bootdevice[0]#boot-device=}
-                       for (( i=${#bootdevice[*]}; i-- >0; )); do
-                               if [[ "${bootdevice[$i]}" == ${boot_path}* ]]; 
then
-                                       unset bootdevice[$i];
-                               fi
-                       done
-                       nvsetenv boot-device "$boot_path ${bootdevice[*]}"
-
+                       if [ is_nvram ];then
+                               echo "Prepending  '$boot_path'" to open 
firmware variable boot-device
+
+                               local -a bootdevice=( $(nvsetenv boot-device) )
+                               bootdevice[0]=${bootdevice[0]#boot-device=}
+                               for (( i=${#bootdevice[*]}; i-- >0; )); do
+                                       if [[ "${bootdevice[$i]}" == 
${boot_path}* ]]; then
+                                               unset bootdevice[$i];
+                                       fi
+                               done
+                               nvsetenv boot-device "$boot_path 
${bootdevice[*]}"
+                       fi
                else
                        warning "boot path not set to boot linux as requested" \
                        "please add '$boot_path' somewhere to your boot path 
manually"
diff --git a/lilo.new b/lilo.new
index 39aaa33..21d5180 100755
--- a/lilo.new
+++ b/lilo.new
@@ -672,7 +672,13 @@ while [ "$1" ]; do case "$1" in
        ;;
 esac; shift; done
 
-
+function is_nvram () {
+       if [ -e /dev/nvram ];then
+               return 0
+       else
+               return 1
+       fi
+}
 
 function running_on_iseries () {
     source /lib/lilo/lilo-iseries.lib
diff --git a/show_of_path.sh b/show_of_path.sh
index 52ceb16..03af210 100644
--- a/show_of_path.sh
+++ b/show_of_path.sh
@@ -361,6 +361,11 @@ case "$file_full_sysfs_path" in
                fi
        done
        ;;
+       */pci+([0-9:])+([0-9]):*/virtio[0-9])
+       declare spec="${file_full_sysfs_path##*/}"
+       dbg_show spec
+       cd ..
+       ;;
     *)
         # TODO check the rest of the (hardware) world
        : file_full_sysfs_path $file_full_sysfs_path
@@ -481,6 +486,8 @@ if [ -f devspec ] ; then
        ;;
        ieee1394)
        ;;
+       block)
+       file_storage_type=virtio
        *)
        error "Unknown device type $(< ${file_of_hw_devtype}/device_type)"
        ;;
@@ -610,7 +617,7 @@ if [ -f devspec ] ; then
        ;;
         vscsi)
        (( of_disk_vscsi_nr = ( (2 << 14) | (of_disk_scsi_chan<<5) |  
(of_disk_scsi_id<<8) |  of_disk_scsi_lun ) <<48 )); #
-       if [ -d ${file_of_hw_devtype}/disk ]; then
+       if $(ls -d ${file_of_hw_devtype}/disk* >/dev/null 2>&1); then
                of_disk_vscsi_dir=disk
        elif [ -d ${file_of_hw_devtype}/sd ]; then
                of_disk_vscsi_dir=sd
@@ -627,6 +634,9 @@ if [ -f devspec ] ; then
        # MacOS: boot-device=fw/node@1d20000038f29/sbp-2@c000/@0:7,\\:tbxi
        
file_of_hw_path="${file_of_hw_devtype##/proc/device-tree}"/node@${ieee1394_id}/sbp-2/disk@0
        ;;
+       virtio)
+       file_of_hw_path="${file_of_hw_devtype##/proc/device-tree}"
+       dbg_show file_of_hw_path
        *)
        error "Internal error, can't handle storage type '${file_storage_type}'"
        ;;
-- 
1.6.0.2

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to