Getting parent enitity of enitityreference field
Something like this should work:

// Load wrapper
$wrapper = entity_metadata_wrapper($entity_type, $entity);  
// Load parent entity
$parent = $wrapper-&gt;field_entityreference-&gt;value();
// Get nid
$nid = $parent-&gt;field_computed_field-&gt;value();
// Debug output
drupal_set_message(t('Parent NID: @nid', array('@nid' =&gt; $nid)));