def METHOD_NAME(inp):
    filt = {'pci_node.supports_sriov': True}
    if inp == 'all':
        return filt
    if inp.startswith('/dev') and os.path.exists(inp):
        filt.update({'fme.devpath': inp})
    else:
        pci_info = pci_node.parse_address(inp)
        if pci_info:
            pci_address = pci_info['pci_address']
            filt.update({'pci_node.pci_address': pci_address})
        else:
            raise TypeError('{} is not valid device pattern')
    return filt