[PATCH 1/1] PM / hibernate: memory_bm_find_bit -- tighten node optimisation

2019-09-25 Thread Andy Whitcroft
expected fallout. Ensure the zone we are scanning matches the cached zone before considering the cached node. Deep thanks go to Andrea for many, many, many hours of hacking and testing that went into cornering this bug. Reported-by: Andrea Righi Tested-by: Andrea Righi Signed-off-by: Andy Whitcroft

Re: [PATCH] checkpatch.pl: Improve WARNING on Kconfig help

2018-12-19 Thread Andy Whitcroft
On Wed, Dec 19, 2018 at 02:44:36AM -0800, Joe Perches wrote: > On Wed, 2018-12-19 at 10:35 +0200, Igor Stoppa wrote: > > The checkpatch.pl script complains when the help section of a Kconfig > > entry is too short, but it doesn't really explain what it is looking > > for. Instead, it gives a generi

Re: [PATCH] floppy: Do not copy a kernel pointer to user memory in FDGETPRM ioctl

2018-05-29 Thread Andy Whitcroft
here. As we already have an inparam union with an appropriate member and that memory is already cleared even for read only calls make use of that as a temporary store. Based on an initial patch by Brian Belleville. CVE-2018-7755 Signed-off-by: Andy Whitcroft --- drivers/block/floppy.c | 2 ++

[tip:x86/pti] x86/speculation, objtool: Annotate indirect calls/jumps for objtool on 32-bit kernels

2018-03-14 Thread tip-bot for Andy Whitcroft
Commit-ID: a14bff131108faf50cc0cf864589fd71ee216c96 Gitweb: https://git.kernel.org/tip/a14bff131108faf50cc0cf864589fd71ee216c96 Author: Andy Whitcroft AuthorDate: Wed, 14 Mar 2018 11:24:27 + Committer: Ingo Molnar CommitDate: Wed, 14 Mar 2018 13:24:31 +0100 x86/speculation

[PATCH 1/1] x86/speculation, objtool: Annotate indirect calls/jumps for objtool on 32bit

2018-03-14 Thread Andy Whitcroft
In 9e0e3c5130e9 ("x86/speculation, objtool: Annotate indirect calls/jumps for objtool") we added annotations for CALL_NOSPEC/JMP_NOSPEC on x86 64bit. We did not annotate the 32bit path. Annotate it similarly. Signed-off-by: Andy Whitcroft --- arch/x86/include/asm/nospec-branch.h |

Re: checkpatch potential false positive

2017-11-06 Thread Andy Whitcroft
On Mon, Nov 06, 2017 at 03:19:14PM +1100, Tobin C. Harding wrote: > Hi, > > When parsing drivers/staging/unisys/visorbus/visorchipset.c in Greg's > staging tree checkpatch emits > > -- > visorchipset.c > -- > WARNING: char * array declaration might be better as static cons

Re: Linux 4.12-rc6

2017-06-20 Thread Andy Whitcroft
On Tue, Jun 20, 2017 at 4:42 AM, Dave Jones wrote: > Almost shutdown, but not quite. Coincidentally, coverity just finished > the rc6 run, and barfed this up.. related ? > > *** CID 1412907: Control flow issues (DEADCODE) > /include/linux/mm.h: 2243 in vm_end_gap() > 2237 > 2238 static in

[Acked] [PATCH] checkpatch: Warn on embedded function names

2017-01-03 Thread Andy Whitcroft
p;& > + get_quoted_string($line, $rawline) =~ > /\b$context_function\b/) { > + WARN("EMBEDDED_FUNCTION_NAME", > + "Prefer using \"%s\", __func__ to embedded > function names\n" . $herecurr); > + } > + > # check for spaces before a quoted newline > if ($rawline =~ /^.*\".*\s\\n/) { > if (WARN("QUOTED_WHITESPACE_BEFORE_NEWLINE", > -- > 2.10.0.rc2.1.g053435c > Looks sane enough to me. Acked-by: Andy Whitcroft -apw

Re: [PATCH 1/1] checkpatch: remove false warning for commit reference

2016-10-24 Thread Andy Whitcroft
On Mon, Oct 24, 2016 at 11:39:45AM -0700, Joe Perches wrote: > On Mon, 2016-10-24 at 19:22 +0200, Heinrich Schuchardt wrote: > > On 10/23/2016 10:37 PM, Joe Perches wrote: > > > On Sun, 2016-10-23 at 09:34 +0200, Heinrich Schuchardt wrote: > > > > Checkpatch warns of an incorrect commit reference s

[PATCH 1/1 V2] dm raid: fix compat_features validation

2016-10-11 Thread Andy Whitcroft
>From a30fba068e41214cb0ffcb14e68722482765e0c9 Mon Sep 17 00:00:00 2001 From: Andy Whitcroft Date: Tue, 11 Oct 2016 15:16:57 +0100 In ecbfb9f118bce4 ("dm raid: add raid level takeover support") a new compatible feature flag was added. Validation for these compat_features was added

Re: [dm-devel] [PATCH 1/1] dm raid: fix compat_features validation

