lkml.org 
[lkml]   [2005]   [Oct]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH2 6/6] isicom: More whitespaces and coding style
On 10/10/05, Jiri Slaby <jirislaby@gmail.com> wrote:
> On 10/10/05, Dmitry Torokhov <dtor_core@ameritech.net> wrote:
> > On Sunday 09 October 2005 14:42, Jiri Slaby wrote:
> > > More whitespaces and coding style
> > >
> > > Wrap all the code to 80 chars on a line.
> > > Some `}\nelse' changed to `} else'.
> > > Clean whitespaces in header file.
> > >
> > > Generated in 2.6.14-rc2-mm2 kernel version
> > >
> > > Signed-off-by: Jiri Slaby <xslaby@fi.muni.cz>
> > >
> > > ---
> > > drivers/char/isicom.c | 148 +++++++++++++++++++++++-------------------------
> > > include/linux/isicom.h | 21 +++----
> > > 2 files changed, 82 insertions(+), 87 deletions(-)
> > >
> > > diff --git a/drivers/char/isicom.c b/drivers/char/isicom.c
> > > --- a/drivers/char/isicom.c
> > > +++ b/drivers/char/isicom.c
> > > @@ -467,33 +467,36 @@ static void isicom_tx(unsigned long _dat
> > > residue = NO;
> > > wrd = 0;
> > > while (1) {
> > > - cnt = min_t(int, txcount, (SERIAL_XMIT_SIZE - port->xmit_tail));
> > > + cnt = min_t(int, txcount, (SERIAL_XMIT_SIZE
> > > + - port->xmit_tail));
> >
> > I am sorry but do you really consider the new form more readable?
> Yes, on the terminal it seems much more better than here and than before.
> But if you have some better idea how to do it, tell us and I will apply it.

At the minimum you could break at the last comma and not in the middle
of expression.

You could also take that block of code and split it to isicom_tx(),
isicom_port_tx() and isicom_chunk_tx(). That would save you couple if
identation levels and allow you to keep the code readable within 80
columns.

Just out of curiosity - was it run through Lindent or reformatted by
hand? The thing is - it might be not readable at 80 columns but I
could expand my terminal and get a decent results. Now it may be
better at 80 columns but no level of resizing terminal will make it
better.

--
Dmitry
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-10-10 16:56    [W:0.042 / U:0.144 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site