Comment 10 for bug 715930

Revision history for this message
Elan Ruusamäe (glen666) wrote :

sorry, you were wrong, there is no bitwise matching, arekm looked it up from code.
so reverted bitwise and added special value only

could you retest with trunk again?

the code:
                for(map = pcimap_list; map != NULL; map = map->next) {
                        if (((map->class ^ class) & map->class_mask) == 0 &&
                            ((desired_class ^ class) & desired_classmask)==0 &&
                            (map->dev == DEVICE_ANY ||
                             map->dev == dev->device_id) &&
                            (map->vendor == VENDOR_ANY ||
                             map->vendor == dev->vendor_id) &&
                            (map->subsys_dev == DEVICE_ANY ||
                             map->subsys_dev == subsys_dev) &&
                            (map->subsys_vendor == VENDOR_ANY ||
                             map->subsys_vendor == subsys_vendor) &&
                            prevmodule != map->module) {
                                printf("%s\n", map->module);
                                prevmodule = map->module;
                        }
                }