-#ifdef CONFIG_REISERFS_CHECK
- int n_repeat_counter = 0;
-#endif
-
/* Stat_data item. */
if ( is_statdata_le_ih (p_le_ih) ) {
@@ -1020,13 +1016,11 @@ static char prepare_for_delete_or_cut(
{
int n_unfm_number, /* Number of the item unformatted nodes. */
n_counter,
- n_retry, /* Set to one if there is unformatted node buffer in use. */
n_blk_size;
__u32 * p_n_unfm_pointer; /* Pointer to the unformatted node number. */
__u32 tmp;
struct item_head s_ih; /* Item header. */
char c_mode; /* Returned mode of the balance. */
- struct buffer_head * p_s_un_bh;
int need_research;
@@ -1099,8 +1093,8 @@ static char prepare_for_delete_or_cut(
// note: path could be changed, first line in for loop takes care
// of it
/* a trick. If the buffer has been logged, this
@@ -1182,28 +1130,6 @@ static char prepare_for_delete_or_cut(
*/
reiserfs_restore_prepared_buffer(p_s_sb, p_s_bh);
- if ( n_retry ) {
- /* There is block in use. Wait, they should release it soon */
-
- RFALSE( *p_n_removed >= n_unfm_number, "PAP-5290: illegal case");
-#ifdef CONFIG_REISERFS_CHECK
- if ( !(++n_repeat_counter % 500000) ) {
- reiserfs_warning("PAP-5300: prepare_for_delete_or_cut: (pid %u): "
- "could not delete item %k in (%d) iterations. New file length %Lu. (inode %Ld), Still trying\n",
- current->pid, p_s_item_key, n_repeat_counter, n_new_file_length, inode->i_size);
- if (n_repeat_counter == 5000000) {
- print_block (PATH_PLAST_BUFFER(p_s_path), 3,
- PATH_LAST_POSITION (p_s_path) - 2, PATH_LAST_POSITION (p_s_path) + 2);
- reiserfs_panic(p_s_sb, "PAP-5305: prepare_for_delete_or_cut: key %k, new_file_length %Ld",
- p_s_item_key, n_new_file_length);
- }
- }
-#endif
-
- run_task_queue(&tq_disk);
- current->policy |= SCHED_YIELD;
- schedule();
- }
/* This loop can be optimized. */
} while ( (*p_n_removed < n_unfm_number || need_research) &&
search_for_position_by_key(p_s_sb, p_s_item_key, p_s_path) == POSITION_FOUND );