Skip to content

Fix tasklet_schedule should run with thread_softirqd#24

Closed
mlouielu wants to merge 1 commit intoPikoRT:masterfrom
mlouielu:fix-tasklet-schedule
Closed

Fix tasklet_schedule should run with thread_softirqd#24
mlouielu wants to merge 1 commit intoPikoRT:masterfrom
mlouielu:fix-tasklet-schedule

Conversation

@mlouielu
Copy link
Contributor

@mlouielu mlouielu commented Aug 18, 2017

This close #12. For discussion, please look comment in #12 .

@iankuan
Copy link
Member

iankuan commented Aug 18, 2017

@mlouielu , it might not fix this issue. tasklet_schedule would be only called by someone who wants to enqueue softirq task and trigger softirq handler which is trigger via rasie_softirq. It might be quite similar with Linux.

In our softirq design, it only handles softirqs in thread_softirqd. After this change, it might be failed timer task because it can't trigger softirq_handler. In short, thread_softirqd is a softirq handler, and it doesn't need to call tasklet_schedule.

@mlouielu
Copy link
Contributor Author

The problem here isn't thread_softirqd, is thread_main, which will call tasklet_scheudle (but this is illegal). I think the root cause came from bitmap scheduler (due to the lake of rr scheudler, I can't test on it), but this patch can get an easy fixed so that we won't get other error when playing around minishell.

@jserv
Copy link
Member

jserv commented Aug 19, 2017

@mlouielu, I just wonder if the proposed fix got verified for both RR and bitmap scheduler policy yet. I defer to the analysis of @yenwu since he is hacking sched internals.

@mlouielu
Copy link
Contributor Author

#29 propose a correct fixed.

@mlouielu mlouielu closed this Aug 22, 2017
@mlouielu mlouielu deleted the fix-tasklet-schedule branch August 22, 2017 04:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

minishell when typing, easily execute code outside RAM or ROM on stm32p103

3 participants

Comments