[<prev] [next>] [day] [month] [year] [list]
Message-ID: <2422.172.16.116.56.1203587019.squirrel@linux.intel.com>
Date: Thu, 21 Feb 2008 01:43:39 -0800 (PST)
From: youquan_song@...ux.intel.com
To: linux-kernel@...r.kernel.org
Cc: youquan.song@...el.com
Subject: From 2.6.24 to 2.6.25-rc2,
CPU can not do hotplug when one task set affinity to it
In SMP sever platform, with kernel 2.6.24-rc2 and kernel 2.6.25-rc2,
Set one task affinity to one CPU core, then set offline the CPU core.
After that we can not set online the CPU core again.
1. run the test.sh script: test.sh 1 ( 1 is the logical CPU )
test.sh script:
#!/bin/bash
main(){
typeset -i CPU=$1
./task.sh > /dev/null&
PID=$!
if [ `cat /sys/devices/system/cpu/cpu${CPU}/online` = "0" ]; then
echo "1" > /sys/devices/system/cpu/cpu${CPU}/online
fi
MASK=$((1<<${CPU}))
`taskset -p ${MASK} ${PID} > /dev/null 2>&1`
echo "0" > /sys/devices/system/cpu/cpu${CPU}/online
echo "1" > /sys/devices/system/cpu/cpu${CPU}/online
kill -9 $PID > /dev/null 2>&1
echo "PASS\n"
}
typeset -i TEST_CPU=$1
main $TEST_CPU
2. task.sh script as following
#!/bin/bash
while :
do
NOOP=1
done
Actual Result:
The test.sh will block at set online the CPU ( echo "1" >
/sys/devices/system/cpu/cpu${CPU}/online ).
we check the test.sh has dead by 'ps -aux'.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists