Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-19 Thread Nicolas Pitre
On Mon, 19 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,
 
 On Thu, May 15, 2014 at 10:22 PM, Nicolas Pitre
 nicolas.pi...@linaro.org wrote:
  Once you implement full cluster shutdown I can provide you with another
  script stressing that part.
 I am done with the cluster power on/off code and it seems to work fine
 with bL_switcher. Can you please provide me with your stress script.

Here's the script.  Credits go to Dave Martin for this one.

The script assumes that cluster 0 comprises cpus 0 to 3 and cluster 1 
comprises cpus 4 to 7.  You need to edit it otherwise.

- 8
#!/bin/bash

echo 0 /sys/kernel/bL_switcher/active
sleep 1

pids=

for x in \
cluster=cluster0; cpus='cpu0 cpu1 cpu2 cpu3' \
cluster=cluster1; cpus='cpu4 cpu5 cpu6 cpu7'
do
eval $x
eval \
$cluster () {
pids=
`for cpu in $cpus; do cat EOF; done
(sleep .00\\$RANDOM; echo \\$1 /sys/devices/system/cpu/$cpu/online)
echo \\$1 /sys/devices/system/cpu/$cpu/online
pids=\\$pids\ \\$!
EOF`
wait \$pids
if [ \$1 = 0 ]; then
echo \\$n: $cluster off\
else
echo \\$n: $cluster on\
fi
}
done

n=0
while :; do
: $((++n))
cluster1 1; cluster0 0
cluster0 1; cluster1 0
done
- 8


Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-19 Thread Abhilash Kesavan
On Tue, May 20, 2014 at 9:00 AM, Nicolas Pitre nicolas.pi...@linaro.org wrote:
 On Mon, 19 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,

 On Thu, May 15, 2014 at 10:22 PM, Nicolas Pitre
 nicolas.pi...@linaro.org wrote:
  Once you implement full cluster shutdown I can provide you with another
  script stressing that part.
 I am done with the cluster power on/off code and it seems to work fine
 with bL_switcher. Can you please provide me with your stress script.

 Here's the script.  Credits go to Dave Martin for this one.

 The script assumes that cluster 0 comprises cpus 0 to 3 and cluster 1
 comprises cpus 4 to 7.  You need to edit it otherwise.

 - 8
 #!/bin/bash

 echo 0 /sys/kernel/bL_switcher/active
 sleep 1

 pids=

 for x in \
 cluster=cluster0; cpus='cpu0 cpu1 cpu2 cpu3' \
 cluster=cluster1; cpus='cpu4 cpu5 cpu6 cpu7'
 do
 eval $x
 eval \
 $cluster () {
 pids=
 `for cpu in $cpus; do cat EOF; done
 (sleep .00\\$RANDOM; echo \\$1 /sys/devices/system/cpu/$cpu/online)
 echo \\$1 /sys/devices/system/cpu/$cpu/online
 pids=\\$pids\ \\$!
 EOF`
 wait \$pids
 if [ \$1 = 0 ]; then
 echo \\$n: $cluster off\
 else
 echo \\$n: $cluster on\
 fi
 }
 done

 n=0
 while :; do
 : $((++n))
 cluster1 1; cluster0 0
 cluster0 1; cluster1 0
 done
 - 8
Thanks Nicolas. Will test with the script and post the patch if it works.

Regards,
Abhilash
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-18 Thread Abhilash Kesavan
Hi Kukjin,

On Sat, May 17, 2014 at 5:25 AM, Kukjin Kim kgene@samsung.com wrote:
 On 05/16/14 01:52, Nicolas Pitre wrote:

 On Thu, 15 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,


 Hi all,


 [...]

 Good, that looks pretty good.

 Thanks for you guys effort and time.

 Applied this whole series.
Thanks!

Abhilash


 Once you implement full cluster shutdown I can provide you with another
 script stressing that part.


 Sounds great.

 - Kukjin
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-18 Thread Abhilash Kesavan
Hi Nicolas,

