diff --git a/entitycache.module b/entitycache.module
index 66366e0..c20a50e 100644
--- a/entitycache.module
+++ b/entitycache.module
@@ -111,6 +111,27 @@ function entitycache_entity_update($entity, $type) {
 }
 
 /**
+ * Implements hook_file_update().
+ */
+function entitycache_file_update($file) {
+  // After updating a file we need to clear the entity cache for any entities
+  // known to be referencing the file.
+  $records = db_query("SELECT DISTINCT type, id FROM {file_usage} WHERE fid = :fid AND id > 0", array(':fid' => $file->fid))->fetchAll();
+  if (!empty($records)) {
+    $cid_map = array();
+    foreach ($records as $record) {
+      $cid_map[$record->type][] = $record->id;
+    }
+    foreach ($cid_map as $type => $cids) {
+      $info = entity_get_info($type);
+      if (!empty($info['entity cache'])) {
+        cache_clear_all($cids, 'cache_entity_' . $type);
+      }
+    }
+  }
+}
+
+/**
  * Implements hook_entitycache_node_load().
  *
  * This forces book information to be added on each request, to avoid expensive
