Fork us on GitHub Follow us on Google+ Follow us on Facebook Follow us on Twitter

Opened 6 years ago

Last modified 13 months ago

#508 new defect

Parallel sessions don't mix well with call forwarding

Reported by: Jakub Jermář Owned by: Jakub Jermář
Priority: major Milestone:
Component: helenos/lib/c Version: mainline
Keywords: sessions Cc:
Blocker for: Depends on:
See also: #393

Description

As of mainline,1739, there appear to be two problems with parallel sessions:

  • devman_device_connect(EXCHANGE_PARALLEL, ...) works only by accident
  • devman_parent_device_connect(EXCHANGE_PARALLEL, ...) does not work at all

The fundamental issue here is that the first session phone gets created as a result of forwarding the IPC_M_CONNECT_ME_TO call through devman, which applies some transformations to it prior to forwarding it further along to the destination driver. In contrast, all additional phones are cloned from the first one, which is already directly connected to the respective driver, using the remembered original session arguments. The problem here is that in this latter case, the arguments don't go through the same set of transformations as in the former case.

As a result of this, devman_device_connect() works only because the device handle is still passed unmodified as ARG2 and both the translated and unmodified methods accidentally lead to the same behaviour. On the other hand, devman_parent_device_connect() will fail on the first attempt to clone the original session phone because the numeric value of the original method (i.e. DEVMAN_CONNECT_TO_PARENTS_DEVICE) is not recognized by libdrv's driver_connection(), which in turn returns ENOENT. In addition, the handle does not get translated as is necessary, which would also likely make the function fail.

Change History (4)

comment:1 Changed 6 years ago by Jakub Jermář

I think I am hitting the same issue with loc_service_connect() when the exchange management is EXCHANGE_PARALLEL.

comment:2 Changed 6 years ago by Jiri Svoboda

See also: #393

comment:3 Changed 4 years ago by Jakub Jermář

Milestone: 0.6.00.7.1

comment:4 Changed 13 months ago by Jakub Jermář

Milestone: 0.7.1
Note: See TracTickets for help on using tickets.