2016-10-11 Thread Andy Whitcroft
On Tue, Oct 11, 2016 at 05:04:34PM +0200, Heinz Mauelshagen wrote: > > Andy, > > good catch. > > We should rather check for V190 support only in case any > compat feature flags are actually set. > > { > + if (le32_to_cpu(sb->compat_features) && > + le32_to_cpu(sb->compat_featur

[PATCH 1/1] dm raid: fix compat_features validation

2016-10-11 Thread Andy Whitcroft
at import. Check compat_features for any valid combinations. Fixes: ecbfb9f118bce4 ("dm raid: add raid level takeover support") BugLink: http://bugs.launchpad.net/bugs/1631298 Signed-off-by: Andy Whitcroft --- drivers/md/dm-raid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) It

Re: [PATCH] checkpatch: Improve 'bare use of' signed/unsigned types warning

2016-07-26 Thread Andy Whitcroft
> m{\b($Declare)\s*(?!char\b|short\b|int\b|long\b)\s*($Ident)?\s*[=,;\[\)\(]}g) > { > my $type = $1; > my $var = $2; > $var = "" if (!defined $var); > -- > 2.8.0.rc4.16.g56331f8 > Derp, yes. Acked-by: Andy Whitcroft -apw

Re: [PATCH] checkpatch: Yet another commit id improvement

2016-07-21 Thread Andy Whitcroft
On Tue, Jul 19, 2016 at 03:05:56AM -0700, Joe Perches wrote: > On Tue, 2016-07-19 at 10:51 +0100, Andy Whitcroft wrote: > > On Mon, Jul 18, 2016 at 12:27:42PM -0700, Joe Perches wrote: > > > > > > Using \b isn't good enough to isolate what appears to be a >

Re: [PATCH] checkpatch: Yet another commit id improvement

2016-07-19 Thread Andy Whitcroft
On Mon, Jul 18, 2016 at 12:27:42PM -0700, Joe Perches wrote: > Using \b isn't good enough to isolate what appears to be a > commit id in a commit message. > > Make sure there is a space or a quote like character after > a continuous run of hexadecimal characters that could be > a commit id. > > S

Re: [PATCH v3 1/2] checkpatch: add Kconfig 'default n' test

2016-06-06 Thread Andy Whitcroft
On Mon, Jun 06, 2016 at 09:43:15AM -0700, Joe Perches wrote: > On Sat, 2016-06-04 at 13:10 +0800, Yingjoe Chen wrote: > > If a Kconfig config option doesn't specify 'default', the default > > will be n. Adding 'default n' is unnecessary. > > Add a test to warn about this. > > Is it obvious that a

Re: Fwd: [PATCH] mm: add config option to select the initial overcommit mode

2016-05-10 Thread Andy Whitcroft
On Tue, May 10, 2016 at 02:00:47PM +0200, Sebastian Frias wrote: > Hi, > > Using checkpatch.pl on the forwarded patch results in: > > WARNING: please write a paragraph that describes the config symbol fully > #57: FILE: mm/Kconfig:451: > + config OVERCOMMIT_GUESS > > WARNING: please write

Re: checkpatch false positon on EXPORT_SYMBOL

2016-04-12 Thread Andy Whitcroft
On Tue, Apr 12, 2016 at 10:49:17AM -0700, Joe Perches wrote: > > On Tue, 2016-04-12 at 13:59 +0100, Andy Whitcroft wrote: > > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl > [] > > @@ -3000,7 +3000,7 @@ sub process { > > > >  

Re: checkpatch false positon on EXPORT_SYMBOL

2016-04-12 Thread Andy Whitcroft
line. Basically inline comments should be considered as spaces for the purposes of determining the next line for this purpose. The following patch appears to sort this out. A quick scan says this entire next line calculation is still only used for the EXPORT* check so this should be low risk for other tests. This wo

Re: reinstate dm target local ioctl support

2016-01-29 Thread Andy Whitcroft
On Fri, Jan 29, 2016 at 01:57:12PM +, Alasdair G Kergon wrote: > On Thu, Jan 28, 2016 at 01:50:19PM +0000, Andy Whitcroft wrote: > > However this also removed the possibility of a dm target having target > > specific ioctls. Currently this is not used by any in-tree targ

reinstate dm target local ioctl support

2016-01-28 Thread Andy Whitcroft
the patch below in mainline to allow for such target local ioctls. -apw >From 3fa0480193b944dd97565364efe4df89414c250b Mon Sep 17 00:00:00 2001 From: Andy Whitcroft Date: Wed, 27 Jan 2016 16:05:32 + Subject: dm: introduce a target_ioctl op to allow target specific ioctls In e56f81e0b01e

Re: cgroup pids controller -- WARN_ON_ONCE triggering

2015-12-08 Thread Andy Whitcroft
On Tue, Dec 08, 2015 at 10:24:28AM -0500, Tejun Heo wrote: > Hello, Andy. > > On Tue, Dec 08, 2015 at 02:58:51PM +0000, Andy Whitcroft wrote: > > Converting this to a printk I was able to obtain confirmation that we are > > indeed seeing this go negative in some cases. &

cgroup pids controller -- WARN_ON_ONCE triggering

2015-12-08 Thread Andy Whitcroft
The commit below attempts to fix up pid controller charging: commit afcf6c8b75444382e0f9996157207ebae34a8848 Author: Tejun Heo Date: Thu Oct 15 16:41:53 2015 -0400 cgroup: add cgroup_subsys->free() method and use it to fix pids controller Since this change we are seeing system hangs

Re: [PATCH] scripts:checkpatch - correct the error message during check

2015-10-30 Thread Andy Whitcroft
On Fri, Oct 30, 2015 at 04:55:04PM +0530, shailendr...@samsung.com wrote: > From: Shailendra Verma > > Signed-off-by: Shailendra Verma > --- > scripts/checkpatch.pl | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.

Re: [PATCH 1/1] x509: only prefix strip raw serial numbers

2015-09-16 Thread Andy Whitcroft
On Tue, Sep 15, 2015 at 10:59:43AM +0100, David Howells wrote: > Andy Whitcroft wrote: > > > This leads us to truncate the id for kernel module signing keys and to > > fail to recognise our own modules: > > > > [1.572423] Loaded X.509 cert 'Build ti

Re: possible new false positive in checkpatch

2015-09-15 Thread Andy Whitcroft
On Tue, Sep 15, 2015 at 05:50:40PM +0300, Tal Shorer wrote: > > Yes it feels like that should be eliding them completely, and likely any > > following space as well, something like this: > > > > $s =~ s/$;+\s*//g; > > $c =~ s/$;+\s*//g; > > > Replacing the problematic lines with th

Re: possible new false positive in checkpatch

2015-09-14 Thread Andy Whitcroft
On Sat, Sep 12, 2015 at 03:13:31PM +0300, Tal Shorer wrote: > Since my last pull from upstream (today) , I started seeing some > checkpatch warnings regarding suspect code indent I believe are false > positive. Take this code for example: > > static int foo(void) > { > while (bar()) >

[PATCH 1/1] x509: only prefix strip raw serial numbers

2015-09-14 Thread Andy Whitcroft
p to raw serial number. Signed-off-by: Andy Whitcroft --- crypto/asymmetric_keys/x509_public_key.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) While we are here the prefix strip seems pretty odd, only removing just one 0 byte. Is this meant to strip them all (

[PATCH 1/1 V2] ipv4: off-by-one in continuation handling in /proc/net/route

2015-08-13 Thread Andy Whitcroft
e955cb9 ("fib_trie: Fib walk rcu should take a tnode and key instead of a trie and a leaf") BugLink: http://bugs.launchpad.net/bugs/1483440 Acked-by: Alexander Duyck Signed-off-by: Andy Whitcroft --- net/ipv4/fib_trie.c | 2 +- 1 file ch

[PATCH 1/1] ipv4: off-by-one in continuation handling in /proc/net/route

2015-08-13 Thread Andy Whitcroft
tp://bugs.launchpad.net/bugs/1483440 Signed-off-by: Andy Whitcroft --- net/ipv4/fib_trie.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) From code inspection I belive this was introduced by the Fixes below, but I have not tested this to confirm. Fixes: 8be33e955cb

[Acked] [PATCH] checkpatch: Add __pmem to $Sparse annotations

2015-08-07 Thread Andy Whitcroft
atch.pl > +++ b/scripts/checkpatch.pl > @@ -264,6 +264,7 @@ our $Sparse = qr{ > __kernel| > __force| > __iomem| > + __pmem| > __must_check| > _

Re: false positives with checkpatch

2015-08-07 Thread Andy Whitcroft
On Fri, Aug 07, 2015 at 08:37:47AM -0700, Joe Perches wrote: > On Fri, 2015-08-07 at 09:01 -0600, Ross Zwisler wrote: > > When running checkpatch.pl against my latest patch set, I hit what I think > > are > > two false positives. Here are the related lines: > > > > +static inline void flush_

Re: Checkpatch: False positive

2015-07-16 Thread Andy Whitcroft
On Thu, Jul 16, 2015 at 08:58:56AM -0700, Joe Perches wrote: > On Thu, 2015-07-16 at 16:43 +0100, Andy Whitcroft wrote: > > On Thu, Jul 16, 2015 at 08:35:58AM -0700, Joe Perches wrote: > > > > #31: > > > > arc

Re: Checkpatch: False positive

2015-07-16 Thread Andy Whitcroft
On Thu, Jul 16, 2015 at 08:35:58AM -0700, Joe Perches wrote: > > #31: > > arch/x86/kernel/hpet.c | 198 > > ++--- I guess those are in the limbo land between the end of message and beginning of the patch itself. Perhaps the test should at least stop a

[Acked] [PATCH V2] checkpatch: Make types found in a source file/patch local

2015-05-19 Thread Andy Whitcroft
warn "MODIFIER: $modifier ($possible) > ($line)\n" if ($dbg_possible); > - push(@modifierList, $modifier); > + push(@modifierListFile, $modifier); > } >

Re: [PATCH] checkpatch: types found in one source file do not affect processing of others

2015-05-18 Thread Andy Whitcroft
On Mon, May 18, 2015 at 03:33:29PM +0200, Alex Dowad wrote: > checkpatch uses various cues in its input files to discover the names of > user-defined types. It then uses that information when processing expressions, > to discover more style issues. > > Unfortunately, in rare cases, this means that

Re: [PATCH RFC] checkpatch: flag split arithmetic operations with CHECK

2015-05-05 Thread Andy Whitcroft
On Tue, May 05, 2015 at 10:53:36AM +0200, Nicholas Mc Guire wrote: > Simple arithmetic operations should be on one line, if they can be fit, > rather than splitting at the operator. As this is not in the CodingStyle it > is limited to --strict use of checkpatch.pl and emits a CHECK only. > > Sign

Re: [PATCH 1/1] pty, n_tty: continue processing input until the tty_buffer chain is flushed

2015-03-16 Thread Andy Whitcroft
On Mon, Mar 16, 2015 at 02:03:23PM -0400, Peter Hurley wrote: > I just managed to reproduce this problem with a test jig; > can you confirm that your self-tests also use >= 4096-byte read buffer > (which I think is necessary to trigger the worker race)? The read which triggers the EIO is indeed u

[PATCH 1/1] pty, n_tty: continue processing input until the tty_buffer chain is flushed

2015-03-16 Thread Andy Whitcroft
t processing on final close") BugLink: http://bugs.launchpad.net/bugs/1429756 Cc: # 3.19+ Signed-off-by: Andy Whitcroft --- drivers/tty/n_tty.c | 4 +++- drivers/tty/tty_buffer.c | 19 +++ include/linux/tty_flip.h | 2 ++ 3 files changed, 24 insertions(+), 1 deletion(-)

Re: [PATCH] checkpatch: remove unneeded or ("|")

2015-03-12 Thread Andy Whitcroft
On Thu, Mar 12, 2015 at 07:13:35AM -0700, Joe Perches wrote: > On Thu, 2015-03-12 at 15:07 +0100, Christian Borntraeger wrote: > > while porting commit 89a883530fe7 ("checkpatch: ## is not a valid > > modifier") to QEMU, Peter Maydell noticed that the | at the end of > > the list is not necessary.

arm64 -- psci tell the compiler in which registers we are expecting arguments

2015-01-23 Thread Andy Whitcroft
that when you enable mcount preables (-pg) these are altered and the compilation failed. Inform the compiler of these register requirements. BugLink: http://bugs.launchpad.net/bugs/1414002 Signed-off-by: Andy Whitcroft --- arch/arm64/kernel/psci.c | 18 ++ 1 file changed, 14

Re: [PATCH V3 1/1] Drivers: hv: vmbus: Fix a bug in vmbus_establish_gpadl()

2014-12-15 Thread Andy Whitcroft
On Sun, Dec 14, 2014 at 11:59:19PM -0800, Jeremiah Mahler wrote: > KY Srinivasan, > > On Mon, Dec 15, 2014 at 07:00:45AM +, KY Srinivasan wrote: > > > > > > > -Original Message- > > > From: Jeremiah Mahler [mailto:jmmah...@gmail.com] > > > Sent: Wednesday, December 10, 2014 6:10 PM >

Re: [PATCH] checkpatch: include text files in SPACE_BEFORE_TAB test

2014-12-08 Thread Andy Whitcroft
On Fri, Dec 05, 2014 at 09:45:37PM -0800, Frank Rowand wrote: > From: Frank Rowand > > git-am whined about a patch that I submitted for the Documentation > subtree, (https://lkml.org/lkml/2014/11/24/636) but checkpatch does > not. Make checkpatch just as whiney. > > This patch moves the SPACE_B

Re: How to cope with two incompatible overlayfs formats out in the wild

2014-11-18 Thread Andy Whitcroft
On Tue, Nov 18, 2014 at 03:28:03PM +0100, Miklos Szeredi wrote: > [CC-ing mailing lists, Al and Linus for wider exposure] > > This issue is this: Ubuntu and SUSE carry an "old" format of overlayfs > while mainline has a "new" format. The differences are: > > - whiteouts are represented differen

Re: [PATCH] checkpatch: fix use via symlink, make missing spelling file non-fatal

2014-10-24 Thread Andy Whitcroft
On Fri, Oct 24, 2014 at 02:31:50AM -0700, Joe Perches wrote: > On Fri, 2014-10-24 at 10:02 +0100, Andy Whitcroft wrote: > > On Thu, Oct 23, 2014 at 10:29:11AM -0700, Joe Perches wrote: > > > > [...] > > > my $P = $0; > > > -$P =~ s@(.*)/@@g; > > >

Re: [PATCH] checkpatch: fix use via symlink, make missing spelling file non-fatal

2014-10-24 Thread Andy Whitcroft
On Thu, Oct 23, 2014 at 10:29:11AM -0700, Joe Perches wrote: [...] > my $P = $0; > -$P =~ s@(.*)/@@g; > -my $D = $1; > +my $D = dirname(abs_path($P)); That changes the value of $P, I don't know if that is intended: my $D = dirname(abs_path($0)); or my $D = abs_path($1); perhaps to keep $

Re: [PATCH 0/3] checkpatch: Add missing c90 types

2014-07-18 Thread Andy Whitcroft
gt; Joe Perches (3): > checkpatch: Add short int to c variable types > checkpatch: Add signed generic types > checkpatch: Add test for native c90 types in unusual order > > scripts/checkpatch.pl | 61 > --- > 1 file changed, 53 i

Re: [PATCH] checkpatch: Add for_each tests to indentation and brace tests

2014-07-14 Thread Andy Whitcroft
> - if ($line =~ /\b(?:(?:if|while|for)\s*\(|do\b)/ && $line !~ > /^.\s*#/ && $line !~ /\}\s*while\s*/) { > + if ($line =~ > /\b(?:(?:if|while|for|(?:[a-z_]+|)for_each[a-z_]+)\s*\(|do\b)/ && $line !~ > /^.\s*#/ && $line !~ /\}\s*while\

Re: [PATCH] checkpatch: Emit a warning on file add/move/delete

2014-07-04 Thread Andy Whitcroft
ED_PATCH", That seems like a sensible plan. Sometime we might try and work out if any entries are affected or needed. I think you are checking against the git ways of mentioning this only, don't know if there is any milage in checking the dates which also convey add/remove info via datea at t

Re: [PATCH] checkpatch: Enable whitespace checks for DTS files

2014-06-30 Thread Andy Whitcroft
On Mon, Jun 30, 2014 at 11:53:31AM +0200, Geert Uytterhoeven wrote: > When run on *.dtsi or *.dts files, the whitespace checks were skipped, > while they are valid for DTS files. Hence stop skipping them. > > I ran checkpatch on all in-tree DTS files, and didn't notice any error or > warning mess

ACPI resource change triggers loss of serial ports

2014-06-19 Thread Andy Whitcroft
Zhang's case I wonder if this check could be tightened up to cover only the zero base, something like the (untested) patch below. -apw [1] https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1313981 >From e5211c68278387ef65e483bcfedd5581a79ec783 Mon Sep 17 00:00:00 2001 From: Andy Whitcro

Re: [PATCH] [checkpatch.pl] ctx_statement_block #if/#else/#endif fix

2014-06-11 Thread Andy Whitcroft
On Wed, Jun 11, 2014 at 10:57:11AM +0100, Andy Whitcroft wrote: > Signed-off-by: Andy Whitcroft With your permissions I'll add a Reported-by: etc to this patch in your name. -apw -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a

Re: [PATCH] [checkpatch.pl] ctx_statement_block #if/#else/#endif fix

2014-06-11 Thread Andy Whitcroft
On Wed, Jun 11, 2014 at 10:16:40AM +0100, Andy Whitcroft wrote: > It doesn't seem right to remove the restore of the state. If you > consider the effect of an #if/#else/#endif combination the state of the > statement parser should be reset to the state at #if at the #else as the &

Re: [PATCH] [checkpatch.pl] ctx_statement_block #if/#else/#endif fix

2014-06-11 Thread Andy Whitcroft
On Thu, May 15, 2014 at 04:43:15PM +0200, Ivo Sieben wrote: > When picking up a complete statement block #if/#else/#endif prepocesor > boundaries are taken into account by pushing current level & type on a stack. > But on an #else the level was read from stack again (without actually popping > it

Re: [RFC] quiet checkpatch style recommendation about no spaces around bitfield :

2014-04-03 Thread Andy Whitcroft
On Mon, Mar 31, 2014 at 01:56:28PM -0700, Andrew Morton wrote: > On Mon, 31 Mar 2014 08:31:38 -0700 Joe Perches wrote: > > > > > @@ -143,13 +143,13 @@ union cvmx_usbcx_gahbcfg { > > > > * * 1'b1: Unmask the interrupt assertion to the > > > > application. > > > > */ > > > >

Hyper-V balloon memory hotplug deadlock?

2014-03-14 Thread Andy Whitcroft
We are seeing machines lockup with what appears to be an ABBA deadlock in the memory hotplug system. These are from the 3.13.6 based Ubuntu kernels. The hv_balloon driver is adding memory using add_memory() which takes the hotplug lock, and then emits a udev event, and then attempts to lock the sy

Re: [PATCH] x86: dma-mapping: fix GFP_ATOMIC macro usage

2014-01-17 Thread Andy Whitcroft
On Fri, Jan 17, 2014 at 8:46 AM, Marek Szyprowski wrote: > GFP_ATOMIC is not a single gfp flag, but a macro which expands to the other > flags and LACK of __GFP_WAIT flag. To check if caller wanted to perform an > atomic allocation, the code must test __GFP_WAIT flag presence. This patch > fixes t

Re: [PATCH v3] checkpatch: add DT compatible string documentation checks

2013-12-06 Thread Andy Whitcroft
e/bindings. Vendor prefixes > > are also checked for existing in vendor-prefixes.txt These should be > > temporary checks until we have more sophisticated binding schema checking. > > > > Signed-off-by: Rob Herring > > Cc: Grant Likely > > Cc: Andy

Re: [PATCH] - add "fixpae" bootparam to fix/workaround #930447

2013-11-29 Thread Andy Whitcroft
On Wed, Nov 27, 2013 at 09:41:03PM +0100, Roland wrote: > This patch is meant primarly for ubuntu, as they only ship PAE > enabled kernels and don`t ship non-PAE kernels anymore. So this > resolves an ubuntu specific problem (as the installer disc also has > PAE enabled kernel). > > I know it`s n

Re: [PATCH] doc: fix generation of device-drivers

2013-11-26 Thread Andy Whitcroft
Acked-by: Andy Whitcroft -apw -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

[PATCH 1/1] xen-netback: include definition of csum_ipv6_magic

2013-11-25 Thread Andy Whitcroft
&ipv6h->saddr, Signed-off-by: Andy Whitcroft --- drivers/net/xen-netback/netback.c | 1 + 1 file changed, 1 insertion(+) Found while trying to couple latest kernels for arm64 platforms. Looks like it got missed in the transition. -apw diff --git a/drivers/net/xen-netback/netback.

Re: False positive in checkpatch

2013-09-24 Thread Andy Whitcroft
Thanx, Paul > How about this one, it is a bit of a hack but does at least correctly correct the formal characterisation of the operator to unary. Working on getting this tested a bit better before sending it out formally. -apw >From 5b4e22c123b3492838d1218112

Re: False positive in checkpatch

2013-09-24 Thread Andy Whitcroft
On Mon, Sep 23, 2013 at 09:21:07PM -0700, Joe Perches wrote: > On Mon, 2013-09-23 at 15:59 -0700, Paul E. McKenney wrote: > > Hello! > > > > The checkpatch.pl script complains as follows: > > > > ERROR: need consistent spacing around '*' (ctx:WxB) > > #57: FILE: include/linux/rcupdate.h:564: > >

Re: [PATCH 0/4] Hyper-V TRIM support

2013-09-13 Thread Andy Whitcroft
On Fri, Sep 13, 2013 at 07:57:58AM -0700, James Bottomley wrote: > This is an awful lot of contortions (which don't seem to have any other > users on the horizon) to support a device that's not standards > compliant. What about this, it's simple, it does the right thing and > it's contained in th

[PATCH 3/4] scsi: hyper-v storage -- mark as VPD capable at SPC-2

2013-09-13 Thread Andy Whitcroft
BugLink: http://bugs.launchpad.net/bugs/1223499 Signed-off-by: Andy Whitcroft --- drivers/scsi/storvsc_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c index 1a28f56..14ba8fd 100644 --- a/drivers/scsi/storvsc_drv.c +++ b/drivers

[PATCH 4/4] scsi: hyper-v storage -- mark as preferring READ CAPACITY (16) at SPC-2

2013-09-13 Thread Andy Whitcroft
BugLink: http://bugs.launchpad.net/bugs/1223499 Signed-off-by: Andy Whitcroft --- drivers/scsi/storvsc_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c index 14ba8fd..25e7dd5 100644 --- a/drivers/scsi/storvsc_drv.c +++ b/drivers

[PATCH 0/4] Hyper-V TRIM support

2013-09-13 Thread Andy Whitcroft
. Patches against v3.11. Comments? -apw Andy Whitcroft (4): scsi: add scsi device flag to request VPD pages be used at SPC-2 scsi: add scsi device flag to request READ CAPACITY (16) be preferred scsi: hyper-v storage -- mark as VPD capable at SPC-2 scsi: hyper-v storage -- mark as preferring READ

[PATCH 2/4] scsi: add scsi device flag to request READ CAPACITY (16) be preferred

2013-09-13 Thread Andy Whitcroft
BugLink: http://bugs.launchpad.net/bugs/1223499 Signed-off-by: Andy Whitcroft --- drivers/scsi/sd.c | 2 ++ include/scsi/scsi_device.h | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index 5a8a04d..eba4d6c 100644 --- a/drivers/scsi/sd.c +++ b

[PATCH 1/4] scsi: add scsi device flag to request VPD pages be used at SPC-2

2013-09-13 Thread Andy Whitcroft
present. Add a scsi quirk bit to allow those devices to hint we can and should try these VPD pages. BugLink: http://bugs.launchpad.net/bugs/1223499 Signed-off-by: Andy Whitcroft --- drivers/scsi/sd.c | 6 +- include/scsi/scsi_device.h | 1 + 2 files changed, 6 insertions(+), 1 deletion

[PATCH 1/1] ext4: fix ext4_get_group_number() at cluster boundaries

2013-07-11 Thread Andy Whitcroft
blocks of the boundary (1 block in my failing example). Fix up the calculations to match. BugLink: http://bugs.launchpad.net/bugs/1195710 Signed-off-by: Andy Whitcroft --- fs/ext4/balloc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) While it seems clear this must be correc

Re: [PATCH 2/2] overlayfs -- follow change to do_splice_direct interface

2013-06-27 Thread Andy Whitcroft
On Thu, Jun 27, 2013 at 06:37:45PM +0200, Miklos Szeredi wrote: > Thanks for the patches, Andy. I already pushed a similar set of fixes > to overlayfs.current (.v18) and to .v17 for the dentry_open() refcount > fix. Bah so you did, that'll teach me for waiting for them to be tested. > It is inte

[PATCH 1/1] overlayfs -- ovl_path_open should not take path reference

2013-06-27 Thread Andy Whitcroft
Author: Al Viro Date: Tue Jun 26 21:58:53 2012 +0400 switch dentry_open() to struct path, make it grab references itself BugLink: http://bugs.launchpad.net/bugs/1098378 Signed-off-by: Andy Whitcroft --- fs/overlayfs/super.c | 1 - 1 file changed, 1 deletion(-) Found this

[PATCH 1/2] vfs: export do_splice_direct() to modules -- fix

2013-06-27 Thread Andy Whitcroft
to: vfs: export do_splice_direct() to modules.] Signed-off-by: Andy Whitcroft --- fs/internal.h | 6 -- include/linux/fs.h | 6 ++ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/internal.h b/fs/internal.h index 6dd0ffd..6c9ec69 100644 --- a/fs/internal.h +++ b/fs/in

[PATCH 0/3] overlayfs fixes for v3.8 and later base

2013-06-27 Thread Andy Whitcroft
Following this email are three patches against overlayfs.v17 which allow it to work against v3.10-rc6 and later. With these applied overlayfs passes basic testing. overlayfs -- ovl_path_open should not take path reference Found this in testing on Ubuntu raring, testing against loopback m

[PATCH 2/2] overlayfs -- follow change to do_splice_direct interface

2013-06-27 Thread Andy Whitcroft
The commit below changed the interface to do_splice_direct, follow that change in copy_up: commit 7995bd287134f6c8f80d94bebe7396f05a9bc42b Author: Al Viro Date: Thu Jun 20 18:58:36 2013 +0400 splice: don't pass the address of ->f_pos to methods Signed-off-by: Andy W

[PATCH 1/1] UBUNTU: SAUCE: ubuntu: overlayfs -- ovl_path_open should not take path reference

2013-06-22 Thread Andy Whitcroft
Author: Al Viro Date: Tue Jun 26 21:58:53 2012 +0400 switch dentry_open() to struct path, make it grab references itself BugLink: http://bugs.launchpad.net/bugs/1098378 Signed-off-by: Andy Whitcroft --- fs/overlayfs/super.c | 1 - 1 file changed, 1 deletion(-) Found this

Re: [PATCH 097/102] efivars: explicitly calculate length of VariableName

2013-04-17 Thread Andy Whitcroft
On Wed, Apr 17, 2013 at 12:37:43PM +0800, Lingzhu Xiang wrote: > On 04/16/2013 06:33 PM, Luis Henriques wrote: > >68d929862e29a8b52a7f2f2f86a0600423b093cd efi: be more paranoid about > >available space when creating variables > > This prevents a bricking issue for some Samsung devices but causes

Re: checkpatch: kill the bogus camelcase check

2013-04-10 Thread Andy Whitcroft
On Tue, Apr 09, 2013 at 02:50:54PM -0700, James Bottomley wrote: > It's making checkpatch unusable on most drivers because it's spewing > tons of bogus warnings. The problem is the assumption that studly caps > is always wrong: it isn't if the variables are named after the various > conventions in

Re: [PATCH] checkpatch: Warn on comparisons to true and false

2013-04-10 Thread Andy Whitcroft
On Wed, Apr 10, 2013 at 04:27:51AM -0700, Joe Perches wrote: > like > 0 == foo > instead of > foo == 0 > > there were _way_ too many false positives of > the $Expression sort that I didn't add that test. Makes sense then as it is. Thanks. -apw -- To unsubscribe from this list: send

Re: [PATCH] checkpatch: Warn on comparisons to true and false

2013-04-10 Thread Andy Whitcroft
On Tue, Apr 09, 2013 at 08:17:14PM -0700, Joe Perches wrote: > Comparisons of A to true and false are better written > as A and !A. > > Bleat a message on use. > > Signed-off-by: Joe Perches > --- > scripts/checkpatch.pl | 17 + > 1 file changed, 17 insertions(+) > > diff --git

Re: x86/mm/pageattr: Code without effect?

2013-04-08 Thread Andy Whitcroft
On Sat, Apr 06, 2013 at 04:58:04PM +0200, Andrea Arcangeli wrote: > You're right, so this location clearly didn't trigger the problem so I > didn't notice the noop here. I only exercised the fix in the other > locations of the file that had the same problem. > > It was a noop, so it really couldn

Re: [PATCHv2 1/1] checkpatch: adding Suggested-by as standard signature

2013-03-28 Thread Andy Whitcroft
On Thu, Mar 28, 2013 at 12:58:22PM +0530, Mugunthan V N wrote: > --- a/scripts/checkpatch.pl > +++ b/scripts/checkpatch.pl > @@ -281,6 +281,7 @@ our $signature_tags = qr{(?xi: > Tested-by:| > Reviewed-by:| > Reported-by:| > + Suggested-by:| > To:| > Cc: > )}; Lo

Re: [PATCH] checkpatch: Warn on unnecessary __dev section markings

2013-01-03 Thread Andy Whitcroft
} > + > # Check for potential 'bare' types > my ($stat, $cond, $line_nr_next, $remain_next, $off_next, > $realline_next); That looks simple enough. Acked-by: Andy Whitcroft -apw -- To unsubscribe from this list: send the line "unsubs

Re: [PATCH] checkpatch: prefer dev_( to dev_printk(KERN_

2013-01-03 Thread Andy Whitcroft
On Wed, Jan 02, 2013 at 04:06:34PM -0800, Joe Perches wrote: > Add YA check to printk style. > > dev_ uses are functions and generate smaller > object code than dev_printk(KERN_. > > Signed-off-by: Joe Perches > --- > scripts/checkpatch.pl | 10 ++ > 1 file changed, 10 insertions(+) >

Re: [PATCH V2] checkpatch: Warn on uapi #includes that #include

2012-12-19 Thread Andy Whitcroft
ROR("UAPI_INCLUDE", > + "No #include in ...include/uapi/... > should use a uapi/ path prefix\n" . $herecurr); > } > } > Looks reasonable indeed. Acked-by: Andy Whitcroft -apw -- To unsub

Re: checkpatch.pl and assembly #defines

2012-12-04 Thread Andy Whitcroft
On Tue, Dec 04, 2012 at 04:59:23AM -0800, Paul E. McKenney wrote: > Hello, Andy, > > The current checkpatch.pl complains about cpp macros defined as follows: > > #define callit call my_function > > Of course, if you do put parentheses around the definition, your assembler > will complain. Could

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 01:58:48PM -0800, Joe Perches wrote: > +# check for multiple blank lines, warn only on the second one in a block > + if ($rawline =~ /^.\s*$/ && > + $prevrawline =~ /^.\s*$/ && > + $linenr != $last_blank_linenr + 1) { > +

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 07:32:49PM +, Andy Whitcroft wrote: > On Tue, Nov 20, 2012 at 09:10:35PM +0200, Eilon Greenstein wrote: > > > About the logic - true, if diff will show deleted lines after newly > > added lines, some new double line segments will be missed. However,

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 09:10:35PM +0200, Eilon Greenstein wrote: > About the logic - true, if diff will show deleted lines after newly > added lines, some new double line segments will be missed. However, it > seems like few other things will break if diff will start acting out > like that. The s

[PATCH V2] checkpatch: consolidate if (foo) bar(foo) checks and add debugfs_remove

2012-11-20 Thread Andy Whitcroft
Consolidate the if (foo) bar(foo) detectors into a single check. Add debugfs_remove and family. Based on a patch by Constantine Shulyupin . Signed-off-by: Andy Whitcroft --- scripts/checkpatch.pl | 20 ++-- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a

Re: [PATCH] checkpatch: consolidate if (foo) bar(foo) checks and add debugfs_remove

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 07:51:17AM -0800, Joe Perches wrote: > On Tue, 2012-11-20 at 15:37 +0000, Andy Whitcroft wrote: > > Consolidate the if (foo) bar(foo) detectors into a single check. Add > > debugfs_remove and family. > > > > Based on a patch by Constantine Shul

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 06:22:24PM +0200, Eilon Greenstein wrote: > On Tue, 2012-11-20 at 16:14 +0000, Andy Whitcroft wrote: > > On Tue, Nov 20, 2012 at 06:06:10PM +0200, Eilon Greenstein wrote: > > > I'm only testing the nextline if the current line is newly added. If I >

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 04:14:17PM +, Andy Whitcroft wrote: > On Tue, Nov 20, 2012 at 06:06:10PM +0200, Eilon Greenstein wrote: > > I'm only testing the nextline if the current line is newly added. If I > > got it right, when a line is newly added, the next line can be: >

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 06:06:10PM +0200, Eilon Greenstein wrote: > I'm only testing the nextline if the current line is newly added. If I > got it right, when a line is newly added, the next line can be: > a. another new line > b. existing line (provided for context) > c. Does not exist since this

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 05:07:07PM +0200, Eilon Greenstein wrote: > On Tue, 2012-11-20 at 14:43 +0000, Andy Whitcroft wrote: > > > > > Also this fails if the fragment > > > > is at the top of the hunk emiting a perl warning. > > > > > > I did

[PATCH] checkpatch: consolidate if (foo) bar(foo) checks and add debugfs_remove

2012-11-20 Thread Andy Whitcroft
Consolidate the if (foo) bar(foo) detectors into a single check. Add debugfs_remove and family. Based on a patch by Constantine Shulyupin . Signed-off-by: Andy Whitcroft --- scripts/checkpatch.pl | 20 1 file changed, 8 insertions(+), 12 deletions(-) This is a fully

Re: [PATCH v4] checkpatch: debugfs_remove() can take NULL

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 05:10:43PM +0200, Constantine Shulyupin wrote: > On Tue, Nov 20, 2012 at 4:58 PM, Joe Perches wrote: > > I don't think it's an issue. I'm not sure anyone > > really uses --ignore for much other than LONG_LINE. > > Indeed. Must all code be 80 characters width? My be my be

Re: [PATCH v4] checkpatch: debugfs_remove() can take NULL

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 06:43:49AM -0800, Joe Perches wrote: > On Tue, 2012-11-20 at 14:29 +0000, Andy Whitcroft wrote: > > > This all looks sensible, though we still have three blocks doing the > > same thing. How about we standardise this check into a single check, > >

Re: [PATCH v2] checkpatch: add double empty line check

2012-11-20 Thread Andy Whitcroft
On Tue, Nov 20, 2012 at 04:27:04PM +0200, Eilon Greenstein wrote: > On Tue, 2012-11-20 at 11:52 +0000, Andy Whitcroft wrote: > > Andy, thanks for reviewing this patch. > > > On Sat, Nov 17, 2012 at 01:17:37PM +0200, Eilon Greenstein wrote: > > > Changes from previo

Re: [PATCH v4] checkpatch: debugfs_remove() can take NULL

2012-11-20 Thread Andy Whitcroft
} > } > > # prefer usleep_range over udelay This all looks sensible, though we still have three blocks doing the same thing. How about we standardise this check into a single check, generating the capacity from the matched name. Something like the below

  1   2   3   4   5   >