summaryrefslogtreecommitdiff
path: root/ramfc.cpp
blob: be838166a3307a1c7ee68a71be067cdebd1c15d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include "nvlib.h"

int main(int argc, char** argv)
{
	std::auto_ptr<nv_device> dev;
	dev.reset(nv_device::open_default());

	for(unsigned i = 0; i < dev->channels; ++i) {
		std::cout << "\nChannel " << i ;
		for(unsigned j = 0; j < dev->ramfc->fc_size; j += 4) {
			if(!(j & 15))
				std::cout << std::endl;
			std::cout << std::hex << std::setw(8) << dev->ramfc->fc[i]->rd32(j) << ' ';
		}
		std::cout << std::endl;
	}
	return 0;
}