[PATCH v2 00/11] common: introduce bthreads, co-operative
Ahmad Fatoum
a.fatoum at pengutronix.de
Wed Mar 3 13:58:10 GMT 2021
Hello Stafford,
On 03.03.21 13:15, Stafford Horne wrote:
> On Mon, Mar 01, 2021 at 12:00:55PM +0100, Ahmad Fatoum wrote:
>> Hello,
>>
>> This is v2 of barebox coroutine support:
>> https://lists.infradead.org/pipermail/barebox/2021-February/035032.html
>>
>> As discussed with Sascha, if this is to be added, this should be added for
>> all architectures and not be optional. If we have this as integral part,
>> it means we can substitute coroutines for:
>> - pollers: just wrap the code in a loop
>> - async pollers: just call a delay function in the loop
>> - workqueues: assert_command_context yields until in command context
>>
>> In addition, we will have much less work porting over threaded code from
>> Linux. See the referenced series for an example of a USB mass storage
>> gadget.
>>
>> To prepare for replacing them, the functionality is renamed to
>> bthreads (as in barebox threads) and is made separate from pollers.
>>
>> How to add new architecture support:
>>
>> - Apply this series or check out https://github.com/a3f/barebox/tree/bthread
>
> Now that I got a dev environment booting off master I have switched to your
> bthread branch. I found there is already a commit to remove openrisc in next.
>
> I will revert this in my branch.
Yes, please revert.
> Is there a timeframe you aim to have this all done?
I hoped it would be ready by middle of march, so it can go into next
before v2020.03.0, but no hurry. I can make it optional and withhold
adding code depending on bthreads until all architectures have support.
> Also, It seems networking it not working for me that is ok for the work here,
> but it will be something I have to look into next for OpenRISC.
Can't help here unfortunately. I haven't actually used this platform.
Cheers,
Ahmad
>
> -Stafford
>
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
More information about the barebox
mailing list