On Thu, May 15, 2014 at 10:22 PM, Nicolas Pitre
nicolas.pi...@linaro.org wrote:
 On Thu, 15 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,

 On Wed, May 14, 2014 at 7:09 PM, Abhilash Kesavan
 kesavan.abhil...@gmail.com wrote:
  Hi Nicolas,
 
  On Wed, May 14, 2014 at 7:03 PM, Nicolas Pitre nicolas.pi...@linaro.org 
  wrote:
  On Wed, 14 May 2014, Abhilash Kesavan wrote:
 
  Hi Nicolas,
 
  [...]
  
   1) can't create /sys/devices/system/cpu/cpu//online: nonexistent 
   directory
  
   What do you get if you do:
  
   $ ls -d /sys/devices/system/cpu/cpu?/online
  ls: /sys/devices/system/cpu/cpu//online: No such file or directory
 
  Somehow, you or your shell replaced the ? character into a / character.
  You could try with a * instead.
  With a different RFS your script runs fine without any change. Will
  update with results once testing is done.
 The script has been running for a few hours on my 5420 based
 chromebook. I can see all the cores being hotplugged in/out. A snippet
 of the prints, that I get on running the test, follows:

 [...]

 Good, that looks pretty good.

 Once you implement full cluster shutdown I can provide you with another
 script stressing that part.
I am done with the cluster power on/off code and it seems to work fine
with bL_switcher. Can you please provide me with your stress script.

Regards,
Abhilash


 Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-16 Thread Kukjin Kim

On 05/16/14 01:52, Nicolas Pitre wrote:

On Thu, 15 May 2014, Abhilash Kesavan wrote:


Hi Nicolas,


Hi all,


[...]

Good, that looks pretty good.


Thanks for you guys effort and time.

Applied this whole series.


Once you implement full cluster shutdown I can provide you with another
script stressing that part.


Sounds great.

- Kukjin
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-15 Thread Abhilash Kesavan
Hi Nicolas,

On Wed, May 14, 2014 at 7:09 PM, Abhilash Kesavan
kesavan.abhil...@gmail.com wrote:
 Hi Nicolas,

 On Wed, May 14, 2014 at 7:03 PM, Nicolas Pitre nicolas.pi...@linaro.org 
 wrote:
 On Wed, 14 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,

 [...]
 
  1) can't create /sys/devices/system/cpu/cpu//online: nonexistent 
  directory
 
  What do you get if you do:
 
  $ ls -d /sys/devices/system/cpu/cpu?/online
 ls: /sys/devices/system/cpu/cpu//online: No such file or directory

 Somehow, you or your shell replaced the ? character into a / character.
 You could try with a * instead.
 With a different RFS your script runs fine without any change. Will
 update with results once testing is done.
The script has been running for a few hours on my 5420 based
chromebook. I can see all the cores being hotplugged in/out. A snippet
of the prints, that I get on running the test, follows:

===
[ 2408.454198] CPU4: Booted secondary processor
[ 2408.461468] CPU6: Booted secondary processor
[ 2408.466306] CPU2: Booted secondary processor
[ 2408.527229] CPU7: shutdown
[ 2408.571822] CPU3: shutdown
[ 2408.611762] CPU1: shutdown
[ 2408.647230] CPU6: shutdown
027316[ 2408.686885] CPU2: shutdown
[ 2408.691756] CPU3: Booted secondary processor
[ 2408.696468] CPU0: Booted secondary processor
2[ 2408.705123] CPU2: Booted secondary processor
[ 2408.747231] CPU4: shutdown
4[ 2408.776798] CPU3: shutdown
[ 2408.786452] CPU4: Booted secondary processor
[ 2408.796497] CPU1: Booted secondary processor
3[ 2408.852188] CPU4: shutdown
[ 2408.856478] CPU7: Booted secondary processor
[ 2408.861457] CPU5: Booted secondary processor
4[ 2408.865536] CPU4: Booted secondary processor
[ 2408.921844] CPU1: shutdown
[ 2408.926486] CPU6: Booted secondary processor
[ 2408.931539] CPU3: Booted secondary processor
1[ 2408.967235] CPU7: shutdown
7[ 2409.011792] CPU3: shutdown
[ 2409.016529] CPU1: Booted secondary processor
3[ 2409.082196] CPU6: shutdown
6[ 2409.126847] CPU0: shutdown
[ 2409.172204] CPU4: shutdown
[ 2409.176441] CPU7: Booted secondary processor
04[ 2409.226786] CPU2: shutdown
[ 2409.229347] CPU4: Booted secondary processor
2[ 2409.272214] CPU7: shutdown
[ 2409.276462] CPU0: Booted secondary processor
7[ 2409.317145] CPU5: shutdown
[ 2409.321589] CPU3: Booted secondary processor
[ 2409.326465] CPU7: Booted secondary processor
[ 2409.331456] CPU2: Booted secondary processor
5[ 2409.335634] CPU5: Booted secondary processor
[ 2409.382202] CPU4: shutdown
4[ 2409.421861] CPU1: shutdown
[ 2409.461784] CPU2: shutdown
[ 2409.466485] CPU6: Booted secondary processor
1[ 2409.471381] CPU1: Booted secondary processor
2[ 2409.522210] CPU5: shutdown
5[ 2409.582098] CPU7: shutdown
[ 2409.586421] CPU2: Booted secondary processor
7[ 2409.642135] CPU6: shutdown
6[ 2409.681787] CPU1: shutdown
1[ 2409.716719] CPU0: shutdown
[ 2409.721476] CPU7: Booted secondary processor
[ 2409.726454] CPU5: Booted secondary processor
0[ 2409.731046] CPU0: Booted secondary processor
[ 2409.736473] CPU1: Booted secondary processor
[ 2409.772226] CPU7: shutdown
7[ 2409.816833] CPU3: shutdown
[ 2409.821472] CPU4: Booted secondary processor
3[ 2409.871810] CPU0: shutdown
[ 2409.912194] CPU4: shutdown
[ 2409.957127] CPU5: shutdown
[ 2409.961456] CPU6: Booted secondary processor
[ 2409.966447] CPU3: Booted secondary processor
[ 2409.970816] CPU5: Booted secondary processor
[ 2410.011828] CPU2: shutdown
[ 2410.041787] CPU1: shutdown
[ 2410.044138] CPU2: Booted secondary processor
0452[ 2410.047629] CPU0: Booted secondary processor
[ 2410.056582] CPU4: Booted secondary processor
[ 2410.060400] CPU1: Booted secondary processor
1[ 2410.116858] CPU2: shutdown
[ 2410.121472] CPU7: Booted secondary processor
2[ 2410.176838] CPU1: shutdown
[ 2410.181614] CPU2: Booted secondary processor
1[ 2410.237224] CPU4: shutdown
4[ 2410.286853] CPU2: shutdown
[ 2410.291472] CPU4: Booted secondary processor
2[ 2410.341767] CPU3: shutdown
[ 2410.346579] CPU1: Booted secondary processor
[ 2410.351585] CPU2: Booted secondary processor
3[ 2410.387251] CPU7: shutdown
7[ 2410.426854] CPU1: shutdown
1[ 2410.477217] CPU5: shutdown
5[ 2410.526810] CPU0: shutdown
[ 2410.529108] CPU7: Booted secondary processor
[ 2410.536432] CPU1: Booted secondary processor
[ 2410.592173] CPU7: shutdown
[ 2410.637141] CPU4: shutdown
[ 2410.641459] CPU7: Booted secondary processor
07[ 2410.646392] CPU0: Booted secondary processor
4[ 2410.652206] CPU4: Booted secondary processor
[ 2410.701872] CPU1: shutdown
1[ 2410.746764] CPU0: shutdown
[ 2410.751481] CPU5: Booted secondary processor
[ 2410.756512] CPU1: Booted secondary processor
[ 2410.761505] CPU3: Booted secondary processor
[ 2410.812331] CPU7: shutdown
[ 2410.851841] CPU3: shutdown
[ 2410.854089] CPU7: Booted secondary processor
[ 2410.902210] CPU6: shutdown
[ 2410.906476] CPU3: Booted secondary processor
[ 2410.961858] CPU2: shutdown
07362[ 2411.011814] CPU3: shutdown
[ 2411.016561] CPU2: Booted secondary processor
3[ 

Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-15 Thread Nicolas Pitre
On Thu, 15 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,
 
 On Wed, May 14, 2014 at 7:09 PM, Abhilash Kesavan
 kesavan.abhil...@gmail.com wrote:
  Hi Nicolas,
 
  On Wed, May 14, 2014 at 7:03 PM, Nicolas Pitre nicolas.pi...@linaro.org 
  wrote:
  On Wed, 14 May 2014, Abhilash Kesavan wrote:
 
  Hi Nicolas,
 
  [...]
  
   1) can't create /sys/devices/system/cpu/cpu//online: nonexistent 
   directory
  
   What do you get if you do:
  
   $ ls -d /sys/devices/system/cpu/cpu?/online
  ls: /sys/devices/system/cpu/cpu//online: No such file or directory
 
  Somehow, you or your shell replaced the ? character into a / character.
  You could try with a * instead.
  With a different RFS your script runs fine without any change. Will
  update with results once testing is done.
 The script has been running for a few hours on my 5420 based
 chromebook. I can see all the cores being hotplugged in/out. A snippet
 of the prints, that I get on running the test, follows:
 
[...]

Good, that looks pretty good.

Once you implement full cluster shutdown I can provide you with another 
script stressing that part.


Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-14 Thread Abhilash Kesavan
Hi Nicolas,

