From: Ryan Raasch <ryan.raasch@gmail.com>
To: ofono@ofono.org
Subject: Re: [PATCH] When setting the serial port, the previous settings need to be preserved.
Date: Tue, 20 Oct 2009 17:51:20 +0200 [thread overview]
Message-ID: <4ADDDC78.8030605@gmail.com> (raw)
In-Reply-To: <200910201013.52644.denkenz@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1077 bytes --]
Denis Kenzior wrote:
> Hi Ryan,
>
>> Sorry. I have had a long few days. The last patch was just COMPLETELY
>> wrong :(
>>
>> I think i got it right this time...
>
> So the patch is still wrong :)
>
> memset(&ti, 0, sizeof(ti));
> cfmakeraw(&ti);
>
> + fd = open(tty, O_RDWR | O_NOCTTY | O_NONBLOCK);
> + if (fd < 0)
> + return -1;
> +
> + tcgetattr(fd,&ti);
> +
>
> You're blowing away the result of cfmakeraw. Most of the devices are not true
> serial devices and so do not need any of the special options. Passing a NULL
> options GHashTable should result in cfmakeraw. Why don't you just pass all
> the options you need instead of using tcgetattr?
>
Should i just move the tcgetattr() to happen before cfmakeraw()?
> The other parts of the patch look good to me.
Ok. Why don't i just add the string options ("read", others...) in gattty.c?
Thanks,
Ryan
>
> Regards,
> -Denis
> _______________________________________________
> ofono mailing list
> ofono(a)ofono.org
> http://lists.ofono.org/listinfo/ofono
next prev parent reply other threads:[~2009-10-20 15:51 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-19 14:28 [PATCH] When setting the serial port, the previous settings need to be preserved Ryan Raasch
2009-10-19 17:32 ` Denis Kenzior
2009-10-20 7:43 ` Ryan Raasch
2009-10-20 9:10 ` Ryan Raasch
2009-10-20 15:13 ` Denis Kenzior
2009-10-20 15:51 ` Ryan Raasch [this message]
2009-10-20 15:36 ` Denis Kenzior
2009-10-21 8:43 ` Ryan Raasch
2009-10-22 0:09 ` Denis Kenzior
-- strict thread matches above, loose matches on Subject: below --
2009-10-19 17:18 Ryan Raasch
2009-10-19 17:21 ` Ryan Raasch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4ADDDC78.8030605@gmail.com \
--to=ryan.raasch@gmail.com \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox