I make a function like this
trace_printk(\"111111\"); udelay(4000); trace_printk(\"222222\");
and the log shows it\'s 4.01 ms , it\'OK
Every time you call it, a rounding error is added. Note the comment 2**32 / 1000000000. That value is really ~4.29, but it was rounded up to 5. That's a pretty hefty error.
2**32 / 1000000000
By contrast the udelay error is small: (~4294.97 versus 4295 [0x10c7]).