[...]

 1) can't create /sys/devices/system/cpu/cpu//online: nonexistent directory

 What do you get if you do:

 $ ls -d /sys/devices/system/cpu/cpu?/online
ls: /sys/devices/system/cpu/cpu//online: No such file or directory

 ?

 2) sleep: invalid number '.0026736'

 A sufficiently recent coreutils package should have a sleep command that
 accepts fractional values.  Alternatively you may replace it with
 usleep:

 usleep $RANDOM
Looks like my cramfs needs an update, it seems to have old packages.

 For 1) the cpu number is not being appended. if I give a particular
 cpu in the script then hotplug in/out works fine.
 For 2) a constant msleep 10 works.

 If you have msleep but not usleep then try:

 msleep $(($RANDOM / 1000))
I have msleep present.

 Is it OK for me to modify the script to hotplug in/off a randomly chosed 
 core ?

 No.  They must *all* be hotplugged simultaneously with some random
 timing.
OK.

Regards,
Abhilash
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-14 Thread Nicolas Pitre
On Wed, 14 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,
 
 [...]
 
  1) can't create /sys/devices/system/cpu/cpu//online: nonexistent directory
 
  What do you get if you do:
 
  $ ls -d /sys/devices/system/cpu/cpu?/online
 ls: /sys/devices/system/cpu/cpu//online: No such file or directory

Somehow, you or your shell replaced the ? character into a / character.
You could try with a * instead.


Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-14 Thread Abhilash Kesavan
Hi Nicolas,

On Wed, May 14, 2014 at 7:03 PM, Nicolas Pitre nicolas.pi...@linaro.org wrote:
 On Wed, 14 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,

 [...]
 
  1) can't create /sys/devices/system/cpu/cpu//online: nonexistent directory
 
  What do you get if you do:
 
  $ ls -d /sys/devices/system/cpu/cpu?/online
 ls: /sys/devices/system/cpu/cpu//online: No such file or directory

 Somehow, you or your shell replaced the ? character into a / character.
 You could try with a * instead.
With a different RFS your script runs fine without any change. Will
update with results once testing is done.

Abhilash


 Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-13 Thread Nicolas Pitre
On Tue, 13 May 2014, Abhilash Kesavan wrote:

 This is v6 of the series adding MCPM backend support for SMP secondary boot
 and core switching on Samsung's Exynos5420. The patches are based on the mcpm
 support added for Exynos5420 in the Chromium kernel repository here:
 https://chromium.googlesource.com/chromiumos/third_party/kernel-next/+/chromeos-3.8
 
 The patches have been prepared on Kukjin Kim's for-next branch and tested on
 SMDK5420 EVT1 as well as an exynos5420 based chromebook (peach-pit) using the
 /dev/b.L_switcher user interface. Secondary core boot-up has also been 
 tested
 on both the boards.

OK... Now it is time for real testing.  :-)

The /dev/b.L_switcher interface tests the switcher.  Here you really 
want to hammer the MCPM functionalities and especially your backend code 
as hard as possible.  I therefore recommend the following test script:

-- 8
#!/bin/bash

echo 0 /sys/kernel/bL_switcher/active
sleep 1

pids=
for cpu in /sys/devices/system/cpu/cpu?/online; do
  { cpu_nr=${cpu:27:1}
while true; do
  echo 1  $cpu 2 /dev/null
  sleep .00$RANDOM
  val1=$(cat $cpu)
  echo 0  $cpu 2 /dev/null
  sleep .00$RANDOM
  val0=$(cat $cpu)
  [ $val1 = 1 -a $val0 = 0 ]  echo -n $cpu_nr
done
  } 
  pids=$pids $!
done

trap kill $pids; echo 0 15
wait $pids
-- 8

Leave this running for a couple hours making sure you see all CPU 
numbers being printed.  The printing order will be random, but each CPU 
number should continuously appear.


Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-13 Thread Abhilash Kesavan
Hi Nicolas,

