I don’t know if you have seen Sergey’s blog but in there is a post on how to program the GPIO from Linux and there is a section for the PWM check this link: http://www.malinov.com/Home/sergey-s-blog/intelgalileo-programminggpiofromlinux It’s a little different from your approach but it might help you, since you are able to set the period and duty cycle of the signal easily. I hope this suit your needs
Regards
JPMontero_Intel