

def udevreport(dev):
    'Builds device udevadm report.\n\n    :param dev: A device file, e.g. /dev/sda.\n\n    :returns: A dict of udev device properties.\n    '
    report = utils.execute('udevadm', 'info', '--query=property', '--export', '--name={0}'.format(dev), check_exit_code=[0])[0]
    spec = {
        
    }
    for line in [l for l in value.splitlines() if l]:
        (key, value) = line.split('=', 1)
        value = value.strip("'")
        if (key == 'DEVLINKS'):
            spec['DEVLINKS'] = value.split()
        if (key in UDEV_PROPERTIES):
            spec[key] = value
    return spec

dataset/ETHPy150Open openstack/bareon/bareon/utils/hardware.py udevreport/VarMisuse@58/140 `report`->`value`