On Wed, Aug 22, 2012 at 4:35 PM, Hefty, Sean <[email protected]> wrote:
> I'm haven't identified the specific problem with fork support, but I did see 
> this in libmlx4:
>
> mlx4_alloc_context()
> {
>         ...
>         context->uar = mmap(NULL, to_mdev(ibdev)->page_size, PROT_WRITE,
>                             MAP_SHARED, cmd_fd, 0);
>         if (context->uar == MAP_FAILED)
>                 goto err_free;
>
>         if (resp.bf_reg_size) {
>                 context->bf_page = mmap(NULL, to_mdev(ibdev)->page_size,
>                                         PROT_WRITE, MAP_SHARED, cmd_fd,
>                                         to_mdev(ibdev)->page_size);
>         ...
> }
>
> I don't know for certain that these mmap() calls cause an issue, but the 
> preload library socket() function calls rsocket(), which loads and 
> initializes libibverbs.  This calls mlx4_alloc_context() before fork() has 
> been called.

I don't think those mmap()s should be an issue with fork.... they are
mapping adapter PCI space into userspace, but it should work across
fork.

 - R.
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to