From: Denis Kenzior <denkenz@gmail.com>
To: ofono@ofono.org
Subject: Re: [PATCH 3/5] test-server: Add PPP server support
Date: Thu, 01 Jul 2010 09:00:57 -0500 [thread overview]
Message-ID: <4C2C9F99.1070003@gmail.com> (raw)
In-Reply-To: <33AB447FBD802F4E932063B962385B351F681664@shsmsx501.ccr.corp.intel.com>
[-- Attachment #1: Type: text/plain, Size: 1391 bytes --]
Hi Zhenhua,
>> static void server_destroy(gpointer user)
>> @@ -706,15 +825,11 @@ static void server_destroy(gpointer user)
>>
>> static void set_raw_mode(int fd)
>> {
>> - struct termios options;
>> -
>> - tcgetattr(fd,&options);
>> -
>> - /* Set TTY as raw mode to disable echo back of input characters
>> - * when they are received from Modem to avoid feedback loop */
>> - options.c_lflag&= ~(ICANON | ECHO | ECHOE | ISIG); + struct
>> termios ti;
>>
>> - tcsetattr(fd, TCSANOW,&options);
>> + tcflush(fd, TCIOFLUSH);
>> + cfmakeraw(&ti);
>> + tcsetattr(fd, TCSANOW,&ti);
>> }
>>
>> static gboolean create_tty(const char *modem_path)
>
> I found above changes does not contain latest git tree. The part of change is necessary when I tried to use bluetooth serial proxy between two machines. Without cfmakeraw, the server responses:
> '\r\nOK\r\n'
> would change to:
> '\n\nOK\n\n'
>
> And this issue doesn't exist if both server and client on the same machine.
The above code was causing valgrind to complain, so I left it out,
apologies for not mentioning it, had a bit of a filesystem disaster
happen after I pushed :)
The present code seems to be completely in line with man cfmakeraw. The
cause is probably more subtle or has to do with the RFCOMM tty layer in
the kernel. Could you please investigate some more?
Regards,
-Denis
next prev parent reply other threads:[~2010-07-01 14:00 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-25 3:19 [PATCH 0/5] Add PPP server support Zhenhua Zhang
2010-06-25 3:19 ` [PATCH 1/5] gatppp: Add PPP server extension Zhenhua Zhang
2010-06-25 3:19 ` [PATCH 2/5] atmodem: Fix GAtPPPConnectFunc interface change Zhenhua Zhang
2010-06-25 3:19 ` [PATCH 3/5] test-server: Add PPP server support Zhenhua Zhang
2010-06-25 3:19 ` [PATCH 4/5] test-server: Configure network interface Zhenhua Zhang
2010-06-25 3:19 ` [PATCH 5/5] gsmdial: Configure network interface for PPP Zhenhua Zhang
2010-06-30 9:43 ` [PATCH 3/5] test-server: Add PPP server support Zhang, Zhenhua
2010-07-01 14:00 ` Denis Kenzior [this message]
2010-07-02 3:11 ` Zhang, Zhenhua
2010-07-06 6:23 ` Zhang, Zhenhua
-- strict thread matches above, loose matches on Subject: below --
2010-06-21 9:47 [PATCH 2/5] atmodem: Fix GAtPPPConnectFunc interface change Zhenhua Zhang
2010-06-21 9:48 ` [PATCH 3/5] test-server: Add PPP server support Zhenhua Zhang
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=4C2C9F99.1070003@gmail.com \
--to=denkenz@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.