Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1229520
| From | Tilman Schmidt <tilman@imap.cc> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset |
| Date | 2015-09-21 18:10 +0200 |
| Message-ID | <qbbPd-38F-37@gated-at.bofh.it> (permalink) |
| References | (5 earlier) <q99ya-68w-3@gated-at.bofh.it> <q9j4u-31b-25@gated-at.bofh.it> <q9LWP-38s-43@gated-at.bofh.it> <qa37l-2Hb-45@gated-at.bofh.it> <qb9aH-7Hp-27@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
[Multipart message — attachments visible in raw view] - view raw
Am 21.09.2015 um 15:13 schrieb Peter Hurley: > On 09/18/2015 08:38 AM, Tilman Schmidt wrote: >> Am 17.09.2015 um 20:13 schrieb Peter Hurley: [...] >>> So for example, if you manually set N_PPP (as if by user error) >> >> User error wouldn't suffice, as the LD would get reset to N_TTY when the >> serial device is closed. You would have to write a program that >> deliberately switched the LD first to N_PPP and then to N_GIGASET_M101 >> without closing the device in between. > > ??? > > The tool you authored will do it from the command line > > $ ldattach PPP /dev/ttyS1 > $ ldattach GIGASET_M101 /dev/ttyS1 > > Note that nothing here closes the serial device 'in between', and > the tty core has switched directly from PPP to GIGASET_M101. > n_tty->receive_room is now 64K. Indeed it does. I stand corrected. The possibility of running ldattach a second time without terminating the first instance didn't occur to me. > Please add switching from line disciplines other than N_TTY to your > regression testing. I don't do regression tests for the driver anymore since I stepped down as a maintainer, so that would be up to the present maintainer of ser_gigaset. But I see no reason for that. As I already explained, N_TTY is the only problematic case. >>> and then set this line discipline, tty->receive_room will be 64K, not 4K. >> >> That wouldn't affect the operation of ser_gigaset, > > I've explained this before to you, but here it is again: > > tty->receive_room announces the maximum amt of data the line discipline > can accept from tty core with each call to its receive_buf() method (for > line disciplines that don't provide flow control). > > If the line discipline sets ->receive_room to 64K but can only handle > 8K (as in the case of GIGASET_M101), then data loss should be the expected > result. If you'd care to look at the actual code you'd notice that it truly won't make any difference. The receive_buf() method of ser_gigaset is prepared to drop data and log an error when its receive buffer overflows, no matter how big the block of data passed from tty core is. The only difference a smaller ->receive_room value might possibly make is to distribute the overflowing data to more receive_buf() calls. (Note that the Gigaset M101 device operates at 115200 bits/sec max. so it takes at least 700 msecs to transmit 8k bytes. If we ever get into a situation where tty core actually accumulates more than that amount of data before forwarding it to GIGASET_M101 then we have a more serious problem anyway.) Again, I won't oppose applying this patch to stable releases before 3.10. I just don't see the need, so it would be up to you to advocate such a request. -- Tilman Schmidt E-Mail: tilman@imap.cc Bonn, Germany Diese Nachricht besteht zu 100% aus wiederverwerteten Bits. Ungeöffnet mindestens haltbar bis: (siehe Rückseite)
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 3.12 01/33] mfd: lpc_ich: Assign subdevice ids automatically Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 06/33] ip_tunnel: fix ipv4 pmtu check to honor inner ip header df Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 27/33] bio: fix argument of __bio_add_page() for max_sectors > 0xffff Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 23/33] rds: fix an integer overflow test in rds_info_getsockopt() Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 09/33] net: pktgen: fix race between pktgen_thread_worker() and kthread_stop() Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 15/33] bridge: mdb: fix double add notification Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 03/33] ipv6: Make MLD packets to only be processed locally Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 21/33] netlink: don't hold mutex in rcu callback when releasing mmapd ring Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 25/33] cifs: Send a logoff request before removing a smb session Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 30/33] netfilter: nf_conntrack: fix RCU race in nf_conntrack_find_get Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 33/33] PCI: Add VPD function 0 quirk for Intel Ethernet devices Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 28/33] dm cache mq: fix memory allocation failure for large cache devices Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 26/33] lpfc: Fix scsi prep dma buf error. Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 31/33] netfilter: nf_conntrack: don't release a conntrack with non-zero refcnt Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 29/33] aio: fix reqs_available handling Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 32/33] PCI: Add dev_flags bit to access VPD through function 0 Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 24/33] mtip32xx: dynamically allocate buffer in debugfs functions Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:30 +0200
[PATCH 3.12 18/33] bonding: fix destruction of bond with devices different from arphrd_ether Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 19/33] bonding: correct the MAC address for "follow" fail_over_mac policy Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 11/33] net: call rcu_read_lock early in process_backlog Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 20/33] inet: frags: fix defragmented packet's IP header for af_packet Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 05/33] rtnetlink: verify IFLA_VF_INFO attributes before passing them to driver Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 10/33] net: do not process device backlog during unregistration Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 07/33] net/tipc: initialize security state for new connection socket Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 12/33] net: Clone skb before setting peeked flag Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 04/33] net: graceful exit from netif_alloc_netdev_queues() Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 08/33] bridge: mdb: zero out the local br_ip variable before use Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 14/33] net: Fix skb_set_peeked use-after-free bug Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 13/33] net: Fix skb csum races when peeking Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 17/33] ipv6: lock socket in ip6_datagram_connect() Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Tilman Schmidt <tilman@imap.cc> - 2015-09-16 02:40 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Peter Hurley <peter@hurleysoftware.com> - 2015-09-16 03:20 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Tilman Schmidt <tilman@imap.cc> - 2015-09-16 13:30 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Peter Hurley <peter@hurleysoftware.com> - 2015-09-17 20:20 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Tilman Schmidt <tilman@imap.cc> - 2015-09-18 14:40 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Peter Hurley <peter@hurleysoftware.com> - 2015-09-21 15:20 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Tilman Schmidt <tilman@imap.cc> - 2015-09-21 15:40 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Peter Hurley <peter@hurleysoftware.com> - 2015-09-21 19:00 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Tilman Schmidt <tilman@imap.cc> - 2015-09-21 19:40 +0200
Re: [PATCH 3.12 16/33] isdn/gigaset: reset tty->receive_room when attaching ser_gigaset Tilman Schmidt <tilman@imap.cc> - 2015-09-21 18:10 +0200
[PATCH 3.12 22/33] net/mlx4_core: Fix wrong index in propagating port change event to VFs Jiri Slaby <jslaby@suse.cz> - 2015-09-15 16:50 +0200
[PATCH 3.12 02/33] drm/radeon: fix hotplug race at startup Jiri Slaby <jslaby@suse.cz> - 2015-09-15 17:00 +0200
csiph-web