memory barrier in user space



i have a user space driver that's accessing and initializing the
hardware.

in the kernel driver, i can call barrier() but in the user space,
how can i execute memory barrier?

i am running on MIPS and powerPC.

thank you in advance.
.