Move active clients mask to an atomic uint64_t in shared memory.
Previously, the active_consumer_bit_mask_ was a private member of producer channel for creating new consumer buffers with unique buffer_state_bit_ so that newly added consumer can be uniquely identified amoung its siblings. It was a union of all consumer's buffer_state_bit_. In the re-design of buffer state, every consumer/producer/client buffers need to know the location of every other consumer/producer/client in buffer_state in order to post a buffer: when a client posts a buffer, it changes its own buffer_state to 00 and others' buffer_state to 10. Thus, it need to know where the other siblings locates in buffer_state atomic uint64_t. active_consumer_bit_mask_ suffices this need. This change moves the active_consumer_bit_mask_ from producer channel to an uint64_t atomic variable in shared memory, and rename it as active_clients_bit_mask_ (because it contain both consumers and producers buffer_state_bit). Test: marlin-eng on master branch Test: vega_xr-eng on oc-dr1-daydream-dev branch Test: buffer_hub-test buffer_hub_queue-test buffer_hub_queue_producer-test Bug: 112007999 Change-Id: I1ae562701545c7504fd9367c8c8c63a2fd609264
Loading
Please register or sign in to comment