Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

[131335]: nouveau-pm / tools / strip-all.sh Maximize Restore History

Download this file

strip-all.sh    41 lines (36 with data), 1.5 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/bin/sh
# During the downclocking a number of read/writes occur
# here seems to be only the relevant one
# Tested on a trial and error basis, using mmio-replay and
# playing Nexiuz for about 10 min
#
# Some information about the ranges
# 0x1000 PBUS
# 0x4000 PLLs
# 0xa000 Performance Monitor ??
# 0xe000 PCONNECTOR -- Display and fan
# 0xc000 unknown -- setup coonected with the PLL read/writes
# 0x80000 - unknown, there seems to be a block write to it on nv9x cards
# 0x100000 - PFB - some read/writes may come from the vbios init scripts
# and/or other scripts within the vbios
#
# Seen a number of 0x1100 and 0x88000 - 0x8802080
# reads on nv8x cards
offset=`cat ./BOOT`
for file in [123456789].txt
do
echo Processing $file
cat $file | gawk '{ adr=strtonum($5); read_mode=($1);ofs=strtonum('$offset'); if ( \
(adr >= (ofs + 0x1000) && adr <= (ofs + 0x1fff)) || (adr==(ofs + 0x1100) && (read_mode != "R")) ||\
(adr >= (ofs + 0xa000) && adr < (ofs + 0xafff)) ||\
(adr >= (ofs + 0xe000) && adr < (ofs + 0xefff)) ||\
(adr >= (ofs + 0x80000) && adr < (ofs + 0x800ff)) ||\
((adr >= (ofs + 0x88000) && adr <= (ofs + 0x88020)) && (read_mode != "R")) ||\
(adr > (ofs + 0x88020) && adr < (ofs + 0x88fff)) ||\
(adr >= (ofs + 0x100000) && adr < (ofs + 0x100fff)) ||\
(adr >= (ofs + 0x4000) && adr <= (ofs + 0x4fff)) || (adr >= (ofs + 0xc000) && adr <= (ofs + 0xcfff)) ) print;}' > $file-stripped-all
echo Stripping time
./timestrip $file-stripped-all
rm $file-stripped-all
done
exit 0