code: func (g *gcePersistentDiskCSITranslator) TranslateCSIPVToInTree(pv *v1.PersistentVolume) (*v1.PersistentVolume, error) {
  	if pv == nil || pv.Spec.CSI == nil {
  		return nil, fmt.Errorf("pv is nil or CSI source not defined on pv")
  	}
  	csiSource := pv.Spec.CSI
  
  	pdName, err := pdNameFromVolumeID(csiSource.VolumeHandle)
  	if err != nil {
  		return nil, err
  	}
  
  	gceSource := &v1.GCEPersistentDiskVolumeSource{
  		PDName:   pdName,
  		FSType:   csiSource.FSType,
  		ReadOnly: csiSource.ReadOnly,
  	}
  	if partition, ok := csiSource.VolumeAttributes["partition"]; ok && partition != "" {
  		partInt, err := strconv.Atoi(partition)
  		if err != nil {
  			return nil, fmt.Errorf("Failed to convert partition %v to integer: %v", partition, err)
  		}
  		gceSource.Partition = int32(partInt)
  	}
  
  	// TODO: Take the zone/regional information and stick it into the label.
  
  	pv.Spec.CSI = nil
  	pv.Spec.GCEPersistentDisk = gceSource
  
  	return pv, nil
  }
docs: // TranslateCSIPVToInTree takes a PV with CSIPersistentVolumeSource set and
  // translates the GCE PD CSI source to a GCEPersistentDisk source.