All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Hurley <peter@hurleysoftware.com>
To: Ulrich Hecht <ulrich.hecht+renesas@gmail.com>,
	linux-sh@vger.kernel.org, linux-serial@vger.kernel.org
Cc: horms@verge.net.au, magnus.damm@gmail.com,
	Greg KH <gregkh@linuxfoundation.org>,
	One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>
Subject: Re: [RFC 0/3] serial: sh-sci: SCIF FIFO exploitation
Date: Wed, 17 Sep 2014 16:49:56 +0000	[thread overview]
Message-ID: <5419BBB4.5090802@hurleysoftware.com> (raw)
In-Reply-To: <1410511908-9282-1-git-send-email-ulrich.hecht+renesas@gmail.com>

[ +cc GregKH, Alan ]

Hi Uli,

On 09/12/2014 04:51 AM, Ulrich Hecht wrote:
> Hi!
> 
> The current sh-sci implementation doesn't exploit the RX FIFOs at all and
> has the chip issue an interrupt for every byte received.  This series
> implements the necessary changes to improve that.

Just a general note about the use of the words exploit and exploitation.
In common usage, 'exploit' has become synonymous with 'misuse'.

Perhaps a better choice would be 'utilize' and 'utilization'?

> It includes a sysfs interface for changing the FIFO trigger level; there
> seem to be few drivers that implement something like that (I only found
> one), so I'd like to know if this implementation is palatable.

The method to extend the sysfs interface for a specific device is in
linux-next. The original was proposed by Greg and reworked by
Yoshihiro YUNOMAE; see commit 266dcff03eed0050b6af11aaf2a61ab837d7ba3f,
'Serial: allow port drivers to have a default attribute group' and
commit aef9a7bd9b676f797dd5cefd43deb30d36b976a9,
'serial/uart/8250: Add tunable RX interrupt trigger I/F of FIFO buffers'
for how to use the default attribute group.

OTOH, I like your sysfs attribute name, rx_trigger_level, better than
the new 8250 attribute name, rx_trig_bytes. In one sense Greg was right;
the coming explosion of different device attributes with different handling
behavior is going to suck.

Regards,
Peter Hurley

On a side note: why is there so little locking in the sh-sci driver?
Is it uniprocessor?

> CU
> Uli
> 
> 
> Ulrich Hecht (3):
>   serial: sh-sci: consider DR (data ready) bit adequately
>   serial: sh-sci: exploit RX FIFOs better
>   serial: sh-sci: make RX FIFO trigger tunable via sysfs
> 
>  drivers/tty/serial/sh-sci.c | 113 ++++++++++++++++++++++++++++++++++++++++++--
>  drivers/tty/serial/sh-sci.h |   5 ++
>  include/linux/serial_sci.h  |   2 +
>  3 files changed, 116 insertions(+), 4 deletions(-)
> 


WARNING: multiple messages have this Message-ID (diff)
From: Peter Hurley <peter@hurleysoftware.com>
To: Ulrich Hecht <ulrich.hecht+renesas@gmail.com>,
	linux-sh@vger.kernel.org, linux-serial@vger.kernel.org
Cc: horms@verge.net.au, magnus.damm@gmail.com,
	Greg KH <gregkh@linuxfoundation.org>,
	One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk>
Subject: Re: [RFC 0/3] serial: sh-sci: SCIF FIFO exploitation
Date: Wed, 17 Sep 2014 12:49:56 -0400	[thread overview]
Message-ID: <5419BBB4.5090802@hurleysoftware.com> (raw)
In-Reply-To: <1410511908-9282-1-git-send-email-ulrich.hecht+renesas@gmail.com>

[ +cc GregKH, Alan ]

Hi Uli,

On 09/12/2014 04:51 AM, Ulrich Hecht wrote:
> Hi!
> 
> The current sh-sci implementation doesn't exploit the RX FIFOs at all and
> has the chip issue an interrupt for every byte received.  This series
> implements the necessary changes to improve that.

Just a general note about the use of the words exploit and exploitation.
In common usage, 'exploit' has become synonymous with 'misuse'.

Perhaps a better choice would be 'utilize' and 'utilization'?

> It includes a sysfs interface for changing the FIFO trigger level; there
> seem to be few drivers that implement something like that (I only found
> one), so I'd like to know if this implementation is palatable.

The method to extend the sysfs interface for a specific device is in
linux-next. The original was proposed by Greg and reworked by
Yoshihiro YUNOMAE; see commit 266dcff03eed0050b6af11aaf2a61ab837d7ba3f,
'Serial: allow port drivers to have a default attribute group' and
commit aef9a7bd9b676f797dd5cefd43deb30d36b976a9,
'serial/uart/8250: Add tunable RX interrupt trigger I/F of FIFO buffers'
for how to use the default attribute group.

OTOH, I like your sysfs attribute name, rx_trigger_level, better than
the new 8250 attribute name, rx_trig_bytes. In one sense Greg was right;
the coming explosion of different device attributes with different handling
behavior is going to suck.

Regards,
Peter Hurley

On a side note: why is there so little locking in the sh-sci driver?
Is it uniprocessor?

> CU
> Uli
> 
> 
> Ulrich Hecht (3):
>   serial: sh-sci: consider DR (data ready) bit adequately
>   serial: sh-sci: exploit RX FIFOs better
>   serial: sh-sci: make RX FIFO trigger tunable via sysfs
> 
>  drivers/tty/serial/sh-sci.c | 113 ++++++++++++++++++++++++++++++++++++++++++--
>  drivers/tty/serial/sh-sci.h |   5 ++
>  include/linux/serial_sci.h  |   2 +
>  3 files changed, 116 insertions(+), 4 deletions(-)
> 


  parent reply	other threads:[~2014-09-17 16:49 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-12  8:51 [RFC 0/3] serial: sh-sci: SCIF FIFO exploitation Ulrich Hecht
2014-09-12  8:51 ` Ulrich Hecht
2014-09-12  8:51 ` [RFC 1/3] serial: sh-sci: consider DR (data ready) bit adequately Ulrich Hecht
2014-09-12  8:51   ` Ulrich Hecht
2014-09-12  8:51 ` [RFC 2/3] serial: sh-sci: exploit RX FIFOs better Ulrich Hecht
2014-09-12  8:51   ` Ulrich Hecht
2014-09-12  8:51 ` [RFC 3/3] serial: sh-sci: make RX FIFO trigger tunable via sysfs Ulrich Hecht
2014-09-12  8:51   ` Ulrich Hecht
2014-09-17 16:49 ` Peter Hurley [this message]
2014-09-17 16:49   ` [RFC 0/3] serial: sh-sci: SCIF FIFO exploitation Peter Hurley

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=5419BBB4.5090802@hurleysoftware.com \
    --to=peter@hurleysoftware.com \
    --cc=gnomes@lxorguk.ukuu.org.uk \
    --cc=gregkh@linuxfoundation.org \
    --cc=horms@verge.net.au \
    --cc=linux-serial@vger.kernel.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    --cc=ulrich.hecht+renesas@gmail.com \
    /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.