diff options
author | Vlad Glagolev | 2014-04-25 10:04:48 +0400 |
---|---|---|
committer | Vlad Glagolev | 2015-01-30 11:01:05 +0300 |
commit | 295dc566a3a82055d6626301de66833959a06928 (patch) | |
tree | 01ae4df42e620d85210724faf269d6360d2edf87 | |
parent | aec908bf1114b56a678c3e7a5f8e84d96964b7e1 (diff) |
lilo: added patch for Xen XVD disks recognition
(cherry picked from commit 0399d9c1077b4b429a2965ff67f8fac2a31ab6a0)
-rwxr-xr-x | disk/lilo/CONFIGURE | 4 | ||||
-rw-r--r-- | disk/lilo/HISTORY | 6 | ||||
-rwxr-xr-x | disk/lilo/PRE_BUILD | 6 | ||||
-rw-r--r-- | disk/lilo/xvd.patch | 29 |
4 files changed, 43 insertions, 2 deletions
diff --git a/disk/lilo/CONFIGURE b/disk/lilo/CONFIGURE index cd4cb2e5d6..35e828ee02 100755 --- a/disk/lilo/CONFIGURE +++ b/disk/lilo/CONFIGURE @@ -1 +1,3 @@ -config_query RUN_LILO "Run LILO automatically upon LILO upgrades?" n +config_query RUN_LILO "Run LILO automatically upon LILO upgrades?" n && + +config_query LILO_XVD "Apply patch to get lilo to recognize Xen XVD disks?" n diff --git a/disk/lilo/HISTORY b/disk/lilo/HISTORY index 85e719663e..a4f95126c8 100644 --- a/disk/lilo/HISTORY +++ b/disk/lilo/HISTORY @@ -1,3 +1,9 @@ +2014-04-25 Vlad Glagolev <stealth@sourcemage.org> + * CONFIGURE: added option to apply XVD patch + * PRE_BUILD: apply patch + * xvd.patch: added, patch by Lloyd Richardson <lloyd@drlabs.org> and + Bostjan Skufca <bostjan@a2o.si> for Xen XVD disks recognition + 2013-08-06 Florian Franzmann <siflfran@hawo.stw.uni-erlangen.de> * DETAILS: version 24.0 * PRE_BUILD, 0001-fix-failure-during-install.patch: fix failure during install diff --git a/disk/lilo/PRE_BUILD b/disk/lilo/PRE_BUILD index 17870984b0..1be3d3e271 100755 --- a/disk/lilo/PRE_BUILD +++ b/disk/lilo/PRE_BUILD @@ -1,3 +1,7 @@ default_pre_build && cd ${SOURCE_DIRECTORY} && -patch -p1 < $SPELL_DIRECTORY/0001-fix-failure-during-install.patch +patch -p1 < $SPELL_DIRECTORY/0001-fix-failure-during-install.patch && + +if [[ $LILO_XVD == y ]]; then + patch -p0 < "$SPELL_DIRECTORY/xvd.patch" +fi diff --git a/disk/lilo/xvd.patch b/disk/lilo/xvd.patch new file mode 100644 index 0000000000..35e2ce6885 --- /dev/null +++ b/disk/lilo/xvd.patch @@ -0,0 +1,29 @@ +--- src/geometry.c.orig ++++ src/geometry.c +@@ -339,7 +339,7 @@ unsigned char max_partno[512] = { + 31, 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + +- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* Cx */ ++ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 15, 0, 0, 0, 0, 0, /* Cx */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 +@@ -670,6 +670,7 @@ void geo_query_dev(GEOMETRY *geo,int device,int all) + case MAJOR_SD6: + case MAJOR_SD7: + case MAJOR_SD8: ++ case MAJOR_XVD: + MASK15: + geo->device = 0x80 + last_dev(MAJOR_HD,64) + (MINOR(device) >> 4); + if (!get_all) break; +--- src/lilo.h.orig ++++ src/lilo.h +@@ -148,6 +148,7 @@ + #define MAJOR_EMD 153 /* Enhanced multi-disk RAID sets */ + #define MAJOR_CARM1 160 /* Carmel SATA Disk on first 8-port controller */ + #define MAJOR_CARM2 161 /* Carmel SATA Disk on 2nd 8-port controller */ ++#define MAJOR_XVD 202 /* xen xvd disks */ + + /* don't use the following */ + #define MAJOR_MDP 254 /* Enhanced multi-disk RAID sets [experimental?] */ |