On Monday 24 April 2006 12:13, you wrote:
> Hello!
>
> On Mon, Apr 24, 2006 at 01:51:09AM -0500, anoop aryal wrote:
> > Package: cpufrequtils
> > Version: 001-2
> > Severity: normal
> >
> >
> > as cpufreq-set defaults to cpu 0 and /etc/init.d/cpufrequtils doesn't
> > call cpufreq-set with cpu ids, it ends up not setting any options for
> > the second (virtual) cpu on a 'core duo' processor. i've done the
>
> doh. Silly me for not thinking of it... Ah, if I only had a
> multiprcessor platform... :)
> But do really the Duo processor can swith frequencies independently for
> the 2 cores?
> Just for the records, could you send the output of cpufreq-info?

it looks like it. at least under /sys there are cpu0 and cpu1 directories with 
what looks like independent settings. let me know if you want me to try 
something specific to figure out for sure.

----------- cpufreq-info output
cpufrequtils 001: cpufreq-info (C) Dominik Brodowski 2004-2006
Report errors and bugs to [EMAIL PROTECTED], please.
analyzing CPU 0:
  driver: centrino
  CPUs which need to switch frequency at the same time: 0
  hardware limits: 1000 MHz - 2.00 GHz
  available frequency steps: 2.00 GHz, 1.67 GHz, 1.33 GHz, 1000 MHz
  available cpufreq governors: ondemand, performance
  current policy: frequency should be within 1000 MHz and 2.00 GHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency is 1000 MHz (asserted by call to hardware).
analyzing CPU 1:
  driver: centrino
  CPUs which need to switch frequency at the same time: 1
  hardware limits: 1000 MHz - 2.00 GHz
  available frequency steps: 2.00 GHz, 1.67 GHz, 1.33 GHz, 1000 MHz
  available cpufreq governors: ondemand, performance
  current policy: frequency should be within 1000 MHz and 2.00 GHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency is 1000 MHz (asserted by call to hardware).
----------- end cpufreq output

i have had cpu0 in ondemand and cpu1 in performance before i tried fixing it. 
so i guess you can do it independently.

>
> > following to make it work for me but the line '/bin/true' was added to
> > pacify log_action_end_msg so that probably needs to be fixed.
>
> Indeed, it does need fixing. Using log_action_* functions to tell if the
> action ended successfully for every cpu or not, may be really a better
> idea.

yeah, my bash-fu especially with regard to the related functions for init 
scripts are not quite there. so i figured i'd just take the easy route and 
let you pros handle it ;)

>
> [...]
>
> > +               grep "processor" /proc/cpuinfo | cut -f2 -d':' | \
>
> much better if you could use 'cpufreq-info -a' and use this information
> to tell _which_ cpus need to be switched. Can you include the output of
> 'cpufreq-info -a'? I could cook up a better patch but I'd really need
> some real info to deal with.

------- start
# cpufreq-info -a
0
-------- end

prints just '0' by it's lonesome. does that mean that only cpu0 can be 
changed?

-------- start
# cpufreq-info --cpu 0 -a
0
#cpufreq-info --cpu 1 -a
1
-------- end

i'm not sure it's related 
but /sys/devices/system/cpu/cpu1/cpufreq/affected_cpus had '1' and the 
corresponding file in cpu0 has '0'


>
> > +                   while read cpu
> > +               do
> > +                   $PROGRAM -cpu $cpu $CPUFREQ_OPTIONS 2>&1 > /dev/null
>

that had a typo in it. s/-cpu/--cpu/

> let me see, kind of:
>
>       RETVAL=0
>       for cpu in $(cpufreq-info -a | xargs echo) ; do
>               log_progress_msg "CPU${cpu}"
>               $PROGRAM -cpu $cpu $CPUFREQ_OPTIONS 2>&1 > /dev/null || 
> RETVAL=$?
>       done
>       log_action_end_msg $RETVAL
>
> > +               done
> > +               /bin/true
>
> Oooh! I see now why you need this: since your 2 cores need to switch
> together (eg: you need to invoke cpufreq-set on cpu0 only) the second
> invocation of cpufreq-set gives an error and $? reports failure.
> Could be?
>
> Anyway the issue remains, can you test (and fix eventually :)) the code
> I provided?

yeah. more than happy to do it for you. i'll try it in the evening and send 
you the results.

> Still, could you send the output of the commands I requested above?

let me know if you need anything else.

>
> Thanks

sorry about sending it twice. forgot to hit reply-to-all.
-- 

anoop aryal
[EMAIL PROTECTED]


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to