Skip to contentSkip to conversation

fix mlock() on vectors vma for ARM and add explicit selinux support

PATCH In review Chong Lu 2 participants 5 messages Apr 10, 2014 – Apr 20, 2014

lore
Share & tools
lore

Chong Lu

author
#0 lore raw

cover fix mlock() on vectors vma for ARM and add explicit selinux support

The following changes since commit 477ccd867cc71f8277f2670b7be34b3b15300052:

klibc: restylize a bit the recipes (2014-04-06 13:36:20 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib chonglu/lvm2
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=chonglu/lvm2

Chong Lu (2):
lvm2: fix mlock() on vectors vma for ARM.
lvm2: add explicit selinux support control

 meta-oe/recipes-support/lvm2/lvm2.inc              |  5 ++++
 .../lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch  | 31 ++++++++++++++++++++++
 2 files changed, 36 insertions(+)
 create mode 100644 meta-oe/recipes-support/lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch
Signature · 1 line
1.8.1.2
author
#1 lore raw

PATCH 1/2 lvm2: fix mlock() on vectors vma for ARM.

---
 meta-oe/recipes-support/lvm2/lvm2.inc              |  1 +
 .../lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch  | 31 ++++++++++++++++++++++
 2 files changed, 32 insertions(+)
 create mode 100644 meta-oe/recipes-support/lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch
meta-oe/recipes-support/lvm2/lvm2.inc +1 -0
index 4b43328..63d2cdb 100644
@@ -10,6 +10,7 @@ INC_PR = "r4"
 S = "${WORKDIR}/LVM2.${PV}"
 SRC_URI = "ftp://sources.redhat.com/pub/lvm2/old/LVM2.${PV}.tgz \
            file://0001-Replace-CPPFunction-with-rl_completion_func_t.patch \
+           file://mlock-ignore-vectors-gate_vma.patch \
            file://lvm.conf"
 
 PACKAGECONFIG ??= "readline"
meta-oe/recipes-support/lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch new file +31 -0
new file mode 100644
index 0000000..3105136
@@ -0,0 +1,31 @@
+Subject: [PATCH] fix: mlock ignore [vectors] gate_vma
+
+Upstream-Status: Pending
+
+linux kernel has a new commit f9d4861f for [vectors] vma on ARM
+"ARM: 7294/1: vectors: use gate_vma for vectors user mapping".
+
+mlock()/munlock() on a gate_vma would cause NOMEM error, so add
+[vectors] to _ignore_maps[], as other gate_vmas [vdso]/[vsyscall]
+did.
+
+Signed-off-by: Xin Ouyang <[email protected]>
+---
+ lib/mm/memlock.c |    1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/lib/mm/memlock.c b/lib/mm/memlock.c
+index 8c631bf..a6b1955 100644
+--- a/lib/mm/memlock.c
++++ b/lib/mm/memlock.c
+@@ -84,6 +84,7 @@ static int _default_priority;
+ static const char * const _ignore_maps[] = {
+     "[vdso]",
+     "[vsyscall]",
++    "[vectors]",
+ };
+ 
+ /* default blacklist for maps */
+-- 
+1.7.9.5
+
Signature · 1 line
1.8.1.2
author
#2 lore raw

PATCH 2/2 lvm2: add explicit selinux support control

In reply to Chong Lu

package has configure options controlling selinux support, so we want to explicitly use them via PACKAGECONFIG.

---
 meta-oe/recipes-support/lvm2/lvm2.inc | 4 ++++
 1 file changed, 4 insertions(+)
meta-oe/recipes-support/lvm2/lvm2.inc +4 -0
index 63d2cdb..c6a9ec0 100644
@@ -30,6 +30,10 @@ EXTRA_OECONF = "--with-user= \
                 --with-udev-prefix= \
 "
 
+PACKAGECONFIG += "${@base_contains('DISTRO_FEATURES', 'selinux', 'selinux', '', d)}"
+
+PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux,"
+
 inherit autotools
 
 do_install_append() {
Signature · 1 line
1.8.1.2
#3 lore raw
In reply to Chong Lu
Quoted 1 line · Chong Lu

The following changes since commit 477ccd867cc71f8277f2670b7be34b3b15300052:

Both merged, thanks!

Quoted 25 lines

klibc: restylize a bit the recipes (2014-04-06 13:36:20 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib chonglu/lvm2
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=chonglu/lvm2

Chong Lu (2):
lvm2: fix mlock() on vectors vma for ARM.
lvm2: add explicit selinux support control

 meta-oe/recipes-support/lvm2/lvm2.inc              |  5 ++++
 .../lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch  | 31 ++++++++++++++++++++++
 2 files changed, 36 insertions(+)
 create mode 100644 meta-oe/recipes-support/lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch
Signature · 7 lines
1.8.1.2

-- 
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel
Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
#4 lore raw
In reply to Chong Lu
Quoted 1 line · Chong Lu

The following changes since commit 477ccd867cc71f8277f2670b7be34b3b15300052:

Both merged, thanks!

Quoted 25 lines

klibc: restylize a bit the recipes (2014-04-06 13:36:20 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib chonglu/lvm2
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=chonglu/lvm2

Chong Lu (2):
lvm2: fix mlock() on vectors vma for ARM.
lvm2: add explicit selinux support control

 meta-oe/recipes-support/lvm2/lvm2.inc              |  5 ++++
 .../lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch  | 31 ++++++++++++++++++++++
 2 files changed, 36 insertions(+)
 create mode 100644 meta-oe/recipes-support/lvm2/lvm2/mlock-ignore-vectors-gate_vma.patch
Signature · 7 lines
1.8.1.2

-- 
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel
Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]