mciupak / nrf24

nrf24l01 linux device driver
GNU General Public License v3.0
23 stars 13 forks source link

nrf0_rx_thread using 100% cpu #8

Closed edillmann closed 5 years ago

edillmann commented 5 years ago

Hi,

The nrf0_rx_thread is using 100% cpu, shouldn't RX be IRQ driven ?

Regards, Eric

sergey-suloev commented 5 years ago

@edillmann It already is, by the way. The RX thread sleeps waiting for the event which arrives from the ISR.

mciupak commented 5 years ago

Yes, it is interrupt/event driven with wait queues, so it should not use 100%, unless there is something wrong...

What does debug dmesg say when it hits 100% cpu?

Unfortunate;y I do not have an access to working setup now so I cannot check this. @sergey-suloev do you have maybe a working setup and if so could you please check cpu usage of rx thread?

sergey-suloev commented 5 years ago

@mciupak I don't have either. But when I was testing it (about 2-3 mon ago) there was NO 100% usage. Never. My test environment was an Allwinner H3-based board, kernel 4.20.

mciupak commented 5 years ago

Neither I haven't seen such behavior.

@edillmann Please share more details regarding you build and setup. And dmesg logs as well. There is also status register printed to dmesg if you read it via sysfs.