def METHOD_NAME(self, fd, cmd):
    """Issues a system fcntl(fd, cmd, self). Updates self with what was
    returned by the kernel. Otherwise raises IOError(errno)."""
    st = struct.pack(self.FORMAT, * self.fields)
    st = METHOD_NAME.METHOD_NAME(fd, cmd, st)
    fields = struct.unpack(self.FORMAT, st)
    self.__init__( * fields)