lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Thu, 15 Nov 2012 16:30:57 -0800
From:	Joe Perches <joe@...ches.com>
To:	Markus Grabner <grabner@....tugraz.at>
Cc:	Dan Carpenter <dan.carpenter@...cle.com>,
	Stefan Hajnoczi <stefanha@...il.com>,
	devel@...verdev.osuosl.org, line6linux-devel@...ts.sourceforge.net,
	linux-kernel@...r.kernel.org, Daniel Mack <zonque@...il.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Subject: Re: [PATCH 1/8] staging: line6: wrap >80 char lines in capture.c

On Fri, 2012-11-16 at 00:43 +0100, Markus Grabner wrote:
> On Thursday 15 November 2012 14:12:31 Joe Perches wrote:
> > On Thu, 2012-11-15 at 22:03 +0100, Markus Grabner wrote:
> > > Am Mittwoch, 14. November 2012, 17:33:05 schrieb Dan Carpenter:
> > > > The reason this is hitting the 80 character limit is because
> > > > "LINE6_INDEX_PCM_ALSA_CAPTURE_STREAM" is 35 characters long.  It
> > > > isn't even clear from the name what it holds.  It's just a very crap
> > > > name.
> > > 
> > > Please refer to the file pcm.h for a detailed documentation of this and
> > > similar names (in fact, the documentation explains the LINE6_BIT_PCM_*
> > > names instead, but I bevlieve the correspondence is obvious). It's hard
> > > to define a shorter name which is at the same time descriptive,
> > > consistent, and not to be confused with related names.
> > > 
> > > Should such documentation be moved to a separate file (e.g.,
> > > "Documentation/sound/alsa/line6usb.txt")?
> > 
> > Documenting poor naming choices doesn't make it better.
> Yes, but the documentation might help understanding why a particular naming 
> was chosen and that it might not be as poor as it seemed at first sight. I 
> assume that you are aware of the meaning of the LINE6_INDEX_PCM_* symbols (and 
> of the issues that were fixed by introducing them), so which naming scheme 

Hi Markus

Dunno why they were introduced, but I think
several things could be shorter as to me
none of these longish L6_BIT(foo) elements
means much and I'd need to read the code
to figure them out anyway.

the LINE6_ prefix is excessive,
L6_ would probably be fine.
(and that goes for all the functions too)

CAPTURE/RECORD could be RD/WR
MONITOR could be MON
IMPULSE could be IRM

BUFFER could be I
STREAM could be O
(or the other way 'round)

etc..., cheers, Joe

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