[PATCHES] Fix PPP in libbsd and optimize ATSAM console

Christian MAUDERER christian.mauderer at embedded-brains.de
Mon Sep 27 08:24:43 UTC 2021


Hello,

same like for another patch set: There is a pending discussion for this one.

Chris: Back when I posted the patch set you mentioned that you are not 
entirely happy about it in a discord chat (about 17.08.2021 6:50 in UTC 
time zone). Is there still an open point left of can I push the patches?

Best regards

Christian

Am 12.08.21 um 13:41 schrieb Christian Mauderer:
> Hello,
> 
> this set of patches fixes PPP. Basically the current implementation in
> libbsd can't work with console drivers that can't buffer a lot of
> characters. The pppstart() function just assumes that the low level
> console write can send an arbitrary number of characters without
> checking how many characters are actually send.
> 
> In the extreme case of the ATSAM interfaces (only one character can be
> send at once) it's not even possible to establish a PPP connection with
> that. For UARTS that have some FIFO establishing might work but bigger
> packets won't go through. I opened tickets for 6 and 5 here:
> 
> https://devel.rtems.org/ticket/4493
> https://devel.rtems.org/ticket/4494
> 
> I would like to apply the patches to both branches (5 and 6).
> 
> The solution I implemented in this patch set is the following: PPP
> output processing is done in the line discipline function l_start (or
> rather the function where l_start points to: pppstart). Our device
> writes don't return how many characters have been sent. Instead, that
> feedback is given via rtems_termios_dequeue(). Luckily that's the
> function that calls the l_start function.
> 
> The RTEMS patch for termios extends the l_start function so that it gets
> the number of characters as a second argument. This extension shouldn't
> be a problem for existing code. In the worst case it will trigger a
> warning that the function doesn't match the pointer type. But in the
> linked code, that additional argument will just be ignored.
> 
> The libbsd patch extends the pppstart function so that it then handles
> that new information.
> 
> Patches belonging to this set:
> * [PATCH rtems 1/2] bsps/atsam: Improve UART / USART tx performance
> * [PATCH rtems 2/2] termios: Pass number of sent chars to l_start
> * [PATCH rtems-libbsd] ppp: Fix transmitting data
> 
> Best regards
> 
> Christian
> 

-- 
--------------------------------------------
embedded brains GmbH
Herr Christian MAUDERER
Dornierstr. 4
82178 Puchheim
Germany
email: christian.mauderer at embedded-brains.de
phone: +49-89-18 94 741 - 18
fax:   +49-89-18 94 741 - 08

Registergericht: Amtsgericht München
Registernummer: HRB 157899
Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler
Unsere Datenschutzerklärung finden Sie hier:
https://embedded-brains.de/datenschutzerklaerung/


More information about the devel mailing list