Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I don't care if this is done in the bios or a kernel module or software. Is there any way at all to do make the 'fn' key act as 'control' and the 'control' key act as 'fn' in linux running on a macbook pro?

PS. You can do this with software in OSX with the application KeyRemap4MacBook.

share|improve this question
I think this is hardwired in the keyboard. Not sure, though. – maxelost Jan 24 '11 at 16:36
I can't give you an exact answer, but look at how the authors of these keyboard layout files change the mappings of keys. I find that changing regular keys is rather trivial. With a bit of patience and by studying the other examples (where those files should be installed) you might be able to figure out how to remap the control and fn keys. – Ярослав Рахматуллин Sep 18 '13 at 7:38

I personally haven't needed to do this, but this link shows that you should be able to modify the kernel keymapping upon booting to make this switch.

This link also states that XFree86 will try and load the kernel mapping at its load time so it shouldn't need to be changes just for X if you do the above first.

share|improve this answer
While this link may answer the question, it is better to include the essential parts of the answer here and provide the link for reference. Link-only answers can become invalid if the linked page changes. - From Review – Ben N Feb 2 at 15:51

You could try running xev from an xterm and see what the key code for fn works out to be. bits are getting anded and orred so maybe you'll need to hold another key (ctrl) while you press fn to see data but then take the (probably 0xffe3) back out and maybe you'll have a value you can use with xmodmap. I struggled with that d**m fn key before on those keyboards and I gave up.

share|improve this answer
This does not really answer the question. If you have a different question, you can ask it by clicking Ask Question. You can also add a bounty to draw more attention to this question once you have enough reputation. – David May 2 '14 at 17:46

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.