On Tue, May 13, 2014 at 11:25 PM, Nicolas Pitre
nicolas.pi...@linaro.org wrote:
 On Tue, 13 May 2014, Abhilash Kesavan wrote:

 This is v6 of the series adding MCPM backend support for SMP secondary boot
 and core switching on Samsung's Exynos5420. The patches are based on the mcpm
 support added for Exynos5420 in the Chromium kernel repository here:
 https://chromium.googlesource.com/chromiumos/third_party/kernel-next/+/chromeos-3.8

 The patches have been prepared on Kukjin Kim's for-next branch and tested on
 SMDK5420 EVT1 as well as an exynos5420 based chromebook (peach-pit) using the
 /dev/b.L_switcher user interface. Secondary core boot-up has also been 
 tested
 on both the boards.

 OK... Now it is time for real testing.  :-)

 The /dev/b.L_switcher interface tests the switcher.  Here you really
 want to hammer the MCPM functionalities and especially your backend code
 as hard as possible.  I therefore recommend the following test script:

 -- 8
 #!/bin/bash

 echo 0 /sys/kernel/bL_switcher/active
 sleep 1

 pids=
 for cpu in /sys/devices/system/cpu/cpu?/online; do
   { cpu_nr=${cpu:27:1}
 while true; do
   echo 1  $cpu 2 /dev/null
   sleep .00$RANDOM
   val1=$(cat $cpu)
   echo 0  $cpu 2 /dev/null
   sleep .00$RANDOM
   val0=$(cat $cpu)
   [ $val1 = 1 -a $val0 = 0 ]  echo -n $cpu_nr
 done
   } 
   pids=$pids $!
 done

 trap kill $pids; echo 0 15
 wait $pids
 -- 8

 Leave this running for a couple hours making sure you see all CPU
 numbers being printed.  The printing order will be random, but each CPU
 number should continuously appear.
I tried this script and I get two errors:

1) can't create /sys/devices/system/cpu/cpu//online: nonexistent directory
2) sleep: invalid number '.0026736'


For 1) the cpu number is not being appended. if I give a particular
cpu in the script then hotplug in/out works fine.
For 2) a constant msleep 10 works.

Is it OK for me to modify the script to hotplug in/off a randomly chosed core ?

Regards,
Abhilash


 Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v6 0/5] MCPM backend for Exynos5420

2014-05-13 Thread Nicolas Pitre
On Wed, 14 May 2014, Abhilash Kesavan wrote:

 Hi Nicolas,
 
 On Tue, May 13, 2014 at 11:25 PM, Nicolas Pitre
 nicolas.pi...@linaro.org wrote:
  On Tue, 13 May 2014, Abhilash Kesavan wrote:
 
  This is v6 of the series adding MCPM backend support for SMP secondary boot
  and core switching on Samsung's Exynos5420. The patches are based on the 
  mcpm
  support added for Exynos5420 in the Chromium kernel repository here:
  https://chromium.googlesource.com/chromiumos/third_party/kernel-next/+/chromeos-3.8
 
  The patches have been prepared on Kukjin Kim's for-next branch and tested 
  on
  SMDK5420 EVT1 as well as an exynos5420 based chromebook (peach-pit) using 
  the
  /dev/b.L_switcher user interface. Secondary core boot-up has also been 
  tested
  on both the boards.
 
  OK... Now it is time for real testing.  :-)
 
  The /dev/b.L_switcher interface tests the switcher.  Here you really
  want to hammer the MCPM functionalities and especially your backend code
  as hard as possible.  I therefore recommend the following test script:
 
  -- 8
  #!/bin/bash
 
  echo 0 /sys/kernel/bL_switcher/active
  sleep 1
 
  pids=
  for cpu in /sys/devices/system/cpu/cpu?/online; do
{ cpu_nr=${cpu:27:1}
  while true; do
echo 1  $cpu 2 /dev/null
sleep .00$RANDOM
val1=$(cat $cpu)
echo 0  $cpu 2 /dev/null
sleep .00$RANDOM
val0=$(cat $cpu)
[ $val1 = 1 -a $val0 = 0 ]  echo -n $cpu_nr
  done
} 
pids=$pids $!
  done
 
  trap kill $pids; echo 0 15
  wait $pids
  -- 8
 
  Leave this running for a couple hours making sure you see all CPU
  numbers being printed.  The printing order will be random, but each CPU
  number should continuously appear.
 I tried this script and I get two errors:
 
 1) can't create /sys/devices/system/cpu/cpu//online: nonexistent directory

What do you get if you do:

$ ls -d /sys/devices/system/cpu/cpu?/online

?

 2) sleep: invalid number '.0026736'

A sufficiently recent coreutils package should have a sleep command that 
accepts fractional values.  Alternatively you may replace it with 
usleep:

usleep $RANDOM

 For 1) the cpu number is not being appended. if I give a particular
 cpu in the script then hotplug in/out works fine.
 For 2) a constant msleep 10 works.

If you have msleep but not usleep then try:

msleep $(($RANDOM / 1000))

 Is it OK for me to modify the script to hotplug in/off a randomly chosed core 
 ?

No.  They must *all* be hotplugged simultaneously with some random 
timing.


Nicolas
--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html