code: func ValidateControllerRevision(revision *apps.ControllerRevision) field.ErrorList {
  	errs := field.ErrorList{}
  
  	errs = append(errs, apivalidation.ValidateObjectMeta(&revision.ObjectMeta, true, ValidateControllerRevisionName, field.NewPath("metadata"))...)
  	if revision.Data == nil {
  		errs = append(errs, field.Required(field.NewPath("data"), "data is mandatory"))
  	}
  	errs = append(errs, apivalidation.ValidateNonnegativeField(revision.Revision, field.NewPath("revision"))...)
  	return errs
  }
docs: // ValidateControllerRevision collects errors for the fields of state and returns those errors as an ErrorList. If the
  // returned list is empty, state is valid. Validation is performed to ensure that state is a valid ObjectMeta, its name
  // is valid, and that it doesn't exceed the MaxControllerRevisionSize.