+static void unregister_links(struct block_entry *be, int tcache_id)
+{
+ struct block_link *bl_unresolved = unresolved_links[tcache_id];
+ struct block_link *bl, *bl_next;
+
+ for (bl = be->links; bl != NULL; ) {
+ bl_next = bl->next;
+ bl->next = bl_unresolved;
+ bl_unresolved = bl;
+ bl = bl_next;
+ }
+ be->links = NULL;
+ unresolved_links[tcache_id] = bl_unresolved;
+}
+
+// unlike sh2_smc_rm_block, the block stays and can still be accessed
+// by other already directly linked blocks, just not preferred
+static void kill_block_entry(struct block_entry *be, int tcache_id)
+{
+ rm_from_hashlist(be, tcache_id);
+ unregister_links(be, tcache_id);
+}
+