Implement FS_IOC_GETFLAGS

Gentoo Portage's FEATURES=xattr breaks because python's xattr.list()
reads regular atrributes too. We implement FS_IOC_GETFLAGS to fix this.
Only flags common to both both Linux and Solaris are returned. Flags
cannot be set until FS_IOC_SETFLAGS is implemented.

Issue zfsonlinux/zfs#1691

Original-patch-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Richard Yao <ryao@gentoo.org>