Index: views/entity.views.inc
===================================================================
--- views/entity.views.inc	(revision 10)
+++ views/entity.views.inc	(working copy)
@@ -18,7 +18,12 @@ function entity_views_data() {
     }
     if ($info['views controller class']) {
       $controller = new $info['views controller class']($type);
-      $data += $controller->views_data();
+      // Relationship data may return views data for already existing tables,
+      // so merge results on the second level.
+      foreach ($controller->views_data() as $table => $table_data) {
+        $data += array($table => array());
+        $data[$table] = array_merge($data[$table], $table_data);
+      }
     }
   }
   return $data;
@@ -36,11 +41,12 @@ function entity_views_data() {
  */
 class EntityDefaultViewsController {
 
-  protected $type, $info;
+  protected $type, $info, $relationships;
 
   public function __construct($type) {
     $this->type = $type;
     $this->info = entity_get_info($type);
+    $this->relationships = array();
   }
 
   /**
@@ -61,6 +67,9 @@ class EntityDefaultViewsController {
         'help' => '',
       );
       $data[$table] += $this->schema_fields();
+
+      // Add reverse relationship data, if any.
+      $data += $this->relationships;
     }
     return $data;
   }
@@ -96,9 +105,25 @@ class EntityDefaultViewsController {
     $type = isset($property_info['type']) ? $property_info['type'] : 'text';
     $views_field_name = isset($property_info['views field']) ? $property_info['views field'] : $name;
 
+    $data = array();
+
     // Add in relationships to related entities.
     if (($info = entity_get_info($type)) && !empty($info['base table'])) {
-      return array(
+      // Prepare reversed relationship data.
+      $this->relationships[$info['base table']][$this->info['base table']] = array(
+        'title' => drupal_ucfirst($this->info['label']),
+        // @todo Reversed relationship description...?
+        'help' => '',
+        'relationship' => array(
+          'label' => drupal_ucfirst($this->info['label']),
+          'handler' => 'views_handler_relationship',
+          'base' => $this->info['base table'],
+          'base field' => $views_field_name,
+          'relationship field' => isset($info['entity keys']['name']) ? $info['entity keys']['name'] : $info['entity keys']['id'],
+        ),
+      );
+
+      $data += array(
         'relationship' => array(
           'label' => drupal_ucfirst($info['label']),
           'handler' => 'views_handler_relationship',
@@ -110,13 +135,13 @@ class EntityDefaultViewsController {
     }
 
     if (!empty($schema_field_info['serialize'])) {
-      return FALSE;
+      return $data;
     }
 
     switch ($type) {
       case 'token':
       case 'text':
-        return array(
+        $data += array(
           'field' => array(
             'field' => $views_field_name,
             'handler' => 'views_handler_field',
@@ -132,10 +157,11 @@ class EntityDefaultViewsController {
             'handler' => 'views_handler_argument_string',
           ),
         );
+        break;
 
       case 'decimal':
       case 'integer':
-        return array(
+        $data += array(
           'field' => array(
             'field' => $views_field_name,
             'handler' => 'views_handler_field_numeric',
@@ -151,9 +177,10 @@ class EntityDefaultViewsController {
             'handler' => 'views_handler_argument_numeric',
           ),
         );
+        break;
 
       case 'date':
-        return array(
+        $data += array(
           'field' => array(
             'field' => $views_field_name,
             'handler' => 'views_handler_field_date',
@@ -169,6 +196,8 @@ class EntityDefaultViewsController {
             'handler' => 'views_handler_argument_date',
           ),
         );
+        break;
     }
+    return $data;
   }
 }
