Lines Matching refs:local_devices
3660 static void drmFoldDuplicatedDevices(drmDevicePtr local_devices[], int count) in drmFoldDuplicatedDevices() argument
3666 if (drmCompareBusInfo(local_devices[i], local_devices[j]) == 0) { in drmFoldDuplicatedDevices()
3667 local_devices[i]->available_nodes |= local_devices[j]->available_nodes; in drmFoldDuplicatedDevices()
3668 node_type = log2(local_devices[j]->available_nodes); in drmFoldDuplicatedDevices()
3669 memcpy(local_devices[i]->nodes[node_type], in drmFoldDuplicatedDevices()
3670 local_devices[j]->nodes[node_type], drmGetMaxNodeName()); in drmFoldDuplicatedDevices()
3671 drmFreeDevice(&local_devices[j]); in drmFoldDuplicatedDevices()
3764 drmDevicePtr *local_devices; in drmGetDevice2()
3794 local_devices = calloc(max_count, sizeof(drmDevicePtr)); in drmGetDevice2()
3795 if (local_devices == NULL) in drmGetDevice2()
3860 temp = realloc(local_devices, max_count * sizeof(drmDevicePtr)); in drmGetDevice2()
3863 local_devices = temp; in drmGetDevice2()
3868 local_devices[i] = local_devices[0]; in drmGetDevice2()
3869 local_devices[0] = d; in drmGetDevice2()
3872 local_devices[i] = d; in drmGetDevice2()
3877 drmFoldDuplicatedDevices(local_devices, node_count); in drmGetDevice2()
3879 *device = local_devices[0]; in drmGetDevice2()
3880 drmFreeDevices(&local_devices[1], node_count - 1); in drmGetDevice2()
3883 free(local_devices); in drmGetDevice2()
3889 drmFreeDevices(local_devices, i); in drmGetDevice2()
3893 free(local_devices); in drmGetDevice2()
3930 drmDevicePtr *local_devices; in drmGetDevices2() local
3944 local_devices = calloc(max_count, sizeof(drmDevicePtr)); in drmGetDevices2()
3945 if (local_devices == NULL) in drmGetDevices2()
4016 temp = realloc(local_devices, max_count * sizeof(drmDevicePtr)); in drmGetDevices2()
4019 local_devices = temp; in drmGetDevices2()
4022 local_devices[i] = device; in drmGetDevices2()
4027 drmFoldDuplicatedDevices(local_devices, node_count); in drmGetDevices2()
4031 if (!local_devices[i]) in drmGetDevices2()
4035 devices[device_count] = local_devices[i]; in drmGetDevices2()
4037 drmFreeDevice(&local_devices[i]); in drmGetDevices2()
4043 free(local_devices); in drmGetDevices2()
4047 drmFreeDevices(local_devices, i); in drmGetDevices2()
4051 free(local_devices); in drmGetDevices2()