mirror of
https://github.com/ceph/ceph
synced 2025-01-19 09:32:00 +00:00
Merge pull request #25404 from ptozys/master
async/dpdk: when enable dpdk, multiple message queue defect Reviewed-by: Haomai Wang <haomai@xsky.com>
This commit is contained in:
commit
b88de88059
@ -258,13 +258,14 @@ void DPDKStack::spawn_worker(unsigned i, std::function<void ()> &&func)
|
|||||||
// cores
|
// cores
|
||||||
ceph_assert(rte_lcore_count() >= i + 1);
|
ceph_assert(rte_lcore_count() >= i + 1);
|
||||||
unsigned core_id;
|
unsigned core_id;
|
||||||
|
int j = i;
|
||||||
RTE_LCORE_FOREACH_SLAVE(core_id) {
|
RTE_LCORE_FOREACH_SLAVE(core_id) {
|
||||||
if (i-- == 0) {
|
if (i-- == 0) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
dpdk::eal::execute_on_master([&]() {
|
dpdk::eal::execute_on_master([&]() {
|
||||||
r = rte_eal_remote_launch(dpdk_thread_adaptor, static_cast<void*>(&funcs[i]), core_id);
|
r = rte_eal_remote_launch(dpdk_thread_adaptor, static_cast<void*>(&funcs[j]), core_id);
|
||||||
if (r < 0) {
|
if (r < 0) {
|
||||||
lderr(cct) << __func__ << " remote launch failed, r=" << r << dendl;
|
lderr(cct) << __func__ << " remote launch failed, r=" << r << dendl;
|
||||||
ceph_abort();
|
ceph_abort();
|
||||||
|
Loading…
Reference in New Issue
Block a user