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]
Message-Id: <20110320103503.8de522d1.rdunlap@xenotime.net>
Date:	Sun, 20 Mar 2011 10:35:03 -0700
From:	Randy Dunlap <rdunlap@...otime.net>
To:	Arne Jansen <lists@...-jansens.de>
Cc:	Jeffrin Jose <ahiliation@...oo.co.in>,
	Greg Kroah-Hartman <gregkh@...e.de>,
	linux-kernel@...r.kernel.org
Subject: Re: aligning with spaces [was: Re: format fixes]

On Sun, 20 Mar 2011 14:39:13 +0100 Arne Jansen wrote:

> On 20.03.2011 11:45, Jeffrin Jose wrote:
> > I have created a patch with fixes and format
> > error by replacing spaces with tabs.
> 
> The CodingStyle guide seems to me a big vague on this topic, but
> checkpatch.pl has a clear idea of what is right and wrong. But
> the formerly present indentation seems to me totally valid.

AFAICT, the patch replaces 8 spaces with 1 tab.  That's a good change
IMO, except that the patch does not apply to linux-next 2011-0318.
I can't tell if the patch was made against an earlier tree or a later one.
In either case, it looks like this particular printk has probably already
been fixed by some other patch.

> Use tab to indent to the current indentation level, then continue
> with spaces for the alignment of broken-up lines. This has a
> few advantages. One of them is that the code still looks neat with
> a different tab size (of course, no one ever does that). Another is,
> that editing is easier if you change the name of the function and
> with it the needed alignment for the following lines.
> If we really require using tabs as much as possible for aligning, we
> should also _only_ use tabs for it and require e.g. 2 tabs for
> broken-up lines.
> In fact, the example in CodingStyle uses only tabs and does not try
> to align the double quotes of the broken-up string with each other.

We accept patches either way, but it mostly depends on (a) the
current/surrounding code and (b) the maintainer who is merging the patches.

CodingStyle may be vague on all of this.  It's easy to be ambiguous or
vague in language, even when you try not to be.


---
~Randy
*** Remember to use Documentation/SubmitChecklist when testing your code ***
--
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