> +       /* First pause all related threaded processes */
> +       if (dump_threads)       {
> +               suspend_threads();
> +       }
> +       
> +       /* now stop all vm operations */
> +       down_write(¤t->mm->mmap_sem);
> +       segs = current->mm->map_count;
> +
Stopping all vm operations means that copy_{to,from}_user can cause
deadlocks.
ia64 needs copy_to_user in their stack unwind handler, IIRC called by
ELF_CORE_COPY_REGS.
Afaics you don't handle that. You must dump all thread state before
down_write(mmap_sem). And I don't see how you protect against 2 threads
of one process calling suspend_threads() simultaneously.
-- Manfred - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/