Merge "Remove auto-allocation 1G hugepage from ks for vswitch"
This commit is contained in:
commit
31e93caa04
@ -13,14 +13,7 @@ n_cpus=$(cat /proc/cpuinfo 2>/dev/null | \
|
|||||||
n_numa=$(ls -d /sys/devices/system/node/node* 2>/dev/null | wc -l)
|
n_numa=$(ls -d /sys/devices/system/node/node* 2>/dev/null | wc -l)
|
||||||
KERN_OPTS=" iommu=pt usbcore.autosuspend=-1"
|
KERN_OPTS=" iommu=pt usbcore.autosuspend=-1"
|
||||||
|
|
||||||
# Add kernel options for hugepages
|
KERN_OPTS="${KERN_OPTS} hugepagesz=2M hugepages=0 default_hugepagesz=2M"
|
||||||
if grep -q pdpe1gb /proc/cpuinfo
|
|
||||||
then
|
|
||||||
KERN_OPTS="${KERN_OPTS} hugepagesz=1G hugepages=${n_numa}"
|
|
||||||
KERN_OPTS="${KERN_OPTS} hugepagesz=2M hugepages=0 default_hugepagesz=2M"
|
|
||||||
else
|
|
||||||
KERN_OPTS="${KERN_OPTS} hugepagesz=2M hugepages=0 default_hugepagesz=2M"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# If this is an all-in-one system, we need at least 4 CPUs
|
# If this is an all-in-one system, we need at least 4 CPUs
|
||||||
if [ "$system_type" = "All-in-one" -a ${n_cpus} -lt 4 ]; then
|
if [ "$system_type" = "All-in-one" -a ${n_cpus} -lt 4 ]; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user