code: func (pdev podDevices) toCheckpointData() []checkpoint.PodDevicesEntry {
  	var data []checkpoint.PodDevicesEntry
  	for podUID, containerDevices := range pdev {
  		for conName, resources := range containerDevices {
  			for resource, devices := range resources {
  				devIds := devices.deviceIds.UnsortedList()
  				if devices.allocResp == nil {
  					klog.Errorf("Can't marshal allocResp for %v %v %v: allocation response is missing", podUID, conName, resource)
  					continue
  				}
  
  				allocResp, err := devices.allocResp.Marshal()
  				if err != nil {
  					klog.Errorf("Can't marshal allocResp for %v %v %v: %v", podUID, conName, resource, err)
  					continue
  				}
  				data = append(data, checkpoint.PodDevicesEntry{
  					PodUID:        podUID,
  					ContainerName: conName,
  					ResourceName:  resource,
  					DeviceIDs:     devIds,
  					AllocResp:     allocResp})
  			}
  		}
  	}
  	return data
  }
docs: // Turns podDevices to checkpointData.