Compare commits

...

8 Commits

Author SHA1 Message Date
Marek Marczykowski-Górecki
c2beb1703a
version 4.0.26 2019-09-28 12:11:44 +02:00
xaki23
ac13973ded
partition full volatile for non-COW setups too
(cherry picked from commit 699e10c057)
2019-09-28 12:11:12 +02:00
Marek Marczykowski-Górecki
484f67a618
Disable BLS config style in grub
Fedora use "Boot Loader Specification" config style by default. This is
available only in Fedora-patched grub, so it's incompatible with vanilla
grub shipped by dom0.
Disable it, to generate normal boot entries.

QubesOS/qubes-issues#5212

(cherry picked from commit bd55c1efe4)
2019-09-28 12:07:08 +02:00
xaki23
4a28ab6e3d
align volatile swap partition to 1Mb instead of 512b
(cherry picked from commit ecc0b70f67)
Notes from origin:
    Fixes QubesOS/qubes-issues#5151
2019-09-20 20:06:58 +02:00
Marek Marczykowski-Górecki
ff7f65858e
rpm: update python2 deps
Name python2 explicitly in the dependencies, since Fedora 31 has python3
by default.

QubesOS/qubes-issues#5289

(cherry picked from commit ba6be8d8be)
2019-09-17 04:58:20 +02:00
M. Vefa Bicakci
5a83961a88
u2mfn: Make compatible with kernel versions >= 5.3.y 2019-08-17 03:46:45 -04:00
Marek Marczykowski-Górecki
425f7f4f07
version 4.0.25 2019-06-10 00:42:47 +02:00
Marek Marczykowski-Górecki
6501b26a36
initrd: mount / rw for the overlayfs setup time
overlayfs refuse to use R/O upperdir. Since dmroot is properly set
already, it's ok to mount it R/W.
But remount it later R/O, to not confuse startup scripts.

Fixes QubesOS/qubes-issues#5087

(cherry picked from commit 84188910cf)
2019-06-10 00:41:22 +02:00
7 changed files with 46 additions and 15 deletions

25
debian/changelog vendored
View File

@ -1,3 +1,28 @@
qubes-utils (4.0.26) unstable; urgency=medium
[ M. Vefa Bicakci ]
* u2mfn: Make compatible with kernel versions >= 5.3.y
[ Marek Marczykowski-Górecki ]
* rpm: update python2 deps
[ xaki23 ]
* align volatile swap partition to 1Mb instead of 512b
[ Marek Marczykowski-Górecki ]
* Disable BLS config style in grub
[ xaki23 ]
* partition full volatile for non-COW setups too
-- Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com> Sat, 28 Sep 2019 12:11:44 +0200
qubes-utils (4.0.25) unstable; urgency=medium
* initrd: mount / rw for the overlayfs setup time
-- Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com> Mon, 10 Jun 2019 00:42:47 +0200
qubes-utils (4.0.24) unstable; urgency=medium
[ Marek Marczykowski-Górecki ]

View File

@ -79,8 +79,8 @@ if [ `cat /sys/class/block/$ROOT_DEV/ro` = 1 ] ; then
die "volatile.img smaller than 1GB, cannot continue"
fi
sfdisk -q --unit S /dev/xvdc >/dev/null <<EOF
1,$SWAP_SIZE,S
,,L
xvdc1: type=82,start=2048,size=$SWAP_SIZE
xvdc2: type=83
EOF
if [ $? -ne 0 ]; then
die "Qubes: failed to setup partitions on volatile device"
@ -97,7 +97,8 @@ else
log_begin "Qubes: Doing R/W setup for TemplateVM..."
while ! [ -e /dev/xvdc ]; do sleep 0.1; done
sfdisk -q --unit S /dev/xvdc >/dev/null <<EOF
1,$SWAP_SIZE,S
xvdc1: type=82,start=2048,size=$SWAP_SIZE
xvdc3: type=83
EOF
if [ $? -ne 0 ]; then
die "Qubes: failed to setup partitions on volatile device"

View File

