It's relatively simple to control the clock manager registers. I've found a set of values, and have C code that writes the desired values to the clock manager registers. This works well; that part of the problem is solved for me.

However, now I'm trying to incorporate that functionality into a kernel module. This answer makes it clear that a kernel module shall request IO memory prior to using it. So far so good.

However, this memory is already reserved by another module. Running sudo cat /proc/iomem tells me that this other module is called cprman:

$ sudo cat /proc/iomem ... irrelevant ... 3f101000-3f102fff : /soc/cprman@7e101000 ... irrelevant ...

A quick google search reveals that this is a kernel module dedicated to clock management. Great!

Does anyone know how to interface, from C, with this module? I would like to command a clock configuration, in the "right way". I have code that steps around the other kernel module and modifies the clock control registers directly. What I want is to play nice, and make the request through the piece of code that's supposed to be managing the clocks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.