Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop pthreads #15

Merged
merged 2 commits into from
Aug 25, 2019
Merged

Drop pthreads #15

merged 2 commits into from
Aug 25, 2019

Conversation

ukleinek
Copy link
Contributor

This finally gets rid of the dependency to pthreads.

This is a restructuring without any intended side effect. The motivation
is that this way telnet handling can go to telnet.c and so only affect
telnet connections. Similar for can this should allow to get rid of the
pipe and pthread stuff.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
@lgtm-com
Copy link

lgtm-com bot commented Jun 14, 2019

This pull request introduces 2 alerts and fixes 1 when merging 59a8088 into 141c575 - view on LGTM.com

new alerts:

  • 2 for Comparison result is always the same

fixed alerts:

  • 1 for Local variable hides global variable

Since there are ios specific read and write callbacks the needed overhead
for can transfers can be implemented in these which makes the separate
thread superfluous. This simplifies the can driver considerably.

As a consequence microcom doesn't need pthreads any more and the
respective changes in configure.ac can go away, too. The configuration
for lgtm which assert that the AX_PTHREAD macro is available can be
dropped and the travis configuration can be simplified accordingly.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Closes: pengutronix#8
@lgtm-com
Copy link

lgtm-com bot commented Jun 14, 2019

This pull request fixes 1 alert when merging dc0d7aa into 141c575 - view on LGTM.com

fixed alerts:

  • 1 for Local variable hides global variable

Copy link
Member

@a3f a3f left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With the nitpicks addressed:

Reviewed-by: Ahmad Fatoum <a.fatoum@pengutronix.de>

can.c Show resolved Hide resolved
can.c Show resolved Hide resolved
can.c Show resolved Hide resolved
can.c Show resolved Hide resolved
@ukleinek ukleinek requested a review from a3f August 25, 2019 21:43
Copy link
Member

@a3f a3f left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, Reviewed-by: Ahmad Fatoum <a.fatoum@pengutronix.de>.

A follow up patch removing the EINTR checks would be nice as well.

@ukleinek
Copy link
Contributor Author

I don't have the complete picture about your EINTR remark yet. Will open a separate issue for it.

@ukleinek ukleinek merged commit dc0d7aa into pengutronix:master Aug 25, 2019
@ukleinek ukleinek deleted the droppthreads branch August 28, 2019 17:41
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.

2 participants