'Return the name of the given device or None if we don\'t know.'

@_refresh_on_acccess_denied
def get_device_name(self, mac):

    if (self.leasefile is None):
        result = _req_json_rpc(self.url, self.session_id, 'call', 'uci', 'get', config='dhcp', type='dnsmasq')
        if result:
            values = result['values'].values()
            self.leasefile = next(iter(values))['leasefile']
        else:
            return
    if (self.mac2name is None):
        result = _req_json_rpc(self.url, self.session_id, 'call', 'file', 'read', path=self.leasefile)
        if result:
            self.mac2name = dict()
            for line in result['data'].splitlines():
                hosts = line.split('    ')
                self.mac2name[hosts[1].upper()] = hosts[3]
        else:
            return
    return self.mac2name.get(mac.upper(), None)
