Changing IOMUX pad settings from userspace

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Changing IOMUX pad settings from userspace

Jump to solution
1,414 Views
davemcmordie
Contributor III

On the i.MX6Q we would like to be able to adjust the pad settings of MX6QDL_PAD_GPIO_3__CCM_CLKO2 from userspace after the kernel has booted in order to fine-tune clock edge speed.  Is this possible and if so how can we do it?  We also would especially like to be able to read back the value of this register in order to ensure that our chances have taken effect.  I have seen other posts on this forum saying that IOMUX settings can be adjusted at runtime, but I am not sure how this can be done in Linux 3.14.38.  

0 Kudos
1 Solution
1,410 Views
igorpadykov
NXP Employee
NXP Employee

Hi davemcmordie

 

one can try memtool included in unit tests (folder ..test/memtool)

https://patchwork.openembedded.org/patch/110753/

 

Best regards
igor

View solution in original post

5 Replies
1,404 Views
turker
Contributor IV

You can try devmem tool.

devmem 0x20E05FC # read
devmem 0x20E05FC 32 0xXXXXXXXX # write

 

1,390 Views
elseiforelse
Contributor I

Hello,

Thanks for your help. When I write, I don't see the updated value from the readback. Any ideas on how to fix this?

root@devunit:/home/linaro/devmem# ./devmem 0x20E05FC w 0x0001B070
/dev/mem opened.
Memory mapped at address 0x76fbe000.
Read at address  0x020E05FC (0x76fbe5fc): 0x0001B0B0
Write at address 0x020E05FC (0x76fbe5fc): 0x0001B070, readback 0x0001B0B0
root@devunit:/home/linaro/devmem#
0 Kudos
1,411 Views
igorpadykov
NXP Employee
NXP Employee

Hi davemcmordie

 

one can try memtool included in unit tests (folder ..test/memtool)

https://patchwork.openembedded.org/patch/110753/

 

Best regards
igor

1,384 Views
elseiforelse
Contributor I

This works. Thanks!

0 Kudos
1,385 Views
davemcmordie
Contributor III

Not sure why, but memtool worked and devmem did not. Thanks for your help!

0 Kudos