Fix an endian bug for the ioctl argument

Signed-off-by: Yohei Ueda <yohei@jp.ibm.com>
Merge pull request #231 from yoheiueda/fix-ioctl-endian-issue

Fix an endian bug for the ioctl argument