@ -53,8 +53,8 @@ if [ `cat /sys/class/block/$ROOT_DEV/ro` = 1 ] ; then
die "volatile.img smaller than 1GB, cannot continue"
fi
/sbin/sfdisk -q --unit S /dev/xvdc >/dev/null <<EOF
1,$SWAP_SIZE,S
,,L
xvdc1: type=82,start=2048,size=$SWAP_SIZE
xvdc2: type=83
EOF
if [ $? -ne 0 ]; then
echo "Qubes: failed to setup partitions on volatile device"
@ -72,7 +72,8 @@ else
echo "Qubes: Doing R/W setup for TemplateVM..."
while ! [ -e /dev/xvdc ]; do sleep 0.1; done
/sbin/sfdisk -q --unit S /dev/xvdc >/dev/null <<EOF
1,$SWAP_SIZE,S
xvdc1: type=82,start=2048,size=$SWAP_SIZE
xvdc3: type=83
EOF
if [ $? -ne 0 ]; then
die "Qubes: failed to setup partitions on volatile device"
@ -86,7 +87,7 @@ fi
/sbin/modprobe ext4
mkdir -p /sysroot
mount /dev/mapper/dmroot /sysroot -o ro
mount /dev/mapper/dmroot /sysroot -o rw
NEWROOT=/sysroot
kver="`uname -r`"
@ -99,18 +100,14 @@ if ! [ -d "$NEWROOT/lib/modules/$kver/kernel" ]; then
if /sbin/modprobe overlay; then
# if overlayfs is supported, use that to provide fully writable /lib/modules
if ! [ -d "$NEWROOT/lib/.modules_work" ]; then
mount "$NEWROOT" -o remount,rw
mkdir -p "$NEWROOT/lib/.modules_work"
mount "$NEWROOT" -o remount,ro
fi
mount -t overlay none $NEWROOT/lib/modules -o lowerdir=/tmp/modules,upperdir=$NEWROOT/lib/modules,workdir=$NEWROOT/lib/.modules_work
else
# otherwise mount only `uname -r` subdirectory, to leave the rest of
# /lib/modules writable
if ! [ -d "$NEWROOT/lib/modules/$kver" ]; then
mount "$NEWROOT" -o remount,rw
mkdir -p "$NEWROOT/lib/modules/$kver"
mount "$NEWROOT" -o remount,ro
fi
mount --bind "/tmp/modules/$kver" "$NEWROOT/lib/modules/$kver"
fi
@ -119,5 +116,6 @@ if ! [ -d "$NEWROOT/lib/modules/$kver/kernel" ]; then
fi
umount /dev /sys /proc
mount "$NEWROOT" -o remount,ro
exec /sbin/switch_root $NEWROOT /sbin/init

View File

@ -5,4 +5,4 @@ if [ -r /usr/share/qubes/marker-vm ] &&
[ "$(cat /var/lib/qubes/initramfs-updated 2>/dev/null || echo 0)" -ge 1 ]; then
GRUB_CMDLINE_LINUX="$GRUB_CMDLINE_LINUX xen_scrub_pages=0"
fi
GRUB_ENABLE_BLSCFG=false

View File

@ -54,10 +54,17 @@ static inline unsigned long VIRT_TO_MFN(void *addr)
}
#endif
#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,3,0)
static int u2mfn_get_mfn(pte_t *pte, unsigned long addr, void *data) {
*((unsigned long *) data) = pfn_to_mfn(pte_pfn(*pte));
return 0;
}
#else
static int u2mfn_get_mfn(pte_t *pte, pgtable_t token, unsigned long addr, void *data) {
*((unsigned long *) data) = pfn_to_mfn(pte_pfn(*pte));
return 0;
}
#endif
/// User virtual address to mfn translator
/**

View File

@ -15,7 +15,7 @@ Requires: python%{python3_pkgversion}-qubesimgconverter
%{?systemd_requires}
BuildRequires: systemd
BuildRequires: qubes-libvchan-devel
BuildRequires: python-setuptools
BuildRequires: python2-setuptools
BuildRequires: python%{python3_pkgversion}-setuptools
BuildRequires: python2-rpm-macros
BuildRequires: python3-rpm-macros
@ -28,7 +28,7 @@ Common Linux files for Qubes Dom0 and VM
%package -n python2-qubesimgconverter
Summary: Python package qubesimgconverter
Requires: python
Requires: python2
Requires: pycairo
%if 0%{?rhel} >= 7
Requires: python-pillow

View File

@ -1 +1 @@
4.0.24
4.0.26